Hi,

thanks for making poppler!
Attached are two small patches
 Make-glib-API-reference-more-complete.patch
 glib-small-doc-comment-corrections.patch
with the hope that they are useful or can be improved to be.

I also have a question: It seems to me that the poppler API uses three
different ways to make embedded files accessible for different types:
- PDFDoc.getCatalog().embeddedFile(i) returning EmbFile
- AnnotFileAttachment::getFile
  that stops short of returning EmbFile (qt bindings seem to access
  things via EmbFile, thoug)
- Apparently Movie::outputToFile is different here.

Is it OK to model access to file attachment annotations after the the
document-attachment (that wraps the access via
PDFDoc.getCatalog().embeddedFile)?

Kind regards

T.
-- 
Thomas Viehmann, http://thomas.viehmann.net/
>From 26682e40325dd1fdcf16ae6a37b5d0aefea08e93 Mon Sep 17 00:00:00 2001
From: Thomas Viehmann <[email protected]>
Date: Sat, 17 Jan 2009 12:58:20 +0100
Subject: [PATCH] Make glib API reference more complete

---
 glib/reference/poppler-docs.sgml        |    2 +
 glib/reference/poppler-sections.txt     |   55 +++++
 glib/reference/tmpl/poppler-action.sgml |    9 +-
 glib/reference/tmpl/poppler-annot.sgml  |  368 +++++++++++++++++++++++++++++++
 glib/reference/tmpl/poppler-layer.sgml  |   79 +++++++
 5 files changed, 511 insertions(+), 2 deletions(-)
 create mode 100644 glib/reference/tmpl/poppler-annot.sgml
 create mode 100644 glib/reference/tmpl/poppler-layer.sgml

diff --git a/glib/reference/poppler-docs.sgml b/glib/reference/poppler-docs.sgml
index 103dd9c..e75d4cd 100644
--- a/glib/reference/poppler-docs.sgml
+++ b/glib/reference/poppler-docs.sgml
@@ -15,5 +15,7 @@
     <xi:include href="xml/poppler-attachment.xml"/>
     <xi:include href="xml/poppler-form-field.xml"/>
     <xi:include href="xml/poppler-enums.xml"/>
+    <xi:include href="xml/poppler-annot.xml"/>
+    <xi:include href="xml/poppler-layer.xml"/>
   </chapter>
 </book>
diff --git a/glib/reference/poppler-sections.txt b/glib/reference/poppler-sections.txt
index fe0cb99..5388be0 100644
--- a/glib/reference/poppler-sections.txt
+++ b/glib/reference/poppler-sections.txt
@@ -253,3 +253,58 @@ PopplerPage
 <FILE>stamp-poppler-enums</FILE>
 </SECTION>
 
+<SECTION>
+<FILE>poppler-annot</FILE>
+PopplerAnnot
+poppler_annot_callout_line_copy
+poppler_annot_callout_line_free
+poppler_annot_callout_line_get_type
+poppler_annot_callout_line_new
+poppler_annot_external_data_type_get_type
+poppler_annot_flag_get_type
+poppler_annot_free_text_get_callout_line
+poppler_annot_free_text_get_quadding
+poppler_annot_free_text_get_type
+poppler_annot_free_text_quadding_get_type
+poppler_annot_get_annot_type
+poppler_annot_get_color
+poppler_annot_get_contents
+poppler_annot_get_flags
+poppler_annot_get_id
+poppler_annot_get_modified
+poppler_annot_get_name
+poppler_annot_get_type
+poppler_annot_mapping_copy
+poppler_annot_mapping_free
+poppler_annot_mapping_get_type
+poppler_annot_mapping_new
+poppler_annot_markup_get_date
+poppler_annot_markup_get_external_data
+poppler_annot_markup_get_label
+poppler_annot_markup_get_opacity
+poppler_annot_markup_get_popup_is_open
+poppler_annot_markup_get_reply_to
+poppler_annot_markup_get_subject
+poppler_annot_markup_get_type
+poppler_annot_markup_reply_type_get_type
+poppler_annot_movie_get_movie
+poppler_annot_movie_get_title
+poppler_annot_movie_get_type
+poppler_annot_text_get_icon
+poppler_annot_text_get_is_open
+poppler_annot_text_get_state
+poppler_annot_text_get_type
+poppler_annot_text_state_get_type
+poppler_annot_type_get_type
+</SECTION>
+
+<SECTION>
+<FILE>poppler-layer</FILE>
+poppler_layer_get_type
+poppler_layer_get_title
+poppler_layer_is_visible
+poppler_layer_show
+poppler_layer_hide
+poppler_layer_is_parent
+poppler_layer_get_radio_button_group_id
+</SECTION>
diff --git a/glib/reference/tmpl/poppler-action.sgml b/glib/reference/tmpl/poppler-action.sgml
index e887187..4a10a17 100644
--- a/glib/reference/tmpl/poppler-action.sgml
+++ b/glib/reference/tmpl/poppler-action.sgml
@@ -1,8 +1,8 @@
 <!-- ##### SECTION Title ##### -->
-poppler-action
+PopplerAction
 
 <!-- ##### SECTION Short_Description ##### -->
-
+Action links
 
 <!-- ##### SECTION Long_Description ##### -->
 <para>
@@ -109,6 +109,11 @@ poppler-action
 
 @type: 
 @title: 
+...@operation: 
+...@has_annotation_ref: 
+...@has_annotation_title: 
+...@annotation_title: 
+...@annotation_id: 
 
 <!-- ##### STRUCT PopplerDest ##### -->
 <para>
diff --git a/glib/reference/tmpl/poppler-annot.sgml b/glib/reference/tmpl/poppler-annot.sgml
new file mode 100644
index 0000000..e5046ec
--- /dev/null
+++ b/glib/reference/tmpl/poppler-annot.sgml
@@ -0,0 +1,368 @@
+<!-- ##### SECTION Title ##### -->
+PopplerAnnot
+
+<!-- ##### SECTION Short_Description ##### -->
+Annotations
+
+<!-- ##### SECTION Long_Description ##### -->
+<para>
+
+</para>
+
+<!-- ##### SECTION See_Also ##### -->
+<para>
+
+</para>
+
+<!-- ##### SECTION Stability_Level ##### -->
+
+
+<!-- ##### STRUCT PopplerAnnot ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION poppler_annot_callout_line_copy ##### -->
+<para>
+
+</para>
+
+...@callout: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_callout_line_free ##### -->
+<para>
+
+</para>
+
+...@callout: 
+
+
+<!-- ##### FUNCTION poppler_annot_callout_line_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_callout_line_new ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_external_data_type_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_flag_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_free_text_get_callout_line ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_free_text_get_quadding ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_free_text_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_free_text_quadding_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_annot_type ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_color ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_contents ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_flags ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_id ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_modified ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_name ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_mapping_copy ##### -->
+<para>
+
+</para>
+
+...@mapping: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_mapping_free ##### -->
+<para>
+
+</para>
+
+...@mapping: 
+
+
+<!-- ##### FUNCTION poppler_annot_mapping_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_mapping_new ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_date ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_external_data ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_label ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_opacity ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_popup_is_open ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_reply_to ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_subject ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_markup_reply_type_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_movie_get_movie ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_movie_get_title ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_movie_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_text_get_icon ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_text_get_is_open ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_text_get_state ##### -->
+<para>
+
+</para>
+
+...@poppler_annot: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_text_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_text_state_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_annot_type_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
diff --git a/glib/reference/tmpl/poppler-layer.sgml b/glib/reference/tmpl/poppler-layer.sgml
new file mode 100644
index 0000000..a2fe01c
--- /dev/null
+++ b/glib/reference/tmpl/poppler-layer.sgml
@@ -0,0 +1,79 @@
+<!-- ##### SECTION Title ##### -->
+PopplerLayer
+
+<!-- ##### SECTION Short_Description ##### -->
+
+
+<!-- ##### SECTION Long_Description ##### -->
+<para>
+
+</para>
+
+<!-- ##### SECTION See_Also ##### -->
+<para>
+
+</para>
+
+<!-- ##### SECTION Stability_Level ##### -->
+
+
+<!-- ##### FUNCTION poppler_layer_get_type ##### -->
+<para>
+
+</para>
+
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_layer_get_title ##### -->
+<para>
+
+</para>
+
+...@layer: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_layer_is_visible ##### -->
+<para>
+
+</para>
+
+...@layer: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_layer_show ##### -->
+<para>
+
+</para>
+
+...@layer: 
+
+
+<!-- ##### FUNCTION poppler_layer_hide ##### -->
+<para>
+
+</para>
+
+...@layer: 
+
+
+<!-- ##### FUNCTION poppler_layer_is_parent ##### -->
+<para>
+
+</para>
+
+...@layer: 
+...@returns: 
+
+
+<!-- ##### FUNCTION poppler_layer_get_radio_button_group_id ##### -->
+<para>
+
+</para>
+
+...@layer: 
+...@returns: 
+
+
-- 
1.5.6.5

>From 8e1ebf9752e954078a51d20dc585588e7175a776 Mon Sep 17 00:00:00 2001
From: Thomas Viehmann <[email protected]>
Date: Sat, 17 Jan 2009 13:16:38 +0100
Subject: [PATCH] glib small doc comment corrections

---
 glib/poppler-attachment.cc |    2 +-
 glib/poppler-layer.cc      |    2 ++
 glib/poppler.cc            |    2 --
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/glib/poppler-attachment.cc b/glib/poppler-attachment.cc
index b51dbbe..1c3eef0 100644
--- a/glib/poppler-attachment.cc
+++ b/glib/poppler-attachment.cc
@@ -187,7 +187,7 @@ poppler_attachment_save (PopplerAttachment  *attachment,
 
 /**
  * poppler_attachment_save_to_callback:
- * @attachment: A #GdkPixbuf.
+ * @attachment: A #PopplerAttachment.
  * @save_func: a function that is called to save each block of data that the save routine generates.
  * @user_data: user data to pass to the save function.
  * @error: return location for error, or %NULL.
diff --git a/glib/poppler-layer.cc b/glib/poppler-layer.cc
index 2049dc7..43aa85a 100644
--- a/glib/poppler-layer.cc
+++ b/glib/poppler-layer.cc
@@ -171,6 +171,7 @@ poppler_layer_hide (PopplerLayer *poppler_layer)
 
 /**
  * poppler_layer_is_parent
+ * @layer: a #PopplerLayer
  *
  * Returns whether @layer is parent of other nested layers.
  *
@@ -186,6 +187,7 @@ poppler_layer_is_parent (PopplerLayer *poppler_layer)
 
 /**
  * poppler_layer_get_radio_button_group_id
+ * @layer: a #PopplerLayer
  *
  * Returns the numeric ID the radio button group associated with @layer.
  *
diff --git a/glib/poppler.cc b/glib/poppler.cc
index 541cc1b..3c1d503 100644
--- a/glib/poppler.cc
+++ b/glib/poppler.cc
@@ -31,7 +31,6 @@ GQuark poppler_error_quark (void)
 
 /**
  * poppler_get_backend:
- * @void: 
  * 
  * Returns the backend compiled into the poppler library.
  * 
@@ -53,7 +52,6 @@ static const char poppler_version[] = PACKAGE_VERSION;
 
 /**
  * poppler_get_version:
- * @void: 
  * 
  * Returns the version of poppler in use.  This result is not to be freed.
  * 
-- 
1.5.6.5

_______________________________________________
poppler mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/poppler

Reply via email to