summaryrefslogtreecommitdiff
path: root/Build/source/libs/poppler/poppler-src
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2016-11-15 08:21:51 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2016-11-15 08:21:51 +0000
commit6e827fd56d868ddcce6e5a27a5deb6163b3c73ae (patch)
treeaece51431fda5048f14beca7366eddc0a2913fd9 /Build/source/libs/poppler/poppler-src
parent0d673e8552b2a33c39cd1bfa5f36b0fc92f2ffdf (diff)
poppler 0.49.0
git-svn-id: svn://tug.org/texlive/trunk@42513 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/libs/poppler/poppler-src')
-rw-r--r--Build/source/libs/poppler/poppler-src/CMakeLists.txt4
-rw-r--r--Build/source/libs/poppler/poppler-src/ChangeLog183
-rw-r--r--Build/source/libs/poppler/poppler-src/NEWS16
-rw-r--r--Build/source/libs/poppler/poppler-src/configure.ac4
-rw-r--r--Build/source/libs/poppler/poppler-src/goo/GooString.cc4
-rw-r--r--Build/source/libs/poppler/poppler-src/goo/GooString.h5
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/Form.cc83
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/Form.h9
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/Gfx.cc1
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/Makefile.am2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/Object.h2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/PDFDoc.cc4
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/PDFDoc.h2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/PSOutputDev.cc2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.cc32
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.h1
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/XRef.cc2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/XRef.h2
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.cmake3
-rw-r--r--Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.in3
-rw-r--r--Build/source/libs/poppler/poppler-src/splash/Splash.cc38
21 files changed, 317 insertions, 85 deletions
diff --git a/Build/source/libs/poppler/poppler-src/CMakeLists.txt b/Build/source/libs/poppler/poppler-src/CMakeLists.txt
index 1a694a3cdd1..c25e961f878 100644
--- a/Build/source/libs/poppler/poppler-src/CMakeLists.txt
+++ b/Build/source/libs/poppler/poppler-src/CMakeLists.txt
@@ -22,7 +22,7 @@ if (ECM_FOUND)
endif()
set(POPPLER_MAJOR_VERSION "0")
-set(POPPLER_MINOR_VERSION "48")
+set(POPPLER_MINOR_VERSION "49")
set(POPPLER_MICRO_VERSION "0")
set(POPPLER_VERSION "${POPPLER_MAJOR_VERSION}.${POPPLER_MINOR_VERSION}.${POPPLER_MICRO_VERSION}")
@@ -502,7 +502,7 @@ add_library(poppler STATIC ${poppler_SRCS})
else(MSVC)
add_library(poppler SHARED ${poppler_SRCS})
endif(MSVC)
-set_target_properties(poppler PROPERTIES VERSION 64.0.0 SOVERSION 64)
+set_target_properties(poppler PROPERTIES VERSION 65.0.0 SOVERSION 65)
target_link_libraries(poppler LINK_PRIVATE ${poppler_LIBS})
install(TARGETS poppler RUNTIME DESTINATION bin LIBRARY DESTINATION lib${LIB_SUFFIX} ARCHIVE DESTINATION lib${LIB_SUFFIX})
diff --git a/Build/source/libs/poppler/poppler-src/ChangeLog b/Build/source/libs/poppler/poppler-src/ChangeLog
index 298744ad5a5..a71866b290d 100644
--- a/Build/source/libs/poppler/poppler-src/ChangeLog
+++ b/Build/source/libs/poppler/poppler-src/ChangeLog
@@ -1,3 +1,186 @@
+commit 02e2d8e2c3004c36d1f8f798e5a7a30166f48f37
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Tue Nov 15 00:10:43 2016 +0100
+
+ 0.49
+
+ CMakeLists.txt | 4 ++--
+ NEWS | 5 ++++-
+ configure.ac | 2 +-
+ cpp/Doxyfile | 2 +-
+ poppler/Makefile.am | 2 +-
+ qt4/src/Doxyfile | 2 +-
+ qt5/src/Doxyfile | 2 +-
+ 7 files changed, 11 insertions(+), 8 deletions(-)
+
+commit f7f0f14e095425d171456a697804f2f34ed26426
+Author: Tor Lillqvist <tml@collabora.com>
+Date: Tue Nov 15 00:06:26 2016 +0100
+
+ VS 2013 has fmin() and fmax()
+
+ NEWS | 13 +++++++++++++
+ poppler/poppler-config.h.cmake | 3 ++-
+ 2 files changed, 15 insertions(+), 1 deletion(-)
+
+commit 07ac68603552b36a2a6b8ea5982f22f24f5835b1
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Tue Nov 15 00:03:24 2016 +0100
+
+ Update (C)
+
+ poppler/PSOutputDev.cc | 1 +
+ poppler/poppler-config.h.in | 1 +
+ utils/pdfseparate.cc | 2 +-
+ 3 files changed, 3 insertions(+), 1 deletion(-)
+
+commit b837ae3bc69c5c76f1a4e3abaeb22d0574d6b2c8
+Author: Thomas Freitag <Thomas.Freitag@alfa.de>
+Date: Thu Nov 10 00:33:17 2016 +0100
+
+ Continue rendering in case of 'Singular matrix in shading pattern
+ fill'
+
+ Bug #98623
+
+ poppler/Gfx.cc | 1 +
+ 1 file changed, 1 insertion(+)
+
+commit 6c01a48458a8b4896d606ef9bcc4af5e03393b72
+Author: Thomas Freitag <Thomas.Freitag@alfa.de>
+Date: Wed Nov 2 23:10:01 2016 +0100
+
+ merge type3 glyph handling from xpdf 3.04
+
+ Fixes bug #96667
+
+ poppler/SplashOutputDev.cc | 28 +++++++++++++++++++++++-----
+ poppler/SplashOutputDev.h | 1 -
+ 2 files changed, 23 insertions(+), 6 deletions(-)
+
+commit f43cb73939f85952d83afc87a6dc638dc1ae311b
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Wed Nov 2 00:13:26 2016 +0100
+
+ Avoid UBSan warning about undefined downcast
+
+ ...of this-ptr of in-construction FormFieldSignature while still in
+ the base
+ FormField ctor by simply casting the parent-class field member
+ when needed
+
+ poppler/Form.cc | 83
+ ++++++++++++++++++++++++++++++++-------------------------
+ poppler/Form.h | 9 +++----
+ 2 files changed, 50 insertions(+), 42 deletions(-)
+
+commit 4539d0b002efbd19393fd55a6fb87b013acdb8f1
+Author: Caolán McNamara <caolanm@redhat.com>
+Date: Thu Oct 27 14:31:20 2016 +0200
+
+ PSOutputDev.cc: std::max requires <algorithm>
+
+ poppler/PSOutputDev.cc | 1 +
+ 1 file changed, 1 insertion(+)
+
+commit 4619957cbab81ab0b25f3fdd3ed872f0ad93f074
+Author: Tor Lillqvist <tml@collabora.com>
+Date: Thu Oct 27 14:27:32 2016 +0200
+
+ VS 2013 has fmin() and fmax()
+
+ poppler/poppler-config.h.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit be073d39f72f625bf3d8482ead76881150695bf4
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Mon Oct 31 10:11:56 2016 +0100
+
+ Fix typo in disable nss help string
+
+ Bug #98514
+
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 2a09ec47aef8870dba345f4045e691ffb5a59f4d
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Mon Oct 24 20:04:22 2016 +0200
+
+ Fix memory leak in parametrized gouraudTriangleShadedFill
+
+ poppler/SplashOutputDev.cc | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 169889b8e196cfcd288e6555fb048fbbf95ba3f6
+Author: Albert Astals Cid <aacid@kde.org>
+Date: Mon Oct 24 20:04:00 2016 +0200
+
+ Fix crash on broken files
+
+ splash/Splash.cc | 38 ++++++++++++++++++++------------------
+ 1 file changed, 20 insertions(+), 18 deletions(-)
+
+commit 269a91e3b03a19acc06fd0f72356f2e48a6368a7
+Author: Jakub Alba <jakubalba@gmail.com>
+Date: Tue Aug 23 13:20:44 2016 +0200
+
+ PDFDoc::setDocInfoStringEntry(): treat value consisting of just the
+ unicode marker as an empty string
+
+ poppler/PDFDoc.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 43cfdf9de45e6833a2815b173f8cc945f1c5f9d6
+Author: Jakub Alba <jakubalba@gmail.com>
+Date: Tue Aug 23 13:19:07 2016 +0200
+
+ goo: add GooString::hasJustUnicodeMarker(void)
+
+ goo/GooString.cc | 2 +-
+ goo/GooString.h | 3 ++-
+ 2 files changed, 3 insertions(+), 2 deletions(-)
+
+commit e3c5bdf4fcd29c5d180046d1c279d3f99c1027a7
+Author: Jakub Alba <jakubalba@gmail.com>
+Date: Fri Oct 21 23:06:23 2016 +0200
+
+ update copyrights
+
+ cpp/poppler-document.cpp | 2 +-
+ cpp/poppler-document.h | 2 +-
+ cpp/poppler-embedded-file.cpp | 2 +-
+ cpp/poppler-global.cpp | 2 +-
+ cpp/poppler-private.cpp | 2 +-
+ cpp/poppler-private.h | 2 +-
+ glib/poppler-document.cc | 2 +-
+ glib/poppler-document.h | 2 +-
+ goo/GooString.cc | 2 +-
+ goo/GooString.h | 2 +-
+ poppler/Object.h | 2 +-
+ poppler/PDFDoc.cc | 2 +-
+ poppler/PDFDoc.h | 2 +-
+ poppler/XRef.cc | 2 +-
+ poppler/XRef.h | 2 +-
+ qt4/src/poppler-document.cc | 2 +-
+ qt4/src/poppler-private.cc | 2 +-
+ qt4/src/poppler-private.h | 2 +-
+ qt4/src/poppler-qt4.h | 2 +-
+ qt5/src/poppler-document.cc | 2 +-
+ qt5/src/poppler-private.cc | 2 +-
+ qt5/src/poppler-private.h | 2 +-
+ qt5/src/poppler-qt5.h | 2 +-
+ 23 files changed, 23 insertions(+), 23 deletions(-)
+
+commit 5d15a52aade68c618c356fe403ca500e74917ef7
+Author: Pino Toscano <pino@kde.org>
+Date: Sun Oct 9 13:04:46 2016 +0200
+
+ pdfseparate: remove extra '%' in error message
+
+ utils/pdfseparate.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
commit 036bcee237c814197af3324cd3697ea88d9ac6d3
Author: Albert Astals Cid <aacid@kde.org>
Date: Sat Oct 8 17:55:31 2016 +0200
diff --git a/Build/source/libs/poppler/poppler-src/NEWS b/Build/source/libs/poppler/poppler-src/NEWS
index 6d98bbf1490..619d7f40558 100644
--- a/Build/source/libs/poppler/poppler-src/NEWS
+++ b/Build/source/libs/poppler/poppler-src/NEWS
@@ -1,3 +1,19 @@
+Release 0.49.0
+ core:
+ * Merge type3 glyph handling from xpdf 3.04. Bug #96667
+ * Continue rendering in case of 'Singular matrix in shading pattern fill. Bug #98623
+ * Fix memory leak in parametrized gouraudTriangleShadedFill
+ * Fix crash on broken files
+ * PDFDoc::setDocInfoStringEntry(): treat value consisting of just the unicode marker as an empty string
+ * Fix UBSAN warning
+ * Misc compile fixes
+
+ utils:
+ * pdfseparate: remove extra '%' in error message
+
+ build system:
+ * configure: Fix typo in disable nss help string
+
Release 0.48.0
core:
* Fix crashes and memory leaks in invalid files.
diff --git a/Build/source/libs/poppler/poppler-src/configure.ac b/Build/source/libs/poppler/poppler-src/configure.ac
index 2ff66bea2dd..0ba420adbee 100644
--- a/Build/source/libs/poppler/poppler-src/configure.ac
+++ b/Build/source/libs/poppler/poppler-src/configure.ac
@@ -1,5 +1,5 @@
m4_define([poppler_version_major],[0])
-m4_define([poppler_version_minor],[48])
+m4_define([poppler_version_minor],[49])
m4_define([poppler_version_micro],[0])
m4_define([poppler_version],[poppler_version_major.poppler_version_minor.poppler_version_micro])
@@ -262,7 +262,7 @@ fi
dnl Test for NSS
AC_ARG_ENABLE(libnss,
- AC_HELP_STRING([--disable-nss],
+ AC_HELP_STRING([--disable-libnss],
[Do not build against libnss3.]),
enable_libnss=$enableval,
enable_libnss="try")
diff --git a/Build/source/libs/poppler/poppler-src/goo/GooString.cc b/Build/source/libs/poppler/poppler-src/goo/GooString.cc
index 1c0c634ce5a..12592e4902f 100644
--- a/Build/source/libs/poppler/poppler-src/goo/GooString.cc
+++ b/Build/source/libs/poppler/poppler-src/goo/GooString.cc
@@ -25,7 +25,7 @@
// Copyright (C) 2012 Pino Toscano <pino@kde.org>
// Copyright (C) 2013 Jason Crain <jason@aquaticape.us>
// Copyright (C) 2015 William Bader <williambader@hotmail.com>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -912,7 +912,7 @@ GBool GooString::endsWith(const char *suffix) const {
return strcmp(s + length - suffixLen, suffix) == 0;
}
-GBool GooString::hasUnicodeMarker(void)
+GBool GooString::hasUnicodeMarker(void) const
{
return length > 1 && (s[0] & 0xff) == 0xfe && (s[1] & 0xff) == 0xff;
}
diff --git a/Build/source/libs/poppler/poppler-src/goo/GooString.h b/Build/source/libs/poppler/poppler-src/goo/GooString.h
index a37e02ab6eb..5deeda7e870 100644
--- a/Build/source/libs/poppler/poppler-src/goo/GooString.h
+++ b/Build/source/libs/poppler/poppler-src/goo/GooString.h
@@ -21,7 +21,7 @@
// Copyright (C) 2012-2014 Fabio D'Urso <fabiodurso@hotmail.it>
// Copyright (C) 2013 Jason Crain <jason@aquaticape.us>
// Copyright (C) 2015 Adam Reichold <adam.reichold@t-online.de>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -175,7 +175,8 @@ public:
// Return true if string ends with suffix
GBool endsWith(const char *suffix) const;
- GBool hasUnicodeMarker(void);
+ GBool hasUnicodeMarker(void) const;
+ GBool hasJustUnicodeMarker(void) const { return length == 2 && hasUnicodeMarker(); }
// Sanitizes the string so that it does
// not contain any ( ) < > [ ] { } / %
diff --git a/Build/source/libs/poppler/poppler-src/poppler/Form.cc b/Build/source/libs/poppler/poppler-src/poppler/Form.cc
index 8e3b26568f4..dd62aaf1d18 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/Form.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/Form.cc
@@ -171,7 +171,6 @@ FormWidgetButton::FormWidgetButton (PDFDoc *docA, Object *aobj, unsigned num, Re
FormWidget(docA, aobj, num, ref, p)
{
type = formButton;
- parent = static_cast<FormFieldButton*>(field);
onStr = NULL;
Object obj1, obj2;
@@ -200,7 +199,7 @@ char *FormWidgetButton::getOnStr() {
// 12.7.4.2.3 Check Boxes
// Yes should be used as the name for the on state
- return parent->getButtonType() == formButtonCheck ? (char *)"Yes" : NULL;
+ return parent()->getButtonType() == formButtonCheck ? (char *)"Yes" : NULL;
}
FormWidgetButton::~FormWidgetButton ()
@@ -210,7 +209,7 @@ FormWidgetButton::~FormWidgetButton ()
FormButtonType FormWidgetButton::getButtonType () const
{
- return parent->getButtonType ();
+ return parent()->getButtonType ();
}
void FormWidgetButton::setAppearanceState(const char *state) {
@@ -227,20 +226,25 @@ void FormWidgetButton::updateWidgetAppearance()
void FormWidgetButton::setState (GBool astate)
{
//pushButtons don't have state
- if (parent->getButtonType() == formButtonPush)
+ if (parent()->getButtonType() == formButtonPush)
return;
// Silently return if can't set ON state
if (astate && !onStr)
return;
- parent->setState(astate ? onStr->getCString() : (char *)"Off");
+ parent()->setState(astate ? onStr->getCString() : (char *)"Off");
// Parent will call setAppearanceState()
}
GBool FormWidgetButton::getState ()
{
- return onStr ? parent->getState(onStr->getCString()) : gFalse;
+ return onStr ? parent()->getState(onStr->getCString()) : gFalse;
+}
+
+FormFieldButton *FormWidgetButton::parent() const
+{
+ return static_cast<FormFieldButton*>(field);
}
@@ -248,17 +252,16 @@ FormWidgetText::FormWidgetText (PDFDoc *docA, Object *aobj, unsigned num, Ref re
FormWidget(docA, aobj, num, ref, p)
{
type = formText;
- parent = static_cast<FormFieldText*>(field);
}
GooString* FormWidgetText::getContent ()
{
- return parent->getContent();
+ return parent()->getContent();
}
GooString* FormWidgetText::getContentCopy ()
{
- return parent->getContentCopy();
+ return parent()->getContentCopy();
}
void FormWidgetText::updateWidgetAppearance()
@@ -269,42 +272,42 @@ void FormWidgetText::updateWidgetAppearance()
bool FormWidgetText::isMultiline () const
{
- return parent->isMultiline();
+ return parent()->isMultiline();
}
bool FormWidgetText::isPassword () const
{
- return parent->isPassword();
+ return parent()->isPassword();
}
bool FormWidgetText::isFileSelect () const
{
- return parent->isFileSelect();
+ return parent()->isFileSelect();
}
bool FormWidgetText::noSpellCheck () const
{
- return parent->noSpellCheck();
+ return parent()->noSpellCheck();
}
bool FormWidgetText::noScroll () const
{
- return parent->noScroll();
+ return parent()->noScroll();
}
bool FormWidgetText::isComb () const
{
- return parent->isComb();
+ return parent()->isComb();
}
bool FormWidgetText::isRichText () const
{
- return parent->isRichText();
+ return parent()->isRichText();
}
int FormWidgetText::getMaxLen () const
{
- return parent->getMaxLen ();
+ return parent()->getMaxLen ();
}
void FormWidgetText::setContent(GooString* new_content)
@@ -314,14 +317,18 @@ void FormWidgetText::setContent(GooString* new_content)
return;
}
- parent->setContentCopy(new_content);
+ parent()->setContentCopy(new_content);
+}
+
+FormFieldText *FormWidgetText::parent() const
+{
+ return static_cast<FormFieldText*>(field);
}
FormWidgetChoice::FormWidgetChoice(PDFDoc *docA, Object *aobj, unsigned num, Ref ref, FormField *p) :
FormWidget(docA, aobj, num, ref, p)
{
type = formChoice;
- parent = static_cast<FormFieldChoice*>(field);
}
FormWidgetChoice::~FormWidgetChoice()
@@ -330,7 +337,7 @@ FormWidgetChoice::~FormWidgetChoice()
bool FormWidgetChoice::_checkRange (int i)
{
- if (i < 0 || i >= parent->getNumChoices()) {
+ if (i < 0 || i >= parent()->getNumChoices()) {
error(errInternal, -1, "FormWidgetChoice::_checkRange i out of range : {0:d}", i);
return false;
}
@@ -344,7 +351,7 @@ void FormWidgetChoice::select (int i)
return;
}
if (!_checkRange(i)) return;
- parent->select(i);
+ parent()->select(i);
}
void FormWidgetChoice::toggle (int i)
@@ -354,7 +361,7 @@ void FormWidgetChoice::toggle (int i)
return;
}
if (!_checkRange(i)) return;
- parent->toggle(i);
+ parent()->toggle(i);
}
void FormWidgetChoice::deselectAll ()
@@ -363,7 +370,7 @@ void FormWidgetChoice::deselectAll ()
error(errInternal, -1, "FormWidgetChoice::deselectAll called on a read only field\n");
return;
}
- parent->deselectAll();
+ parent()->deselectAll();
}
GooString* FormWidgetChoice::getEditChoice ()
@@ -372,7 +379,7 @@ GooString* FormWidgetChoice::getEditChoice ()
error(errInternal, -1, "FormFieldChoice::getEditChoice called on a non-editable choice\n");
return NULL;
}
- return parent->getEditChoice();
+ return parent()->getEditChoice();
}
void FormWidgetChoice::updateWidgetAppearance()
@@ -384,7 +391,7 @@ void FormWidgetChoice::updateWidgetAppearance()
bool FormWidgetChoice::isSelected (int i)
{
if (!_checkRange(i)) return false;
- return parent->isSelected(i);
+ return parent()->isSelected(i);
}
void FormWidgetChoice::setEditChoice (GooString* new_content)
@@ -398,59 +405,63 @@ void FormWidgetChoice::setEditChoice (GooString* new_content)
return;
}
- parent->setEditChoice(new_content);
+ parent()->setEditChoice(new_content);
}
int FormWidgetChoice::getNumChoices()
{
- return parent->getNumChoices();
+ return parent()->getNumChoices();
}
GooString* FormWidgetChoice::getChoice(int i)
{
- return parent->getChoice(i);
+ return parent()->getChoice(i);
}
bool FormWidgetChoice::isCombo () const
{
- return parent->isCombo();
+ return parent()->isCombo();
}
bool FormWidgetChoice::hasEdit () const
{
- return parent->hasEdit();
+ return parent()->hasEdit();
}
bool FormWidgetChoice::isMultiSelect () const
{
- return parent->isMultiSelect();
+ return parent()->isMultiSelect();
}
bool FormWidgetChoice::noSpellCheck () const
{
- return parent->noSpellCheck();
+ return parent()->noSpellCheck();
}
bool FormWidgetChoice::commitOnSelChange () const
{
- return parent->commitOnSelChange();
+ return parent()->commitOnSelChange();
}
bool FormWidgetChoice::isListBox () const
{
- return parent->isListBox();
+ return parent()->isListBox();
+}
+
+FormFieldChoice *FormWidgetChoice::parent() const
+{
+ return static_cast<FormFieldChoice*>(field);
}
FormWidgetSignature::FormWidgetSignature(PDFDoc *docA, Object *aobj, unsigned num, Ref ref, FormField *p) :
FormWidget(docA, aobj, num, ref, p)
{
type = formSignature;
- parent = static_cast<FormFieldSignature*>(field);
}
SignatureInfo *FormWidgetSignature::validateSignature(bool doVerifyCert, bool forceRevalidation)
{
- return parent->validateSignature(doVerifyCert, forceRevalidation);
+ return static_cast<FormFieldSignature*>(field)->validateSignature(doVerifyCert, forceRevalidation);
}
void FormWidgetSignature::updateWidgetAppearance()
diff --git a/Build/source/libs/poppler/poppler-src/poppler/Form.h b/Build/source/libs/poppler/poppler-src/poppler/Form.h
index d467b473bcd..4628dbfe328 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/Form.h
+++ b/Build/source/libs/poppler/poppler-src/poppler/Form.h
@@ -167,8 +167,8 @@ public:
void updateWidgetAppearance();
protected:
+ FormFieldButton *parent() const;
GooString *onStr;
- FormFieldButton *parent;
};
//------------------------------------------------------------------------
@@ -197,7 +197,7 @@ public:
bool isRichText () const;
int getMaxLen () const;
protected:
- FormFieldText *parent;
+ FormFieldText *parent() const;
};
//------------------------------------------------------------------------
@@ -238,7 +238,7 @@ public:
bool isListBox () const;
protected:
bool _checkRange (int i);
- FormFieldChoice *parent;
+ FormFieldChoice *parent() const;
};
//------------------------------------------------------------------------
@@ -251,9 +251,6 @@ public:
void updateWidgetAppearance();
SignatureInfo *validateSignature(bool doVerifyCert, bool forceRevalidation);
-
-protected:
- FormFieldSignature *parent;
};
//------------------------------------------------------------------------
diff --git a/Build/source/libs/poppler/poppler-src/poppler/Gfx.cc b/Build/source/libs/poppler/poppler-src/poppler/Gfx.cc
index 7d748b9ea17..a8f5be95e4b 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/Gfx.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/Gfx.cc
@@ -2348,6 +2348,7 @@ void Gfx::doShadingPatternFill(GfxShadingPattern *sPat,
det = ctm[0] * ctm[3] - ctm[1] * ctm[2];
if (fabs(det) < 0.000001) {
error(errSyntaxError, getPos(), "Singular matrix in shading pattern fill");
+ restoreStateStack(savedState);
return;
}
det = 1 / det;
diff --git a/Build/source/libs/poppler/poppler-src/poppler/Makefile.am b/Build/source/libs/poppler/poppler-src/poppler/Makefile.am
index aa70853b5b5..15aa5465794 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/Makefile.am
+++ b/Build/source/libs/poppler/poppler-src/poppler/Makefile.am
@@ -327,7 +327,7 @@ libpoppler_la_LIBADD = \
$(win32_libs)
libpoppler_la_LDFLAGS = \
- -version-info 64:0:0 \
+ -version-info 65:0:0 \
@create_shared_lib@ \
@auto_import_flags@
diff --git a/Build/source/libs/poppler/poppler-src/poppler/Object.h b/Build/source/libs/poppler/poppler-src/poppler/Object.h
index 048f95a2451..312a8eb32cb 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/Object.h
+++ b/Build/source/libs/poppler/poppler-src/poppler/Object.h
@@ -21,7 +21,7 @@
// Copyright (C) 2013 Thomas Freitag <Thomas.Freitag@alfa.de>
// Copyright (C) 2013 Adrian Johnson <ajohnson@redneon.com>
// Copyright (C) 2013 Adrian Perez de Castro <aperez@igalia.com>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
diff --git a/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.cc b/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.cc
index ed2dbba414a..587b2be278d 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.cc
@@ -34,7 +34,7 @@
// Copyright (C) 2015 Li Junling <lijunling@sina.com>
// Copyright (C) 2015 André Guerreiro <aguerreiro1985@gmail.com>
// Copyright (C) 2015 André Esser <bepandre@hotmail.com>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -615,7 +615,7 @@ void PDFDoc::setDocInfoModified(Object *infoObj)
void PDFDoc::setDocInfoStringEntry(const char *key, GooString *value)
{
- GBool removeEntry = !value || value->getLength() == 0;
+ GBool removeEntry = !value || value->getLength() == 0 || value->hasJustUnicodeMarker();
if (removeEntry) {
delete value;
}
diff --git a/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.h b/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.h
index daff3f48f74..99de8a21a34 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.h
+++ b/Build/source/libs/poppler/poppler-src/poppler/PDFDoc.h
@@ -29,7 +29,7 @@
// Copyright (C) 2013 Adrian Perez de Castro <aperez@igalia.com>
// Copyright (C) 2015 André Guerreiro <aguerreiro1985@gmail.com>
// Copyright (C) 2015 André Esser <bepandre@hotmail.com>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
diff --git a/Build/source/libs/poppler/poppler-src/poppler/PSOutputDev.cc b/Build/source/libs/poppler/poppler-src/poppler/PSOutputDev.cc
index 183e929090e..9124c4932da 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/PSOutputDev.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/PSOutputDev.cc
@@ -30,6 +30,7 @@
// Copyright (C) 2012 Lu Wang <coolwanglu@gmail.com>
// Copyright (C) 2014 Till Kamppeter <till.kamppeter@gmail.com>
// Copyright (C) 2015 Marek Kasik <mkasik@redhat.com>
+// Copyright (C) 2016 Caolán McNamara <caolanm@redhat.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -48,6 +49,7 @@
#include <signal.h>
#include <math.h>
#include <limits.h>
+#include <algorithm>
#include "goo/GooString.h"
#include "goo/GooList.h"
#include "goo/GooHash.h"
diff --git a/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.cc b/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.cc
index 688540beaf0..7b6e14ae578 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.cc
@@ -1323,6 +1323,10 @@ T3FontCache::~T3FontCache() {
struct T3GlyphStack {
Gushort code; // character code
+ GBool haveDx; // set after seeing a d0/d1 operator
+ GBool doNotCache; // set if we see a gsave/grestore before
+ // the d0/d1
+
//----- cache info
T3FontCache *cache; // font cache for the current font
T3FontCacheTag *cacheTag; // pointer to cache tag for the glyph
@@ -1600,11 +1604,21 @@ void SplashOutputDev::endPage() {
void SplashOutputDev::saveState(GfxState *state) {
splash->saveState();
+ if (t3GlyphStack && !t3GlyphStack->haveDx) {
+ t3GlyphStack->doNotCache = gTrue;
+ error(errSyntaxWarning, -1,
+ "Save (q) operator before d0/d1 in Type 3 glyph");
+ }
}
void SplashOutputDev::restoreState(GfxState *state) {
splash->restoreState();
needFontUpdate = gTrue;
+ if (t3GlyphStack && !t3GlyphStack->haveDx) {
+ t3GlyphStack->doNotCache = gTrue;
+ error(errSyntaxWarning, -1,
+ "Restore (Q) operator before d0/d1 in Type 3 glyph");
+ }
}
void SplashOutputDev::updateAll(GfxState *state) {
@@ -2668,8 +2682,8 @@ GBool SplashOutputDev::beginType3Char(GfxState *state, double x, double y,
t3GlyphStack->cache = t3Font;
t3GlyphStack->cacheTag = NULL;
t3GlyphStack->cacheData = NULL;
-
- haveT3Dx = gFalse;
+ t3GlyphStack->haveDx = gFalse;
+ t3GlyphStack->doNotCache = gFalse;
return gFalse;
}
@@ -2699,7 +2713,7 @@ void SplashOutputDev::endType3Char(GfxState *state) {
}
void SplashOutputDev::type3D0(GfxState *state, double wx, double wy) {
- haveT3Dx = gTrue;
+ t3GlyphStack->haveDx = gTrue;
}
void SplashOutputDev::type3D1(GfxState *state, double wx, double wy,
@@ -2711,10 +2725,14 @@ void SplashOutputDev::type3D1(GfxState *state, double wx, double wy,
int i, j;
// ignore multiple d0/d1 operators
- if (haveT3Dx) {
+ if (t3GlyphStack->haveDx) {
+ return;
+ }
+ t3GlyphStack->haveDx = gTrue;
+ // don't cache if we got a gsave/grestore before the d1
+ if (t3GlyphStack->doNotCache) {
return;
}
- haveT3Dx = gTrue;
if (unlikely(t3GlyphStack == NULL)) {
error(errSyntaxWarning, -1, "t3GlyphStack was null in SplashOutputDev::type3D1");
@@ -4762,17 +4780,17 @@ GBool SplashOutputDev::gouraudTriangleShadedFill(GfxState *state, GfxGouraudTria
default:
break;
}
- SplashGouraudColor *splashShading = new SplashGouraudPattern(bDirectColorTranslation, state, shading, colorMode);
// restore vector antialias because we support it here
if (shading->isParameterized()) {
+ SplashGouraudColor *splashShading = new SplashGouraudPattern(bDirectColorTranslation, state, shading, colorMode);
GBool vaa = getVectorAntialias();
GBool retVal = gFalse;
setVectorAntialias(gTrue);
retVal = splash->gouraudTriangleShadedFill(splashShading);
setVectorAntialias(vaa);
+ delete splashShading;
return retVal;
}
- delete splashShading;
return gFalse;
}
diff --git a/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.h b/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.h
index e93a20f1821..5c5512ba518 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.h
+++ b/Build/source/libs/poppler/poppler-src/poppler/SplashOutputDev.h
@@ -459,7 +459,6 @@ private:
t3FontCache[splashOutT3FontCacheSize];
int nT3Fonts; // number of valid entries in t3FontCache
T3GlyphStack *t3GlyphStack; // Type 3 glyph context stack
- GBool haveT3Dx; // set after seeing a d0/d1 operator
SplashFont *font; // current font
GBool needFontUpdate; // set when the font needs to be updated
diff --git a/Build/source/libs/poppler/poppler-src/poppler/XRef.cc b/Build/source/libs/poppler/poppler-src/poppler/XRef.cc
index d9e6db55a7b..e5ecd632a51 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/XRef.cc
+++ b/Build/source/libs/poppler/poppler-src/poppler/XRef.cc
@@ -24,7 +24,7 @@
// Copyright (C) 2012, 2013 Fabio D'Urso <fabiodurso@hotmail.it>
// Copyright (C) 2013, 2014 Adrian Johnson <ajohnson@redneon.com>
// Copyright (C) 2013 Pino Toscano <pino@kde.org>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
diff --git a/Build/source/libs/poppler/poppler-src/poppler/XRef.h b/Build/source/libs/poppler/poppler-src/poppler/XRef.h
index 245b14b8621..5ae33e5c738 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/XRef.h
+++ b/Build/source/libs/poppler/poppler-src/poppler/XRef.h
@@ -22,7 +22,7 @@
// Copyright (C) 2012, 2013, 2016 Thomas Freitag <Thomas.Freitag@kabelmail.de>
// Copyright (C) 2012, 2013 Fabio D'Urso <fabiodurso@hotmail.it>
// Copyright (C) 2013 Adrian Johnson <ajohnson@redneon.com>
-// Copyright (C) 2016 Jakub Kucharski <jakubkucharski97@gmail.com>
+// Copyright (C) 2016 Jakub Alba <jakubalba@gmail.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
diff --git a/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.cmake b/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.cmake
index e3e2cfb7de9..773f3ffd0ce 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.cmake
+++ b/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.cmake
@@ -15,6 +15,7 @@
//
// Copyright (C) 2014 Bogdan Cristea <cristeab@gmail.com>
// Copyright (C) 2014 Hib Eris <hib@hiberis.nl>
+// Copyright (C) 2016 Tor Lillqvist <tml@collabora.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -186,7 +187,7 @@ char * strtok_r (char *s, const char *delim, char **save_ptr);
#define GCC_PRINTF_FORMAT(fmt_index, va_index)
#endif
-#if defined(_MSC_VER)
+#if defined(_MSC_VER) && _MSC_VER < 1800
#define fmax(a, b) std::max(a, b)
#define fmin(a, b) std::min(a, b)
#endif
diff --git a/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.in b/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.in
index 79d452f4d1e..8e1f71958f6 100644
--- a/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.in
+++ b/Build/source/libs/poppler/poppler-src/poppler/poppler-config.h.in
@@ -15,6 +15,7 @@
//
// Copyright (C) 2014 Bogdan Cristea <cristeab@gmail.com>
// Copyright (C) 2014 Hib Eris <hib@hiberis.nl>
+// Copyright (C) 2016 Tor Lillqvist <tml@collabora.com>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -186,7 +187,7 @@ char * strtok_r (char *s, const char *delim, char **save_ptr);
#define GCC_PRINTF_FORMAT(fmt_index, va_index)
#endif
-#if defined(_MSC_VER)
+#if defined(_MSC_VER) && _MSC_VER < 1800
#define fmax(a, b) std::max(a, b)
#define fmin(a, b) std::min(a, b)
#endif
diff --git a/Build/source/libs/poppler/poppler-src/splash/Splash.cc b/Build/source/libs/poppler/poppler-src/splash/Splash.cc
index e179c1cbff3..46b8ce292c2 100644
--- a/Build/source/libs/poppler/poppler-src/splash/Splash.cc
+++ b/Build/source/libs/poppler/poppler-src/splash/Splash.cc
@@ -5745,24 +5745,26 @@ GBool Splash::gouraudTriangleShadedFill(SplashGouraudColor *shading)
colorinterp = scanColorMap[0] * scanLimitL + scanColorMap[1];
bitmapOff = scanLineOff + scanLimitL * colorComps;
- for (int X = scanLimitL; X <= scanLimitR && bitmapOff + colorComps <= bitmapOffLimit; ++X, colorinterp += scanColorMap[0], bitmapOff += colorComps) {
- // FIXME : standard rectangular clipping can be done for a
- // complete scanline which is faster
- // --> see SplashClip and its methods
- if (!clip->test(X, Y))
- continue;
-
- assert(fabs(colorinterp - (scanColorMap[0] * X + scanColorMap[1])) < 1e-10);
- assert(bitmapOff == Y * rowSize + colorComps * X && scanLineOff == Y * rowSize);
-
- shading->getParameterizedColor(colorinterp, bitmapMode, &bitmapData[bitmapOff]);
-
- // make the shading visible.
- // Note that opacity is handled by the bDirectBlit stuff, see
- // above for comments and below for implementation.
- if (hasAlpha)
- bitmapAlpha[Y * bitmapWidth + X] = 255;
- }
+ if (likely(bitmapOff >= 0)) {
+ for (int X = scanLimitL; X <= scanLimitR && bitmapOff + colorComps <= bitmapOffLimit; ++X, colorinterp += scanColorMap[0], bitmapOff += colorComps) {
+ // FIXME : standard rectangular clipping can be done for a
+ // complete scanline which is faster
+ // --> see SplashClip and its methods
+ if (!clip->test(X, Y))
+ continue;
+
+ assert(fabs(colorinterp - (scanColorMap[0] * X + scanColorMap[1])) < 1e-10);
+ assert(bitmapOff == Y * rowSize + colorComps * X && scanLineOff == Y * rowSize);
+
+ shading->getParameterizedColor(colorinterp, bitmapMode, &bitmapData[bitmapOff]);
+
+ // make the shading visible.
+ // Note that opacity is handled by the bDirectBlit stuff, see
+ // above for comments and below for implementation.
+ if (hasAlpha)
+ bitmapAlpha[Y * bitmapWidth + X] = 255;
+ }
+ }
}
}
} else {