Commit graph

76 commits

Author SHA1 Message Date
Keavon Chambers
fb0fab0622 Update links from graphite.rs to graphite.art
Some checks failed
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
Library: Rawkit / build (push) Has been cancelled
Website / build (push) Has been cancelled
2025-12-06 18:10:27 -08:00
Timon
a5cf62a90b
Desktop: Custom cursor support (#3452)
custom cursors with caching
2025-12-06 16:16:14 -08:00
Timon
2e4481880e
Desktop: Fix missing resize events causing all-gray window on Mac after launch (#3445)
* okayish solution

should be improved at some point but for now it works well enough.

* do leftover renames

* better solution

* less weird resize frames

* move surface reconfiguration

* fix recent desktop mac breakages

* better looking resize on mac

* fix background color

* Fix blank screen on window initialization

* cleanup

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-12-06 23:11:47 +00:00
Timon
39b5229df7
Desktop: Limit application to a single instance (#3441)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* only allow single instance

* more reliable CEF cache cleanup

* some cleanup

* fix lock file location

* add simple signal handling

* fix skew handles on desktop

* mac remove unused helpers
2025-12-03 19:13:15 +01:00
Keavon Chambers
600fb5c28f
Refactor the old menu bar plumbing to use standard TextButtons (#3444)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* Refactor the old menu bar plumbing to use standard TextButtons

* WIP: Fix Mac native menu bar

* WIP: fix desktop menu bar mac

* Refactor menu bar definitions to use the builder pattern

* WIP: fixup desktop

* cleanup

* fix linux

* Remove dead code that was failing to lint

---------

Co-authored-by: Timon Schelling <me@timon.zip>
2025-12-03 12:41:54 +00:00
Timon
3fd0460d03
Desktop: Update CEF to 142 (#3431)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* update CEF to 142

* fix win

* fixup

* post merge fix

* use getter instead
2025-11-30 23:23:31 +00:00
Timon
94e5c8fc05
Desktop: Prevent CEF context menu to fix crashing by right-clicking a text field (#3429)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* add dummy context menu handler to prevent some crashes

* some cleanup

correcting cef handler impl names
using std::ffi::c_int
2025-11-29 00:08:43 +00:00
Timon
bb4516e377
Desktop: Add app menu for Mac (#3428)
* add mac app menu

* review fixup

* Remove "About Graphite" ellipsis, add "Show All", make it say "Quit Graphite"

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-11-28 23:42:14 +00:00
Timon
f4608a6e40
Desktop: Resize issue mitigation, scroll speed adjustment and duplicate pointer move event filtering (#3424)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* mitigate resizing issue on mac and windows

* adjust scroll speed for mac and win

* fixup

* filter out duplicate mouse move events
2025-11-27 16:18:52 +00:00
Timon
5ff399d3f2
Desktop: Display taskbar icon on Windows (#3376)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* task bar icon

* limit cef render processes to 1

* disable more chrome features
2025-11-25 14:16:59 +00:00
Timon
3f532e478c
Separate branded assets from monorepo (#3406)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* remove branded files

* use branding repo

* include favicons

* nixpkg fixup

* win fix ico path

* fix fmt

* skip licensenses for dev builds

* review fixup

* test

* test

* ci test

* ci test

* ci test

* fix ci
2025-11-25 02:42:27 +00:00
Dennis Kobert
a932eaedcf
Render artwork at correct resolution when using vello on wasm (#3416)
Some checks are pending
Editor: Dev & CI / cargo-deny (push) Waiting to run
Editor: Dev & CI / build (push) Waiting to run
* Work on fixing rendering for wasm+vello

* Render vello canvas in wasm at the correct resolution

* Cleanup unused surface rendering code

* Remove vector to raster conversion

* Remove desktop changes

* Revert window.rs changes

* Don't round logical coordinates

* Fix desktop compilation + don't round logical coordinates for svg rendering

* Further cleanup

* Compute logical size from acutal physical sizes
2025-11-24 14:23:27 +00:00
Timon
548e0df1a1
Desktop: Mac menu workaround (#3398)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
2025-11-19 17:13:35 +00:00
Timon
e751979e5c
Desktop: Mac fix keyboard input (#3371)
* add browser debug port env

* mac use option as alt

* fix cef texture double sRGB conversion by using cef-rs fork with fix

* fix keyboard input on mac

* add missing frontend messages

* fixup

* fix keyboard input mac

* dbg

* re implement keyboard mapping

Co-authored-by: csmoe <csmoe@msn.com>

* Fix double arrow keys

* try fix for non mac

* test

* Revert "test"

This reverts commit c7cde9c597.

* fix mac

* some cleanup

* fix zoom in shortcut on mac introduced in #3377

* disable menu shortcut display

* fixup
2025-11-17 11:51:59 +00:00
Timon
9be207f4c5
Desktop: Update CEF to 141 (#3352)
update cef to 141
2025-11-08 11:59:02 +00:00
Timon
f02f834097
Desktop: Add support for UI scaling (#3310)
* desktop support ui scaling

* fix some warnings

* use browser zoom if needed

* fix infinite footprint size

* fix web canvas scale

* always set zoom

* use only zoom for scaling

* prevent user zoom

* remove mouse position scaling
2025-11-08 12:32:04 +01:00
Timon
0d76ffd66d
Desktop: Mac remove menubar flicker (#3335)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* remove unnecessary folders from bundling for mac

* mac remove menu bar flicker

* clean up implementation
2025-11-04 09:26:08 +00:00
Timon
5be9b1fabc
Desktop: Mac native menu bar (#3301)
* macos native menu bar

* fix nix build

* Add shortcut symbols to menu

* fix fmt

* fix vendoring

* cleanup intercept frontend message

* accept into editor message in queue function
2025-10-27 14:11:24 +00:00
Timon
52e98ea8a3
Desktop: Remove winit fork, fix nix package, and improve rendering (#3307)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* reduce triangle count

* switch to winit repo after changes where upstreamed

* fix nix pkg
2025-10-25 00:47:36 +00:00
Timon
c4f6a2c9c1
Desktop: Add window abstraction layer (#3302)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* add bundle for mac os and windows

* Fix bundle name

This name gets used as the display name of the app on mac os, shorter name looks better and is more consistent.

* preserve std out by running bin directly

* bundle placeholder on linux

* fix linux

* window abstraction

* fix linux

* fix windows

* fix fmt

* remove windows file that was left

* use self
2025-10-23 11:33:32 +00:00
Timon
7fbe440e73
Desktop: Bundle for Mac and Windows (#3297)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* add bundle for mac os and windows

* Fix bundle name

This name gets used as the display name of the app on mac os, shorter name looks better and is more consistent.

* preserve std out by running bin directly

* bundle placeholder on linux

* fix linux
2025-10-23 10:39:08 +00:00
Timon
39f4ccf8e0
Desktop: Fixup MacOS build (#3295)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
desktop mac os fixup

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2025-10-20 13:31:36 +00:00
Timon
3509f0b035
Desktop: Persist document path (#3272)
* persist document path

* persist data cleanup
2025-10-15 10:30:47 +00:00
Timon
717defb2bb
Desktop: Trackpad pinch to zoom (#3271)
Some checks are pending
Editor: Dev & CI / cargo-deny (push) Waiting to run
Editor: Dev & CI / build (push) Waiting to run
* prototype pinch gesture

* pinch to zoom

* fix
2025-10-14 22:27:27 +00:00
Mateo
497758c273
Desktop: Add simple cli interface (#3059)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* Open document from cli and add some files to .gitignore

* Revert .gitignore

* Revert .gitignore

* Implement cli properly

* Add ui-accelerated-painting option

* Format code

* Revert changes in .vscode folder

* Don't use global variables for cli

* Apply suggested changes

* Make ready for merge

* Improve names

* remove comment

---------

Co-authored-by: Timon <me@timon.zip>
2025-10-13 21:09:40 +00:00
Timon
e366e4d64e
Desktop: Update CEF to v140 (#3277)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* update cef to v140

* fix build

* update flake
2025-10-13 04:56:56 +00:00
Timon
48ac24da14
Desktop: Fix frontend message response dispatch (#3247)
* One annoying debugging session later

Discovered that the editor handles frontend messages differently from other messages.
It requires all frontend messages to be fully processed before dispatching any resulting messages.

In the web frontend, this behavior happened implicitly because message dispatch is queued at the current end of the JavaScript execution queue.
For the desktop frontend, I added a vector to collect all responses until the entire batch of frontend messages is handled, and then dispatch them afterwards.

* Fix double click travel
2025-10-06 20:04:24 +00:00
Timon
4bb1d05fc3
Desktop: Add taskbar icon on Windows (#3225)
* include icon as resource on windows

* load icon
2025-09-26 14:30:01 +02:00
Timon
d06c8164e1
Desktop: Forward multi-clicks (double/triple/etc.-clicks) to CEF correctly (#3224)
* fix multiclick

* Revert "fix multiclick"

This reverts commit c4130d12ee.

* try another way

* use copy

* Use struct initializer syntax fror click tracker (#3226)

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2025-09-26 14:29:56 +02:00
Timon
ed22e6a63d
Desktop: Add rudimentary support for custom WGPU adapter selection (#3201)
* rudimentary custom wgpu adapter selection

* WgpuContextBuilder

* wasm fix

* fix wasm warnings

* Clean up

* Review suggestions

* fix
2025-09-25 14:38:26 +00:00
Timon
d595089bb0
Desktop: Fix maximized window extending outside the screen on Windows (#3210)
Desktop: Fix window extending outside the screen on windows when maximized
2025-09-25 15:22:05 +02:00
Timon
04a2452333
Desktop: Support cursor icon change (#3223)
* browser console message forwarding

* replace target to make it easy to identify browser console messages

* use warn as per review comment

* cursor icon change

* fix win build
2025-09-25 11:23:19 +00:00
Timon
b4be616de0
Desktop: Browser console message forwarding (#3193)
* browser console message forwarding

* replace target to make it easy to identify browser console messages

* use warn as per review comment
2025-09-25 10:42:07 +00:00
Timon
d15f63f4fd
Ensure the LoadPreferences message is dispatched with None when no preferences exist (#3198)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* preference load message on default load

* review fixup
2025-09-23 20:19:16 +00:00
Timon
21f34ab19a
Desktop: Enable window resize controls on Wayland compositors (#3183)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
wayland client side decorations
2025-09-21 12:17:05 +00:00
Timon
09bc891ab2
Desktop: Forward the pointer leave event to CEF (#3197)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* pointer leave

* make one-liner
2025-09-21 10:23:51 +00:00
Timon
46d5928724
Desktop: Fix window maximize and minimize (#3200)
Some checks are pending
Editor: Dev & CI / cargo-deny (push) Waiting to run
Editor: Dev & CI / build (push) Waiting to run
Fix window maximize and minimize state
2025-09-20 23:48:47 +00:00
Timon
3fe7c477e9
Desktop: Switch to the latest unreleased version of Winit (#3177)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* Use unstable winit

* Improve

* Remove unnecessary heap indirection
2025-09-17 16:40:43 +02:00
Timon
ab55b3225d
Desktop: Window resize handling on Windows (#3167)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* Native window resize on windows

* Fix linux build

* Fix windows build

* try clean up

* clean up

* Add module comment

* FIx

* Review improvements

* Improve
2025-09-15 12:15:31 +00:00
Timon
da330b6dd0
Desktop: Run CEF in incognito mode and delete root cache path on exit (#3137)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
* Try

* Run cef in non persistence mode
2025-09-13 22:19:45 +00:00
Timon
944a6eeea2
Desktop: Hook up native window controls (#3161)
* Implement window controls

* Fix drag target size

* Maximize with drag area double click
2025-09-13 20:15:52 +00:00
Timon
e97d5520e8
Desktop: Support receiving double click inputs (#3168)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* input support double clicks and clean up

* Review improvements
2025-09-13 12:40:31 +00:00
Timon
c51967384f
Desktop: Fix keyboard shortcuts on windows (#3139)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* Try to fix shortcuts on windows

* Fix
2025-09-10 10:51:15 +00:00
Timon
50be13522b
Desktop: Move preferences persistence to native (#3138)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* Move preference persistence to native

* Pass preferences as struct instead of serialized to string
2025-09-09 16:22:25 +00:00
Timon
4261b7dad1
Desktop: Move autosave persistence to native (#3134)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* Move autosave persistence to native 1

* Move autosave persistence to native 2

* Reimplement quirky behavior of the web frontend

* Code revew

* Use select_after_open

* fix fmt

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-09-09 11:27:54 +00:00
Dennis Kobert
acd7ba38cc
Graphene: Fine-grained context caching (#2500)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
* RFC: Fine Grained Context Caching

* Fix typos

* Fix label

* Add description of inject traits

* Explicitly support context modification

* Start implementation of context invalidation

* Add inject trait variants
* Route Extract / Inject traits to the proto nodes

* Implement context dependency analysis

* Implement context modification node insertion

* Fix erronous force graph run message

* Fix Extract* Inject* annotations in the nodes

* Require Hash implementation for VarArgs

* Fix nullification node insertion

* Cross of done items unresolved questions section

* Update Cargo.lock

* Fix context features propagation

* Update demo artwork

* Remove BondlessFootprint and FreezeRealTime nodes

* Fix migration

* Add migrations for adding context features to old networks

* Always update real time regardless of animation state

* Cargo fmt

* Fix tests

* Readd sed command to hopefully fix profile result parsing

* Add debug output to profiling pr

* Use new totals instead of summaries for for iai results

* Even more debugging

* Use correct debug metrics (hopefully)

* Add more MemoNode implementations

* Add context features annotation to shader node macro

* Cleanup

* Time -> RealTime

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-09-05 11:44:26 +00:00
Timon
1d4d1026d4
Desktop: Make embedded resources optional (#3094)
* Make embedding resources optional

* Move remaining cef rc to internal module

* Move embedded resources to separate crate

* Review fixup

* Fix

* Fix read

* Add read error
2025-08-28 17:18:18 +00:00
Timon
c5991c6f61
Desktop: show platform specific window buttons (#3078)
Some checks failed
Editor: Dev & CI / build (push) Has been cancelled
Editor: Dev & CI / cargo-deny (push) Has been cancelled
Implement app window button functionality and set platform
2025-08-25 14:15:31 +00:00
Timon
508606cdba
Desktop: add missing txt file mime type mapping (#3091)
add missing txt file extension to mime type mapping

missing mapping caused license dialog that loads txt file to fail and report no network connection
2025-08-25 15:51:59 +02:00
Timon
c6ec3a27ca
Desktop: Buffer web messages until connection is initialized (#3082)
Some checks are pending
Editor: Dev & CI / build (push) Waiting to run
Editor: Dev & CI / cargo-deny (push) Waiting to run
Buffer web messages until connection is initialized
2025-08-22 15:15:17 +00:00