On Tuesday 15 May 2007, GAMBELLI Raffaele wrote: > I have also modified RtfElement.TWIPS_FACTOR and set it to 15 instead of > 20. The reason is simply, Microsoft Word 2000 does it like this. In this case you have also changed all other measurements. This might lead to strange side-effects. You probably only want to change the usage in RtfImage.
> In particular when you save a rtf using Word, you'll see that the values of > \picwgoal and \pichgoal are respectively the width in pixel of image * 15 > and the height in pixel of image * 15. > > Also in Wikipedia is stated that 15 twips equals to 1 pixel. > From MSDN \picwgoalN is the desired width of the picture in twips and so > the formula is easy. Of course that's easy, but it's only easy if you are just generating RTF. In that case you get behaviour that matches what Word does. If you are generating both RTF and PDF then it is not so easy, as the generated RTF and PDF files then look different. It's a question of what you require. Word equivalence or PDF equivalence. > Other question [RTF does not support GIF] > I saw that Word for GIF use the control word \pngblip (in fact also png > supports trasparency). And so I have simply added the support of GIF to RTF > writing that control word when I have to add a GIF to the document and the > game is done ;-) Now RTF supports GIF, certainly with trasparency. Sounds good :-). When I've got a solution for the current image issues, I'll test this at my end and then add it into the main codebase. Greetings, Mark -- Avoid reality at all costs. My GPG public key is available at: http://www.edu.uni-klu.ac.at/~mhall/data/security/MarkHall.asc
pgpbQ6szzTUhK.pgp
Description: PGP signature
------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/
_______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
