////////////////////////////////////////////////////////////////////////////// // // Ch script highlighter written Frederic Rigaut // based on wxWindowscpp highlighter by Robert O'Connor, rob@medicalmnemonics.com // ////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// // language name Language: CH Script ////////////////////////////////////////////////////////////////////////////// // default file filter // note: if more than one extension is associated, eg: // C/Ch/chf/chs files (*.c,*.ch,*.chf,*.chs,*.h)|*.c;*.ch;*.chf;*.chs;*.h Filter: CH Script files (*.c,*.ch,*.chf,*.chs,*.h)|*.c;*.ch;*.chf;*.chs;*.h ////////////////////////////////////////////////////////////////////////////// // help file which will be invokend when F1 is pressed HelpFile: ////////////////////////////////////////////////////////////////////////////// // language case sensitivity // 0 - no // 1 - yes CaseSensitive: 1 ////////////////////////////////////////////////////////////////////////////// // comment type: LineComment - comment to the end of line // BlockCommentBeg - block comment begin, it could be // multiline // BlockCommentEnd - block comment end LineComment: // BlockCommentBeg: /* BlockCommentEnd: */ ////////////////////////////////////////////////////////////////////////////// // identifier characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char IdentifierBegChars: a..z A..Z _%@. IdentifierChars: a..z A..Z _ 0..9 ? ////////////////////////////////////////////////////////////////////////////// // numeric constants begin characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char // number always starts with 0..9 except when NumConstBeg // defines other NumConstBegChars: 0..9 ////////////////////////////////////////////////////////////////////////////// // numeric constants characters // note: characters shouldn't be delimited, except arrays // array of chars could be defined as from_char..to_char // number always starts with 0..9 except when NumConstBeg // defines other NumConstChars: 0..9 ////////////////////////////////////////////////////////////////////////////// // escape character EscapeChar: \ ////////////////////////////////////////////////////////////////////////////// // keyword table // note: delimited with spaces, lines could be wrapped // you may divide keywords into two groups which can be // highlighted differently // [ch script : standard commands] KeyWords1: auto bool break case char complex const continue default do double else enum extern float for goto if inline int long register restrict return short signed sizeof static struct switch this typedef union unsigned void volatile while class delete new private public this using __declspec array foreach string_t ComplexInf ComplexNaN Inf NaN NULL //[ch script : preprocessing directives and preprocessing operator] KeyWords2: #define #elif #else #endif #error #if #ifdef #ifndef #include #line #pragma #undef defined // [ch script : functions and macros] KeyWords3: _cgets _cprintf _cputs _creat _cscanf _dlclose _dlerror _dlopen _dlsym _exit _getch _getche _inp _inpd _inpw _kbhit _outp _outpd _outpw _putch _read _ungetch _write abort abs accept access acct acos acosh acosl aio_cancel aio_error aio_fsync aio_read aio_return aio_suspend aio_write alarm alias arg ascftime asctime asctime_r asin asinh asinl assert atan atan2 atan2l atanh atanl atexit atoc atof atoi atol balance bcmp bcopy bind bindtextdomain bsearch btowc bzero cabs cabsf cabsl cacos cacosf cacosh cacoshf cacoshl cacosl calloc carg cargf cargl casin casinf casinh casinhf casinhl casinl catan catanf catanh catanhf catanhl catanl cbrt ccompanionmatrix ccos ccosf ccosh ccoshf ccoshl ccosl cdeterminant cdiagonal cdiagonalmatrix ceil ceill cerr cexp cexpf cexpl cfevalarray cfgetispeed cfgetospeed cfsetispeed cfsetospeed cftime cfunm charpolycoef chdir chinfo chmod choldecomp chown chroot cimag cimagf cimagl cin cinverse clear clearerr clock clock_getres clock_gettime clock_settime clog clogf clogl close closedir closelog closesocket cmean combination companionmatrix complexsolve condnum conj conjf conjl connect connet conv conv2 copysign corrcoef correlation2 cos cosh coshl cosl cout covariance cpinverse CControl CPlot cpolyeval cpow cpowf cpowl cproduct cproj cputs creal crealf creall creat cross crypt cscanf csin csinf csinh csinhf csinhl csinl csqrt csqrtf csqrtl csum ctan ctanf ctanh ctanhf ctanhl ctanl ctermid ctime ctime_r ctrace ctriangularmatrix cumprod cumsum curvefit cuserid deconv derivative derivatives determinant dgettext diagonal diagonalmatrix difference difftime div dlclose dlerror dlopen dlsym dot dup dup2 eigensystem endgrent endhostent endnetconfig endnetent endnetpath endprotoent endpwent endservent eof erf erfc execl execle execlp execlpe execv execve execvp execvpe exit exp exp2 exp2f exp2l expl expm expm1 fabs fabsl factorial fattach fchdir fchmod fchown fchroot fclose fcntl fdetach fdim fdimf fdiml fdopen fegetround feof ferror fesetround fevalarray fflush fft fgetc fgetchar fgetgrent fgetgrent_r fgetpos fgetpwent fgetpwent_r fgets fgetwc fgetws fileno filter filter2 findvalue fliplr flipud flockfile floor floorl fma fmax fmin fminimum fminimums fmod fmodf fmodl fopen fork fpathconf fpclassify fplotxy fplotxyz fprintf fput fputc fputchar fputs fputwc fputws fread free freenetconfigent freopen frexp frexpl fscanf fseek fsetpos fsolve fstat fsync ftell ftime ftok ftruncate funlockfile funm fwide fwprintf fwrite fzero gamma gamma_r gcd getc getc_unlocked getch getchar getche getcwd getegid getenv geteuid getgid getgrent getgrent_r getgrgid getgrgid_r getgrnam getgrnam_r getgroups gethostbyaddr gethostbyaddr_r gethostbyname gethostbyname_r gethostent gethostent_r gethostid gethostname getline getlogin getlogin_r getmsg getnetbyaddr getnetbyaddr_r getnetbyname getnetbyname_r getnetconfig getnetconfigent getnetent getnetent_r getnetpath getnum getopt getpeername getpgid getpgrp getpid getpid2 getpmsg getppid getpriority getprotobyname getprotobyname_r getprotobynumber getprotobynumber_r getprotoent getprotoent_r getpwent getpwent_r getpwnam getpwnam_r getpwuid getpwuid_r getrlimit getrusage gets getservbyname getservbyname_r getservbyport getservbyport_r getservent getservent_r getsid getsockname getsockopt gettext gettime gettxt getuid getwc getwchar glob globfree gmtime gmtime_r gsignal hessdecomp histogram householdermatrix htonl htons hypot hypotl identitymatrix ifft ilogb imag index inet_addr inet_lnaof inet_makeaddr inet_netof inet_network inet_ntoa initgroups initstate integral1 integral2 integral3 integration2 integration3 interp1 interp2 inverse ioctl ioctlsocket isalnum isalpha isascii isastream isatty iscnan iscntrl iscnum isdigit isenv isfinite isgraph isinf iskey islower isnan isnormal isnum isprint ispunct isspace isstudent isupper isvar iswalnum iswalpha iswcntrl iswctype iswdigit iswgraph iswlower iswnum iswprint iswpunct iswspace iswupper iswxdigit isxdigit itoa j0 j1 jn kbhit keep kill labs lchown lcm ldexp ldexpl ldiv lgamma lgamma_r link linsolve linspace lio_listio listen llsqcovsolve llsqnonnegsolve llsqsolve localeconv localtime localtime_r lockf log log10 log10l log1p log2 logb logl logm logspace longjmp lseek lstat ltoa ludecomp malloc matherr max maxloc maxv mblen mbrlen mbrtowc mbsinit mbsrtowcs mbstowcs mbtowc mean median memccpy memchr memcmp memcpy memicmp memmove memset min mincore minloc minv mkdir mkfifo mknod mkstemp mktemp mktime mlock mlockall mmap modf modfl movmem mprotect mq_close mq_getattr mq_notify mq_open mq_receive mq_send mq_setattr mq_unlink msgctl msgget msgrcv msgsnd msync munlock munlockall munmap nanosleep netdir_free netdir_getbyaddr netdir_getbyname netdir_options netdir_perror netdir_sperror nextafter nice norm ntohl ntohs nullspace odesolve open opendir openlog orthonormalbase outp outportperror pathconf pause pclose perror pinverse pipe plock plotxy plotxyf plotxyz plotxyzf polarpow poll polycoef polyder polyder2 polyeval polyevalarray polyevalm polyfit popen pow pow10 pow10l powl printf processcfile processhfile product profil ptrace putc putc_unlocked putch putchar putenv putmsg putpmsg putpwent puts puttext putw putwc putwchar qrdecomp qrdelete qrinsert qsort raise rand random rank rcmd rcondnum re_comp re_exec read readdir readdir_r readline readlink readv real realloc recv recvfrom recvmsg regcmp regcomp regerror regex regexec regfree remainder remenv remove rename residue rewind rewinddir rexec rindex rint rmdir roots rot90 rrandom rresvport rsf2csf ruserok sbrk scalb scalbn scanf sched_get_priority_max sched_get_priority_min sched_get_rr_interval sched_getparam sched_getscheduler sched_setparam sched_setscheduler sched_yield schurdecomp seekdir select sem_close sem_destroy sem_getvalue sem_init sem_open sem_post sem_trywait sem_unlink sem_wait semctl semget semop send sendmsg sendto set_new_handler setbuf setegid seteuid setgid setgrent setgroups sethostent setjmp setlocale setlogmask setmode setnetconfig setnetent setnetpath setpgid setpgrp setpriority setprotoent setpwent setrlimit setservent setsid setsockopt setstate setuid setvbuf shm_open shm_unlink shmat shmctl shmdt shmget shutdown sigaction sigaddset sigaltstack sigdelset sigemptyset sigfillset sighold sigignore sigismember sign signal signbit sigpause sigpending sigprocmask sigqueue sigrelse sigsend sigsendset sigset sigsuspend sigtimedwait sigwaitinfo sin sinh sinhl sinl sizeofelement sleep snprintf socket socketpair sort spawnl spawnle spawnlp spawnlpe spawnv spawnve spawnvp spawnvpe specialmatrix sprintf sqrt sqrtl sqrtm srand srandom sscanf ssignal stat std stime stpcpy str2ascii str2mat stradd strcasecmp strcat strchr strcmp strcoll strconcat strcpy strcspn strdup strerror streval strftime strgetc stricmp strjoin strlen strlwr strncasecmp strncat strncmp strncpy strnset strparse strpbrk strputc strrchr strrep strrev strset strspn strstr strtod strtok strtok_r strtol strtoul strupr strxfrm sum svd swprintf symlink sync sysconf syslog system t_accept t_alloc t_bind t_close t_connect t_error t_free t_getinfo t_getstate t_listen t_look t_open t_optmgmt t_rcv t_rcvconnect t_rcvdis t_rcvrel t_rcvudata t_rcvuderr t_snd t_snddis t_sndrel t_sndudata t_strerror t_sync t_unbind taddr2uaddr tan tanh tanhl tanl tcdrain tcflow tcflush tcgetattr tcgetpgrp tcsendbreak tcsetattr tcsetpgrp tell telldir tempnam textdomain time timer_create timer_delete timer_getoverrun timer_gettime timer_settime times tmpfile tmpnam toascii tolower toupper towctrans towlower towupper trace triangularmatrix truncate ttyname ttyname_r tzset uaddr2taddr umask uname ungetc ungetch ungetwc unlink unlock unwrap urand usleep utime va_arg va_copy va_count va_dim va_elementtype va_end va_extent va_isarray va_list VA_NOARG va_start vandermatrix vfork vfprintf vfscanf vfwprintf vhangup vprintf vscanf vsnprintf vsprintf vsscanf vswprintf vwprintf w2cstombs wait waitid waitpid wcrtomb wcscat wcschr wcscmp wcscoll wcscpy wcscspn wcsftime wcslen wcsncat wcsncmp wcsncpy wcspbrk wcsrchr wcsrtombs wcsspn wcsstr wcstod wcstok wcstol wcstombs wcstoul wcswcs wcswidth wcsxfrm wctob wctomb wctrans wctype wcwidth wgetenv wmemchr wmemcmp wmemcpy wmemmove wmemset wprintf write writev WSAAsyncGetHostByAddr WSAAsyncGetHostByName WSAAsyncGetProtoByName WSAAsyncGetProtoByNumber WSAAsyncGetServByName WSAAsyncGetServByPort WSAAsyncSelect WSACancelAsyncRequest WSACancelBlockingCall WSACleanup WSAGetLastError WSAIsBlocking WSASetBlockingHook WSASetLastError WSAStartup WSAUnhookBlockingHook wsprintf xcorr y0 y1 yn // [ch script : predefined macros and system constants] KeyWords4: __LINE__ __FILE__ __DATE__ __TIME__ __STDC__ __func__ __class__ __class_func__ _argc _argv _cwd _environ _errno _fpath _fpathext _histnum _histsize _home _host _ignoreeof _ipath _lang _lc_all _lc_collate _lc_ctype _lc_monetary _lc_numeric _lc_time _logname _lpath _new_handler _path _pathext _ppath _prompt _shell _status _term _tz _user _warning ////////////////////////////////////////////////////////////////////////////// // string delimiter: StringBegChar - string begin char // StringEndChar - string end char // MultilineStrings - enables multiline strings, as perl // has it StringBegChar: " StringEndChar: " MultilineStrings: 0 ////////////////////////////////////////////////////////////////////////////// // use preprocessor: 0 - no // 1 - yes // note: if yes, '#' and statements after it will be // highlighted with Preprocessor defined colors UsePreprocessor: 1 ////////////////////////////////////////////////////////////////////////////// // highlight line: 0 - no // 1 - yes // note: if yes, current line will be highlighted CurrLineHighlighted: 0 ////////////////////////////////////////////////////////////////////////////// // colors // note: first value is foreground, second is background color // and third (optional) represents font attribute: // B - bold // I - italic // U - underline // S - strike out // attributes can be combined: eg. B or BI // as value, it could be used any standard windows color: // clBlack, clMaroon, clGreen, clOlive, clNavy, // clPurple, clTeal, clGray, clSilver, clRed, clLime, // clYellow, clBlue, clFuchsia, clAqua, clLtGray, // clDkGray, clWhite, clScrollBar, clBackground, // clActiveCaption, clInactiveCaption, clMenu, clWindow, // clWindowFrame, clMenuText, clWindowText, clCaptionText, // clActiveBorder, clInactiveBorder, clAppWorkSpace, // clHighlight, clHighlightText, clBtnFace, clBtnShadow, // clGrayText, clBtnText, clInactiveCaptionText, // clBtnHighlight, cl3DDkShadow, cl3DLight, clInfoText, // clInfoBk // as value, it could be used hex numeric constant too: // $BBGGRR - BB: blue, GG: green, RR: red, eg: $FF6A00 SpaceCol: clWindowText clWindow Keyword1Col: clRed clWindow Keyword2Col: clPurple clWindow Keyword3Col: clNavy clWindow Keyword4Col: clTeal clWindow B IdentifierCol: clWindowText clWindow CommentCol: clGray clWindow I NumberCol: clGreen clWindow StringCol: clGreen clWindow SymbolCol: clNavy clWindow PreprocessorCol: clPurple clWindow SelectionCol: clWhite clNavy CurrentLineCol: clBlack clYellow OverrideTxtFgColor: 1 BlockAutoindent: 1 BlockBegStr: { BlockEndStr: } MatchedBracesCol: clWindowText clWindow Keyword5Col: clWindowText clWindow