forked from m1k1o/neko
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathxorg.h
More file actions
49 lines (39 loc) · 1.48 KB
/
xorg.h
File metadata and controls
49 lines (39 loc) · 1.48 KB
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
#pragma once
#include <X11/Xlib.h>
#include <X11/XKBlib.h>
#include <X11/Xutil.h>
#include <X11/extensions/Xrandr.h>
#include <X11/extensions/XTest.h>
#include <X11/extensions/Xfixes.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
// for computing xrandr modelines at runtime
#include <libxcvt/libxcvt.h>
extern void goCreateScreenSize(int index, int width, int height, int mwidth, int mheight);
extern void goSetScreenRates(int index, int rate_index, short rate);
Display *getXDisplay(void);
int XDisplayOpen(char *input);
void XDisplayClose(void);
void XMove(int x, int y);
void XCursorPosition(int *x, int *y);
void XScroll(int deltaX, int deltaY);
void XButton(unsigned int button, int down);
typedef struct xkeyentry_t {
KeySym keysym;
KeyCode keycode;
struct xkeyentry_t *next;
} xkeyentry_t;
static void XKeyEntryAdd(KeySym keysym, KeyCode keycode);
static KeyCode XKeyEntryGet(KeySym keysym);
static KeyCode XkbKeysymToKeycode(Display *dpy, KeySym keysym);
void XKey(KeySym keysym, int down);
Status XSetScreenConfiguration(int width, int height, short rate);
void XGetScreenConfiguration(int *width, int *height, short *rate);
void XGetScreenConfigurations();
void XCreateScreenMode(int *width, int *height, short rate);
XRRModeInfo *XCreateScreenModeInfo(int hdisplay, int vdisplay, short vrefresh);
void XSetKeyboardModifier(unsigned char mod, int on);
unsigned char XGetKeyboardModifiers();
XFixesCursorImage *XGetCursorImage(void);
char *XGetScreenshot(int *w, int *h);