Skip to content

feat(desktop): tapping the background's row opens the colour panel on its colour, as Procreate - #97

Open
zednaked wants to merge 1 commit into
artcraft-android:mainfrom
zednaked:feat/background-tap
Open

zednaked wants to merge 1 commit into
artcraft-android:mainfrom
zednaked:feat/background-tap

Conversation

@zednaked

@zednaked zednaked commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

What

On the desktop, tapping the Layers panel's Background color row (anywhere but its visibility box) opens the colour panel on the background's colour. What is picked there goes to the background live, as Procreate does and as Android already does (pickBackground). The change is one undo step when the panel closes, and the brush's colour is given back then.

How

  • layers.rs: background_row returns true when the row is tapped off its visibility box, which sets Layers::pick_background.
  • ui.rs: start_background_pick keeps the brush's colour, puts the background's into the panel and opens it. follow_background_pick sends changes with set_background_color(.., false) while the panel is open, and on close commits with done = true and restores the brush colour.

Checked

cargo check -p procraft-desktop passes. Used on Linux: the background follows the panel live, the brush colour comes back after closing, and one undo restores the old background.

🤖 Generated with Claude Code

… its colour, as Procreate

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant