Which version of RTF standard does the RadRichTextBox support?

2 posts, 0 answers
  1. Aggie
    Aggie avatar
    3 posts
    Member since:
    Apr 2011

    Posted 07 Apr 2011 Link to this post

    Hello,

    I'm trying to find out which version of the RTF standard the RadRichTextBox supports? I'm trying to set column widths in a table and while the document displays correctly in Word it does not look correct in RadRichTextBox. Using code like below to set column width to 20% of the table width:
    \clftsWidth2\clwWidth1000\cellx1

    Additionally, specifying absolute cell width like \cellx1234 produces an exception in RadRichTextBox "ColumnSpan must be at least 1".
    Is there any way to format tables correctly inside RadRichTextBox? I don't mind specifying absolute sizes as long as they are displayed correctly!

    Cheers,
    Aggie


  2. Alex
    Admin
    Alex avatar
    130 posts

    Posted 13 Apr 2011 Link to this post

    Hi Aggie,

    The RTF support for the RadRichTextBox is being developed according to RTF v.1.9.1 specification (you can download it from here). 

    As for specifying cell widths - your approach by using the \clftsWidth and \clwWidth control words is correct. However the \cellx control word cannot be omitted as it marks the end of cell definition. Also note that according to the RTF the specification cellx defines the right boundary of a table cell. So it is not only the width of the individual cell but the sum of that with and the widths of all the cells before it. In the case when an explicit cell width is specified (using the \clftsWidth and \clwWidth control words) the actual values of the \cellx tags are ignored, but still these values must be in increasing order otherwise you will probably get the "ColumnSpan must be at least 1" exception. 

    To make thing clearer here is a short example of a table with two columns 40% and 60% of the width:

    \pard\intbl\itap1 first cell\cell\pard\intbl\itap1 second cell\cell\trowd\irow0\trgaph0\clftsWidth2\clwWidth2000\cellx2000\clftsWidth2\clwWidth3000\cellx5000\row

    Please don't hesitate to contact us again if you have more questions.

    Regards,
    Alex
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top