Class AbstractLanguageSupport

java.lang.Object
org.fife.rsta.ac.AbstractLanguageSupport
All Implemented Interfaces:
LanguageSupport
Direct Known Subclasses:
AbstractMarkupLanguageSupport, Asm6502LanguageSupport, CLanguageSupport, CssLanguageSupport, GroovyLanguageSupport, JavaLanguageSupport, JavaScriptLanguageSupport, PerlLanguageSupport, ShellLanguageSupport, TypeScriptLanguageSupport

public abstract class AbstractLanguageSupport extends Object implements LanguageSupport
A base class for language support implementations.
Version:
1.0
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private int
    The delay for auto-activation, in milliseconds.
    private boolean
    Whether auto-activation for completion choices is enabled for this language.
    private boolean
    Whether auto-completion is enabled for this language.
    private boolean
    Whether parameter assistance should be enabled for this language.
    The default renderer for the completion list.
    private boolean
    Whether the description window is displayed when the completion list window is displayed.
    private Map<org.fife.ui.rsyntaxtextarea.RSyntaxTextArea,org.fife.ui.autocomplete.AutoCompletion>
    Map of all text areas using this language support to their installed AutoCompletion instances.

    Fields inherited from interface org.fife.rsta.ac.LanguageSupport

    PROPERTY_LANGUAGE_PARSER
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected org.fife.ui.autocomplete.AutoCompletion
    createAutoCompletion(org.fife.ui.autocomplete.CompletionProvider p)
    Creates an auto-completion instance pre-configured and usable by most LanguageSupports.
    Creates the default cell renderer to use when none is specified.
    private void
    delegateToSubstanceRenderer(org.fife.ui.autocomplete.CompletionCellRenderer ccr)
    Attempts to delegate rendering to a Substance cell renderer.
    int
    Returns the delay between when the user types a character and when the code completion popup should automatically appear (if applicable).
    protected org.fife.ui.autocomplete.AutoCompletion
    getAutoCompletionFor(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
    Returns the auto-completion instance used by a text area.
    Returns the default list cell renderer to install for all text areas with this language support installed.
    boolean
    REturns whether the description window is also shown when the completion list is displayed, for editors of this language.
    protected Set<org.fife.ui.rsyntaxtextarea.RSyntaxTextArea>
    Returns the text areas with this language support currently installed.
    protected void
    installImpl(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea, org.fife.ui.autocomplete.AutoCompletion ac)
    Registers an auto-completion instance.
    boolean
    Returns whether auto-activation is enabled (that is, whether the completion popup will automatically appear after a delay when the user types an appropriate character).
    boolean
    Returns whether auto-completion is enabled for this language.
    boolean
    Returns whether parameter assistance is enabled for editors of this language.
    void
    Sets the delay between when the user types a character and when the code completion popup should automatically appear (if applicable).
    void
    setAutoActivationEnabled(boolean enabled)
    Toggles whether auto-activation is enabled.
    void
    setAutoCompleteEnabled(boolean enabled)
    Toggles whether auto-completion is enabled for this language.
    void
    Sets the default list cell renderer to install for all text areas with this language support installed.
    void
    Toggles whether parameter assistance is enabled for editors of this language.
    void
    setShowDescWindow(boolean show)
    Toggles whether the description window should also be shown when the completion list is displayed, for editors of this language.
    protected void
    uninstallImpl(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
    Unregisters an textArea.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.fife.rsta.ac.LanguageSupport

    install, uninstall
  • Field Details

    • textAreaToAutoCompletion

      private Map<org.fife.ui.rsyntaxtextarea.RSyntaxTextArea,org.fife.ui.autocomplete.AutoCompletion> textAreaToAutoCompletion
      Map of all text areas using this language support to their installed AutoCompletion instances. This should be maintained by subclasses by adding to, and removing from, it in their LanguageSupport.install(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea) and LanguageSupport.uninstall(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea) methods.
    • autoCompleteEnabled

      private boolean autoCompleteEnabled
      Whether auto-completion is enabled for this language.
    • autoActivationEnabled

      private boolean autoActivationEnabled
      Whether auto-activation for completion choices is enabled for this language. Note that this parameter only matters if autoCompleteEnabled is true.
    • autoActivationDelay

      private int autoActivationDelay
      The delay for auto-activation, in milliseconds. This parameter is only honored if both autoCompleteEnabled and autoActivationEnabled are true.
    • parameterAssistanceEnabled

      private boolean parameterAssistanceEnabled
      Whether parameter assistance should be enabled for this language.
    • showDescWindow

      private boolean showDescWindow
      Whether the description window is displayed when the completion list window is displayed.
    • renderer

      private ListCellRenderer<Object> renderer
      The default renderer for the completion list.
  • Constructor Details

    • AbstractLanguageSupport

      protected AbstractLanguageSupport()
      Constructor.
  • Method Details