the pastefromclipboard method appears to be adding a carriage return when it executes. Thanks
#1
♥ 0
the pastefromclipboard method appears to be adding a carriage return when it executes. Thanks
It appears that the problem does not occur unless you have the following code in the OnNewRTFDataBlock event
RTFDataBlock.RTFProps.AttrHelper.Clear;
RTFDataBlock.RTFProps.AttrHelper.SetFontName('Verdana');
RTFDataBlock.RTFProps.AttrHelper.SetFontSize(10);
RTFDataBlock.FirstPar.LoadedCharAttr := RTFDataBlock.RTFProps.AttrHelper.CharAttr;
Thanks
Hi,
OnNewRTFDataBlock is also called to create the RTFDataBlocks which are used to load the text.
Please wrap your code into
if RTFDataBlock.Kind<>wpisLoadedBody then
begin
...
end;
I is better to apply a fixed char attr to coped text in the BeforePasxte event.
Julian