mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-28 10:02:43 +01:00
e3e945dc02
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
19 lines
749 B
Diff
19 lines
749 B
Diff
--- a/src/ApvlvFile.cpp 2011-07-07 16:26:45.257995568 +0200
|
|
+++ b/src/ApvlvFile.cpp 2011-07-07 16:29:46.654995527 +0200
|
|
@@ -302,9 +302,14 @@
|
|
|
|
bool ApvlvPDF::pagetext (int pn, int x1, int y1, int x2, int y2, char **out)
|
|
{
|
|
- PopplerRectangle rect = { x1, y1, x2, y2 };
|
|
PopplerPage *page = poppler_document_get_page (mDoc, pn);
|
|
- *out = poppler_page_get_text (page, POPPLER_SELECTION_WORD, &rect);
|
|
+#if POPPLER_CHECK_VERSION(0, 15, 1)
|
|
+ PopplerRectangle rect = { x1, y2, x2, y1 };
|
|
+ *out = poppler_page_get_selected_text (page, POPPLER_SELECTION_WORD, &rect);
|
|
+#else
|
|
+ PopplerRectangle rect = { x1, y1, x2, y2 };
|
|
+ *out = poppler_page_get_text (page, POPPLER_SELECTION_WORD, &rect);
|
|
+#endif
|
|
if (*out != NULL)
|
|
{
|
|
return true;
|