接口 LanguageSupport

    • 字段概要

      字段 
      修饰符和类型 字段 说明
      static java.lang.String PROPERTY_LANGUAGE_PARSER
      Client property set on RSyntaxTextAreas referencing the Parser instance parsing its source code.
    • 方法概要

      所有方法 实例方法 抽象方法 
      修饰符和类型 方法 说明
      int getAutoActivationDelay()
      Returns the delay between when the user types a character and when the code completion popup should automatically appear (if applicable).
      javax.swing.ListCellRenderer getDefaultCompletionCellRenderer()
      Returns the default list cell renderer to install for all text areas with this language support installed.
      boolean getShowDescWindow()
      REturns whether the description window is also shown when the completion list is displayed, for editors of this language.
      void install​(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
      Installs this support.
      boolean isAutoActivationEnabled()
      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 isAutoCompleteEnabled()
      Returns whether auto-completion is enabled for this language.
      boolean isParameterAssistanceEnabled()
      Returns whether parameter assistance is enabled for editors of this language.
      void setAutoActivationDelay​(int ms)
      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 setDefaultCompletionCellRenderer​(javax.swing.ListCellRenderer r)
      Sets the default list cell renderer to install for all text areas with this language support installed.
      void setParameterAssistanceEnabled​(boolean enabled)
      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.
      void uninstall​(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
      Uninstalls this support.
    • 字段详细资料

      • PROPERTY_LANGUAGE_PARSER

        static final java.lang.String PROPERTY_LANGUAGE_PARSER
        Client property set on RSyntaxTextAreas referencing the Parser instance parsing its source code. This will be null if a language support does not install such a parser.
        另请参阅:
        常量字段值
    • 方法详细资料

      • getAutoActivationDelay

        int getAutoActivationDelay()
        Returns the delay between when the user types a character and when the code completion popup should automatically appear (if applicable). This parameter is only honored if isAutoActivationEnabled() returns true.
        返回:
        The delay, in milliseconds.
        另请参阅:
        setAutoActivationDelay(int)
      • getDefaultCompletionCellRenderer

        javax.swing.ListCellRenderer getDefaultCompletionCellRenderer()
        Returns the default list cell renderer to install for all text areas with this language support installed.
        返回:
        The renderer. This will never be null.
        另请参阅:
        setDefaultCompletionCellRenderer(ListCellRenderer)
      • getShowDescWindow

        boolean getShowDescWindow()
        REturns whether the description window is also shown when the completion list is displayed, for editors of this language.
        返回:
        Whether the description window is shown.
        另请参阅:
        setShowDescWindow(boolean)
      • isAutoActivationEnabled

        boolean isAutoActivationEnabled()
        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). Note that this parameter will be ignored if auto-completion is disabled.
        返回:
        Whether auto-activation is enabled.
        另请参阅:
        setAutoActivationEnabled(boolean), getAutoActivationDelay(), isAutoCompleteEnabled()
      • isAutoCompleteEnabled

        boolean isAutoCompleteEnabled()
        Returns whether auto-completion is enabled for this language. If this value is false, then ctrl+space will do nothing.
        返回:
        Whether auto-completion is enabled.
        另请参阅:
        setAutoCompleteEnabled(boolean)
      • install

        void install​(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
        Installs this support.
        参数:
        textArea - The text area to install onto.
        另请参阅:
        uninstall(RSyntaxTextArea)
      • isParameterAssistanceEnabled

        boolean isParameterAssistanceEnabled()
        Returns whether parameter assistance is enabled for editors of this language. Note that some language do not support parameter assistance at all; in those cases, this parameter does nothing.
        返回:
        Whether parameter assistance is enabled for editors of this language.
        另请参阅:
        setParameterAssistanceEnabled(boolean)
      • setAutoActivationDelay

        void setAutoActivationDelay​(int ms)
        Sets the delay between when the user types a character and when the code completion popup should automatically appear (if applicable). This parameter is only honored if isAutoActivationEnabled() returns true.
        参数:
        ms - The delay, in milliseconds. This should be greater than zero.
        另请参阅:
        getAutoActivationDelay()
      • setAutoActivationEnabled

        void setAutoActivationEnabled​(boolean enabled)
        Toggles whether auto-activation is enabled. Note that auto-activation also depends on auto-completion itself being enabled.
        参数:
        enabled - Whether auto-activation is enabled.
        另请参阅:
        isAutoActivationEnabled(), setAutoActivationDelay(int)
      • setAutoCompleteEnabled

        void setAutoCompleteEnabled​(boolean enabled)
        Toggles whether auto-completion is enabled for this language. If this is set to false, then ctrl+space will do nothing.
        参数:
        enabled - Whether auto-completion should be enabled.
        另请参阅:
        isAutoCompleteEnabled()
      • setDefaultCompletionCellRenderer

        void setDefaultCompletionCellRenderer​(javax.swing.ListCellRenderer r)
        Sets the default list cell renderer to install for all text areas with this language support installed. This renderer will be shared amongst all text areas.
        参数:
        r - The renderer. If this is null, a default will be used.
        另请参阅:
        getDefaultCompletionCellRenderer()
      • setParameterAssistanceEnabled

        void setParameterAssistanceEnabled​(boolean enabled)
        Toggles whether parameter assistance is enabled for editors of this language.
        参数:
        enabled - Whether parameter assistance is enabled.
        另请参阅:
        isParameterAssistanceEnabled()
      • setShowDescWindow

        void setShowDescWindow​(boolean show)
        Toggles whether the description window should also be shown when the completion list is displayed, for editors of this language.
        参数:
        show - Whether to show the description window.
        另请参阅:
        getShowDescWindow()
      • uninstall

        void uninstall​(org.fife.ui.rsyntaxtextarea.RSyntaxTextArea textArea)
        Uninstalls this support.
        参数:
        textArea - The text area to uninstall from.
        另请参阅:
        install(RSyntaxTextArea)