Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4302891

JTextArea should document that \n is used for newlines

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 1.4.0
    • 1.3.0
    • docs
    • beta
    • generic
    • generic



      Name: mc57594 Date: 01/05/2000


      12/30/99 eval1127@eng -- see also 4256058, 4221296

      java version "1.3beta"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.3beta-O)
      Java(TM) HotSpot Client VM (build 1.3beta-O, mixed mode)

      Swing text seems to use Unicode to specify newlines, not
      platform dependent encodings (such as \r\n). This should
      be specified in the help. It should especially be specified
      in the help for JTextArea since this differs from java.awt.TextArea.

      The following is taken from bug number 4256058:
      The swing text package models newlines as \n's. Other platforms that model
      newlines differently must be converted to \n. Use the EditorKits read method,
      which will do this conversion as necessary as well as setting an internal
      flag as to what the newline should be. If done in this manner the write
      method will map the internal notion of newlines to the format found from
      the read method.
      (Review ID: 99429)
      ======================================================================

            sharonz Sharon Zakhour (Inactive)
            mchamnessunw Mark Chamness (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: