User Keyword Categories

Overview

The plug-in has a feature to enable highlighting keywords in a source file when displayed in the ProvideX Editor. These keywords have been defined in control files shipped with plug-in and are not be easily modified by the user.

The plug-in will check in the same folder as contributed tools and extensions for user-defined keyword categories and will fall-back to the root folder of the current workspace.

info We recommend the keyword category files be placed into the folder identified for contributed tools and extensions. This will enable the same definitions to be used by multiple workspaces.

ProvideX Contributed Extensions / Tools Preferences

File: keywordcats.properties

This file defines one or more keyword categories. The comment lines beginning with a ' # ' character and any blank lines in the file will be ignored. Each of the remaining lines must define a new keyword category. Each category must have a unique name and a unique property file which is used to define the keywords for the category.

The key for each line in this properties file is the unique name for a keyword category. The value is list of characteristics separated by semicolons.

Property File
Name of the property file used to define the keywords in the category
Icon File Path
The relative path to an icon file contained within the plug-in distribution. The icon will appear in any completion list matching a keyword in the category.
Text Attributes
The remaining six items in the list are text attributes to be used when a keyword in the category is displayed in the editor.
  1. Keyword displayed as bold text (true, false)
  2. Keyword displayed as italic text (true, false)
  3. RGB text color (R-G-B); each value must be three characters in length and padded on left with zeroes
  4. RGB background color (R-G-B); each value must be three characters in length and padded on left with zeroes
  5. Keyword displayed as strike-through text (true, false)
  6. Keyword displayed as underlined text (true, false)

Sample keywordcats.properties

# Sample Keyword Categories File
# ----------------------------------------------------------------------------------------------------------
# UniqueKey=PropertyFile          ;IconFilePath              ;________________TextAttributes________________
#                                                            ;Bold;Ital ;TextColor  ;BkgdColor  ;Strk ;ULine
# ----------------------------------------------------------------------------------------------------------
MyConstants=myconstants.properties;$nl$/icons/masIconBlue.gif;true;false;064-128-016;200-200-200;false;false

Keyword Category File

This file defines the keywords for a category. The comment lines beginning with a ' # ' character and any blank lines in the file will be ignored. Each of the remaining lines must define a new keyword such as a variable used as a constant or a method name.

The key for each line in this properties file is a unique keyword in the category. The value is the text to appear in the help tip when a user hovers over the keyword.

Sample Category Properties File

# Sample Categories File
# ----------------------------------------------------------------------------------------------------------
# KeyWord=Help/Tip text
# ----------------------------------------------------------------------------------------------------------
statCLOSED$=Order status code 'Closed'
statNONE$=Order status code 'None'
statOPEN$=Order status code 'Open'

Next Section: Project-Specific Properties - Properties for Project