Skip to content

cosmic-config: refactor cosmic config, add ghaf dark and light themes#1513

Merged
brianmcgillion merged 1 commit intotiiuae:mainfrom
kajusnau:cosmic-refactor
Nov 1, 2025
Merged

cosmic-config: refactor cosmic config, add ghaf dark and light themes#1513
brianmcgillion merged 1 commit intotiiuae:mainfrom
kajusnau:cosmic-refactor

Conversation

@kajusnau
Copy link
Copy Markdown
Collaborator

@kajusnau kajusnau commented Oct 29, 2025

Description of Changes

  1. Refactored config implementation to instead use .ron theme files

  2. Added ghaf themes to initial setup

  3. Removed default cosmic themes from initial setup via a patch

  4. Set ghaf default wallpaper both in login screen and desktop

    • Cosmic "Nebula" wallpaper should now not show up anywhere
  5. Updated default keybindings to follow upstream and industry standard

    • New keybindings can be found at line 160 in modules/desktop/graphics/cosmic/config/cosmic-config.yaml
  6. Removed default xkb_config as it can be set via initial setup

  7. Refactored ghaf cosmic nix config:

    • Added idleManagement option config to allow setting a custom timeout
    • Removed redundant autostart commands, added extraAutostart option
    • Cleanup

Notes

Ghaf Dark and Ghaf Light are not by any means the "final" variants of our theme/color palette.
Ideally it would be nice to have a UI/UX designer whip up a color palette for us to use, taking into account the feedback we've received so far from the testing teams.

Type of Change

  • New Feature
  • Bug Fix
  • Improvement / Refactor

Related Issues / Tickets

ghafpkgs input should be updated to include tiiuae/ghafpkgs#129

Should wait for #1510, if possible, so I could rebase the new patches here.

Checklist

  • Clear summary in PR description
  • Detailed and meaningful commit message(s)
  • Commits are logically organized and squashed if appropriate
  • Contribution guidelines followed
  • Ghaf documentation updated with the commit - https://tiiuae.github.io/ghaf/
  • Author has run make-checks and it passes
  • All automatic GitHub Action checks pass - see actions
  • Author has added reviewers and removed PR draft status

Testing Instructions

Applicable Targets

  • Orin AGX aarch64
  • Orin NX aarch64
  • Lenovo X1 x86_64
  • Dell Latitude x86_64
  • System 76 x86_64

Installation Method

  • Requires full re-installation Not absolutely necessary, but easier
  • Can be updated with nixos-rebuild ... switch Remove ~/.config before testing
  • Other:

Test Steps To Verify:

Before building, update ghafpkgs input manually: nix flake update ghafpkgs

  1. Boot into Ghaf
  2. Verify login screen background image is set to this one
  3. Login and wait for Initial Setup dialog to open
  4. Proceed to "Personalize Appearance" page and verify only two themes are available - Ghaf Dark and Ghaf Light
  5. Select either one and confirm the changes take effect (the new Ghaf Dark theme is slightly different than previous, but should mostly look the same)
  6. Exit Initial Setup and confirm changes done persist
  7. Verify all expected keyboard shortcuts still function as they should
  8. Verify FI and ARA keyboard layouts ("Input Sources") are not present, only US is enabled by default.

@kajusnau kajusnau changed the title refactor: simplify cosmic config, add sorting refactor: simplify cosmic config Oct 29, 2025
@kajusnau kajusnau changed the title refactor: simplify cosmic config cosmic-config: refactor cosmic config, add ghaf dark and light themes Oct 31, 2025
@kajusnau kajusnau marked this pull request as ready for review October 31, 2025 11:48
@kajusnau kajusnau self-assigned this Oct 31, 2025
@kajusnau kajusnau added the Needs Testing CI Team to pre-verify label Oct 31, 2025
@kajusnau

This comment was marked as resolved.

@vunnyso

This comment was marked as resolved.

@milva-unikie milva-unikie removed the Needs Testing CI Team to pre-verify label Oct 31, 2025
- refactored config implementation to instead use .ron theme files
- added ghaf themes to initial setup
- removed default cosmic themes from initial setup via a patch
- set ghaf default wallpaper both in login screen and desktop
- updated default keybindings to follow upstream and industry standard
- removed default xkb_config as it can be set via initial setup
- refactored ghaf cosmic nix config

Signed-off-by: Kajus Naujokaitis <kajus.naujokaitis@unikie.com>
@kajusnau
Copy link
Copy Markdown
Collaborator Author

Rebased on top of main ✅
Ready to test, if there are no build failures.

@brianmcgillion
Copy link
Copy Markdown
Collaborator

verified all steps work. The only issue that I see is that the color of the text on the login screen is a pastel blue. But the color on the lock screen is green. I think that we should maintain our green for consistency. But that can be fixed in a follow up patch.

@brianmcgillion brianmcgillion merged commit 907b5ec into tiiuae:main Nov 1, 2025
28 checks passed
@kajusnau
Copy link
Copy Markdown
Collaborator Author

kajusnau commented Nov 1, 2025

verified all steps work. The only issue that I see is that the color of the text on the login screen is a pastel blue. But the color on the lock screen is green. I think that we should maintain our green for consistency. But that can be fixed in a follow up patch.

The problem with this is that cosmic-greeter seems to fallback to the cosmic default theme and theme builders.
The only way to override this behavior atm is to provide the very cumbersome theme builders in /run/current-system/sw/share/cosmic/... which I explicitly removed in this PR. It accounted for around 3000 lines of code.

The initial setup (cosmic-initial-setup) instead takes the relatively simple .ron theme files, which I added here, and builds the themes in the user config dir. cosmic-greeter simply has no access to these themes before login is complete, hence the matching theme in lockscreen but not in the login screen.

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.

4 participants