(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
{{#seo: | {{#seo: | ||
− | |title= | + | |title=UltraEdit text editor code and syntax highlighting |
|description=An overview of how syntax highlighting works in UltraEdit text editor for Windows, Mac, and Linux | |description=An overview of how syntax highlighting works in UltraEdit text editor for Windows, Mac, and Linux | ||
}}[[Category:General]] | }}[[Category:General]] | ||
Line 7: | Line 7: | ||
In UltraEdit, syntax highlighting for different coding languages is defined in plain text configuration files called '''wordfiles''' (.uew files). Wordfiles contain a set of definitions and rules for the associated language (as well as configurations for brace matching, code folding, function listing, etc.). UltraEdit applies the highlighting in wordfiles based upon file name or extension, or in some cases by identifying a "shebang" line at the top of a file. UltraEdit comes with several pre-defined wordfiles for the most popular and common coding languages, however you can add (or create) many more. | In UltraEdit, syntax highlighting for different coding languages is defined in plain text configuration files called '''wordfiles''' (.uew files). Wordfiles contain a set of definitions and rules for the associated language (as well as configurations for brace matching, code folding, function listing, etc.). UltraEdit applies the highlighting in wordfiles based upon file name or extension, or in some cases by identifying a "shebang" line at the top of a file. UltraEdit comes with several pre-defined wordfiles for the most popular and common coding languages, however you can add (or create) many more. | ||
− | Because wordfiles are self-contained in a plain text file with an human readable syntax, they are very easy to modify. You can open and modify wordfiles by going to [[Editor display:Syntax highlighting|Editor Display » Syntax Highlighting]] | + | Because wordfiles are self-contained in a plain text file with an human readable syntax, they are very easy to modify. You can open and modify wordfiles by going to [[Settings:Editor display:Syntax highlighting|Settings » Editor Display » Syntax Highlighting]]. Select a wordfile from the drop down list and click the '''Open''' button to open it in the editor. You can also see and change (if desired) the folder containing wordfiles that UltraEdit uses for syntax highlighting. |
For exhaustive documentation on the various components and settings available for wordfiles, please see the [[Wordfiles]] topic. | For exhaustive documentation on the various components and settings available for wordfiles, please see the [[Wordfiles]] topic. | ||
− | You can specify the default syntax highlighting type for new files in | + | You can specify the default syntax highlighting type for new files in [[Settings:Editor display:Syntax highlighting|Settings » Editor Display » Syntax Highlighting]]. |
You can add or remove wordfiles for syntax highlighting by clicking the '''[[Add syntax highlighting languages|Add another language...]]''' button in the Formatting group of the [[:Category:Coding tab|Coding tab]]. | You can add or remove wordfiles for syntax highlighting by clicking the '''[[Add syntax highlighting languages|Add another language...]]''' button in the Formatting group of the [[:Category:Coding tab|Coding tab]]. | ||
Line 24: | Line 24: | ||
* [[Add syntax highlighting languages]] | * [[Add syntax highlighting languages]] | ||
* [[Manage themes]] | * [[Manage themes]] | ||
− | * [[Editor display:Syntax highlighting|Editor Display » Syntax Highlighting]] | + | * [[Settings:Editor display:Syntax highlighting|Editor Display » Syntax Highlighting]] |
</div> | </div> |
Syntax highlighting refers to the ability to recognize predefined words or patterns of text and display these in different colors or font styles. This is particularly useful for coding and can also be useful for general text editing where you want certain words in a file to display in a different color.
In UltraEdit, syntax highlighting for different coding languages is defined in plain text configuration files called wordfiles (.uew files). Wordfiles contain a set of definitions and rules for the associated language (as well as configurations for brace matching, code folding, function listing, etc.). UltraEdit applies the highlighting in wordfiles based upon file name or extension, or in some cases by identifying a "shebang" line at the top of a file. UltraEdit comes with several pre-defined wordfiles for the most popular and common coding languages, however you can add (or create) many more.
Because wordfiles are self-contained in a plain text file with an human readable syntax, they are very easy to modify. You can open and modify wordfiles by going to Settings » Editor Display » Syntax Highlighting. Select a wordfile from the drop down list and click the Open button to open it in the editor. You can also see and change (if desired) the folder containing wordfiles that UltraEdit uses for syntax highlighting.
For exhaustive documentation on the various components and settings available for wordfiles, please see the Wordfiles topic.
You can specify the default syntax highlighting type for new files in Settings » Editor Display » Syntax Highlighting.
You can add or remove wordfiles for syntax highlighting by clicking the Add another language... button in the Formatting group of the Coding tab.
You can change (or apply) syntax highlighting for the active file by using the View as language drop down in the Formatting group of the Coding tab, or the syntax highlighting selector in the Status bar.
You can modify the colors used for syntax highlighting on a per-language or global basis in the Manage themes dialog.