fzf added to the bashrc
[dotfiles/.git] / .nano / x11basic.nanorc
1 ## Sytax highlighting for nano and pico for X11-Basic. (c) Markus Hoffmann 2019
2
3 # This file is part of X11-Basic, the basic interpreter for Unix/X
4 # ======================================================================
5 # X11-Basic is free software and comes with NO WARRANTY - read the file
6 # COPYING for details
7
8 syntax "x11basic" "\.(bas|xbas|LST|BAS)$"
9
10 # Variable names
11
12 icolor brightwhite "\<[A-Z_][A-Za-z0-9_]*(|\$|\%|\&|\||\(\))\>"
13
14 # system vars
15 icolor cyan "\<(CCSAPLID|CCSERR|COLS|CRSCOL|CRSLIN|CTIMER|ERR|FALSE)\>"
16 icolor cyan "\<(GPS_ALT|GPS_LAT|GPS_LON|MOUSEK|MOUSES|MOUSEX|MOUSEY)\>"
17 icolor cyan "\<(PC|PI|ROWS|SP|STIMER|TIMER|TRUE)\>"
18
19 # system string vars
20 icolor cyan "\<(DATE|FILEEVENT|INKEY|TERMINALNAME|TIME|TRACE)\$"
21
22 #special system vars
23 icolor cyan "\<(ANDROID|GPIO|GPS|SENSOR|WIN32|UNIX)\?"
24
25
26 # system array vars
27
28 # regular functions
29
30 icolor green "\<(ABS|ACOS|ACOSH|ADD|AND|ARG|ARRPTR|ASC|ASIN|ASINH|ATAN|ATANH|ATN)\("
31 icolor green "\<(BCHG|BCLR|BSET|BTST|BYTE)\("
32 icolor green "\<(CALL|CALLD|CARD|CBRT|CEIL|COLOR_RGB|COMBIN|CONJ|COS|COSH|CRC|CVD|CVF|CVI|CVL|CVS)\("
33 icolor green "\<(DEG|DET|DEVICE|DIV|DPEEK)\("
34 icolor green "\<(EOF|EVAL|EVEN|EXEC|EXIST|EXP|EXPM1)\("
35 icolor green "\<(FACT|FIX|FLOOR|FORK|FORM_ALERT|FORM_CENTER|FORM_DIAL|FORM_DO|FRAC|FREEFILE)\("
36 icolor green "\<(GAMMA|GASDEV|GCD|GET_COLOR|GLOB|GPIO|GRAY)\("
37 icolor green "\<(HYPOT)\("
38 icolor green "\<(IMAG|INODE|INP|INSTR|INT|INVERT|IOCTL)\("
39 icolor green "\<(JULIAN)\("
40 icolor green "\<(LCM|LEN|LGAMMA|LISTSELECT|LN|LOC|LOF|LOG|LOG10|LOG1P|LOGB|LPEEK|LTEXTLEN)\("
41 icolor green "\<(MALLOC|MAX|MIN|MOD|MODE|MSHRINK|MUL)\("
42 icolor green "\<(NEXTPRIME|NLINK|NOT)\("
43 icolor green "\<(OBJC_DRAW|OBJC_FIND|OBJC_OFFSET|ODD|OR)\("
44 icolor green "\<(PEEK|POINT|POWM|PRED|PTST)\("
45 icolor green "\<(RAD|RAND|RANDOM|REAL|REALLOC|RINSTR|RND|ROL|ROOT|ROR|ROUND|RSRC_GADDR)\("
46 icolor green "\<(SENSOR|SGN|SHL|SHM_ATTACH|SHM_MALLOC|SHR|SIN|SINH|SIZE|SQR|SQRT|SRAND|SUB|SUCC|SWAP|SYM_ADR)\("
47 icolor green "\<(TALLY|TAN|TANH|TRUNC)\("
48 icolor green "\<(UBOUND)\("
49 icolor green "\<(VAL|VARIAT|VARPTR|VRFY)\("
50 icolor green "\<(WORD|WORT_SEP)\("
51 icolor green "\<(XOR)\("
52
53 # question functions
54 icolor green "\<(DIM|EVENT|INP|TYP|VAL)\?\("
55
56 # special functions
57
58 icolor green "\<(INP)\%\("
59 icolor green "\<(INP)\&\("
60
61
62
63 # string functions
64 icolor green "\<(ARID|ARIE)\$\("
65 icolor green "\<(BIN|BWTD|BWTE)\$\("
66 icolor green "\<(CALL|CHR|COMPRESS)\$\("
67 icolor green "\<(DECLOSE|DECRYPT|DIR)\$\("
68 icolor green "\<(ENCLOSE|ENCRYPT|ENV|ERR)\$\("
69 icolor green "\<(FSFIRST|FSNEXT)\$\("
70 icolor green "\<(HASH|HEX)\$\("
71 icolor green "\<(INLINE|INPUT)\$\("
72 icolor green "\<(JULDATE)\$\("
73 icolor green "\<(LEFT|LEFTOF|LINEINPUT|LOWER)\$\("
74 icolor green "\<(MID|MKA|MKD|MKF|MKI|MKL|MKS|MTFD|MTFE)\$\("
75 icolor green "\<(OCT)\$\("
76 icolor green "\<(PARAM|PNGDECODE|PNGENCODE|PRG)\$\("
77 icolor green "\<(REPLACE|REVERSE|RADIX|RIGHT|RIGHTOF|RLD|RLE)\$\("
78 icolor green "\<(SIGN|SPACE|STR|STRING|SYSTEM)\$\("
79 icolor green "\<(TERMINALNAME|TRIM)\$\("
80 icolor green "\<(UCASE|UNCOMPRESS|UNIXDATE|UNIXTIME|UPPER|USING)\$\("
81 icolor green "\<(WORD)\$\("
82 icolor green "\<(XTRIM)\$\("
83
84 # array functions
85
86 icolor green "\<(0|1|CONVOLUT|CVA|FFT|INV|SMUL|SOLVE|TRANS)\("
87
88
89
90 # special commands
91
92 icolor brightmagenta "(^|^[[:space:]]*)(DIM|LOCAL|LET)\>"
93 icolor cyan "(^|^[[:space:]]*)DATA.*$"
94
95 icolor red "(^|^[[:space:]]*)ENDFUNCTION\>"
96 icolor red "(^|^[[:space:]]*)(RETURN|BREAK|CONTINUE|EXIT\ IF)\>"
97 icolor red "(^|^[[:space:]]*)(FUNCTION|PROCEDURE|DEFFN)\>"
98
99 icolor blue "(^|^[[:space:]]*)(endselect|select|default|endif|else\ if|else|case|do|loop|next|for|if|while|wend|repeat|until|goto|gosub|spawn|void)\>"
100 icolor brightred "(^|^[[:space:]]*)(END|QUIT|STOP|TRON|TROFF|ECHO|EDIT|NEW|RUN)\>"
101
102
103 # regular commands
104
105 icolor brightgreen "(^|^[[:space:]]*)(ABSOLUTE|ADD|AFTER|ALERT|ARRAYCOPY|ARRAYFILL)\>"
106 icolor brightgreen "(^|^[[:space:]]*)(BEEP|BELL|BGET|BLOAD|BMOVE|BOTTOMW|BOUNDARY|BOX|BPUT|BSAVE)\>"
107 icolor brightgreen "(^|^[[:space:]]*)(CALL|CHAIN|CHDIR|CHMOD|CIRCLE|CLEAR|CLEARW|CLIP|CLOSE|CLOSEW|CLR|CLS|COLOR|CONNECT|COPYAREA|CURVE)\>"
108 icolor brightgreen "(^|^[[:space:]]*)(DEC|DEFFILL|DEFLINE|DEFMARK|DEFMOUSE|DEFTEXT|DELAY|DIV|DPOKE|DRAW|DUMP)\>"
109 icolor brightgreen "(^|^[[:space:]]*)(ELLIPSE|ERASE|ERROR|EVAL|EVENT|EVERY|EXEC)\>"
110 icolor brightgreen "(^|^[[:space:]]*)(FFT|FILESELECT|FILL|FIT|FIT_LINEAR|FIT_POLY|FLUSH|FREE|FULLW)\>"
111 icolor brightgreen "(^|^[[:space:]]*)(GET|GET_GEOMETRY|GET_LOCATION|GET_SCREENSIZE|GPIO|GPRINT|GPS|GRAPHMODE)\>"
112 icolor brightgreen "(^|^[[:space:]]*)(HELP|HIDEK|HIDEM|HOME)\>"
113 icolor brightgreen "(^|^[[:space:]]*)(INC|INFOW|INPUT)\>"
114 icolor brightgreen "(^|^[[:space:]]*)(KEYEVENT|KILL)\>"
115 icolor brightgreen "(^|^[[:space:]]*)(LINE|LINEINPUT|LINK|LIST|LOAD|LOCATE|LPOKE|LTEXT)\>"
116 icolor brightgreen "(^|^[[:space:]]*)(MEMDUMP|MENU|MENUDEF|MENUKILL|MENUSET|MERGE|MFREE|MKDIR|MOUSE|MOUSEEVENT|MOTIONEVENT|MOVEW|MSYNC|MUL)\>"
117 icolor brightgreen "(^|^[[:space:]]*)(NOOP|NOP|NOROOTWINDOW)\>"
118 icolor brightgreen "(^|^[[:space:]]*)(OBJC_ADD|OBJC_DELETE|ON|OPEN|OPENW|OUT)\>"
119 icolor brightgreen "(^|^[[:space:]]*)(PAUSE|PBOX|PCIRCLE|PELLIPSE|PIPE|PLAYSOUND|PLAYSOUNDFILE|PLIST|PLOT|POKE|POLYFILL|POLYLINE|POLYMARK|PRBOX|PRINT|PUT|PUTBACK|PUT_BITMAP)\>"
120 icolor brightgreen "(^|^[[:space:]]*)(RANDOMIZE|RBOX|READ|RECEIVE|RELSEEK|RENAME|RESTORE|RMDIR|ROOTWINDOW|RSRC_FREE|RSRC_LOAD)\>"
121 icolor brightgreen "(^|^[[:space:]]*)(SAVE|SAVESCREEN|SAVEWINDOW|SCOPE|SCREEN|SEEK|SEND|SENSOR|SETFONT|SETMOUSE|SGET|SHELL|SHM_DETACH|SHM_FREE|SHOWK|SHOWM|SHOEPAGE|SIZEW|SORT|SOUND|SPEAK|SPLIT|SPUT|SUB|SWAP|SYSTEM)\>"
122 icolor brightgreen "(^|^[[:space:]]*)(TEXT|TITLEW|TOPW|TOUCH)\>"
123 icolor brightgreen "(^|^[[:space:]]*)(UNLINK|UNMAP|USEWINDOW)\>"
124 icolor brightgreen "(^|^[[:space:]]*)(VERSION|VSYNC)\>"
125 icolor brightgreen "(^|^[[:space:]]*)(WATCH|WAVE|WORT_SEP)\>"
126 icolor brightgreen "(^|^[[:space:]]*)(XLOAD|XRUN)\>"
127
128 ## commands with a blank in it
129
130 icolor brightblue "(^|^[[:space:]]*)(ON\ ERROR\ CONT)"
131 icolor brightblue "(^|^[[:space:]]*)(ON\ BREAK\ CONT)"
132 icolor brightred "(^|^[[:space:]]*)(ECHO\ (ON|OFF))"
133
134
135 ## keywords
136 icolor brightblue "\<(and|or|not|to|xor|not|then|step|var|tab|using)\>"
137
138 ## operators
139 color white "[+*=\^]" "<" ">" "/" "-"
140 color brightred "[@\~]" 
141
142
143 ## number constants
144 icolor brightyellow "\b(([1-9][0-9]+)|0+)\.[0-9]+j?\b" "\b([1-9][0-9]*[Lj]?)\b" "\b0o?[0-7]*L?\b" "\b0x[1-9a-f][0-9a-f]*L?\b" "\b0b[01]+\b"
145 icolor brightyellow "[\ ,\(]\#[1-9][0-9]*\b"
146
147 ## parentheses
148 color magenta "[(){}]" "\[" "\]"
149
150 # labels
151 icolor red "(^|^[[:space:]]*)[^\ ^=.]*:"
152
153 # Comments.
154 color yellow "(^|^[[:space:]]*)'.*$"
155 icolor yellow "(^|^[[:space:]]*)REM.*$"
156 color yellow "!.*$"
157
158 icolor brightwhite,blue "(^|^[[:space:]]*)PROGRAM.*$"
159
160 #shebang line
161 icolor brightwhite,green "^\#\!.*$"
162
163
164
165 # Strings
166 color yellow "<[^= ]*>" ""(\\.|[^"])*""
167
168 ## trailing spaces
169 color ,green "[[:space:]]+$"
170
171 ## reminders
172 color brightwhite,yellow "(FIXME|TODO|XXX)"