[gs-bugs] [Bug 691342] (Hyper)Links lost on conversion to PDF

bugzilla-daemon at ghostscript.com bugzilla-daemon at ghostscript.com
Thu May 27 08:57:08 UTC 2010


http://bugs.ghostscript.com/show_bug.cgi?id=691342

Ken Sharp <ken.sharp at artifex.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|tor.andersson at artifex.com   |ken.sharp at artifex.com
           Severity|normal                      |enhancement

--- Comment #2 from Ken Sharp <ken.sharp at artifex.com> 2010-05-27 08:57:05 UTC ---
(In reply to comment #0)

> I'm having another issue with XPS->PDF conversion: when converting a document
> that contains hyperlinks, the format of the links is converted successfully,
> but the links themselves aren't converted. I'm left with a PDF document that
> has something that *looks* like a link, but doesn't do anything when clicked.
> 
> Debugging the code seems to suggest that the link attribute in the XPS file
> (FixedPage.NavigateUri="...") is ignored. Is this a bug or a feature?

I suppose arguably its a missing feature. Right now the XPS->PDF conversion is
a 'best effort' conversion, and is limited to appearance only. This means that
XPS features which do not exist in PDF (certain dash types, line caps and
shadings, among other things) are either converted to the nearest PDF
equivalent, or rendered as images. In addition document metadata such as
hyperlinks is not processed.

In PDF files the Link annotation is stored separately to the appearance, so a
link can look as you would expect, but unless a LNK annotation is created it
won't do anything.

These annotations are normally created in the output PDF file by executing a
PostScript pdfmark operator. When the input file is PDF the PDF interpreter
(which runs in the PostScript environment) converts the PDF annotation into a
pdfmark operation.

The XPS interpreter doesn't (I don't think) handle hyperlinks in the input XPS
document (the XPS interpreter assumes its printing the document), so there is
no pass-through of that information into the output PDF file. Also, the XPS
interpreter doesn't execute in the PostScript environment, so there is no way
to execute a PostScript pdfmark operation.


I've altered this from a bug to an enhancement, because it would be nice to be
able to preserve such features as far as possible. However making the
conversion more robust has a higher priority.

-- 
Configure bugmail: http://bugs.ghostscript.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the gs-bugs mailing list