El sáb, 17-01-2009 a las 19:34 +0100, Thomas Viehmann escribió: > Hi, Hi Thomas,
I'm sorry for the late reply :-( > attached are three patches > - poppler.add-support-for-file-attachment-annotations.patch > As mentioned on IRC know, I'm wondering whether it'd be better to > avoid creating an own GType for each annotation type, in particular > if there is nothing to know beyond the type for users. > For now this patch follows the AnootText example and has its own > type. > An alternative could be to just check the type field and make the > interface take PopplerAnnot. We discussed it when implemented the initial annots support and we decided to use GObjects because we need some logic like GAnnotationMarkup is an interface implemented by other Annotation objects. Then we realized it would be better not use interfaces (I don't remember exactly why), but make Markup inherit from Annot, so that markup annots will inherit from Markup and the other annots will inherit directly from Annot base class. Anyway, I'm afraid it's too late to change the API ... > - poppler.extend-test-poppler-glib-to-show-more-page-annotatio.patch > Makes test-poppler-glib print information about PopplerAnnotation > and > PopplerAction items associated with a page. > This currently depends on the aforementioned patch, but if adopting > that is difficult, I could also separate it out. > - poppler.signedness-of-PopplerAttachment.size.patch > While running test-poppler-glib, I noticed that EmbFile will use > size > -1 to indicate that no size has been specified. This could be > captured > better by making PopplerAttachment.size gssize instead of gsize. Thank you very much for the patches. Some minor comments about the first patch below. > Kind regards > > T. > -- > Thomas Viehmann, http://thomas.viehmann.net/ > > > > > > > > diferencias entre > archivos adjunto > (poppler.add-support-for-file-attachment-annotations.patch) > > diff --git a/glib/poppler-annot.cc b/glib/poppler-annot.cc > index 067afcc..15d7178 100644 > --- a/glib/poppler-annot.cc > +++ b/glib/poppler-annot.cc > @@ -24,6 +24,8 @@ typedef struct _PopplerAnnotClass > PopplerAnnotClass; > typedef struct _PopplerAnnotMarkupClass PopplerAnnotMarkupClass; > typedef struct _PopplerAnnotFreeTextClass PopplerAnnotFreeTextClass; > typedef struct _PopplerAnnotTextClass PopplerAnnotTextClass; > +typedef struct _PopplerAnnotMovieClass PopplerAnnotMovieClass; > +typedef struct _PopplerAnnotFileAttachmentClass > PopplerAnnotFileAttachmentClass; hmm, I guess that PopplerAnnotMovieClass is from another patch or something. > +/* PopplerAnnotFileAttachment */ > +/** > + * poppler_annot_file_attachment_get_attachment: > + * @annot: a #PopplerAnnotFileAttachment > + * > + * Creates a #PopplerAttachment for the file of the file attachment > annotation @annot. > + * The #PopplerAttachment must be freed with g_free by the caller. > + * This is wrong, PopplerAttachment is a GObject and should be free with g_object_unref(), not with g_free() Thanks, -- Carlos Garcia Campos [email protected] [email protected] http://carlosgc.linups.org PGP key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x523E6462
signature.asc
Description: Esta parte del mensaje está firmada digitalmente
_______________________________________________ poppler mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/poppler
