400 Commits

Author SHA1 Message Date
Mitchell Hashimoto
d2d21801d8 macos: need to link to libstdc++ 2023-02-19 10:44:54 -08:00
Mitchell Hashimoto
d2dd3df86a libtoolstep 2023-02-19 10:44:54 -08:00
Mitchell Hashimoto
8b80e65928 lots of broken stuff 2023-02-19 10:44:54 -08:00
Mitchell Hashimoto
1abaf87de9 build: LipoStep 2023-02-19 10:44:53 -08:00
Mitchell Hashimoto
55aff76922 build: remove SwiftBuildStep 2023-02-19 10:44:53 -08:00
Mitchell Hashimoto
abd739f3ef build: just copy xcframework 2023-02-19 10:44:53 -08:00
Mitchell Hashimoto
8035865596 build: ghostty lib, framework, build into app 2023-02-19 10:44:53 -08:00
Mitchell Hashimoto
4d09f8dba6 build: add SwiftBuildStep to run "swift build" 2023-02-19 10:44:52 -08:00
Mitchell Hashimoto
b49634a57c add TODO notes about arch 2023-02-19 10:44:52 -08:00
Mitchell Hashimoto
1f70181032 build: can build the app using Swift (noop) 2023-02-19 10:44:52 -08:00
Mitchell Hashimoto
a2f17aa71a fix tests, wasm build works again 2023-02-14 21:06:09 -08:00
Mitchell Hashimoto
be75109a1d new build system 2023-02-14 20:58:33 -08:00
Mitchell Hashimoto
4a1ff37d63 build conformance into dedicated directory 2023-02-10 08:43:32 -08:00
Mitchell Hashimoto
7d16acdf06 build: add comptime check to verify Zig version 2023-02-08 15:42:41 -08:00
Mitchell Hashimoto
f07e21c22e remove libuv from build 2023-02-04 17:37:51 -08:00
Mitchell Hashimoto
60fca27c33 vendor/libxev 2023-01-30 19:17:43 -08:00
Mitchell Hashimoto
e9bf2a5680 pkg/objc: extract to zig-objc repo 2023-01-02 21:35:32 -08:00
Mitchell Hashimoto
ce490e21ea can specify a wasm target in build 2022-12-31 08:53:11 -08:00
Mitchell Hashimoto
241bfee7d4 wasm: use shared, imported memory
This switches our wasm build to use "shared" memory. Shared memory can
be shared across multiple web workers, which is something we'll want to
support for our multi-threaded behaviors later.

Shared memory has a number of different restrictions so this updates
zig-js to support it as well as updates some of our functions that need
to be aware of it.
2022-12-24 16:24:43 -08:00
Mitchell Hashimoto
c34d911488 wasm: disable stack protector 2022-12-13 10:03:26 -08:00
Mitchell Hashimoto
2c5b5429e3 wasm: build.zig uses addDeps for wasm 2022-12-07 18:39:46 -08:00
Mitchell Hashimoto
2a74330911 font: begin making Group work with wasm 2022-12-05 16:08:20 -08:00
Mitchell Hashimoto
437f1772f1 logging works for wasm 2022-12-04 12:29:11 -08:00
Mitchell Hashimoto
940828ed97 font: web canvas creates a canvas element 2022-12-03 22:11:01 -08:00
Mitchell Hashimoto
21faf0b6fb add zig-js 2022-12-03 21:46:00 -08:00
Mitchell Hashimoto
6b101c2293 support unit testing wasm via wasmtime 2022-12-01 13:02:17 -08:00
Mitchell Hashimoto
24cc01e055 move wasm main to src/, export an Atlas API
We don't need the Atlas API for wasm at all, but its a good way to test
things work incrementally and its a pretty cool thing to have as a wasm
library really.
2022-12-01 13:02:17 -08:00
Mitchell Hashimoto
5c58067489 add pixman package 2022-11-24 10:21:27 -08:00
Mitchell Hashimoto
894d36f28a build: support for dynamic linking pixman 2022-11-24 10:21:27 -08:00
Mitchell Hashimoto
699370bd4a pkg/pixman: starting API 2022-11-24 10:21:27 -08:00
Mitchell Hashimoto
30d62fc144 workaround for x86_64 ABI issue: https://github.com/ziglang/zig/issues/13598 2022-11-19 22:07:48 -08:00
Mitchell Hashimoto
81fbc94b3c Add a benchmark exe for testing parser throughput 2022-11-13 11:29:05 -08:00
Mitchell Hashimoto
9d736985b3 Mac bundle, icons 2022-10-31 14:04:41 -07:00
Mitchell Hashimoto
c1b70cb788 metal: devmode 2022-10-31 09:44:37 -07:00
Mitchell Hashimoto
090bab6798 metal: setup the render loop, draw the background color 2022-10-31 09:44:36 -07:00
Mitchell Hashimoto
10ee05b435 pkg/objc: selectors 2022-10-25 16:33:45 -07:00
Mitchell Hashimoto
dd8fde52d9 pkg/objc starting 2022-10-25 16:21:11 -07:00
Mitchell Hashimoto
58c107dceb freetype: resize glyphs that are too tall prior to storing in texture
Most emoji fonts are massive glyphs (128x128, 256x256, etc.). This means
the texture we need to store emoji is also massive. For a 128x128 emoji
font (both Apple and Noto), we can only store 12 emoji before resizing
prior to this commit.

This commit now threads through a max height through to the font face
and resizes the bitmap in memory before putting it in the atlas. This
results in significant savings. The max height is the cell height. We
allow the glyphs to be as wide as necessary due to double (and more)
wide glyphs.

For the unicode emoji test file, the atlas size before and after:

  Before: 262 MB
  After: 16 MB
2022-10-17 19:14:30 -07:00
Mitchell Hashimoto
20f1077e86 enable freetype with imgui 2022-10-17 11:41:46 -07:00
Mitchell Hashimoto
f29393bca6 Imgui (#20)
* vendor/cimgui

* Add a "dev mode" window which for now is just imgui demo
2022-10-16 16:20:08 -07:00
Mitchell Hashimoto
699da6fcfe update mach 2022-10-13 11:03:23 -07:00
Mitchell Hashimoto
939e6e7a65 pkg/harfbuzz: add coretext compilation on macOS 2022-10-02 11:05:40 -07:00
Mitchell Hashimoto
12c9482d48 Mac Font Discovery with CoreText (#17)
This implements font discovery so the `--font-family` flag works for macOS. Fonts are looked up using the Core Text API so any installed font on the Mac system can be used. 

We still use FreeType for rendering, and CoreText doesn't _quite_ give us all the information we need to build the exact face in FreeType. So a TODO after this is to now implement glyph _rendering_ using Core Text and Core Graphics. Until then, a couple fonts don't quite work (i.e. Monaco, a big one!) but many do!
2022-10-01 22:21:30 -07:00
Mitchell Hashimoto
f9e1127317 pkg/macos: add CoreText 2022-09-30 14:48:06 -07:00
Mitchell Hashimoto
ab4491a45d pkg/macos: start core foundation bindings 2022-09-30 14:03:37 -07:00
Mitchell Hashimoto
68786814f8 -Dtest-exe flag to build and install test executables
This will be used to copy tests to other platforms.
2022-09-30 13:05:23 -07:00
Mitchell Hashimoto
141182aa13 start adding fontconfig conditional compilation 2022-09-23 14:12:38 -07:00
Mitchell Hashimoto
72105fc6cd update to the latest stage2 compiler we can 2022-09-23 12:08:06 -07:00
Mitchell Hashimoto
77851b30a2 Revert "update to latest Zig nightly"
This reverts commit f3f2c3df268db905b6af6588e5e5008da0f48b60.
2022-09-14 19:39:10 -07:00
Mitchell Hashimoto
f3f2c3df26 update to latest Zig nightly 2022-09-14 19:34:19 -07:00