Cargo.toml

  1[package]
  2name = "gpui"
  3version = "0.2.2"
  4edition.workspace = true
  5authors = ["Nathan Sobo <nathan@zed.dev>"]
  6description = "Zed's GPU-accelerated UI framework"
  7repository = "https://github.com/zed-industries/zed"
  8publish = true
  9license = "Apache-2.0"
 10homepage = "https://gpui.rs"
 11readme = "README.md"
 12keywords = ["desktop", "gui", "immediate"]
 13categories = ["gui"]
 14
 15
 16[lints]
 17workspace = true
 18
 19[features]
 20default = ["font-kit", "wayland", "x11", "windows-manifest"]
 21test-support = [
 22    "leak-detection",
 23    "collections/test-support",
 24    "http_client/test-support",
 25    "wayland",
 26    "x11",
 27    "proptest",
 28]
 29inspector = ["gpui_macros/inspector"]
 30leak-detection = ["backtrace"]
 31wayland = [
 32    "bitflags",
 33]
 34x11 = [
 35    "scap?/x11",
 36]
 37screen-capture = [
 38    "scap",
 39]
 40windows-manifest = ["dep:embed-resource"]
 41input-latency-histogram = ["dep:hdrhistogram"]
 42
 43[lib]
 44path = "src/gpui.rs"
 45doctest = false
 46
 47[dependencies]
 48anyhow.workspace = true
 49async-task = "4.7"
 50backtrace = { workspace = true, optional = true }
 51bitflags = { workspace = true, optional = true }
 52
 53collections.workspace = true
 54ctor.workspace = true
 55derive_more.workspace = true
 56etagere = "0.2"
 57futures.workspace = true
 58futures-concurrency.workspace = true
 59gpui_macros.workspace = true
 60gpui_shared_string.workspace = true
 61http_client.workspace = true
 62image.workspace = true
 63inventory.workspace = true
 64itertools.workspace = true
 65log.workspace = true
 66num_cpus = "1.13"
 67parking = "2.0.0"
 68parking_lot.workspace = true
 69postage.workspace = true
 70proptest = { workspace = true, optional = true }
 71chrono.workspace = true
 72profiling.workspace = true
 73rand.workspace = true
 74raw-window-handle = "0.6"
 75regex.workspace = true
 76refineable.workspace = true
 77scheduler.workspace = true
 78resvg = { version = "0.45.0", default-features = false, features = [
 79    "text",
 80    "system-fonts",
 81    "memmap-fonts",
 82    "raster-images"
 83] }
 84usvg = { version = "0.45.0", default-features = false }
 85ttf-parser = "0.25"
 86util_macros.workspace = true
 87schemars.workspace = true
 88seahash = "4.1"
 89serde.workspace = true
 90serde_json.workspace = true
 91slotmap.workspace = true
 92smallvec.workspace = true
 93async-channel.workspace = true
 94stacksafe.workspace = true
 95strum.workspace = true
 96sum_tree.workspace = true
 97taffy = "=0.9.0"
 98thiserror.workspace = true
 99gpui_util.workspace = true
100hdrhistogram = { workspace = true, optional = true }
101waker-fn = "1.2.0"
102lyon = "1.0"
103pin-project = "1.1.10"
104spin = "0.10.0"
105pollster.workspace = true
106url.workspace = true
107uuid.workspace = true
108web-time.workspace = true
109
110[target.'cfg(target_family = "wasm")'.dependencies]
111getrandom = { version = "0.3.4", features = ["wasm_js"] }
112uuid = { workspace = true, features = ["js"] }
113
114
115[target.'cfg(target_os = "macos")'.dependencies]
116block = "0.1"
117cocoa.workspace = true
118cocoa-foundation.workspace = true
119core-foundation.workspace = true
120core-foundation-sys.workspace = true
121core-graphics = "0.24"
122core-video.workspace = true
123core-text = "21"
124# WARNING: If you change this, you must also publish a new version of zed-font-kit to crates.io
125font-kit = { git = "https://github.com/zed-industries/font-kit", rev = "94b0f28166665e8fd2f53ff6d268a14955c82269", package = "zed-font-kit", version = "0.14.1-zed", optional = true }
126foreign-types = "0.5"
127log.workspace = true
128media.workspace = true
129objc.workspace = true
130objc2 = { version = "0.6", optional = true }
131objc2-metal = { version = "0.3", optional = true }
132mach2.workspace = true
133#TODO: replace with "objc2"
134metal.workspace = true
135
136[target.'cfg(any(target_os = "linux", target_os = "freebsd", target_os = "macos"))'.dependencies]
137pathfinder_geometry = "0.5"
138
139[target.'cfg(any(target_os = "linux", target_os = "freebsd", target_os = "windows"))'.dependencies]
140scap = { workspace = true, optional = true }
141
142
143
144[target.'cfg(target_os = "windows")'.dependencies]
145windows = { version = "0.61", features = ["Win32_Foundation"] }
146
147
148[dev-dependencies]
149backtrace.workspace = true
150collections = { workspace = true, features = ["test-support"] }
151env_logger.workspace = true
152gpui_platform = { workspace = true, features = ["font-kit"] }
153gpui_util = { workspace = true }
154lyon = { version = "1.0", features = ["extra"] }
155proptest = { workspace = true }
156rand.workspace = true
157scheduler = { workspace = true, features = ["test-support"] }
158unicode-segmentation = { workspace = true }
159
160[target.'cfg(not(target_family = "wasm"))'.dev-dependencies]
161http_client = { workspace = true, features = ["test-support"] }
162reqwest_client = { workspace = true, features = ["test-support"] }
163
164[target.'cfg(target_family = "wasm")'.dev-dependencies]
165wasm-bindgen = { workspace = true }
166gpui_web.workspace = true
167
168[build-dependencies]
169embed-resource = { version = "3.0", optional = true }
170
171[target.'cfg(target_os = "macos")'.build-dependencies]
172bindgen = "0.71"
173cbindgen = { version = "0.28.0", default-features = false }
174naga.workspace = true
175
176
177
178
179[[example]]
180name = "hello_world"
181path = "examples/hello_world.rs"
182
183[[example]]
184name = "image"
185path = "examples/image/image.rs"
186
187[[example]]
188name = "input"
189path = "examples/input.rs"
190
191[[example]]
192name = "on_window_close_quit"
193path = "examples/on_window_close_quit.rs"
194
195[[example]]
196name = "opacity"
197path = "examples/opacity.rs"
198
199[[example]]
200name = "pattern"
201path = "examples/pattern.rs"
202
203[[example]]
204name = "set_menus"
205path = "examples/set_menus.rs"
206
207[[example]]
208name = "shadow"
209path = "examples/shadow.rs"
210
211[[example]]
212name = "svg"
213path = "examples/svg/svg.rs"
214
215[[example]]
216name = "tab_stop"
217path = "examples/tab_stop.rs"
218
219[[example]]
220name = "text"
221path = "examples/text.rs"
222
223[[example]]
224name = "text_wrapper"
225path = "examples/text_wrapper.rs"
226
227[[example]]
228name = "tree"
229path = "examples/tree.rs"
230
231[[example]]
232name = "uniform_list"
233path = "examples/uniform_list.rs"
234
235[[example]]
236name = "window_shadow"
237path = "examples/window_shadow.rs"
238
239[[example]]
240name = "grid_layout"
241path = "examples/grid_layout.rs"
242
243[[example]]
244name = "list_example"
245path = "examples/list_example.rs"
246
247[[example]]
248name = "mouse_pressure"
249path = "examples/mouse_pressure.rs"