[poppler] 2 commits - poppler/Form.h qt5/src

Albert Astals Cid aacid at kemper.freedesktop.org
Wed Mar 1 23:57:01 UTC 2017


 poppler/Form.h              |    2 +-
 qt5/src/poppler-document.cc |   18 +++++++++++++++++-
 qt5/src/poppler-qt5.h       |    9 ++++++++-
 3 files changed, 26 insertions(+), 3 deletions(-)

New commits:
commit a4c6433c423bd0dcc5056d9ee0375188fea9a0bc
Author: Albert Astals Cid <aacid at kde.org>
Date:   Thu Mar 2 00:56:43 2017 +0100

    Update (C) of previous commit

diff --git a/poppler/Form.h b/poppler/Form.h
index 8696d2f..a197ad6 100644
--- a/poppler/Form.h
+++ b/poppler/Form.h
@@ -6,7 +6,7 @@
 //
 // Copyright 2006 Julien Rebetez <julienr at svn.gnome.org>
 // Copyright 2007, 2008, 2011 Carlos Garcia Campos <carlosgc at gnome.org>
-// Copyright 2007-2010, 2012, 2015, 2016 Albert Astals Cid <aacid at kde.org>
+// Copyright 2007-2010, 2012, 2015-2017 Albert Astals Cid <aacid at kde.org>
 // Copyright 2010 Mark Riedesel <mark at klowner.com>
 // Copyright 2011 Pino Toscano <pino at kde.org>
 // Copyright 2012 Fabio D'Urso <fabiodurso at hotmail.it>
commit 0151e6e3824a6db907d871a2e56f5c20c001b588
Author: Albert Astals Cid <aacid at kde.org>
Date:   Thu Mar 2 00:56:27 2017 +0100

    Qt5: expose form calculate order

diff --git a/qt5/src/poppler-document.cc b/qt5/src/poppler-document.cc
index 98959a1..741a1b7 100644
--- a/qt5/src/poppler-document.cc
+++ b/qt5/src/poppler-document.cc
@@ -1,7 +1,7 @@
 /* poppler-document.cc: qt interface to poppler
  * Copyright (C) 2005, Net Integration Technologies, Inc.
  * Copyright (C) 2005, 2008, Brad Hards <bradh at frogmouth.net>
- * Copyright (C) 2005-2010, 2012, 2013, 2015, Albert Astals Cid <aacid at kde.org>
+ * Copyright (C) 2005-2010, 2012, 2013, 2015, 2017, Albert Astals Cid <aacid at kde.org>
  * Copyright (C) 2006-2010, Pino Toscano <pino at kde.org>
  * Copyright (C) 2010, 2011 Hib Eris <hib at hiberis.nl>
  * Copyright (C) 2012 Koji Otani <sho at bbr.jp>
@@ -784,6 +784,22 @@ namespace Poppler {
         return Document::NoForm; // make gcc happy
     }
 
+    QVector<int> Document::formCalculateOrder() const
+    {
+        QVector<int> result;
+
+        Form *form = m_doc->doc->getCatalog()->getForm();
+        const std::vector<Ref> &calculateOrder = form->getCalculateOrder();
+        for (uint i = 0; i < calculateOrder.size(); ++i) {
+            FormWidget *w = form->findWidgetByRef(calculateOrder[i]);
+            if (w) {
+                result << w->getID();
+            }
+        }
+
+        return result;
+    }
+
     QDateTime convertDate( char *dateString )
     {
         int year, mon, day, hour, min, sec, tzHours, tzMins;
diff --git a/qt5/src/poppler-qt5.h b/qt5/src/poppler-qt5.h
index 562507e..45cc6ff 100644
--- a/qt5/src/poppler-qt5.h
+++ b/qt5/src/poppler-qt5.h
@@ -1,7 +1,7 @@
 /* poppler-qt.h: qt interface to poppler
  * Copyright (C) 2005, Net Integration Technologies, Inc.
  * Copyright (C) 2005, 2007, Brad Hards <bradh at frogmouth.net>
- * Copyright (C) 2005-2015, Albert Astals Cid <aacid at kde.org>
+ * Copyright (C) 2005-2015, 2017, Albert Astals Cid <aacid at kde.org>
  * Copyright (C) 2005, Stefan Kebekus <stefan.kebekus at math.uni-koeln.de>
  * Copyright (C) 2006-2011, Pino Toscano <pino at kde.org>
  * Copyright (C) 2009 Shawn Rutledge <shawn.t.rutledge at gmail.com>
@@ -1523,6 +1523,13 @@ QString subject = m_doc->info("Subject");
 	FormType formType() const;
 
 	/**
+	   Returns the calculate order for forms (using their id)
+
+	   \since 0.53
+	*/
+	QVector<int> formCalculateOrder() const;
+
+	/**
 	   Destructor.
 	*/
 	~Document();


More information about the poppler mailing list