Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-17483

TextArea incorrectly adds trailing newline

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • Adobe Flex SDK 3.2 (Release)
    • None
    • mx: TextArea
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Steps to reproduce:
      1. Open the attached .swf file
      2. Note there is no trailing newline after the last line in the editable TextArea
      3. Click the large button to set the htmlText to a slightly altered version of itself
      4. Note that now there is a trailing newline after the last line of text.
      5. remove the trailing newline and return to step 3 to repeat

      Actual Results:
      a miscreant newline is added to the textArea when it's own input is read

      Expected Results:
      the text should be left unchanged.

      Workaround (if any):
      store the number of characters that should be in the TextArea, and after applying the htmlText and calling text_area.validateNow() check to see if there is an extra character. If so, remove it like this (for a TextArea named text_area):

      text_area.setSelection(text_area.text.length-1, text_area.text.length);
      text_area.replaceSelectedText('');

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: