|
|
@@ -236,7 +236,7 @@ well more than 24 line of code, we'd want to scroll it or modify it if we're mak |
|
|
|
function does its' work, and how we use 'syntax_*' functions in them. |
|
|
|
*/ |
|
|
|
|
|
|
|
void preview_c_file (char * text_file, int width, int height, int x, int y) { |
|
|
|
void preview_c_file (char * text_file, int x, int y) { |
|
|
|
// Before we begin (Ada pun intended, remove this in final version), I won't (re)align 'separators' and 'keywords', because they fuck-up my comments, which I never write |
|
|
|
// in my "official" programs. I write comments only here, to explain stuff in more details. Have fun... Oh, and type of variable 'keywords' an array of string pointers of |
|
|
|
// automatic length, which we get with "sizeof (keywords) / sizeof (keywords [0])" part, for those keywords, it would be 32UL, and we cast it to integer. |
|
|
@@ -253,8 +253,7 @@ void preview_c_file (char * text_file, int width, int height, int x, int y) { |
|
|
|
|
|
|
|
int word, reset_x, reset_y; |
|
|
|
|
|
|
|
(void) width; |
|
|
|
(void) height; |
|
|
|
curses_configure (); |
|
|
|
|
|
|
|
syntax_define (FALSE, FALSE, "/*", "*/", '\0', COLOUR_GREY, EFFECT_BOLD); // Below, we're simply using our 'syntax_define' function. |
|
|
|
syntax_define (FALSE, FALSE, "//", "\n", '\0', COLOUR_GREY, EFFECT_BOLD); |
|
|
|