Changed definitions...
This commit is contained in:
parent
55709e823a
commit
10b97692d0
20
xyntax.c
20
xyntax.c
@ -144,28 +144,28 @@ void syntax_define_separators (char * separator) {
|
||||
syntax_separator = separator;
|
||||
}
|
||||
|
||||
void syntax_define_default (int string_colour, int string_effect, int number_colour, int number_effect) {
|
||||
void syntax_define_default (int case_sensitive, int string_colour, int string_effect, int number_colour, int number_effect) {
|
||||
(void) syntax_insert (1, 0, " \t\r\n", "", '\0', COLOUR_WHITE, EFFECT_BOLD);
|
||||
(void) syntax_insert (0, 0, "\"", "\"", '\\', string_colour, string_effect);
|
||||
(void) syntax_insert (1, 1, "0123456789", syntax_separator, '\0', number_colour, number_effect);
|
||||
}
|
||||
|
||||
void syntax_define_words (int case_sensitive, char * * word_array, int word_count, int word_colour, int word_effect) {
|
||||
int word = 0;
|
||||
|
||||
for (word = 0; word != word_count; ++word) {
|
||||
(void) syntax_insert (0, 1, word_array [word], syntax_separator, '\0', word_colour, word_effect);
|
||||
}
|
||||
|
||||
if (case_sensitive != 0) {
|
||||
(void) syntax_insert (1, 1, "abcdefghijklmnopqrstuvwxyz", syntax_separator, '\0', COLOUR_WHITE, EFFECT_NORMAL);
|
||||
(void) syntax_insert (1, 1, "ABCDEFGHIJKLMNOPQRSTUVWXYZ", syntax_separator, '\0', COLOUR_WHITE, EFFECT_BOLD);
|
||||
(void) syntax_insert (1, 1, "_", syntax_separator, '\0', COLOUR_PINK, EFFECT_BOLD);
|
||||
(void) syntax_insert (1, 1, "_", syntax_separator, '\0', COLOUR_GREY, EFFECT_BOLD);
|
||||
} else {
|
||||
(void) syntax_insert (1, 1, "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_", syntax_separator, '\0', COLOUR_WHITE, EFFECT_NORMAL);
|
||||
}
|
||||
}
|
||||
|
||||
void syntax_define_words (char * * word_array, int word_count, int word_colour, int word_effect) {
|
||||
int word = 0;
|
||||
|
||||
for (word = 0; word != word_count; ++word) {
|
||||
(void) syntax_insert (0, 1, word_array [word], syntax_separator, '\0', word_colour, word_effect);
|
||||
}
|
||||
}
|
||||
|
||||
void syntax_define_range (char * range_begin, char * range_end, char range_escape, int range_colour, int range_effect) {
|
||||
(void) syntax_insert (0, 0, range_begin, range_end, range_escape, range_colour, range_effect);
|
||||
}
|
||||
|
4
xyntax.h
4
xyntax.h
@ -33,9 +33,9 @@ extern void syntax_define_style (int *, int *);
|
||||
|
||||
extern void syntax_define_separators (char *);
|
||||
|
||||
extern void syntax_define_default (int, int, int, int);
|
||||
extern void syntax_define_default (int, int, int, int, int);
|
||||
|
||||
extern void syntax_define_words (int, char * *, int, int, int);
|
||||
extern void syntax_define_words (char * *, int, int, int);
|
||||
|
||||
extern void syntax_define_range (char *, char *, char, int, int);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user