mirror of
https://github.com/noctalia-dev/noctalia-shell.git
synced 2026-05-11 17:08:27 +08:00
cleanup(NScrollText): remove unused imports, gate layer on overflow
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Effects
|
||||
import QtQuick.Layouts
|
||||
import Quickshell
|
||||
import Quickshell.Wayland
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Effects
|
||||
import QtQuick.Layouts
|
||||
import Quickshell
|
||||
import qs.Commons
|
||||
|
||||
@@ -40,7 +40,7 @@ Item {
|
||||
property real scrollCycleDuration: Math.max(4000, root.text.length * 120)
|
||||
property real resettingDuration: 300
|
||||
|
||||
// Fade controls
|
||||
// Fade controls (fadeExtent: 0.0–0.5, fraction of width that fades)
|
||||
property real fadeExtent: 0.1
|
||||
property real fadeCornerRadius: 0
|
||||
property bool fadeRoundLeftCorners: true
|
||||
@@ -56,7 +56,7 @@ Item {
|
||||
implicitWidth: alwaysMaxWidth ? maxWidth : Math.min(maxWidth, contentWidth)
|
||||
implicitHeight: titleText.height
|
||||
|
||||
layer.enabled: true
|
||||
layer.enabled: contentWidth > maxWidth
|
||||
layer.effect: MultiEffect {
|
||||
maskEnabled: true
|
||||
maskThresholdMin: 0.5
|
||||
@@ -213,6 +213,6 @@ Item {
|
||||
}
|
||||
layer.enabled: true
|
||||
layer.smooth: true
|
||||
opacity: 0 // Great for debugging! Will show the white masks
|
||||
opacity: 0
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user