Posted by webmaster Guido on June 05, 2005
In Reply to: Re: set TRichEdit text in bold posted by joe90 on June 04, 2005 That's because SelAttributes starts working from the position where the text cursor is (also called the "insertion point"). You can set this with the SelStart property, like this: RE.SelStart := Length(RE.Text); // Position cursor at end of RichEdit
RE.SelAttributes.Style := [fsBold];
RE.Lines.Add('This should be bold');
RE.SelAttributes.Style := [];
RE.Lines.Add('This should be regular');
webmaster Guido
Related Articles and Replies
|
|