[Gambas-user] Stickers
Doriano Blengino
doriano.blengino at ...1909...
Tue Oct 21 08:20:50 CEST 2008
Almanova Sistemi ha scritto:
> Hi All,
>
> I try to write an application for print some stickers and I need to format the text in vaious mode (undelined, bold, italics) various color as alignment.
>
> I tried with TextArea, Editor and TextEdit but I have not received a satisfactory result.
> The only way to format a text is to use TextEdit but it give me a problem when I write text and when I print it.
>
> When I write a text and I need to press enter key I must press <Crtl>+<Enter> for avoid a blank line undere the current line.
>
> When I try to print the text inside a TextEdit (I use Draw.RichText(hTextEdit.Text)) and the text contain a <br> the printed first part of the text is overwritten by the seconf paert.
> I obtain the same result if I use something like
> <p>some text</p>
> <p>anohter text</p>
>
What I would do instead is to use no richtext at all. May be I am wrong,
but I think richedit+html is targeted to something different than
labelling, even if richtexts are so handy. With draw.text() you can
print bold text, underline and so on by setting draw.font properties,
and you can place text on paper with great precision. It depends a lot
on what you are doing - for example: these stickers have a fixed format
(template) or they vary a lot? The more they are "fixed" format, the
more a simple draw.text() is good.
Regards,
Doriano
More information about the User
mailing list