[Lazarus] html control from turbopower_ipro that comes with lazarus

Mattias Gaertner nc-gaertnma at netcologne.de
Thu Aug 23 23:25:30 CEST 2012


On Thu, 23 Aug 2012 20:46:21 +0100
Howard Page-Clark <hdpc at talktalk.net> wrote:

> On 23/8/12 8:17, Ajeandro Gonzalo wrote:
> 
> > But how can this control be used like Delphi's RichEdit control to just
> > add color and bold (for example) to simple text?
> 
> AFAIK the control itself has no colouring or emboldening capabilities 
> beyond its ability to render valid html text correctly.
> You have to adapt your text data, i. e. save it as an .html file and 
> insert the HTML tags yourself.
> So the text 'This has a single *bold* word' would need to be saved as 
> (say) test.html containing the data:
> 
> <html>
> <body>
> This has a single <b>bold</b> word
> </body>
> </html>

You don't need to save it. You can load it from any stream including a
TMemoryStream.

Mattias




More information about the Lazarus mailing list