forked from erkyrath/remglk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrgstyle.c
59 lines (45 loc) · 1.22 KB
/
rgstyle.c
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
/* rgstyle.c: Style formatting hints.
for RemGlk, remote-procedure-call implementation of the Glk API.
Designed by Andrew Plotkin <[email protected]>
http://eblong.com/zarf/glk/
*/
#include <stdio.h>
#include "glk.h"
#include "remglk.h"
#include "rgdata.h"
#include "rgwin_grid.h"
#include "rgwin_buf.h"
/* This version of the library doesn't accept style hints. */
void glk_stylehint_set(glui32 wintype, glui32 styl, glui32 hint,
glsi32 val)
{
}
void glk_stylehint_clear(glui32 wintype, glui32 styl, glui32 hint)
{
}
glui32 glk_style_distinguish(window_t *win, glui32 styl1, glui32 styl2)
{
if (!win) {
gli_strict_warning("style_distinguish: invalid ref");
return FALSE;
}
if (styl1 >= style_NUMSTYLES || styl2 >= style_NUMSTYLES)
return FALSE;
/* ### */
return FALSE;
}
glui32 glk_style_measure(window_t *win, glui32 styl, glui32 hint,
glui32 *result)
{
glui32 dummy;
if (!win) {
gli_strict_warning("style_measure: invalid ref");
return FALSE;
}
if (styl >= style_NUMSTYLES || hint >= stylehint_NUMHINTS)
return FALSE;
if (!result)
result = &dummy;
/* ### */
return FALSE;
}