1 | [package] |
2 | name = "x11rb" |
3 | version = "0.13.0" |
4 | description = "Rust bindings to X11" |
5 | authors = [ |
6 | "Uli Schlachter <psychon@znc.in>" , |
7 | "Eduardo Sánchez Muñoz <eduardosm-dev@e64.io>" , |
8 | "notgull <jtnunley01@gmail.com>" , |
9 | ] |
10 | repository = "https://github.com/psychon/x11rb" |
11 | readme = "../README.md" |
12 | edition = "2021" |
13 | rust-version = "1.63" |
14 | license = "MIT OR Apache-2.0" |
15 | keywords = ["xcb" , "X11" ] |
16 | |
17 | [dependencies] |
18 | x11rb-protocol = { version = "0.13.0" , default-features = false, features = ["std" ], path = "../x11rb-protocol" } |
19 | libc = { version = "0.2" , optional = true } |
20 | libloading = { version = "0.8.0" , optional = true } |
21 | once_cell = { version = "1.17" , optional = true } |
22 | as-raw-xcb-connection = { version = "1.0" , optional = true } |
23 | tracing = { version = "0.1" , optional = true, default-features = false } |
24 | rustix = { version = "0.38" , default-features = false, features = ["std" , "event" , "fs" , "net" , "system" ] } |
25 | |
26 | [target.'cfg(not(unix))'.dependencies] |
27 | gethostname = "0.4" |
28 | |
29 | [dev-dependencies] |
30 | gethostname = "0.4" |
31 | polling = "3.3.1" |
32 | tracing-subscriber = "0.3" |
33 | |
34 | [features] |
35 | # Without this feature, all uses of `unsafe` in the crate are forbidden via |
36 | # #![deny(unsafe_code)]. This has the effect of disabling the XCB FFI bindings. |
37 | allow-unsafe-code = ["libc" , "as-raw-xcb-connection" ] |
38 | |
39 | # Enable utility functions in `x11rb::cursor` for loading mouse cursors. |
40 | cursor = ["render" , "resource_manager" ] |
41 | |
42 | # Enable utility functions in `x11rb::image` for working with image data. |
43 | image = [] |
44 | |
45 | # Enable utility functions in `x11rb::resource_manager` for querying the |
46 | # resource databases. |
47 | resource_manager = ["x11rb-protocol/resource_manager" ] |
48 | |
49 | dl-libxcb = ["allow-unsafe-code" , "libloading" , "once_cell" ] |
50 | |
51 | # Enable extra traits on protocol types. |
52 | extra-traits = ["x11rb-protocol/extra-traits" ] |
53 | |
54 | # Add the ability to parse X11 requests (not normally needed). |
55 | request-parsing = ["x11rb-protocol/request-parsing" ] |
56 | |
57 | # Enable this feature to enable all the X11 extensions |
58 | all-extensions = [ |
59 | "x11rb-protocol/all-extensions" , |
60 | "composite" , |
61 | "damage" , |
62 | "dbe" , |
63 | "dpms" , |
64 | "dri2" , |
65 | "dri3" , |
66 | "glx" , |
67 | "present" , |
68 | "randr" , |
69 | "record" , |
70 | "render" , |
71 | "res" , |
72 | "screensaver" , |
73 | "shape" , |
74 | "shm" , |
75 | "sync" , |
76 | "xevie" , |
77 | "xf86dri" , |
78 | "xf86vidmode" , |
79 | "xfixes" , |
80 | "xinerama" , |
81 | "xinput" , |
82 | "xkb" , |
83 | "xprint" , |
84 | "xselinux" , |
85 | "xtest" , |
86 | "xv" , |
87 | "xvmc" |
88 | ] |
89 | |
90 | # Features to enable individual X11 extensions |
91 | composite = ["x11rb-protocol/composite" , "xfixes" ] |
92 | damage = ["x11rb-protocol/damage" , "xfixes" ] |
93 | dbe = ["x11rb-protocol/dbe" ] |
94 | dpms = ["x11rb-protocol/dpms" ] |
95 | dri2 = ["x11rb-protocol/dri2" ] |
96 | dri3 = ["x11rb-protocol/dri3" ] |
97 | glx = ["x11rb-protocol/glx" ] |
98 | present = ["x11rb-protocol/present" , "randr" , "xfixes" , "sync" ] |
99 | randr = ["x11rb-protocol/randr" , "render" ] |
100 | record = ["x11rb-protocol/record" ] |
101 | render = ["x11rb-protocol/render" ] |
102 | res = ["x11rb-protocol/res" ] |
103 | screensaver = ["x11rb-protocol/screensaver" ] |
104 | shape = ["x11rb-protocol/shape" ] |
105 | shm = ["x11rb-protocol/shm" ] |
106 | sync = ["x11rb-protocol/sync" ] |
107 | xevie = ["x11rb-protocol/xevie" ] |
108 | xf86dri = ["x11rb-protocol/xf86dri" ] |
109 | xf86vidmode = ["x11rb-protocol/xf86vidmode" ] |
110 | xfixes = ["x11rb-protocol/xfixes" , "render" , "shape" ] |
111 | xinerama = ["x11rb-protocol/xinerama" ] |
112 | xinput = ["x11rb-protocol/xinput" , "xfixes" ] |
113 | xkb = ["x11rb-protocol/xkb" ] |
114 | xprint = ["x11rb-protocol/xprint" ] |
115 | xselinux = ["x11rb-protocol/xselinux" ] |
116 | xtest = ["x11rb-protocol/xtest" ] |
117 | xv = ["x11rb-protocol/xv" , "shm" ] |
118 | xvmc = ["x11rb-protocol/xvmc" , "xv" ] |
119 | |
120 | [package.metadata.docs.rs] |
121 | all-features = true |
122 | |
123 | [[example]] |
124 | name = "generic_events" |
125 | required-features = ["present" ] |
126 | |
127 | [[example]] |
128 | name = "shared_memory" |
129 | required-features = ["libc" , "shm" ] |
130 | |
131 | [[example]] |
132 | name = "xeyes" |
133 | required-features = ["shape" ] |
134 | |
135 | [[example]] |
136 | name = "simple_window" |
137 | required-features = ["cursor" , "resource_manager" , "tracing" , "tracing-subscriber/env-filter" ] |
138 | |
139 | [[example]] |
140 | name = "display_ppm" |
141 | required-features = ["image" ] |
142 | |
143 | [[example]] |
144 | name = "record" |
145 | required-features = ["record" ] |
146 | |