lwl | Less with links. |
| download: http://git.y1.nz/archives/lwl.tar.gz | |
| README | Files | Log | Refs |
state.h
1 #include "text.h"
2
3 typedef struct _s {
4 int mode;
5
6 /* current scroll position */
7 int line_offset;
8
9 /* name of the file being displayed */
10 const char *filename;
11
12 /* message displayed in status bar (or NULL) */
13 const char *message;
14
15 /* user input typed into status bar */
16 char *input;
17 int input_length;
18
19 Markup **results;
20 int result_count;
21
22 /* dynamic markups for showing text matches, etc */
23 Markup **markups;
24 int markup_count;
25 int markup_index;
26 } State;
27
28 State *init_state();
29
30 void set_mode(State *state, int mode);
31 void type_input_char(State *state, Wrap *wrap, char ch);
32 void type_input_backspace(State *state);
33
34 void scroll_to(State *state, Wrap *wrap, int index);
35
36 void set_markups(State *state, Markup **markups, int markup_count);
37 void do_search(FileContents *contents, State *state, Wrap *wrap);
38 void next_markup(State *state, Wrap *wrap, int step);
This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.