Jeremias,

1- i actually have several other metadatas to associate to the attachment:
a- the name of the user that associated the file
b- the date it was done
c- a status regarding the attached file, ...

while i could use embeddedfiles dictionary at pdf level and i could try to pack
all informations in the description PDF entry but i was rather interested in the
use of FOP to embed not only file, but also these related informations in the
pdf. therefore, it looked like a PDFLink (that goes through annotation as well),
except it does not refers to any text element within.

i am intending to get someting in the pdf like:

+ {date}    {user}    {status}    [file]:   {comment}
+ {date2}   {user2}   {status2}   [file2]:  {comment2}

2- i've been contacting Andrejus a few days ago but the implementation i saw
uses xobject rather than embeddedfile (EF) object. therefore, i am in the
process of writing an extension ... that would behave like a fo:basic-link
except it does not accept any other object inside.
therefore, i was thinking of an empty area (to reserve space) and an annotation.

do you think i could go the other way (regular embeddedfiles) with the other
requirements (associated meta-datas) ?

Daniel,

> On 17.03.2008 09:43:37 thebluemountain wrote:
> > Hi,
> >
> > I need to support embedding files as attachment when generating pdf file.
> >
> > I've been
> > - registering my element (using element mapping class). the Attachment
> class
> > extends the AbstractGraphics
>
> An embedded file doesn't have any visual appearance in the PDF file so
> deriving from AbstractGraphics is wrong.
>
> > now, for the layout manager, i've been trying to extend the
> > AbstractGraphicsLayoutManager: however, the class defines a method abstract
> Area
> > getChildArea() that prevents from extending, unless from same package.
> >
> > What i've then been doing was copying the AbstractGraphicsLayoutManager
> code
> > into my AttachmentLayoutManager that now extends LeafNodeLayoutManager.
> >
> > 1- Is there any reason the getChildArea () is restricted to classes in same
> > package ?
>
> AFAIK, noone has written an external extension that requires a layout
> manager, yet. It could very well be that this will require some tweaking
> the first time someone does that. But as mentioned above for your case
> this is the wrong approach.
>
> > 2- Should I do it another way ?
>
> Yes. Take a look at https://issues.apache.org/bugzilla/show_bug.cgi?id=44460
> Andrejus Chaliapinas has already started to write a patch for the same
> thing. I rejected the first patch because of the issues listed. Andrejus
> hasn't submitted a new version since. Maybe you can help him finish the
> patch the way we need it. You can contact him through the Bugzilla issue.
> I'll gladly review the improved patch once it's available.
>
> > Thank you for your help
> >
> > Daniel
>
>
>
> Jeremias Maerki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


le

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to