Re: Printing formatted text



"GD1" <euthymos@xxxxxxxxx> wrote in message
news:1157014881.548340.65340@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

You're drawing on a canvas; it has a font.

Yes, I know how to print a bold or an italic text string. But if you
had read the question more carefully, you would have understood that my
problem is quite different.

If you had explained it better, I might have, too. (Go back and read
your question as if you _don't_ know what you mean. '[how can I format]
text within the string' suggested the text on the canvas to me.)

Am I to understand that you want a markup format for your strings to
indicate which parts are to be bold or italic? Well then, a subset of
HTML looks fine to me.

Or some simple markers, for example '\B' for bold-on and '\b' for
bold-off. And '\\' for a literal backslash, don't forget.

Or Chr(2) or '*' or whatever for 'the next character is bold'. Or the
next word.

Or an extra string of the same length, with an attribute byte for every
character, where bit 0 means bold, bit 1 means italic, etcetera.

Groetjes,
Maarten Wiltink


.



Relevant Pages

  • Setting character attributes in a text string
    ... character attributes for a subset of ... Suppose cell A10 contained the string: ... Suppose further that I wish to set the contents of cell C20 ... take on bold or italic characteristics? ...
    (microsoft.public.excel.worksheet.functions)
  • Re: Track Changes VBA Granular information needed
    ... If the second string occurs somewhere in the first ... Bold, Italic". ... If you're keeping separate track of bold formatting and italic ... extract more specific changes. ...
    (microsoft.public.word.vba.beginners)
  • Re: 2 different formats of text in a single cell?
    ... Enter the text "Some bold and red words" in A1 and then give this code a try... ... Dim Word As String ... Select the desired formatting, and that will be applied to the def. ...
    (microsoft.public.excel.misc)
  • Re: How to format a string in resource
    ... part into bold type. ... After you added your string into your resource(Through Project ... using a Label or other control to show your string. ... positioning algorithm depends how you and what you use to ...
    (microsoft.public.dotnet.languages.vb)
  • Re: powerpoint automation via vb.net
    ... I am sending list of rows from datagrid to powerpoint. ... If you know the start point and length of the portion you want to make bold (which ... through the string to find the start and stop positions marked by #-marks. ... Dim ppItem As Microsoft.Office.Interop.PowerPoint.Shape ...
    (microsoft.public.office.developer.automation)