eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'Tools::NaiveSyntaxHighlighterForLisp':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: NaiveSyntaxHighlighterForLisp (in Tools)


Inheritance:

   Object
   |
   +--Scanner
      |
      +--Parser
         |
         +--AbstractSyntaxHighlighter
            |
            +--Tools::NaiveSyntaxHighlighter
               |
               +--Tools::NaiveSyntaxHighlighterForLisp

Package:
stx:libtool
Category:
Interface-Tools-File-Syntax
Version:
rev: 1.10 date: 2024/04/28 08:41:47
user: cg
file: Tools__NaiveSyntaxHighlighterForLisp.st directory: libtool
module: stx stc-classLibrary: libtool

Description:


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...

formatFileContents:elementsInto:

format (recolor) a file's contents. Return the text containing font changes and color information.

Class protocol:

constants
o  controlFlowKeywords
flush cache when changing:
ControlFlowKeywords := nil

o  knownFunctionKeywords
flush cache when changing:
KnownFunctionKeywords := nil

o  syntaxDefiningKeywords
flush cache when changing:
SyntaxDefiningKeywords := nil


Instance protocol:

api highlighting
o  formatFileContents: aString elementsInto: elementsCollection
format (recolor) a file's contents.
Return the text containing font changes and color information.

initialization
o  initialize
must be called if redefined

private-scanning
o  scanAtom
attn: stops on one of those special chars,

o  scanEOLComment

o  scanHashBarComment

o  scanNumber
CScanner notNil

o  scanStep
actually a constant: nil.

o  scanString
unterminated string



ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Mon, 18 Nov 2024 08:55:41 GMT