Fix dark url navigator band in Dolphin with DisableDolphinUrlNavigatorBackground - #346
Open
limonzhik wants to merge 1 commit into
Open
Fix dark url navigator band in Dolphin with DisableDolphinUrlNavigatorBackground#346limonzhik wants to merge 1 commit into
limonzhik wants to merge 1 commit into
Conversation
…rBackground With KIO 6, KUrlNavigator paints its PE_FrameLineEdit background itself in breadcrumb mode. The style set the fill fully transparent but renderLineEdit still drew its box shadow and outline, so they showed as a dark band and halo over the toolbar. When the toolbar is opaque, fill the bar with the window color and skip renderLineEdit entirely.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When "Disable Dolphin URL navigator background" is on and the toolbar is opaque, the location bar in Dolphin is drawn as a dark band with a darker outline around it instead of blending into the toolbar.
With KIO 6, KUrlNavigator always keeps its KUrlComboBox child (hidden in breadcrumb mode) and paints its PE_FrameLineEdit background itself in KUrlNavigator::paintEvent. drawFrameLineEditPrimitive then sets the background fully transparent (setAlphaF(0)), but renderLineEdit still draws its box shadow and outline, and with no opaque fill on top they stay visible over the toolbar. Measured on Plasma 6.7 / KIO 6.28 / Dolphin 26.04: toolbar #1F1F1F, the bar flat #1A1A1A, which is exactly the toolbar color darkened by the alpha 40 box shadow.
Fix: when the option is on and the toolbar is opaque, fill the bar with the window color and skip renderLineEdit. The translucent toolbar path (toolBarOpacity < 100) is left unchanged. Editable location mode is unaffected, KUrlNavigator does not paint PE_FrameLineEdit there.
Tested on Darkly master, Plasma 6.7 Wayland, KIO 6.28, Dolphin 26.04. After the patch the bar is pixel identical to the toolbar, no halo around it.