Merge pull request #6943 from dotCooCoo/feat/color-rgb-percent

Color: a double-click right of an RGB field switches between percent and 0 to 255
This commit is contained in:
BFlat
2026-11-13 08:31:01 +07:00
committed by GitHub
36 changed files with 362 additions and 24 deletions
+4 -1
View File
@@ -593,7 +593,10 @@ space. RGB edits preserve the other native channels; HSB uses those same working
display sRGB retain their native numeric values. `ui.colorPanel` selects the panel mode and `ui.colorPicker`
opens the picker through `run_command` with the remote backend. `ui.colorPanel {"recentColors": false}` unchecks
the panel menu's Show Recent Colors, which hides the Color panel's Recent Colors row, and `true` shows it again;
applied colors still join the list while it is hidden.
applied colors still join the list while it is hidden. `ui.colorPanel {"rgbPercent": true}` shows the Color panel's
RGB fields in percent, as a double-click right of an RGB field does, and `false` shows them from 0 to 255 again.
`ui.colorRgbPercent` (Toggle RGB Percent in the command palette and Keyboard Shortcuts) switches between the two
and answers true when the fields show in percent.
In remote desktop mode, `invoke_menu` with `{"command":"ui.sampleScreenColor","params":{}}` shows the system's
screen color sampler and returns `null` before a color is picked: the system's sampler on macOS, the XDG desktop