locked
Why line spacing of these RichEditBoxs are different? RRS feed

  • Question

  • I have two RichEditBoxs like attached file.

    Both RichEditBox are created by same function,then I changed only BackGroundColor and Canvas.Left and Top.

    Originary I copied content from visual studio and web page on Opera,then pasted to RichEditBox on right side.

    Then I get RTF string from right one with TextGetOptions.FormatRtf,then set this string to the left one with TextSetOptions.FormatRtf. It means both contents are same. But obviously line spaces of both are different.

    I can't reproduce this ,but sometimes it happens.

    I wanna know why it happens and where should I check to determine which property's difference makes this difference.

    I checked RichEditBox.Document.GetRange(50,50).ParagraphFormat, but they looks similar.

    Regards,image


    cyclops

    Saturday, November 23, 2013 4:54 AM

Answers

  • Hi Jamles,

    Sorry,I can't reproduce this also.

    When it happened,there were five RichEditBox. Just one of them produced this issue. I tried to repro by text from VS and browser,but I failed.

    If I succeed to repro,I'll provide it here.


    cyclops

    Wednesday, November 27, 2013 11:34 PM

All replies

  • Hi Cyclops,

    I cannot reproduce the issue you are facing, I'm not sure if the issue related with line spacing setting http://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.text.itextparagraphformat.setlinespacing.aspx or the FontFamily. But it seems the content from the left one just copied from the right one, should be same.

    Could you provide me the code that you are using that I can do a further test, include the text you copied from VS and browser.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, November 25, 2013 11:37 AM
    Moderator
  • Hi Jamles,

    Sorry,I can't reproduce this also.

    When it happened,there were five RichEditBox. Just one of them produced this issue. I tried to repro by text from VS and browser,but I failed.

    If I succeed to repro,I'll provide it here.


    cyclops

    Wednesday, November 27, 2013 11:34 PM