Skip to content

Conversation

ChiahongHong
Copy link
Contributor

@ChiahongHong ChiahongHong commented Sep 1, 2024

This pull request updates the colors of the macOS window control buttons (Close, Minimize, Maximize) in SourceGit to better match the native appearance.

Color Source

The colors were obtained by unpacking /System/Library/CoreServices/SystemAppearance.bundle/Contents/Resources/Aqua.car and DarkAqua.car using ThemeEngine. The colors were then measured using Digital Color Meter. Due to the pixelated nature of the images, there may be slight inaccuracies.

Aqua.car

Note: The button border remains set to <Setter Property="Stroke" Value="#40000000"/> due to the difficulty in measuring the border color, which is very small, and I'm not sure starting from which version of macOS the maximize button's direction was rotated 90 degrees, so I didn't change it.

Pressed Effect

The original buttons did not include a pressed state. I have now implemented this effect to enhance the user experience, as shown in this GIF.

Pressed Effect

@ChiahongHong ChiahongHong marked this pull request as draft September 1, 2024 05:15
@ChiahongHong ChiahongHong marked this pull request as ready for review September 1, 2024 05:51
@love-linger love-linger self-assigned this Sep 1, 2024
@love-linger love-linger added the enhancement New feature or request label Sep 1, 2024
@love-linger love-linger merged commit e3ee07b into sourcegit-scm:develop Sep 1, 2024
13 checks passed
love-linger added a commit that referenced this pull request Sep 1, 2024
* move resources and styles for macOS caption button to `CaptionButtonsMacOS` because it is never used by others and should not been changed
* add `IsCloseButtonOnly` property to `CaptionButtons` and `CaptionButtonsMacOS` and replace the controls in windows
@ChiahongHong ChiahongHong deleted the macos-buttons branch September 1, 2024 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants