Coloration syntaxique Rebol/Cheyenne pour Scite | |
Laurent | 25-Jun-2011/20:50:52+2:00 |
Sous Linux j'utilise Scite (Scintilla) comme IDE me permettant de bénéficier de la coloration syntaxique Rebol, ce qui change la vie. L’exécution automatique dans un terminal intégré est sympa aussi. Pour cela j'ai récupéré un vieux fichier de config Scite Rebol que j'ai modifié en ajoutant des mots clés manquants, notamment ceux de l'API Cheyenne. Je vous le communique au cas où des personnes n'utiliseraient pas encore la coloration syntaxique avec Rebol. Dans Scite vous pouvez aisément faire les modifications que vous voulez pour personnaliser vos couleurs/polices. PS: Sous Windows j'utilisais "Programmer's Notepad" qui a aussi un fichier de coloration syntaxique Rebol, et qui marche d'ailleurs très bien sous Linux avec Wine. Voilà mon fichier: # Define SciTE settings for REBOL files. file.patterns.rebol=*.r;*.reb;*.r3;*.rsp filter.rebol=REBOL (r)|$(file.patterns.rebol)| lexer.$(file.patterns.rebol)=rebol # keywords. Found at http://www.rebol.com/docs/dictionary.html keywords.$(file.patterns.rebol)=about abs absolute add \ alert alias all alter and \ any any-block? any-function? any-string? any-type? \ any-word? append arccosine arcsine arctangent \ array as-pair ask at attempt \ back binary? bind bitset? block? \ break brightness? browse build-tag caret-to-offset \ catch center-face change change-dir char? \ charset checksum choose clean-path clear \ clear-fields close comment complement component? \ compose compress confirm connected? construct \ context copy cosine datatype? date? \ debase decimal? decode-cgi decompress dehex \ delete detab difference dir? dirize \ disarm dispatch divide do do-events \ does dump-face dump-obj echo either \ else email? empty? enbase entab \ equal? error? even? event? exclude \ exists? exit exp extract fifth \ file? find first flash focus \ for forall foreach forever form \ forskip found? fourth free func \ function function? get get-modes get-word? \ greater-or-equal? greater? halt has hash? \ head head? help hide hide-popup \ if image? import-email in in-window? \ index? info? inform input input? \ insert integer? intersect issue? join \ last launch layout length? lesser-or-equal? \ lesser? library? license link? list-dir \ list? lit-path? lit-word? load load-image \ log-10 log-2 log-e logic? loop \ lowercase make make-dir make-face max \ maximum maximum-of min minimum minimum-of \ modified? mold money? multiply native? \ negate negative? next none? not \ not-equal? now number? object? odd? \ offset-to-caret offset? op? open or \ pair? paren? parse parse-xml path? \ pick poke port? positive? power \ prin print probe protect protect-system \ query quit random read read-io \ recycle reduce refinement? reform rejoin \ remainder remold remove remove-each rename \ repeat repend replace request request-color \ request-date request-download request-file request-list request-pass \ request-text resend return reverse routine? \ same? save script? second secure \ select send series? set set-modes \ set-net set-path? set-word? show show-popup \ sign? sine size-text size? skip \ sort source span? split-path square-root \ strict-equal? strict-not-equal? string? struct? stylize \ subtract suffix? switch tag? tail \ tail? tangent third throw time? \ to to-binary to-bitset to-block to-char \ to-date to-decimal to-email to-file to-get-word \ to-hash to-hex to-idate to-image to-integer \ to-issue to-list to-lit-path to-lit-word to-local-file \ to-logic to-money to-pair to-paren to-path \ to-rebol-file to-refinement to-set-path to-set-word to-string \ to-tag to-time to-tuple to-url to-word \ trace trim try tuple? type? \ unfocus union unique unprotect unset \ unset? until unview update upgrade \ uppercase url? usage use value? \ view viewed? wait what what-dir \ while within? word? write write-io xor zero? \ \ build-markup call case delta-time local none quit self split-path to-error unless values-of \ \ some thru to \ \ request response session db-cache locale debug debug? \ on-rsp-start on-rsp-end on-application-start on-application-end on-database-init \ on-session-start on-session-end on-page-start on-page-end \ emit include include-file validate html-decode html-encode url-encode do-sql say # test functions keywords2.$(file.patterns.rebol)=action? any-block? any-function? any-string? \ any-type? any-word? binary? bitset? block? char? component? connected? \ datatype? date? decimal? dir? email? empty? equal? error? even? event? exists? \ file? found? function? get-word? greater-or-equal greater? hash? head? image? \ index? info? input? integer? issue? length? lesser-or-equal? lesser? library? \ link-app? link? list? lit-path? lit-word? logic? modified? money? native? negative? \ none? not-equal? number? object? odd? offset? op? pair? paren? path? port? \ positive? rebol-command? rebol-encap? rebol-link? rebol-pro? rebol-view? \ refinement? routine? same? script? series? set-path? set-word? sign? size? \ strict-equal? strict-not-equal string? struct? suffix? tag? tail? time? tuple? type? \ unset? url? value? view? word? zero? # types keywords3.$(file.patterns.rebol)=action! any-block! any-function! any-string! any-type! \ any-word! binary! bitset! block! char! datatype! date! decimal! email! error! \ event! file! function! get-word! hash! image! integer! issue! library! list! lit-path! \ lit-word! logic! money! native! none! number! object! op! pair! paren! path! \ port! refinement! routine! series! set-path! set-word! string! struct! symbol! tag! \ time! tuple! unset! url! word! word.chars.rebol=$(chars.alpha)$(chars.numeric)?!.+-*&|=_~ word.characters.$(file.patterns.rebol)=$(word.chars.rebol) comment.block.rebol=; comment.box.start.rebol=;; comment.box.middle.rebol=;; comment.box.end.rebol=;; # REBOL styles # Default style.rebol.32=$(font.base) # Any other text style.rebol.0=fore:#000000,bold # Line Comment style.rebol.1=$(colour.code.comment.box),$(font.code.comment.box) # Block Comment ( comment {the text} ) style.rebol.2=$(colour.code.comment.box),$(font.code.comment.box) # Preface (text before the REBOL header) style.rebol.3=$(colour.code.comment.box),$(font.code.comment.box),bold # Operators style.rebol.4=$(colour.operator),bold # Characters ( #"a" ) style.rebol.5=$(colour.string) # String with quotes style.rebol.6=$(colour.string) # String with braces style.rebol.7=$(colour.string) # Number style.rebol.8=$(colour.number) # Pair ( 800x600 ) style.rebol.9=fore:#005090 # Tuple ( 127.0.0.1 ) style.rebol.10=fore:#005090 # Binary ( 16#{1A803F59} ) style.rebol.11=fore:#C000C0 # Money style.rebol.12=fore:#003070 # Issue { #123-CD-456 } style.rebol.13=fore:#800000 # Tag { <TITLE height=100> } style.rebol.14=fore:#C00000 # File { %/C/Winnt/some.dll } style.rebol.15=fore:#0080FF # Email { joe@mail.dom } style.rebol.16=fore:#0080FF # URL { ftp://there.dom } style.rebol.17=fore:#0080FF # Date { 17-Feb-2004 1/3/99 } style.rebol.18=fore:#8000FF # Time { 12:30 11:22:59 01:59:59.123 } style.rebol.19=fore:#8000FF # Identifiers style.rebol.20= # Keyword (all) style.rebol.21=$(colour.keyword),bold # Keyword (test functions) style.rebol.22=fore:#8000C0,bold # Keyword (datatypes) style.rebol.23=fore:#800060,bold # Matched Operators style.rebol.34=fore:#0000FF,bold style.rebol.35=fore:#FF0000,bold # Braces are only matched in default style braces.rebol.style=0 command.go.$(file.patterns.rebol)=/usr/bin/rebol -qs $(FilePath) | |
Login required to Post. |