How to justify a single line in a paragraph? RRS feed

  • Question

  • I'm recently working on a text editor application using RichTextBox. I'm able to divide the user's input text into multiple pages when the text content size is bigger than the page size by taking the overflowing text into another page. The the paragraphs are well justified right-to-left and left-to-tight except the last line in the last paragraph when I'm taking that overflowing text into the newly created page. This line should be justified like the others lines in the same paragraph because it has a another part in the next page.

    I know I can use space mono fonts and replace the blank spaces with measured size of space characters. But it seem to cause another font problem inside the text.

    How can I make that last line justified to the end of page width?

    Sunday, July 28, 2019 7:03 AM

All replies

  • Hi

    Here is alink to my version of a RTB editor. Not fantastic, but seems to do all the formatting OK, including Justification over page breaks.

    It has a novel way of dealing with ContextMenus, just a trial of an idea.

    It loads a sample file, but has a Load File option to get rid of that.

    This is a LINK to the complete VB Project file set, see if there is anything there that helps.

    Regards Les, Livingston, Scotland

    • Edited by leshay Sunday, July 28, 2019 2:00 PM
    Sunday, July 28, 2019 1:55 PM