File: mp_synhi.h

package info (click to toggle)
mped 3.3.17-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,288 kB
  • ctags: 1,635
  • sloc: ansic: 13,150; sh: 393; makefile: 232; perl: 66
file content (72 lines) | stat: -rw-r--r-- 1,724 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
/*

    mp_synhi.h

    Syntax higlighters.

    mp - Programmer Text Editor

    Copyright (C) 1991-2005 Angel Ortega <angel@triptico.com>

    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.

    http://www.triptico.com

*/

struct mps_wsynhi
{
	char * word;
	int color;
};

#define MAX_WORDS_PER_SYNHI	150

struct mps_synhi
{
	char * type;
	char * mode;
	char * q_start;
	char * q_end;
	char ** c_start;
	char ** c_end;
	char ** magic_1;
	char ** magic_2;
	char ** exts;
	char ** tokens;
	char ** vars;
	char ** helpers;
	char * seps;
	int casesig;
	int numbers;

	int wi;
	struct mps_wsynhi w[MAX_WORDS_PER_SYNHI];
};

extern struct mps_synhi _mps_synhi[];
extern int _draw_quoting;
extern int _in_comment;
extern int _override_synhi;
extern char * _mps_last_tag_target;


int mps_is_sep(char c, int synhi);
void mps_auto_synhi(mp_txt * txt);
int mps_word_color(int synhi, char * word, int col, int line);
int mps_quoting(int c, int color, int synhi);
int mps_set_override_mode(char * mode);
char * mps_enumerate_modes(void);
void mps_startup(void);