Sorry if I mislead you Hack but what I meant was that I wanted to reproduce the look of, for example, the entirety of post #1 in a richtextbox. In other words a shaded box within the RTB. It will take modifications to the RTB's TextRTF property and I've done a bunch of that in my Private Message Viewer (shameless plug), but so far I haven't been successful with the box. BTW if you or anyone else is interested here is the official RTF spec sheet.
I have not worked with RichTextBoxes, but, is it possible
to use the Line method in one?
If so, perhaps you could set ForeColor to light gray, and use the BF
parameters. There would be several tricky aspects to this:
-- 1. getting the correct x,y coordinates
-- 2. the shaded area would need to be "painted" before the text is added,
or else the text would be "wiped out" by the fill.
If that doesn't work, is it possible to embed a RichTextBox control
in a RichTextBox? If so, the embedded controls could possibly be
a control array (for multiple uses) -- would that do you any good?
Thanks. It looks like someone took the four class modules written by moeur that I just found that deal with rtf and added other stuff.
from the date i put on the folder, that would probably be me. i just added the table before i posted. The table i copied from my app. in my app it opens a form
to display how many columns, centered and width options. i have noticed that typing into the table the text can run past the table borders and not contained within the table.
Waiting for a full featured smart phone with out marrying a provider
Go Android
Go raiders
I tried to modify the code so that I can set a row's height to 1000 twips using the \trrh row height parameter and as you see here the Debug.Print display of strInsert looks like
{\colortbl ;\red221\green221\blue221;}
\highlight1\par\trowd\trqc\trgaph10\trleft36\trrh1000\cellx8248\pard\intbl Originally Posted by MartinLiss\cell\row
\pard
\par
but when strInsert is inserted into the rich text the result is
{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fcharset0 MS Sans Serif;}}
{\colortbl ;\red221\green221\blue221;}
\viewkind4\uc1\pard\highlight1\f0\fs17
\par \trowd\trgaph10\trleft36\trqc\cellx8248\pard\intbl Originally Posted by MartinLiss\cell\row
\pard
\par
\par }
Too bad you've gone so far using RTF markup already.
The DHTMLEdit control in "browse mode" make a nice alternative document canvas. I prefer it to a WebBrowser control because you can use it for input as well in "edit mode." Like the difference between a Label and a TextBox.
RTF itself just isn't as human-friendly as HTML + CSS even though they're both plain-text markup. HTML and CSS are well documented for the Trident rendering engine underlying most of Microsoft's HTML software - right in your MSDN Library. IE, MSHTML, WebBrowser control, and DHTMLEdit control all use the Trident engine.
I tried to modify the code so that I can set a row's height to 1000 twips using the \trrh row height parameter and as you see here the Debug.Print display of strInsert looks like
but when strInsert is inserted into the rich text the result is
Grrrrr.
I have a module for line spacing i will upload it and maybe it will help. Don' remember why I have it. I have went a few rounds with rtb and quite a few times. I know what you mean
Waiting for a full featured smart phone with out marrying a provider
Go Android
Go raiders
I have a module for line spacing i will upload it and maybe it will help. Don' remember why I have it. I have went a few rounds with rtb and quite a few times. I know what you mean
I don't think that applies to me. I'm trying to to increase the height of a line (actually a table with one row and one column) rather than increasing the spacing between lines.
I don't think that applies to me. I'm trying to to increase the height of a line (actually a table with one row and one column) rather than increasing the spacing between lines.
Seems i remember the tables height is based on the height of text be used for that row
Waiting for a full featured smart phone with out marrying a provider
Go Android
Go raiders
If what you say is true then why does the spec say this about \trrh?
Height of a table row in twips. When 0, the height is sufficient for all the text in the line; when positive, the height is guaranteed to be at least the specified height; when negative, the absolute value of the height is used, regardless of the height of the text in the line.