aboutsummaryrefslogtreecommitdiff
path: root/components/StandardButton.qml
diff options
context:
space:
mode:
authorSander Ferdinand <sa.ferdinand@gmail.com>2017-12-10 19:52:05 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2018-03-29 23:04:02 +0100
commitf262ce520978fa406e6531ffc9a8464a14a3a722 (patch)
tree71c838057f4fcf897c093292ecec748f4176e189 /components/StandardButton.qml
parentbe9cb8931c9bfe9fccf9d4ec7060dc467a1a6c8e (diff)
downloadmonzero-gui-f262ce520978fa406e6531ffc9a8464a14a3a722.tar.gz
monzero-gui-f262ce520978fa406e6531ffc9a8464a14a3a722.tar.xz
monzero-gui-f262ce520978fa406e6531ffc9a8464a14a3a722.zip
Finishing up on the settings page for now and modified some QML components
Diffstat (limited to 'components/StandardButton.qml')
-rw-r--r--components/StandardButton.qml11
1 files changed, 8 insertions, 3 deletions
diff --git a/components/StandardButton.qml b/components/StandardButton.qml
index f41c104a..76c8c889 100644
--- a/components/StandardButton.qml
+++ b/components/StandardButton.qml
@@ -32,15 +32,20 @@ import "." 1.0
Item {
id: button
- height: 37 * scaleRatio
property string icon: ""
property string textColor: button.enabled? Style.buttonTextColor: Style.buttonTextColorDisabled
- property int fontSize: 16 * scaleRatio
+ property bool small: false
property alias text: label.text
+ property int fontSize: {
+ if(small) return 14 * scaleRatio;
+ else return 16 * scaleRatio;
+ }
signal clicked()
- // Dynamic label width
+ // Dynamic height/width
Layout.minimumWidth: (label.contentWidth > 50)? label.contentWidth + 22 : 60
+ height: small ? 30 * scaleRatio : 36 * scaleRatio
+
function doClick() {
// Android workaround