-
Notifications
You must be signed in to change notification settings - Fork 9.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
embed pdf.ttf to tesseract library #2551 #3194
Conversation
We could also create |
This would requires additional multi-platforms tool - just for build. I think easier is to provide generated file (without removing pdf.ttf). |
Yes, |
Personally I do not see any benefit from this (maybe I miss something): instead of final and tested header file you propose to include script (that we do not have)?. I prefer possibility to build tesseract with minimal extra dependencies. To install python (perl?) just to generate one small file is IMO overkill. I prefer to adjust "final product" instead of tweaking script - e.g. my first commit work for me on windows (clang, msvs) and linux (opensuses), but appveyor and travis were not happy with it... |
Both ways have their advantages and disadvantages. This specific file does not change very often, so I think it's fine to go with the manually generated way. |
Thanks! :-) |
@@ -623,24 +625,21 @@ bool TessPDFRenderer::BeginDocumentHandler() { | |||
|
|||
stream.str(""); | |||
stream << datadir_.c_str() << "/pdf.ttf"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be cleaner to remove the code for reading pdf.ttf
and remove that file from installations, too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I leave it there if somebody would like to adapt and test pdf.ttf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be sufficient to enable that feature only for DEBUG
code? For most users (and that includes all Linux distributions) installing pdf.ttf
is not necessary, and I'd prefer to remove it from the normal installation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think using it in DEBUG code only it good idea.
No description provided.