Saving text-style information in RTF files (OnSaveRTFExtra)?
Posted: Thu Dec 21, 2006 4:37 pm
Hi,
i saving additional information in RTF files with the OnSaveRTFExtra event.
I save my footer with following code:
How do I save text-styles for the footer? So that the same text-styles of the footer in the RTF file is saved?
The footer becomes in "MS Word" displayed to example in "Arial 12" instead "Tahoma 7".
Is that difficult?
Regards
Crowbar
i saving additional information in RTF files with the OnSaveRTFExtra event.
I save my footer with following code:
Code: Select all
Procedure TForm.MainRichViewEditSaveRTFExtra(Sender: TCustomRichView; Area: TRVRTFSaveArea; Obj: TObject; Index1, Index2: Integer; InStyleSheet: Boolean; var RTFCode: string);
Var
strFooter : String;
begin
FooterRichViewEdit.SelectAll;
strFooter:=FooterRichViewEdit.GetSelTextW;
FooterRichViewEdit.Deselect;
case Area of
rv_rtfs_Doc : RTFCode:='{\footer\pard\plain\posxc '+strFooter+'\par}';
rv_rtfs_TextStyle : ; // Here ???
end;
end;
The footer becomes in "MS Word" displayed to example in "Arial 12" instead "Tahoma 7".
Is that difficult?
Regards
Crowbar