Browse Source

bold font wasn't loaded when regular font loading was succesful

some styling fixes
patch-4
Sander van Grieken 3 years ago
parent
commit
e84bc4561f
  1. 2
      electrum/gui/qml/components/Addresses.qml
  2. 3
      electrum/gui/qml/components/Receive.qml
  3. 3
      electrum/gui/qml/components/Send.qml
  4. 5
      electrum/gui/qml/qeapp.py

2
electrum/gui/qml/components/Addresses.qml

@ -81,7 +81,7 @@ Pane {
color: model.held
? Qt.rgba(1,0,0,0.75)
: model.numtx > 0
? model.balance == 0
? model.balance.satsInt == 0
? Qt.rgba(0.5,0.5,0.5,1)
: Qt.rgba(0.75,0.75,0.75,1)
: model.type == 'receive'

3
electrum/gui/qml/components/Receive.qml

@ -143,7 +143,8 @@ Pane {
width: parent.width
Label {
text: qsTr('Receive queue')
font.pixelSize: constants.fontSizeXLarge
font.pixelSize: constants.fontSizeLarge
color: Material.accentColor
}
}
}

3
electrum/gui/qml/components/Send.qml

@ -176,7 +176,8 @@ Pane {
width: parent.width
Label {
text: qsTr('Send queue')
font.pixelSize: constants.fontSizeXLarge
font.pixelSize: constants.fontSizeLarge
color: Material.accentColor
}
}
}

5
electrum/gui/qml/qeapp.py

@ -154,8 +154,9 @@ class ElectrumQmlApplication(QGuiApplication):
# add a monospace font as we can't rely on device having one
self.fixedFont = 'PT Mono'
if (QFontDatabase.addApplicationFont('electrum/gui/qml/fonts/PTMono-Regular.ttf') < 0 and
QFontDatabase.addApplicationFont('electrum/gui/qml/fonts/PTMono-Bold.ttf') < 0):
not_loaded = QFontDatabase.addApplicationFont('electrum/gui/qml/fonts/PTMono-Regular.ttf') < 0
not_loaded = QFontDatabase.addApplicationFont('electrum/gui/qml/fonts/PTMono-Bold.ttf') < 0 and not_loaded
if not_loaded:
self.logger.warning('Could not load font PT Mono')
self.fixedFont = 'Monospace' # hope for the best

Loading…
Cancel
Save