Uploaded image for project: 'Pivot'
  1. Pivot
  2. PIVOT-992

"getSelectedText" in TextPane always gets a trailing newline regardless of whether the end of line is selected or not

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.0.4, 2.1
    • 2.1, 2.0.5
    • wtk
    • None

    Description

      Because of the way the "getSelectedText()" method is implemented it will construct a separate document containing an enclosing paragraph and then put the selected range of stuff into that document. But for simple text, that enclosing paragraph causes the PlainTextSerializer to output a line break. Thus the selected text result will always end in a newline even if the selection does not encompass the end of the line. This differs from the result of "getText(...)" using the selection bounds.

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            rwhitcomb Roger Lee Whitcomb
            rwhitcomb Roger Lee Whitcomb
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment