Edgewall Software

Changes between Version 2 and Version 3 of SilverCityAddLanguage


Ignore:
Timestamp:
Jul 9, 2004, 2:42:05 PM (20 years ago)
Author:
anonymous
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • SilverCityAddLanguage

    v2 v3  
    77How to add syntax-highlightning to SilverCity that exists in Scintilla
    88======================================================================
     9
     10First download the !SilverCity package and the latest Scintialla package.
    911
    1012root = where you unpacked SilverCity
     
    2123      - cd root/PySilverCity/Src
    2224
    23       - python write_scintilla.py ../../scintilla/include tmp.py
     25      - python write_scintilla.py ../../scintilla/include ../../scintilla/include/Scintilla.iface tmp.py
    2426
    2527      - rm ../SilverCity/ScintillaConstants.py
     
    2931+  Now you change to the root/PySilverCity/SilverCity and have to create a module lang.py
    3032
    31        - cp YAML.py lang.py
     33       - We are using the YAML.py as template so do 'cp YAML.py lang.py'
    3234
    3335       - in lang.py replace every occurance of Yaml with lang
    3436
     37       - replace "from ScintillaConstants import SCLEX_YAML" to use your language lexer.
     38
     39       - replace occurance of SCE_YAML with the equivalant for your language lexer
     40
     41       - To find the equivalent constant for lang look into ScintillaConstants.py
     42
    3543       - change the langue info at the.
    3644
    37          + Change suffixes to what the new lang has.
     45          + Change suffixes to what the new lang has. So that one can deduce from filename what lexer to use.
    3846
    3947
    40        - Open root/scintilla/src/Lex'lang' see how many word list arguments are to the function.
     48       - Open root/scintilla/src/Lex'lang' see how many WordList arguments are to the function.
    4149         
    42          +  In lang.py add so many wordlist in self._keywords in the langLexer.__init__ function
     50         +  In lang.py add so many WordList in self._keywords in the langLexer.__init__ function
    4351           
    44             - Check the CPP.py as example.
     52         + Check the CPP.py as example.
    4553
    4654       - Add the keywords for the language in the Keywords module