mirror of
https://github.com/pdf2htmlEX/pdf2htmlEX.git
synced 2024-12-22 13:00:08 +00:00
use correct metric when use cropbox; fixes 110
This commit is contained in:
parent
88c18d56d6
commit
c24e10064c
@ -73,6 +73,10 @@ public:
|
||||
// Does this device need non-text content?
|
||||
virtual GBool needNonText() { return (param->process_nontext) ? gTrue: gFalse; }
|
||||
|
||||
// Does this device need to clip pages to the crop box even when the
|
||||
// box is the crop box?
|
||||
virtual GBool needClipToCropBox() { return gTrue; }
|
||||
|
||||
virtual void setDefaultCTM(double *ctm);
|
||||
|
||||
// Start a page.
|
||||
|
@ -122,7 +122,8 @@ void HTMLRenderer::process(PDFDoc *doc)
|
||||
text_zoom_factor() * DEFAULT_DPI, text_zoom_factor() * DEFAULT_DPI,
|
||||
0,
|
||||
(!(param->use_cropbox)),
|
||||
false, false,
|
||||
true, // crop
|
||||
false, // printing
|
||||
nullptr, nullptr, nullptr, nullptr);
|
||||
|
||||
if(param->split_pages)
|
||||
|
@ -48,7 +48,10 @@ void Preprocessor::process(PDFDoc * doc)
|
||||
cerr << "Preprocessing: " << (i-param->first_page) << "/" << page_count << '\r' << flush;
|
||||
|
||||
doc->displayPage(this, i, DEFAULT_DPI, DEFAULT_DPI,
|
||||
0, true, false, false,
|
||||
0,
|
||||
(!(param->use_cropbox)),
|
||||
true, // crop
|
||||
false, // printing
|
||||
nullptr, nullptr, nullptr, nullptr);
|
||||
}
|
||||
if(page_count >= 0)
|
||||
|
@ -34,6 +34,7 @@ public:
|
||||
virtual GBool useDrawChar() { return gTrue; }
|
||||
virtual GBool interpretType3Chars() { return gFalse; }
|
||||
virtual GBool needNonText() { return gFalse; }
|
||||
virtual GBool needClipToCropBox() { return gTrue; }
|
||||
|
||||
virtual void drawChar(GfxState *state, double x, double y,
|
||||
double dx, double dy,
|
||||
|
Loading…
Reference in New Issue
Block a user