summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2016-07-13 19:36:39 +0100
committerRobin Watts <robin.watts@artifex.com>2016-07-13 20:09:13 +0100
commitcaafb37ddf3d58f4d37d8c7b535021ff18d57861 (patch)
treef7d8352640c645266d78c1d72ffdb1a88109d30c /include
parented8501ed7f52ba96cbdf12594340e629ab99beef (diff)
downloadmupdf-caafb37ddf3d58f4d37d8c7b535021ff18d57861.tar.xz
Bug 696699: Fix Text extraction mediabox information.
Since the removal of the begin_page device function, structured text extraction has been unable to correctly establish the mediabox for extracted pages. Update the fz_new_stext_page call to take this mediabox information. This is an API change, but hopefully most people are calling fz_new_stext_page_from_page or fz_new_stext_page_from_display_list which are updated here to cope. Update all the apps/tools to behave properly.
Diffstat (limited to 'include')
-rw-r--r--include/mupdf/fitz/structured-text.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/mupdf/fitz/structured-text.h b/include/mupdf/fitz/structured-text.h
index ffb9f263..e4199272 100644
--- a/include/mupdf/fitz/structured-text.h
+++ b/include/mupdf/fitz/structured-text.h
@@ -215,8 +215,10 @@ void fz_drop_stext_sheet(fz_context *ctx, fz_stext_sheet *sheet);
The text page is filled out by the text device to contain the blocks,
lines and spans of text on the page.
+
+ mediabox: optional mediabox information.
*/
-fz_stext_page *fz_new_stext_page(fz_context *ctx);
+fz_stext_page *fz_new_stext_page(fz_context *ctx, const fz_rect *mediabox);
void fz_drop_stext_page(fz_context *ctx, fz_stext_page *page);
void fz_analyze_text(fz_context *ctx, fz_stext_sheet *sheet, fz_stext_page *page);