remove rounded shapes

This commit is contained in:
Michele Guerini Rocco 2024-10-13 02:19:24 +02:00
parent b10aa645e0
commit fe38395b37
Signed by: rnhmjoj
GPG Key ID: BFBAF4C975F76450
26 changed files with 38 additions and 38 deletions

View File

@ -26,7 +26,7 @@ AbstractButton {
id: bg id: bg
color: palette.dark color: palette.dark
radius: Settings.avatarCircles ? height / 2 : height / 8 radius: Settings.avatarCircles ? height / 2 : 0
} }
Label { Label {
@ -46,7 +46,7 @@ AbstractButton {
id: identicon id: identicon
anchors.fill: parent anchors.fill: parent
source: Settings.useIdenticon ? ("image://jdenticon/" + (avatar.userid !== "" ? avatar.userid : avatar.roomid) + "?radius=" + (Settings.avatarCircles ? 100 : 25)) : "" source: Settings.useIdenticon ? ("image://jdenticon/" + (avatar.userid !== "" ? avatar.userid : avatar.roomid) + "?radius=" + (Settings.avatarCircles ? 100 : 0)) : ""
visible: Settings.useIdenticon && img.status != Image.Ready visible: Settings.useIdenticon && img.status != Image.Ready
} }
Image { Image {
@ -56,9 +56,9 @@ AbstractButton {
asynchronous: true asynchronous: true
fillMode: avatar.crop ? Image.PreserveAspectCrop : Image.PreserveAspectFit fillMode: avatar.crop ? Image.PreserveAspectCrop : Image.PreserveAspectFit
source: if (avatar.url.startsWith('image://colorimage')) { source: if (avatar.url.startsWith('image://colorimage')) {
return avatar.url + "&radius=" + (Settings.avatarCircles ? 100 : 25) + ((avatar.crop) ? "" : "&scale"); return avatar.url + "&radius=" + (Settings.avatarCircles ? 100 : 0) + ((avatar.crop) ? "" : "&scale");
} else if (avatar.url.startsWith('image://')) { } else if (avatar.url.startsWith('image://')) {
return avatar.url + "?radius=" + (Settings.avatarCircles ? 100 : 25) + ((avatar.crop) ? "" : "&scale"); return avatar.url + "?radius=" + (Settings.avatarCircles ? 100 : 0) + ((avatar.crop) ? "" : "&scale");
} else if (avatar.url.startsWith(':/')) { } else if (avatar.url.startsWith(':/')) {
return "image://colorimage/" + avatar.url + "?" + label.color; return "image://colorimage/" + avatar.url + "?" + label.color;
} else { } else {
@ -95,7 +95,7 @@ AbstractButton {
anchors.right: avatar.right anchors.right: avatar.right
color: updatePresence() color: updatePresence()
height: avatar.height / 6 height: avatar.height / 6
radius: Settings.avatarCircles ? height / 2 : height / 8 radius: Settings.avatarCircles ? height / 2 : 0
visible: !!avatar.userid visible: !!avatar.userid
width: height width: height

View File

@ -30,7 +30,7 @@ Rectangle {
border.width: 1 border.width: 1
// TODO: Qt.alpha() would make more sense but it wasn't working... // TODO: Qt.alpha() would make more sense but it wasn't working...
color: Qt.rgba(bubbleColor.r, bubbleColor.g, bubbleColor.b, 0.3) color: Qt.rgba(bubbleColor.r, bubbleColor.g, bubbleColor.b, 0.3)
radius: 3 radius: 0
visible: warningRoot.visible visible: warningRoot.visible
z: 3 z: 3

View File

@ -169,7 +169,7 @@ Item {
border.color: palette.buttonText border.color: palette.buttonText
border.width: 1 border.width: 1
color: palette.window color: palette.window
radius: padding radius: 0
} }
contentItem: RowLayout { contentItem: RowLayout {
id: row id: row
@ -637,7 +637,7 @@ Item {
flat: true flat: true
height: width height: width
hoverEnabled: true hoverEnabled: true
radius: width / 2 radius: 0
width: 0 width: 0
background: Rectangle { background: Rectangle {
@ -645,7 +645,7 @@ Item {
border.width: 1 border.width: 1
color: toEndButton.down ? palette.highlight : palette.button color: toEndButton.down ? palette.highlight : palette.button
opacity: enabled ? 1 : 0.3 opacity: enabled ? 1 : 0.3
radius: toEndButton.radius radius: 0
} }
states: [ states: [
State { State {

View File

@ -39,7 +39,7 @@ Flow {
color: reaction.hovered ? palette.highlight : (modelData.selfReactedEvent !== '' ? gentleHighlight : palette.window) color: reaction.hovered ? palette.highlight : (modelData.selfReactedEvent !== '' ? gentleHighlight : palette.window)
implicitHeight: reaction.implicitHeight implicitHeight: reaction.implicitHeight
implicitWidth: reaction.implicitWidth implicitWidth: reaction.implicitWidth
radius: reaction.height / 2 radius: 0
} }
contentItem: Row { contentItem: Row {
spacing: textMetrics.height / 4 spacing: textMetrics.height / 4

View File

@ -34,7 +34,7 @@ Item {
border.color: Nheko.theme.separator border.color: Nheko.theme.separator
border.width: 1 border.width: 1
color: palette.window color: palette.window
radius: Nheko.paddingSmall radius: 0
} }
ColumnLayout { ColumnLayout {
@ -88,7 +88,7 @@ Item {
border.color: Nheko.theme.separator border.color: Nheko.theme.separator
border.width: 1 border.width: 1
color: palette.window color: palette.window
radius: Nheko.paddingSmall radius: 0
} }
onAccepted: SelfVerificationStatus.setupCrosssigning(storeSecretsOnline.checked, usePassword.checked ? passwordField.text : "", useOnlineKeyBackup.checked) onAccepted: SelfVerificationStatus.setupCrosssigning(storeSecretsOnline.checked, usePassword.checked ? passwordField.text : "", useOnlineKeyBackup.checked)

View File

@ -289,7 +289,7 @@ TimelineEvent {
padding: wrapper.isStateEvent ? 0 : 4 padding: wrapper.isStateEvent ? 0 : 4
background: Rectangle { background: Rectangle {
color: !wrapper.isStateEvent ? Qt.tint(palette.base, Qt.hsla(messageBubble.userColor.hslHue, wrapper.hovered ? 0.8 : 0.5, messageBubble.userColor.hslLightness, 0.2)) : "transparent" color: !wrapper.isStateEvent ? Qt.tint(palette.base, Qt.hsla(messageBubble.userColor.hslHue, wrapper.hovered ? 0.8 : 0.5, messageBubble.userColor.hslLightness, 0.2)) : "transparent"
radius: 4 radius: 0
border.color: Nheko.theme.red border.color: Nheko.theme.red
border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0 border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0
} }

View File

@ -294,7 +294,7 @@ TimelineEvent {
color: "transparent" color: "transparent"
border.color: Nheko.theme.red border.color: Nheko.theme.red
border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0 border.width: wrapper.notificationlevel == MtxEvent.Highlight ? 1 : 0
radius: 4 radius: 0
height: contentColumn.implicitHeight + 4 height: contentColumn.implicitHeight + 4
width: contentColumn.implicitWidth + 4 + (wrapper.threadId ? (4 + gridContainer.spacing) : 0) width: contentColumn.implicitWidth + 4 + (wrapper.threadId ? (4 + gridContainer.spacing) : 0)
}, },

View File

@ -43,7 +43,7 @@ Column {
background: Rectangle { background: Rectangle {
color: palette.window color: palette.window
radius: parent.height / 2 radius: 0
} }
} }
Row { Row {

View File

@ -24,7 +24,7 @@ Switch {
color: Qt.rgba(border.color.r, border.color.g, border.color.b, 0.6) color: Qt.rgba(border.color.r, border.color.g, border.color.b, 0.6)
height: parent.height * 0.6 height: parent.height * 0.6
radius: height / 2 radius: 0
width: parent.width - height width: parent.width - height
x: radius x: radius
y: parent.height / 2 - height / 2 y: parent.height / 2 - height / 2
@ -35,7 +35,7 @@ Switch {
border.color: "#767676" border.color: "#767676"
color: palette.button color: palette.button
height: width height: width
radius: width / 2 radius: 0
width: parent.height * 0.9 width: parent.height * 0.9
y: parent.height / 2 - height / 2 y: parent.height / 2 - height / 2
} }

View File

@ -42,7 +42,7 @@ Page {
background: Rectangle { background: Rectangle {
color: palette.window color: palette.window
radius: Nheko.paddingMedium radius: 0
} }
contentItem: ColumnLayout { contentItem: ColumnLayout {
Image { Image {

View File

@ -47,7 +47,7 @@ Button {
background: Rectangle { background: Rectangle {
//height: control.contentItem.implicitHeight * 2 //height: control.contentItem.implicitHeight * 2
//width: control.contentItem.implicitWidth * 2 //width: control.contentItem.implicitWidth * 2
radius: height / 8 radius: 0
color: Qt.lighter(palette.dark, control.down ? 1.4 : (control.hovered ? 1.2 : 1)) color: Qt.lighter(palette.dark, control.down ? 1.4 : (control.hovered ? 1.2 : 1))
} }

View File

@ -33,7 +33,7 @@ Dialog {
color: palette.window color: palette.window
border.color: Nheko.theme.separator border.color: Nheko.theme.separator
border.width: 1 border.width: 1
radius: Nheko.paddingSmall radius: 0
} }
} }

View File

@ -23,7 +23,7 @@ TabButton {
border.color: control.down ? palette.highlight : Nheko.theme.separator border.color: control.down ? palette.highlight : Nheko.theme.separator
color: control.checked ? palette.highlight : palette.base color: control.checked ? palette.highlight : palette.base
border.width: 1 border.width: 1
radius: 2 radius: 0
} }
} }

View File

@ -20,7 +20,7 @@ Rectangle {
visible: mayBeVisible && notificationCount > 0 visible: mayBeVisible && notificationCount > 0
implicitHeight: notificationBubbleText.height + Nheko.paddingMedium implicitHeight: notificationBubbleText.height + Nheko.paddingMedium
implicitWidth: Math.max(notificationBubbleText.width, height) implicitWidth: Math.max(notificationBubbleText.width, height)
radius: height / 2 radius: 0
color: hasLoudNotification ? Nheko.theme.red : bubbleBackgroundColor color: hasLoudNotification ? Nheko.theme.red : bubbleBackgroundColor
ToolTip.text: notificationCount ToolTip.text: notificationCount
ToolTip.delay: Nheko.tooltipDelay ToolTip.delay: Nheko.tooltipDelay

View File

@ -50,7 +50,7 @@ Item {
color: dragArea.held ? palette.highlight : palette.base color: dragArea.held ? palette.highlight : palette.base
Behavior on color { ColorAnimation { duration: 100 } } Behavior on color { ColorAnimation { duration: 100 } }
radius: 2 radius: 0
Drag.active: dragArea.held Drag.active: dragArea.held
Drag.source: dragArea Drag.source: dragArea

View File

@ -73,7 +73,7 @@ Control {
background: Rectangle { background: Rectangle {
color: palette.alternateBase color: palette.alternateBase
radius: fontMetrics.lineSpacing / 2 + 2 * Nheko.paddingMedium radius: 0
visible: !Settings.bubbles // the bubble in a bubble looks odd visible: !Settings.bubbles // the bubble in a bubble looks odd
} }
} }

View File

@ -57,7 +57,7 @@ Control {
} }
background: Rectangle { background: Rectangle {
radius: fontMetrics.lineSpacing / 2 + Nheko.paddingMedium radius: 0
height: contents.implicitHeight + Nheko.paddingMedium * 2 height: contents.implicitHeight + Nheko.paddingMedium * 2
color: palette.alternateBase color: palette.alternateBase
border.color: Nheko.theme.green border.color: Nheko.theme.green

View File

@ -31,7 +31,7 @@ Control {
id: button id: button
color: palette.base color: palette.base
radius: 22 radius: 0
Layout.preferredHeight: 36 Layout.preferredHeight: 36
Layout.preferredWidth: 36 Layout.preferredWidth: 36
@ -91,7 +91,7 @@ Control {
background: Rectangle { background: Rectangle {
color: palette.base color: palette.base
radius: fontMetrics.lineSpacing / 2 + 2 * Nheko.paddingSmall radius: 0
visible: !Settings.bubbles // the bubble in a bubble looks odd visible: !Settings.bubbles // the bubble in a bubble looks odd
} }

View File

@ -13,7 +13,7 @@ Label {
width: contentWidth * 1.2 width: contentWidth * 1.2
background: Rectangle { background: Rectangle {
radius: parent.height / 2 radius: 0
color: palette.base color: palette.base
} }

View File

@ -52,6 +52,6 @@ Control {
background: Rectangle { background: Rectangle {
color: palette.alternateBase color: palette.alternateBase
radius: fontMetrics.lineSpacing / 2 + 2 * Nheko.paddingSmall radius: 0
} }
} }

View File

@ -250,7 +250,7 @@ ApplicationWindow {
background: Rectangle { background: Rectangle {
anchors.fill: parent anchors.fill: parent
color: hovered ? palette.highlight : 'transparent' color: hovered ? palette.highlight : 'transparent'
radius: 5 radius: 0
} }
} }

View File

@ -80,7 +80,7 @@ ApplicationWindow {
border.color: palette.text border.color: palette.text
color: inviteeButton.hovered ? palette.highlight : palette.window color: inviteeButton.hovered ? palette.highlight : palette.window
border.width: 1 border.width: 1
radius: inviteeButton.height / 2 radius: 0
} }
} }
} }

View File

@ -202,7 +202,7 @@ Menu {
background: Rectangle { background: Rectangle {
anchors.fill: parent anchors.fill: parent
color: hovered ? palette.highlight : 'transparent' color: hovered ? palette.highlight : 'transparent'
radius: 5 radius: 0
} }
} }

View File

@ -24,14 +24,14 @@ Slider {
implicitHeight: control.sliderRadius / 4 implicitHeight: control.sliderRadius / 4
width: control.availableWidth - handle.width width: control.availableWidth - handle.width
height: implicitHeight height: implicitHeight
radius: height / 2 radius: 0
color: palette.buttonText color: palette.buttonText
Rectangle { Rectangle {
width: control.visualPosition * parent.width width: control.visualPosition * parent.width
height: parent.height height: parent.height
color: control.progressColor color: control.progressColor
radius: 2 radius: 0
} }
} }
@ -41,7 +41,7 @@ Slider {
y: control.topPadding + control.availableHeight / 2 - height / 2 y: control.topPadding + control.availableHeight / 2 - height / 2
implicitWidth: control.sliderRadius implicitWidth: control.sliderRadius
implicitHeight: control.sliderRadius implicitHeight: control.sliderRadius
radius: control.sliderRadius / 2 radius: 0
color: control.progressColor color: control.progressColor
visible: Settings.mobileMode || control.alwaysShowSlider || control.hovered || control.pressed visible: Settings.mobileMode || control.alwaysShowSlider || control.hovered || control.pressed
border.color: control.progressColor border.color: control.progressColor

View File

@ -55,7 +55,7 @@ Popup {
} }
background: Rectangle { background: Rectangle {
radius: Nheko.paddingLarge radius: 0
color: palette.dark color: palette.dark
opacity: 0.8 opacity: 0.8
} }

View File

@ -156,7 +156,7 @@ Popup {
} }
background: Rectangle { background: Rectangle {
radius: buttonLayout.buttonSize / 2 radius: 0
color: "#ff0000" color: "#ff0000"
} }
@ -185,7 +185,7 @@ Popup {
} }
background: Rectangle { background: Rectangle {
radius: buttonLayout.buttonSize / 2 radius: 0
color: "#00ff00" color: "#00ff00"
} }