Repository navigation
fix(glass): global mode survives disabling stock Blur, tooltip corners, popup pop-in - #24
Merged
Merged
Conversation
…popup slides Corner radius: estimate each corner by fitting a circle to the blur region's edge profile instead of inverting the area missing from the bounding box. Seams and notches no longer inflate the radius (a 5-6 px Breeze tooltip came out as ~16 px), square corners of popups docked to a panel are left out instead of halving the radius, and gaps under 1 px no longer split a surface in two. Tests now rasterise masks the way KSvg::FrameSvg::mask() does. Popup pop-in: Sliding Popups forces WindowForceBlurRole and WindowForceBackgroundContrastRole for the whole slide, which makes stock Blur/Contrast paint over the glass until the slide ends. Hide both roles for the downstream draw of windows we rendered and restore them afterwards. Also: the effect's "state" debug dump shows per-corner estimates and KWin's border radius, and the KCM, README and dock settings explain when KDE's built-in Blur effect can be turned off (dock notice only with global mode on). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- .clang-tidy: disable cppcoreguidelines-pro-bounds-avoid-unchecked-container-access (121 hits, one per operator[]; .at() would add bounds checks to the per-frame physics and layout paths) and exclude generated headers under build/. - Fix the rest by hand: ranges algorithms and QList::removeIf, designated initializers, std::array, Q_DISABLE_COPY_MOVE on QObject classes, member initializers, [[nodiscard]], widening casts, a duplicated switch branch. - Annotate with NOLINT and a reason where Qt/KWin APIs leave no alternative (ItemChangeData union, int paint masks, EGL proc address, const debug()). - battery: skip qmldir entries for Style.js/Presets.js. They are imported by path, and Qt only looks for '.pragma library' in the first 128 bytes, which the SPDX header fills. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
KWin 6.8 tells Wayland clients whether blur is available through one shared flag of ext_background_effect_v1, not a count of providers. Fluctus Glass and stock Blur both set it, and Blur clears it in its destructor even while global mode still serves blur. Plasma then switched to opaque surfaces and stopped sending blur regions: global glass went dark, and the dock's glass fell back to D-Bus geometry updates, which made it snap instead of animate. Track the stock Blur effect (found at load, on window add, on reconfigure and on kwinrc [Plugins] changes) and set the flag again as soon as it is destroyed. KWin delays the removal by 100 ms, so clients never see blur go away. A re-assert shortly after any Desktop Effects change is the safety net. Also print the "log out and back in" reminder after updating the effect in bold on a terminal: KWin keeps running the effect code it loaded at login. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Fixes three Fluctus Glass global-mode bugs on Plasma 6.8 / KWin 6.8.3 and clears every lint, compiler and CMake warning. All verified live by the reporter.
Disabling KDE's Blur effect turned off Liquid Glass
ext_background_effect_v1), not a count of effects providing it. Fluctus Glass and stock Blur both switch it on. When Blur unloads, its destructor switches the flag off, even though Glass still provides blur. Plasma then:glass/src/glasseffect.cpp): Glass keeps a pointer to the Blur effect and turns the flag back on the moment Blur is destroyed. KWin waits 100 ms before telling apps the flag went off, so they never see blur disappear. Glass finds Blur whether it loads before or after Glass, including when you toggle it in Desktop Effects. About a quarter-second after any Desktop Effects change it turns the flag on again as a safety net.Tooltip corners didn't match the glass
A 5–6 px Breeze tooltip got glass with a ~16 px radius, leaving the dark tooltip corners poking out. The radius came from the area missing from the bounding box, which seams and the stepped Breeze mask inflate. Each corner is now fitted from the mask's edge profile:
Checked against the real KSvg mask: 7.51 px, matching the live session. Tests now draw masks the way
KSvg::FrameSvg::mask()does.Start menu glass popped in after the slide
Sliding Popups forces
WindowForceBlurRoleandWindowForceBackgroundContrastRolefor the whole slide, so stock Blur and Contrast painted over the glass until it ended. Glass hides both roles while the rest of the chain draws windows it rendered, then restores the exact values.Also
statedebug dump shows per-corner estimates and KWin's border radius.just update/just glass updateend with a bold yellow "log out and back in" reminder, because KWin keeps running the effect code it loaded at login..clang-tidyturns offavoid-unchecked-container-access, which flagged everyoperator[](121 hits), and excludes generated headers underbuild/.NOLINTwith a reason only where Qt or KWin APIs leave no alternative..jsfiles skip their qmldir entry: Qt only looks for.pragma libraryin the first 128 bytes, which the SPDX header fills.Testing
just test,just test-sanandjust lintare clean, plus a clean rebuild with no compiler warnings.Not covered
🤖 Generated with Claude Code