Skip to content

Add option to preserve panel/dock style on window maximize#601

Open
graham-walker wants to merge 1 commit into
pop-os:masterfrom
graham-walker:keep-style-on-maximize
Open

Add option to preserve panel/dock style on window maximize#601
graham-walker wants to merge 1 commit into
pop-os:masterfrom
graham-walker:keep-style-on-maximize

Conversation

@graham-walker
Copy link
Copy Markdown

This PR fixes the issue in #538 where when the panel/dock is set to be partially transparent, when a window is maximized the panel/dock would flash opaque briefly before popping back to transparent.

In addition to addressing some users stylistic preferences, enabling this option also results in a significant speedup for me maximizing windows when running Pop!_OS in a virtual machine.

Resolves #519


  • I have disclosed use of any AI generated code in my commit messages.
    • If you are using an LLM, and do not fully understand the changes it is making to the code base, do not create a PR.
    • In our experience, AI generated code often results in overly complex code that lacks enough context for a proper fix or feature inclusion. This results in considerably longer code reviews. Due to this, AI authored or partially authored PRs may be closed without comment.
  • I understand these changes in full and will be able to respond to review comments.
  • My change is accurately described in the commit message.
  • My contribution is tested and working as described.
  • I have read the Developer Certificate of Origin and certify my contribution under its conditions.

@jacobgkau jacobgkau requested review from a team May 12, 2026 23:11
@wash2
Copy link
Copy Markdown
Collaborator

wash2 commented May 13, 2026

The panel expands and becomes opaque on window maximization so that cosmic-comp can skip rendering of the lower layers. I'm not really sure that we want to support this option.

@graham-walker
Copy link
Copy Markdown
Author

I prefer the transparent/floating style, but find the changing panel/dock on maximize very distracting. Personally I'd be willing to forgo any savings from cosmic-comp just for that. If the panel/dock styles can't be preserved on maximize, why allow users to customize them in the first place.

Adding recordings of my VM demonstrating the performance improvements I see when keep style on maximize is enabled. It makes the experience using Pop!_OS in a VM much smoother.

default.behavior.webm
keep_style_on_maximize.enabled.webm

@graham-walker
Copy link
Copy Markdown
Author

@wash2 As I understand it cosmic-comp skips rendering the layer below if it is obscured by a fully opaque surface. I don't see any special path for rendering maximized windows, afaik they are handled the same way as floating windows. If keep_style_on_maximize is enabled and a window is maximized the only layers that now aren't being skipped are the background wallpaper layer, plus any floating windows a user has dragged under the panel/dock (rare). I think since the user already accepts the minor performance hit from their configured panel/dock style when windows aren't maximized, that adding this option does not represent significant overhead. If there still is some concern then I think this setting could live under power options.

@wash2
Copy link
Copy Markdown
Collaborator

wash2 commented May 19, 2026

As I understand it cosmic-comp skips rendering the layer below if it is obscured by a fully opaque surface. I don't see any special path for rendering maximized windows, afaik they are handled the same way as floating windows.

@Drakulix could talk about this a bit more. I am a bit less familiar with the cosmic-comp implementation.

If there still is some concern then I think this setting could live under power options.

Maybe, @pop-os/ux would probably need to approve interface changes like that though. There are some other config variables already not exposed in cosmic-settings, but which allow unsupported customization. If I remember correctly, the decision to make the dock / panel expand to the edges when there is a maximized window was also a decision for UX, not just for technical reasons. This is all to say, I think it would be unlikely this config variable would be included in the settings app, but it could exist for users to make unsupported customizations.

@Milli189
Copy link
Copy Markdown

speaking as an user I also don't like that panels and docks change and become full and opaque when a window is maximized, I wish the dock and panel stayed like I set them and stayed transparent when I maximize a window, I have a beefy computer so I don't care about saving every little usage of resources.

I think it should be an option in the cosmic settings app, like "make panels expand when a window is maximized to save power - recommended for low powered laptops" and "allow panels to stay in their position and to keep transparency and blur - recommended for more powerful computers"

@Drakulix
Copy link
Copy Markdown
Member

@Drakulix could talk about this a bit more. I am a bit less familiar with the cosmic-comp implementation.

Technical it is definitely fine at this point (there were some edge-cases for fullscreen/maximized in the beginning of development), but we would loose some optimizations from not blocking the whole screen with opaque surfaces. But nothing too crazy, this is definitely fine from a technical view.

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.

[Bug] Panel/Dock edge settings ignored when a window is maximized

5 participants