Class AbstractMarkupLanguageSupport.InsertClosingTagAction

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action
    Enclosing class:
    AbstractMarkupLanguageSupport

    private class AbstractMarkupLanguageSupport.InsertClosingTagAction
    extends javax.swing.text.TextAction
    Action that checks whether a closing tag should be auto-inserted into the document. Subclasses should map this action to the '>' key-typed event.
    • Field Summary

      • Fields inherited from class javax.swing.AbstractAction

        changeSupport, enabled
      • Fields inherited from interface javax.swing.Action

        ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void actionPerformed​(java.awt.event.ActionEvent e)  
      private java.lang.String discoverTagName​(org.fife.ui.rsyntaxtextarea.RSyntaxDocument doc, int dot)
      Discovers the name of the tag just opened, if any.
      • Methods inherited from class javax.swing.text.TextAction

        augmentList, getFocusedComponent, getTextComponent
      • Methods inherited from class javax.swing.AbstractAction

        addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface javax.swing.Action

        accept
    • Constructor Detail

      • InsertClosingTagAction

        InsertClosingTagAction()
    • Method Detail

      • actionPerformed

        public void actionPerformed​(java.awt.event.ActionEvent e)
      • discoverTagName

        private java.lang.String discoverTagName​(org.fife.ui.rsyntaxtextarea.RSyntaxDocument doc,
                                                 int dot)
        Discovers the name of the tag just opened, if any. Assumes standard SGML-style markup tags.
        Parameters:
        doc - The document to parse.
        dot - The location of the caret. This should be right at a ">" character closing an HTML tag.
        Returns:
        The name of the tag to close, or null if it could not be determined.