Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2012-08

html control from turbopower_ipro that comes with lazarus

3 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Ajeandro Gonzalo

There is no Lines or Items property and the example programs only show how to load a html file. I can't find any documentation.

But how can this control be used like Delphi's RichEdit control to just add color and bold (for example) to simple text? Anyone have code or documentation for this use?

I can't get RichMemo to compile on Win 7 64 bit.

Thanks in advance for any help you can give me.

A. G.

Reply by email

Howard Page-Clark
to Ajeandro Gonzalo
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>

Howard

Reply by email

Mattias Gaertner
to Howard Page-Clark
Show quoted text 17 lines
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

Reply by email