|
Class: NaiveSyntaxHighlighterForC (in Tools)
Object
|
+--Scanner
|
+--Parser
|
+--AbstractSyntaxHighlighter
|
+--Tools::NaiveSyntaxHighlighter
|
+--Tools::NaiveSyntaxHighlighterForC
- Package:
- stx:libtool
- Category:
- Interface-Tools-File-Syntax
- Version:
- rev:
1.7
date: 2024/02/16 18:09:02
- user: stefan
- file: Tools__NaiveSyntaxHighlighterForC.st directory: libtool
- module: stx stc-classLibrary: libtool
a quick and dirty hack;
not really (yet) aware of what it is doing.
All highlighting is based on hardcoded heuristics;
a bad implementation, but better than nothing...
api highlighting
-
formatFileContents: aString elementsInto: elementsCollection
-
format (recolor) a file's contents.
Return the text containing font changes and color information.
constants
-
keywords
-
-
knownFunctions
-
-
knownStdFunctions
-
-
knownUnixFunctions
-
-
typeNames
-
accessing
-
constantColor
-
-
constantEmphasis
-
-
controlFlowKeywordColor
-
-
controlFlowKeywordEmphasis
-
-
functionColor
-
^ Color brown.
-
functionDefinitionColor
-
-
functionDefinitionEmphasis
-
-
functionEmphasis
-
i.e. no emphasis
-
globalVariablesColor
-
-
globalVariablesEmphasis
-
-
keywordColor
-
-
keywordEmphasis
-
-
moreKnownFunctions: aCollectionOfFunctionNames
-
Modified (format): / 22-10-2017 / 15:42:46 / cg
-
wellknownFunctionColor
-
preferences globalIdentifierColor "/ selectorColor
-
wellknownFunctionEmphasis
-
selectorEmphasis
-
wellknownTypeColor
-
-
wellknownTypeEmphasis
-
api highlighting
-
formatFileContents: aString elementsInto: elementsCollection
-
format (recolor) a file's contents.
Return the text containing font changes and color information.
initialization
-
initialize
-
must be called if redefined
private-scanning
-
scanEOLComment
-
-
scanIdentifier
-
(#('typedef' 'sizeof') includes:word) ifTrue:[
-
scanNormalComment
-
unterminated comment
-
scanStep
-
care for #include etc.
-
scanString: delimiter
-
unterminated string
|