[Poppler-bugs] [Bug 81665] Extend support for free text annotations.

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Jul 23 06:21:45 PDT 2014


https://bugs.freedesktop.org/show_bug.cgi?id=81665

--- Comment #6 from Carlos Garcia Campos <carlosgc at gnome.org> ---
Comment on attachment 103328
  --> https://bugs.freedesktop.org/attachment.cgi?id=103328
4/4. Core: Fix issue when adding annot without contents

Review of attachment 103328:
-----------------------------------------------------------------

::: poppler/Annot.cc
@@ +3015,5 @@
>      fontsize = 10;
>    if (fontcolor == NULL)
>      fontcolor = new AnnotColor(0, 0, 0); // Black
> +  if (!contents)
> +         contents = new GooString ("");

hmm, the thing is a bit inconsistent with regards to contents. In
Annot::initialize we set it to NULL when the entry is not present in the dict,
but in Annot::setContents() we create an empty GooString when the new contents
are NULL. I think we should either set it to NULL in Annot::setContents() or
create an empty string in Annot::initialize. If we decide to use NULL for no
contents, it would be better to check it here and not add any text operator to
the appearance stream when it's NULL.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/poppler-bugs/attachments/20140723/4fc5370e/attachment.html>


More information about the Poppler-bugs mailing list