Hi mabri,

What I want is to read destinations(bookmarks) from PDF documents. 
Though I would prefer later pdf versions to be my input(later than 1.2) ,I 
guess even later PDF version could be produced with backward compatibility in 
mind, so having Destinations with PdfName object. 

Having support for destinations with PdfName object would make the class even 
more complete.

Regards
Jaseem

-----Original Message-----
From: Matthew Brincke [mailto:mabr...@ymail.com] 
Sent: 24 April 2016 21:28
To: podofo-users@lists.sourceforge.net
Subject: Re: [Podofo-users] Destination with Pdf Name object

Hi Ali, hi PoDoFo developers, 


that method you mentioned is private, but called by a public 

constructor taking the same arguments, so for making a new 

PdfDestination object it's effective public, but (reading it): 


- only when called with a PdfObject which is an array, that 

  array is written into the PdfDestination object,

- when called with a string PdfObject, the string is searched as 

  key in the given document's "Dests" name tree (PDF 1.2 feature 

  per the gratis-downloaded PDF 1.7 spec PDF32000_2008.pdf), if 

  it's not found, an exception is thrown (code ePdfError_InvalidName). 

  So this isn't for making an entirely new destination, but reading 

  it from a document (which is required to be at least a PDF 1.2 one). 


Associating a string with a destination and writing it into a document 

(of at least version PDF 1.2) is done by the (abstract base class) method 

PdfDocument::AddNamedDestination(const PdfDestination &         rDest, 

                                 const PdfString &      rsName)

with rDest not constructed from a string PdfObject (and a document), 

because otherwise the internal PdfObject of the PdfDestination would become 

a string one, thus that PdfDocument method recording a reference to that 

string, which isn't conforming to the PDF 1.7 spec clause 12.3.2.3 (allowing 

only array and some dictionary). 

I consider this ("otherwise ...") to be a bug in PdfDestination's Init method.
According to Note 3 in that clause making a Named Destination with a name 
object (in PoDoFo: a PdfName), then recorded in the "Dests" entry in the 
document catalogue, should be used only if backward compatibility is a 
consideration. So, please inform me about what you (Ali) want: 


- reading destinations from documents using the PDF 1.1 form of storing them 

- writing destinations to documents in a form conforming to PDF 1.1 

- both

- neither (this post contains enough info for you, Ali, to proceed)?

I would fix the bug I mentioned anyway if you (PoDoFo developer/s) don't give 
me convincing reasons for that being no bug. To give you time for this I'll 
tend to another PoDoFo issue first, I hope today.

Best regards, mabri



----- Original Message -----
From: Jaseem Ali K T <jaseemal...@hcl.com>
To: Matthew Brincke <mabr...@ymail.com>; "podofo-users@lists.sourceforge.net" 
<podofo-users@lists.sourceforge.net>
Sent: Friday, 22 April 2016, 10:18 UTC
Subject: RE: [Podofo-users] Destination with Pdf Name object

Hi mabri

Please have a look at the function void PdfDestination::Init( PdfObject* 
pObject, PdfDocument* pDocument ) in PdfDestination.cpp.


Thanks and Regards
Ali


-----Original Message-----
From: Matthew Brincke [mailto:mabr...@ymail.com]
Sent: 22 April 2016 03:29
To: Jaseem Ali K T <jaseemal...@hcl.com>; podofo-users@lists.sourceforge.net
Subject: Re: [Podofo-users] Destination with Pdf Name object



Hi Ali, hi PoDoFo developers,


in the documentation for the PoDoFo class PdfDestination I haven't seen string 
support either. Where did you get that from, please? With a better 
understanding of this I might be able to produce a patch to add what you 
require (I'm sorry for answering so late), so could you please explain a bit 
more?

Best regards, mabri


________________________________
From: Jaseem Ali K T <jaseemal...@hcl.com>
To: "podofo-users@lists.sourceforge.net" <podofo-users@lists.sourceforge.net>
Sent: Thursday, 17 March 2016, 17:15 UTC
Subject: [Podofo-users] Destination with Pdf Name object




Hi All

As per PDF Reference destinations can be either explicit, in which case the 
data type used would be array, or named, in which case the data type would 
either string or PdfName. I checked the PoDoFo destination class. It seems to 
be only supporting string and array. Any reason why this is the case?


And is there any way to create named destination with PdfName object (through 
PoDoFo, or any other methods)? 
Thanks and Regards,
Ali

::DISCLAIMER::
----------------------------------------------------------------------------------------------------------------------------------------------------
The contents of this e-mail and any attachment(s) are confidential and intended 
for the named recipient(s) only.
E-mail transmission is not guaranteed to be secure or error-free as information 
could be intercepted, corrupted, 
lost, destroyed, arrive late or incomplete, or may contain viruses in 
transmission. The e mail and its contents 
(with or without referred errors) shall therefore not attach any liability on 
the originator or HCL or its affiliates. 
Views or opinions, if any, presented in this email are solely those of the 
author and may not necessarily reflect the 
views or opinions of HCL or its affiliates. Any form of reproduction, 
dissemination, copying, disclosure, modification, 
distribution and / or publication of this message without the prior written 
consent of authorized representative of 
HCL is strictly prohibited. If you have received this email in error please 
delete it and notify the sender immediately. 
Before opening any email and/or attachments, please check them for viruses and 
other defects.
----------------------------------------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231&iu=/4140
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
_______________________________________________
Podofo-users mailing list
Podofo-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to