From 3e7846eb64186997eadfc0f5c48e4e21d34209a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Aliste?= Date: Sat, 8 Dec 2012 10:33:04 -0300 Subject: [PATCH 1/2] glib: Add poppler_annot_set_flags --- glib/poppler-annot.cc | 18 ++++++++++++++++++ glib/poppler-annot.h | 2 ++ 2 files changed, 20 insertions(+) diff --git a/glib/poppler-annot.cc b/glib/poppler-annot.cc index 1627d25..36e1ea4 100644 --- a/glib/poppler-annot.cc +++ b/glib/poppler-annot.cc @@ -508,6 +508,24 @@ poppler_annot_get_flags (PopplerAnnot *poppler_annot) } /** + * poppler_annot_set_flags: + * @poppler_annot: a #PopplerAnnot + * @flags: a #PopplerAnnotFlag + * + * Sets the flag field specifying various characteristics of the + * @poppler_annot. + * + **/ +void +poppler_annot_set_flags (PopplerAnnot *poppler_annot, PopplerAnnotFlag flags) +{ + g_return_if_fail (POPPLER_IS_ANNOT (poppler_annot)); + + return poppler_annot->annot->setFlags ((guint) flags); +} + + +/** * poppler_annot_get_color: * @poppler_annot: a #PopplerAnnot * diff --git a/glib/poppler-annot.h b/glib/poppler-annot.h index 17440fb..88f4e46 100644 --- a/glib/poppler-annot.h +++ b/glib/poppler-annot.h @@ -162,6 +162,8 @@ void poppler_annot_set_contents ( gchar *poppler_annot_get_name (PopplerAnnot *poppler_annot); gchar *poppler_annot_get_modified (PopplerAnnot *poppler_annot); PopplerAnnotFlag poppler_annot_get_flags (PopplerAnnot *poppler_annot); +void poppler_annot_set_flags (PopplerAnnot *poppler_annot, + PopplerAnnotFlag flags); PopplerColor *poppler_annot_get_color (PopplerAnnot *poppler_annot); void poppler_annot_set_color (PopplerAnnot *poppler_annot, PopplerColor *poppler_color); -- 1.8.0.1