Page 1 of 1
Marges
Posted: Thu Dec 22, 2005 4:26 pm
by Benoit B.
Hi,
How to code my rtf for TRichPrint understand my marges ?
Currently, I'm writting like that :
Word know this syntaxe but RichView ignor that.
How to do ?
Thank.
Posted: Thu Dec 22, 2005 9:30 pm
by Sergey Tkachenko
Margins are not read from RTF files.
There is a temporal solution - you need to compile you application with the define RICHVIEW_DPMARGINS (for example, place {$DEFINE RICHVIEW_DPMARGINS} in RV_Defs.inc - of course, a source code version of TRichView is required)
Margins will be read from RTF in RichView.DocProperties, in stings like
'LeftMarginMM=20'.
You can then assign these values to properties of RVPrint.
Posted: Wed Jan 11, 2006 11:54 am
by Tomas
Why page margins are not read from RTF by default? Is it some reason for that? Why you have named it as "temporal solution"?
We asking this because we also need read RTF margins in our current app and we are afraid that enabling Margins can cause side effect on TRichView.
Posted: Thu Jan 12, 2006 7:40 pm
by Sergey Tkachenko
This solution is temporal because DocProperties was designed to store custom user properties, not standard document properties like margins.
Initially TRichView was not designed as WYSIWYG editor, it was assumed that page layout properties are not document but application properties (the same for all documents). What's why TRichViews do not have page layout properties, they are concentrated in TRVPrint component which can be used by many TRichViews.
It will be changed in future.