Skip to content

Commit 876548d

Browse files
committed
Merge #239: Make External Link settings icon follow the design file specs
515e2fa qml: make external links follow the specs in the design file (jarolrod) b73cd4d qml: replace the current export icon with the export-outline icon (Jarol Rodriguez) Pull request description: This replaces the current export icon we have (export-filled) for the export-outline icon, as that is what the design file now specifies. The new icon has been passed through the `optimize-png.py` script, which output the following: ``` optimizing export.png... done summary: +++++++++++++++++ export.png size diff from: 1371 to: 785 old sha256: c93640af06071bcee055727bcfd01f8576d657260a385035dac8f2f1568cf571 new sha256: c0605b933dfaae15b26254d08d11d2e9e9e4b20d5a9748386cd9a9f680502266 completed. Checksum stable: False. Total reduction: 586 bytes ``` Additionally, this adjusts the spacing between the external link text and the icon in order to better match the design file ### master | light | dark | | ----- | ---- | | <img width="752" alt="Screen Shot 2023-01-31 at 7 08 22 PM" src="https://user-images.githubusercontent.com/23396902/215913241-f89a5692-e640-43f2-93be-f25f90eb2323.png"> | <img width="752" alt="Screen Shot 2023-01-31 at 7 08 28 PM" src="https://user-images.githubusercontent.com/23396902/215913260-a730f378-d1b0-41f0-9aba-8f9378e5bbc7.png"> | ### pr | light | dark | | ----- | ---- | | <img width="752" alt="Screen Shot 2023-02-09 at 1 42 16 PM" src="https://user-images.githubusercontent.com/23396902/217935436-e580fec1-8709-4fa5-986b-95001bab8e7f.png"> | <img width="752" alt="Screen Shot 2023-02-09 at 1 42 22 PM" src="https://user-images.githubusercontent.com/23396902/217935461-88258e2c-43cf-48be-bb62-a052d7a9b9c5.png"> | ### layout | external icon | right caret | | ------------- | ----------- | | <img width="642" alt="Screen Shot 2023-02-09 at 1 41 33 PM" src="https://user-images.githubusercontent.com/23396902/217935623-146d4c13-1c40-4454-819b-6df86d573ce0.png"> | <img width="642" alt="Screen Shot 2023-02-09 at 1 41 44 PM" src="https://user-images.githubusercontent.com/23396902/217935668-29ba9c4f-7396-4d0c-a1ac-e15833663f74.png"> | [![Windows](https://img.shields.io/badge/OS-Windows-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/win64/insecure_win_gui.zip?branch=pull/239) [![Intel macOS](https://img.shields.io/badge/OS-Intel%20macOS-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/macos/insecure_mac_gui.zip?branch=pull/239) [![Apple Silicon macOS](https://img.shields.io/badge/OS-Apple%20Silicon%20macOS-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/macos_arm64/insecure_mac_arm64_gui.zip?branch=pull/239) [![ARM64 Android](https://img.shields.io/badge/OS-Android-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/android/insecure_android_apk.zip?branch=pull/239) ACKs for top commit: johnny9: ACK 515e2fa Tree-SHA512: 4db5e911b30cd595211f79123d96f10c4b2013678f0062cb21aa23d2188a98712e5455879f2a95d0508dec0f82374bab677b6f74db1757bd1247bbf25fc38a9e
2 parents 15df21c + 515e2fa commit 876548d

File tree

4 files changed

+20
-24
lines changed

4 files changed

+20
-24
lines changed

src/qml/components/AboutOptions.qml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ ColumnLayout {
1717
parentState: websiteLink.state
1818
description: "bitcoincore.org"
1919
link: "https://bitcoincore.org"
20-
iconSource: "image://images/caret-right"
2120
}
2221
onClicked: loadedItem.clicked()
2322
}
@@ -29,7 +28,6 @@ ColumnLayout {
2928
parentState: sourceLink.state
3029
description: "github.com/bitcoin/bitcoin"
3130
link: "https://github.com/bitcoin/bitcoin"
32-
iconSource: "image://images/caret-right"
3331
}
3432
onClicked: loadedItem.clicked()
3533
}
@@ -41,7 +39,6 @@ ColumnLayout {
4139
parentState: licenseLink.state
4240
description: "MIT"
4341
link: "https://opensource.org/licenses/MIT"
44-
iconSource: "image://images/caret-right"
4542
}
4643
onClicked: loadedItem.clicked()
4744
}
@@ -54,6 +51,8 @@ ColumnLayout {
5451
description: "v22.99.0-1e7564eca8a6"
5552
link: "https://bitcoin.org/en/download"
5653
iconSource: "image://images/caret-right"
54+
iconWidth: 18
55+
iconHeight: 18
5756
}
5857
onClicked: loadedItem.clicked()
5958
}

src/qml/controls/ExternalLink.qml

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ AbstractButton {
1212
required property string link
1313
property string description: ""
1414
property int descriptionSize: 18
15-
property url iconSource: ""
16-
property int iconWidth: 18
17-
property int iconHeight: 18
15+
property url iconSource: "image://images/export"
16+
property int iconWidth: 22
17+
property int iconHeight: 22
1818
property color iconColor
1919
property color textColor
2020
state: root.parentState
@@ -66,21 +66,19 @@ AbstractButton {
6666
}
6767
}
6868
}
69-
Loader {
70-
Layout.fillWidth: true
71-
active: root.iconSource.toString().length > 0
72-
visible: active
73-
sourceComponent: Button {
74-
icon.source: root.iconSource
75-
icon.color: root.iconColor
76-
icon.height: root.iconHeight
77-
icon.width: root.iconWidth
78-
background: null
79-
onClicked: root.clicked()
69+
Button {
70+
leftPadding: 0
71+
topPadding: 0
72+
bottomPadding: 0
73+
icon.source: root.iconSource
74+
icon.color: root.iconColor
75+
icon.height: root.iconHeight
76+
icon.width: root.iconWidth
77+
background: null
78+
onClicked: root.clicked()
8079

81-
Behavior on icon.color {
82-
ColorAnimation { duration: 150 }
83-
}
80+
Behavior on icon.color {
81+
ColorAnimation { duration: 150 }
8482
}
8583
}
8684
}

src/qml/res/icons/export.png

90 Bytes
Loading

src/qml/res/src/export.svg

Lines changed: 3 additions & 4 deletions
Loading

0 commit comments

Comments
 (0)