Skip to content

Append noctalia.css import to the end of gtk-4.0/gtk.css instead of overwriting it#1784

Open
finsofblueimnotyou wants to merge 1 commit intonoctalia-dev:mainfrom
finsofblueimnotyou:no-gtk-overwrite
Open

Append noctalia.css import to the end of gtk-4.0/gtk.css instead of overwriting it#1784
finsofblueimnotyou wants to merge 1 commit intonoctalia-dev:mainfrom
finsofblueimnotyou:no-gtk-overwrite

Conversation

@finsofblueimnotyou
Copy link

Pull Request

Motivation

As it currently stands, the GTK color scheme template overwrites the contents of ~/.config/gtk-4.0/gtk.css with @import url("noctalia.css");. This has the adverse effect of wiping any user-made modifications to the file.

This request addresses the issue by having the noctalia.css import appended to the end of gtk.css, rather than overwriting it. This new behavior is similar to that of the niri template. If the import is already present, nothing is written, and if the file doesn't exist, it is made with the import as per the previous functionality.

Type of Change

Mark the relevant option with an "x".

  • Bug fix
  • New feature
  • Breaking change
  • Refactoring

Related Issue

  • None found.

Testing

Tested with the following permutations:

  • gtk.css not present.

    • Result: File created with import.
  • gtk.css present with no content.

    • Result: Import appended onto file.
  • gtk.css present with user-made modifications.

    • Result: Import appended onto file.
  • gtk.css present with noctalia.css import.

    • Result: Nothing written.
  • gtk.css present with user-made modifications and noctalia.css import.

    • Result: Nothing written.
  • Tested on niri

  • Tested on Hyprland

  • Tested on sway

  • Tested with different bar positions and density settings

  • Tested at different interface scaling values

  • Tested with multiple monitors (if applicable)

Screenshots / Videos

N/A

Checklist

  • Code follows project style guidelines
  • Self-reviewed my code
  • No new warnings or errors
  • Documentation or comments updated (if relevant)

Additional Notes

This is my first pull request, please let me know if I did anything wrong!

@turannul
Copy link
Contributor

turannul commented Feb 12, 2026

I think you forgotten apply_gtk3

@Ly-sec
Copy link
Collaborator

Ly-sec commented Feb 28, 2026

Heyo @finsofblueimnotyou , we split gtk into gtk3 & gtk4 not too long ago, if you'd like to manage that, I'd be all for merging it.

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.

3 participants