merge upstream

This commit is contained in:
Greyfeather
2025-05-21 00:22:49 -06:00
parent 08b9014ee2
commit 65b5ec93c7
87 changed files with 2119 additions and 1602 deletions
@@ -128,7 +128,7 @@ Scope {
GlobalShortcut {
name: "overviewToggle"
description: "Toggles overview on press"
description: qsTr("Toggles overview on press")
onPressed: {
GlobalStates.overviewOpen = !GlobalStates.overviewOpen
@@ -136,7 +136,7 @@ Scope {
}
GlobalShortcut {
name: "overviewClose"
description: "Closes overview"
description: qsTr("Closes overview")
onPressed: {
GlobalStates.overviewOpen = false
@@ -144,7 +144,7 @@ Scope {
}
GlobalShortcut {
name: "overviewToggleRelease"
description: "Toggles overview on release"
description: qsTr("Toggles overview on release")
onPressed: {
GlobalStates.superReleaseMightTrigger = true
@@ -160,9 +160,9 @@ Scope {
}
GlobalShortcut {
name: "overviewToggleReleaseInterrupt"
description: "Interrupts possibility of overview being toggled on release. " +
"This is necessary because GlobalShortcut.onReleased in quickshell triggers whether or not you press something else while holding the key. " +
"To make sure this works consistently, use binditn = MODKEYS, catchall in an automatically triggered submap that includes everything."
description: qsTr("Interrupts possibility of overview being toggled on release. ") +
qsTr("This is necessary because GlobalShortcut.onReleased in quickshell triggers whether or not you press something else while holding the key. ") +
qsTr("To make sure this works consistently, use binditn = MODKEYS, catchall in an automatically triggered submap that includes everything.")
onPressed: {
GlobalStates.superReleaseMightTrigger = false
@@ -2,8 +2,9 @@ import "root:/"
import "root:/services/"
import "root:/modules/common"
import "root:/modules/common/widgets"
import Qt5Compat.GraphicalEffects
import "root:/modules/common/functions/color_utils.js" as ColorUtils
import QtQuick
import QtQuick.Effects
import QtQuick.Layouts
import Quickshell
import Quickshell.Io
@@ -58,6 +59,16 @@ Item {
color: Appearance.colors.colLayer0
radius: Appearance.rounding.screenRounding * root.scale + 5 * 2
layer.enabled: true
layer.effect: MultiEffect {
source: overviewBackground
anchors.fill: overviewBackground
shadowEnabled: true
shadowColor: Appearance.colors.colShadow
shadowVerticalOffset: 1
shadowBlur: 0.5
}
ColumnLayout {
id: workspaceColumnLayout
@@ -78,7 +89,7 @@ Item {
property int colIndex: index
property int workspaceValue: root.workspaceGroup * workspacesShown + rowIndex * ConfigOptions.overview.numOfCols + colIndex + 1
property color defaultWorkspaceColor: Appearance.colors.colLayer1 // TODO: reconsider this color for a cleaner look
property color hoveredWorkspaceColor: Appearance.mix(defaultWorkspaceColor, Appearance.colors.colLayer1Hover, 0.1)
property color hoveredWorkspaceColor: ColorUtils.mix(defaultWorkspaceColor, Appearance.colors.colLayer1Hover, 0.1)
property color hoveredBorderColor: Appearance.colors.colLayer2Hover
property color activeBorderColor: Appearance.m3colors.m3secondary
property bool hoveredWhileDragging: false
@@ -209,15 +220,4 @@ Item {
}
}
}
DropShadow {
z: -9999
anchors.fill: overviewBackground
horizontalOffset: 0
verticalOffset: 2
radius: Appearance.sizes.elevationMargin
samples: radius * 2 + 1 // Ideally should be 2 * radius + 1, see qt docs
color: Appearance.colors.colShadow
source: overviewBackground
}
}
@@ -2,6 +2,7 @@ import "root:/services/"
import "root:/modules/common"
import "root:/modules/common/widgets"
import "root:/modules/common/functions/icons.js" as Icons
import "root:/modules/common/functions/color_utils.js" as ColorUtils
import Qt5Compat.GraphicalEffects
import QtQuick
import QtQuick.Layouts
@@ -42,37 +43,21 @@ Rectangle { // Window
radius: Appearance.rounding.windowRounding * root.scale
color: pressed ? Appearance.colors.colLayer2Active : hovered ? Appearance.colors.colLayer2Hover : Appearance.colors.colLayer2
border.color : Appearance.transparentize(Appearance.m3colors.m3outline, 0.9)
border.color : ColorUtils.transparentize(Appearance.m3colors.m3outline, 0.9)
border.pixelAligned : false
border.width : 1
Behavior on x {
NumberAnimation {
duration: Appearance.animation.elementMoveEnter.duration
easing.type: Appearance.animation.elementMoveEnter.type
easing.bezierCurve: Appearance.animation.elementMoveEnter.bezierCurve
}
animation: Appearance.animation.elementMoveEnter.numberAnimation.createObject(this)
}
Behavior on y {
NumberAnimation {
duration: Appearance.animation.elementMoveEnter.duration
easing.type: Appearance.animation.elementMoveEnter.type
easing.bezierCurve: Appearance.animation.elementMoveEnter.bezierCurve
}
animation: Appearance.animation.elementMoveEnter.numberAnimation.createObject(this)
}
Behavior on width {
NumberAnimation {
duration: Appearance.animation.elementMoveEnter.duration
easing.type: Appearance.animation.elementMoveEnter.type
easing.bezierCurve: Appearance.animation.elementMoveEnter.bezierCurve
}
animation: Appearance.animation.elementMoveEnter.numberAnimation.createObject(this)
}
Behavior on height {
NumberAnimation {
duration: Appearance.animation.elementMoveEnter.duration
easing.type: Appearance.animation.elementMoveEnter.type
easing.bezierCurve: Appearance.animation.elementMoveEnter.bezierCurve
}
animation: Appearance.animation.elementMoveEnter.numberAnimation.createObject(this)
}
ColumnLayout {
@@ -88,11 +73,7 @@ Rectangle { // Window
implicitSize: Math.min(targetWindowWidth, targetWindowHeight) * (root.compactMode ? root.iconToWindowRatioCompact : root.iconToWindowRatio)
Behavior on implicitSize {
NumberAnimation {
duration: Appearance.animation.elementMoveEnter.duration
easing.type: Appearance.animation.elementMoveEnter.type
easing.bezierCurve: Appearance.animation.elementMoveEnter.bezierCurve
}
animation: Appearance.animation.elementMoveEnter.numberAnimation.createObject(this)
}
IconImage {
@@ -2,6 +2,7 @@
import "root:/"
import "root:/modules/common"
import "root:/modules/common/widgets"
import "root:/modules/common/functions/color_utils.js" as ColorUtils
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
@@ -57,7 +58,9 @@ Button {
anchors.leftMargin: root.horizontalMargin
anchors.rightMargin: root.horizontalMargin
radius: Appearance.rounding.normal
color: (root.down || root.keyboardDown) ? Appearance.colors.colLayer1Active : ((root.hovered || root.focus) ? Appearance.colors.colLayer1Hover : Appearance.transparentize(Appearance.m3colors.m3surfaceContainerHigh, 1))
color: (root.down || root.keyboardDown) ? Appearance.colors.colLayer1Active :
((root.hovered || root.focus) ? Appearance.colors.colLayer1Hover :
ColorUtils.transparentize(Appearance.m3colors.m3surfaceContainerHigh, 1))
}
RowLayout {
@@ -100,7 +103,7 @@ Button {
StyledText {
font.pixelSize: Appearance.font.pixelSize.small
color: Appearance.colors.colSubtext
visible: root.itemType && root.itemType != "App"
visible: root.itemType && root.itemType != qsTr("App")
text: root.itemType
}
StyledText {
@@ -7,6 +7,7 @@ import Qt5Compat.GraphicalEffects
import Qt.labs.platform
import QtQuick
import QtQuick.Controls
import QtQuick.Effects
import QtQuick.Layouts
import Quickshell
import Quickshell.Io
@@ -160,6 +161,15 @@ Item { // Wrapper
implicitHeight: columnLayout.implicitHeight
radius: Appearance.rounding.large
color: Appearance.colors.colLayer0
layer.enabled: true
layer.effect: MultiEffect {
source: searchWidgetContent
anchors.fill: searchWidgetContent
shadowEnabled: true
shadowColor: Appearance.colors.colShadow
shadowVerticalOffset: 1
shadowBlur: 0.5
}
ColumnLayout {
id: columnLayout
@@ -227,7 +237,7 @@ Item { // Wrapper
}
}
background: Item {}
background: null
cursorDelegate: Rectangle {
width: 1
@@ -276,7 +286,7 @@ Item { // Wrapper
nonAppResultsTimer.restart();
const mathResultObject = {
name: root.mathResult,
clickActionName: "Copy",
clickActionName: qsTr("Copy"),
type: qsTr("Math result"),
fontType: "monospace",
materialSymbol: 'calculate',
@@ -286,7 +296,7 @@ Item { // Wrapper
}
const commandResultObject = {
name: searchingText,
clickActionName: "Run",
clickActionName: qsTr("Run"),
type: qsTr("Run command"),
fontType: "monospace",
materialSymbol: 'terminal',
@@ -300,8 +310,8 @@ Item { // Wrapper
if (actionString.startsWith(root.searchingText) || root.searchingText.startsWith(actionString)) {
return {
name: root.searchingText.startsWith(actionString) ? root.searchingText : actionString,
clickActionName: "Run",
type: "Action",
clickActionName: qsTr("Run"),
type: qsTr("Action"),
materialSymbol: 'settings_suggest',
execute: () => {
action.execute(root.searchingText.split(" ").slice(1).join(" "))
@@ -319,8 +329,8 @@ Item { // Wrapper
result = result.concat(
AppSearch.fuzzyQuery(root.searchingText)
.map((entry) => {
entry.clickActionName = "Launch";
entry.type = "App"
entry.clickActionName = qsTr("Launch");
entry.type = qsTr("App");
return entry;
})
);
@@ -344,8 +354,8 @@ Item { // Wrapper
// Web search
result.push({
name: root.searchingText,
clickActionName: "Search",
type: "Search the web",
clickActionName: qsTr("Search"),
type: qsTr("Search the web"),
materialSymbol: 'travel_explore',
execute: () => {
let url = ConfigOptions.search.engineBaseUrl + root.searchingText
@@ -361,22 +371,9 @@ Item { // Wrapper
}
delegate: SearchItem {
entry: modelData
// itemName: modelData.name
// itemIcon: modelData.icon
}
}
}
}
DropShadow {
id: searchWidgetShadow
anchors.fill: searchWidgetContent
source: searchWidgetContent
radius: Appearance.sizes.elevationMargin
samples: radius * 2 + 1
color: Appearance.colors.colShadow
verticalOffset: 2
horizontalOffset: 0
}
}