< prev index next >

src/java.desktop/share/classes/javax/swing/text/DefaultEditorKit.java

Print this page

        

@@ -44,28 +44,28 @@
  *
  * <dl>
  * <dt><b>Newlines</b>
  * <dd>
  * There are two properties which deal with newlines.  The
- * system property, <code>line.separator</code>, is defined to be
+ * system property, {@code line.separator}, is defined to be
  * platform-dependent, either "\n", "\r", or "\r\n".  There is also
- * a property defined in <code>DefaultEditorKit</code>, called
- * <a href=#EndOfLineStringProperty><code>EndOfLineStringProperty</code></a>,
+ * a property defined in {@code DefaultEditorKit}, called
+ * <a href=#EndOfLineStringProperty>{@code EndOfLineStringProperty}</a>,
  * which is defined automatically when a document is loaded, to be
  * the first occurrence of any of the newline characters.
- * When a document is loaded, <code>EndOfLineStringProperty</code>
+ * When a document is loaded, {@code EndOfLineStringProperty}
  * is set appropriately, and when the document is written back out, the
- * <code>EndOfLineStringProperty</code> is used.  But while the document
+ * {@code EndOfLineStringProperty} is used.  But while the document
  * is in memory, the "\n" character is used to define a
  * newline, regardless of how the newline is defined when
  * the document is on disk.  Therefore, for searching purposes,
  * "\n" should always be used.  When a new document is created,
- * and the <code>EndOfLineStringProperty</code> has not been defined,
+ * and the {@code EndOfLineStringProperty} has not been defined,
  * it will use the System property when writing out the
  * document.
- * <p>Note that <code>EndOfLineStringProperty</code> is set
- * on the <code>Document</code> using the <code>get/putProperty</code>
+ * <p>Note that {@code EndOfLineStringProperty} is set
+ * on the {@code Document} using the {@code get/putProperty}
  * methods.  Subclasses may override this behavior.
  *
  * </dl>
  *
  * @author  Timothy Prinzing

@@ -80,11 +80,11 @@
     }
 
     /**
      * Gets the MIME type of the data that this
      * kit represents support for.  The default
-     * is <code>text/plain</code>.
+     * is {@code text/plain}.
      *
      * @return the type
      */
     public String getContentType() {
         return "text/plain";

@@ -571,11 +571,11 @@
      * @see #getActions
      */
     public static final String selectionDownAction = "selection-down";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a word.
      * @see #getActions
      */
     public static final String beginWordAction = "caret-begin-word";
 

@@ -585,11 +585,11 @@
      * @see #getActions
      */
     public static final String endWordAction = "caret-end-word";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a word, extending the selection.
      * @see #getActions
      */
     public static final String selectionBeginWordAction = "selection-begin-word";
 

@@ -599,109 +599,109 @@
      * @see #getActions
      */
     public static final String selectionEndWordAction = "selection-end-word";
 
     /**
-     * Name of the <code>Action</code> for moving the caret to the
+     * Name of the {@code Action} for moving the caret to the
      * beginning of the previous word.
      * @see #getActions
      */
     public static final String previousWordAction = "caret-previous-word";
 
     /**
-     * Name of the <code>Action</code> for moving the caret to the
+     * Name of the {@code Action} for moving the caret to the
      * beginning of the next word.
      * @see #getActions
      */
     public static final String nextWordAction = "caret-next-word";
 
     /**
-     * Name of the <code>Action</code> for moving the selection to the
+     * Name of the {@code Action} for moving the selection to the
      * beginning of the previous word, extending the selection.
      * @see #getActions
      */
     public static final String selectionPreviousWordAction = "selection-previous-word";
 
     /**
-     * Name of the <code>Action</code> for moving the selection to the
+     * Name of the {@code Action} for moving the selection to the
      * beginning of the next word, extending the selection.
      * @see #getActions
      */
     public static final String selectionNextWordAction = "selection-next-word";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a line.
      * @see #getActions
      */
     public static final String beginLineAction = "caret-begin-line";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the end of a line.
      * @see #getActions
      */
     public static final String endLineAction = "caret-end-line";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a line, extending the selection.
      * @see #getActions
      */
     public static final String selectionBeginLineAction = "selection-begin-line";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the end of a line, extending the selection.
      * @see #getActions
      */
     public static final String selectionEndLineAction = "selection-end-line";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a paragraph.
      * @see #getActions
      */
     public static final String beginParagraphAction = "caret-begin-paragraph";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the end of a paragraph.
      * @see #getActions
      */
     public static final String endParagraphAction = "caret-end-paragraph";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of a paragraph, extending the selection.
      * @see #getActions
      */
     public static final String selectionBeginParagraphAction = "selection-begin-paragraph";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the end of a paragraph, extending the selection.
      * @see #getActions
      */
     public static final String selectionEndParagraphAction = "selection-end-paragraph";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of the document.
      * @see #getActions
      */
     public static final String beginAction = "caret-begin";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the end of the document.
      * @see #getActions
      */
     public static final String endAction = "caret-end";
 
     /**
-     * Name of the <code>Action</code> for moving the caret
+     * Name of the {@code Action} for moving the caret
      * to the beginning of the document.
      * @see #getActions
      */
     public static final String selectionBeginAction = "selection-begin";
 

@@ -828,21 +828,21 @@
      * some PC keyboards.
      * <p>
      * If the event doesn't get filtered, it will try to insert
      * content into the text editor.  The content is fetched
      * from the command string of the ActionEvent.  The text
-     * entry is done through the <code>replaceSelection</code>
+     * entry is done through the {@code replaceSelection}
      * method on the target text component.  This is the
      * action that will be fired for most text entry tasks.
      * <p>
      * <strong>Warning:</strong>
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#defaultKeyTypedAction
      * @see DefaultEditorKit#getActions
      * @see Keymap#setDefaultAction

@@ -898,11 +898,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#insertContentAction
      * @see DefaultEditorKit#getActions
      */

@@ -947,11 +947,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#insertBreakAction
      * @see DefaultEditorKit#getActions
      */

@@ -990,11 +990,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#insertTabAction
      * @see DefaultEditorKit#getActions
      */

@@ -1272,11 +1272,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#cutAction
      * @see DefaultEditorKit#getActions
      */

@@ -1309,11 +1309,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#copyAction
      * @see DefaultEditorKit#getActions
      */

@@ -1347,11 +1347,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#pasteAction
      * @see DefaultEditorKit#getActions
      */

@@ -1383,11 +1383,11 @@
      * Serialized objects of this class will not be compatible with
      * future Swing releases. The current serialization support is
      * appropriate for short term storage or RMI between applications running
      * the same version of Swing.  As of 1.4, support for long term storage
      * of all JavaBeans&trade;
-     * has been added to the <code>java.beans</code> package.
+     * has been added to the {@code java.beans} package.
      * Please see {@link java.beans.XMLEncoder}.
      *
      * @see DefaultEditorKit#beepAction
      * @see DefaultEditorKit#getActions
      */

@@ -1507,12 +1507,12 @@
                 target.scrollRectToVisible(newVis);
             }
         }
 
         /**
-         * Makes sure <code>y</code> is a valid location in
-         * <code>target</code>.
+         * Makes sure {@code y} is a valid location in
+         * {@code target}.
          */
         private int constrainY(JTextComponent target, int y, int vis) {
             if (y < 0) {
                 y = 0;
             }

@@ -1521,12 +1521,12 @@
             }
             return y;
         }
 
         /**
-         * Ensures that <code>offset</code> is a valid offset into the
-         * model for <code>text</code>.
+         * Ensures that {@code offset} is a valid offset into the
+         * model for {@code text}.
          */
         private int constrainOffset(JTextComponent text, int offset) {
             Document doc = text.getDocument();
 
             if ((offset != 0) && (offset > doc.getLength())) {

@@ -1538,11 +1538,11 @@
             return offset;
         }
 
         /**
          * Returns adjustsed {@code y} position that indicates the location to scroll to
-         * after selecting <code>index</code>.
+         * after selecting {@code index}.
          */
         private int getAdjustedY(JTextComponent text, Rectangle visible, int index) {
             int result = visible.y;
 
             try {

@@ -1562,11 +1562,11 @@
             return result;
         }
 
         /**
          * Adjusts the Rectangle to contain the bounds of the character at
-         * <code>index</code> in response to a page up.
+         * {@code index} in response to a page up.
          */
         private boolean select;
 
         /**
          * Direction to scroll, 1 is down, -1 is up.
< prev index next >