mirror of
https://git.outfoxxed.me/quickshell/quickshell.git
synced 2026-04-10 06:11:54 +10:00
Compare commits
No commits in common. "dacfa9de829ac7cb173825f593236bf2c21f637e" and "395a1301a83e98dafc325289630ccacda5d69607" have entirely different histories.
dacfa9de82
...
395a1301a8
1 changed files with 9 additions and 16 deletions
|
|
@ -26,7 +26,7 @@ Item {
|
||||||
/// Defaults to true if any corner has a non-zero radius, otherwise false.
|
/// Defaults to true if any corner has a non-zero radius, otherwise false.
|
||||||
property /*bool*/alias antialiasing: rectangle.antialiasing
|
property /*bool*/alias antialiasing: rectangle.antialiasing
|
||||||
/// The background color of the rectangle, which goes under its content.
|
/// The background color of the rectangle, which goes under its content.
|
||||||
property /*color*/alias color: shader.backgroundColor
|
property color color: "white"
|
||||||
/// See @@QtQuick.Rectangle.border.
|
/// See @@QtQuick.Rectangle.border.
|
||||||
property clippingRectangleBorder border
|
property clippingRectangleBorder border
|
||||||
/// Radius of all corners. Defaults to 0.
|
/// Radius of all corners. Defaults to 0.
|
||||||
|
|
@ -72,21 +72,14 @@ Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: root.contentInsideBorder ? root.border.width : 0
|
anchors.margins: root.contentInsideBorder ? root.border.width : 0
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
ShaderEffectSource {
|
layer.enabled: true
|
||||||
id: shaderSource
|
layer.samplerName: "content"
|
||||||
hideSource: true
|
layer.effect: ShaderEffect {
|
||||||
sourceItem: contentItemContainer
|
|
||||||
}
|
|
||||||
|
|
||||||
ShaderEffect {
|
|
||||||
id: shader
|
|
||||||
anchors.fill: root
|
|
||||||
fragmentShader: `qrc:/Quickshell/Widgets/shaders/cliprect${root.contentUnderBorder ? "-ub" : ""}.frag.qsb`
|
fragmentShader: `qrc:/Quickshell/Widgets/shaders/cliprect${root.contentUnderBorder ? "-ub" : ""}.frag.qsb`
|
||||||
property Rectangle rect: rectangle
|
property Rectangle rect: rectangle
|
||||||
property color backgroundColor: "white"
|
property color backgroundColor: root.color
|
||||||
property color borderColor: root.border.color
|
property color borderColor: root.border.color
|
||||||
property ShaderEffectSource content: shaderSource
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue