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 #ifndef rangeset_h_DEFINED
32 #define rangeset_h_DEFINED
33
34 #include <Xm/Xm.h>
35 #include <X11/Xft/Xft.h>
36
37 #define N_RANGESETS 63
38
39 typedef struct _Range Range;
40 typedef struct _Rangeset Rangeset;
41
42 void RangesetRefreshRange(Rangeset *rangeset,
int start,
int end);
43 void RangesetEmpty(Rangeset *rangeset);
44 void RangesetInit(Rangeset *rangeset,
int label, textBuffer *buf);
45 int RangesetChangeModifyResponse(Rangeset *rangeset,
char *name);
46 int RangesetFindRangeNo(Rangeset *rangeset,
int index,
int *start,
int *end);
47 int RangesetFindRangeOfPos(Rangeset *rangeset,
int pos,
int incl_end);
48 int RangesetCheckRangeOfPos(Rangeset *rangeset,
int pos);
49 int RangesetInverse(Rangeset *p);
50 int RangesetAdd(Rangeset *origSet, Rangeset *plusSet);
51 int RangesetAddBetween(Rangeset *rangeset,
int start,
int end);
52 int RangesetRemove(Rangeset *origSet, Rangeset *minusSet);
53 int RangesetRemoveBetween(Rangeset *rangeset,
int start,
int end);
54 int RangesetGetNRanges(Rangeset *rangeset);
55 void RangesetGetInfo(Rangeset *rangeset,
int *defined,
int *label,
56 int *count,
char **color,
char **name,
char **mode);
57 RangesetTable *RangesetTableAlloc(textBuffer *buf);
58 RangesetTable *RangesetTableFree(RangesetTable *table);
59 RangesetTable *RangesetTableClone(RangesetTable *srcTable,
60 textBuffer *destBuffer);
61 int RangesetFindIndex(RangesetTable *table,
int label,
int must_be_active);
62 int RangesetLabelOK(
int label);
63 int RangesetCreate(RangesetTable *table);
64 int nRangesetsAvailable(RangesetTable *table);
65 Rangeset *RangesetForget(RangesetTable *table,
int label);
66 Rangeset *RangesetFetch(RangesetTable *table,
int label);
67 unsigned char * RangesetGetList(RangesetTable *table);
68 void RangesetTableUpdatePos(RangesetTable *table,
int pos,
int n_ins,
int n_del);
69 void RangesetBufModifiedCB(
int pos,
int nInserted,
int nDeleted,
int nRestyled,
70 const char *deletedText,
void *cbArg);
71 int RangesetIndex1ofPos(RangesetTable *table,
int pos,
int needs_color);
72 int RangesetAssignColorName(Rangeset *rangeset,
char *color_name);
73 int RangesetAssignColorPixel(Rangeset *rangeset, XftColor color,
int ok);
74 char *RangesetGetName(Rangeset *rangeset);
75 int RangesetAssignName(Rangeset *rangeset,
char *name);
76 int RangesetGetColorValid(Rangeset *rangeset, XftColor *color);
77 char *RangesetTableGetColorName(RangesetTable *table,
int index);
78 int RangesetTableGetColorValid(RangesetTable *table,
int index, XftColor *color, Rangeset **rs);
79 Rangeset* RangesetTableAssignColorPixel(RangesetTable *table,
int index, XftColor color,
80 int ok);
81 XftColor* RangesetGetColor(Rangeset *rangeset);
82
83 #endif
84