Bug 497054 - TextColor does not reliably propagate after opacity and visible animation
Summary: TextColor does not reliably propagate after opacity and visible animation
Status: CONFIRMED
Alias: None
Product: frameworks-kirigami
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: Not decided
Assignee: kdelibs bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-04 21:03 UTC by Kai Uwe Broulik
Modified: 2024-12-15 08:24 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kai Uwe Broulik 2024-12-04 21:03:19 UTC
SUMMARY
I have found this very peculiar setup that leads to the lock screen password field not having a visible reveal password button. The button is there but its color is wrong (white on white) until something (e.g. it being disabled after typing a wrong password) causes it to update

STEPS TO REPRODUCE
1. Lock the screen with Breeze light

OBSERVED RESULT
No “reveal password” button

EXPECTED RESULT
There is a “reveal password” button

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: git master as of 2024-12-04
Qt Version: 6.8.0

ADDITIONAL INFORMATION
I managed to reproduce the situation the lock screen does using the following QML snippet:
run it using the “qml” tool, observe how the reveal password button is invisible. I have no idea where this goes wrong.
The Repeater {} in the ActionTextfield also has something to do with it (parent change not being noticed by the theme inheritance mechanism?). I found that Kirigami.Theme.textColor is actually wrong inside the icon. So it’s not the icon, it’s the color propagation. I have no idea what’s going on …

import QtQuick
import org.kde.kirigami as Kirigami
import org.kde.plasma.extras as PlasmaExtras

Item {
    Kirigami.Theme.inherit: false
    Kirigami.Theme.colorSet: Kirigami.Theme.Complementary

    PropertyAnimation {
        target: pw
        property: "opacity"
        from: 0
        to: 1
        duration: 1
        running: true
    }

    PlasmaExtras.PasswordField {
        id: pw
        visible: opacity > 0
    }
}
Comment 1 John Kizer 2024-12-15 08:24:42 UTC
I can reproduce this on Fedora KDE 41.