Skip to content

Commit

Permalink
revert(graph): re add drop shadow
Browse files Browse the repository at this point in the history
This reverts commit 561c1e6.
  • Loading branch information
orblazer committed Dec 19, 2021
1 parent a80a15b commit b2966a2
Show file tree
Hide file tree
Showing 10 changed files with 141 additions and 107 deletions.
3 changes: 3 additions & 0 deletions package/contents/config/main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@
<entry name="sampleCount" type="Int">
<default>10</default>
</entry>
<entry name="enableShadows" type="Bool">
<default>true</default>
</entry>
<entry name="fontScale" type="Int">
<default>26</default>
</entry>
Expand Down
Binary file not shown.
Binary file not shown.
13 changes: 13 additions & 0 deletions package/contents/ui/components/SensorGraph.qml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import QtQuick 2.2
import QtGraphicalEffects 1.0
import org.kde.plasma.plasmoid 2.0
import org.kde.plasma.components 2.0 as PlasmaComponents

Expand Down Expand Up @@ -26,6 +27,7 @@ Item {
property color secondLabelColor: theme.textColor
property bool secondLabelWhenZero: true

property bool enableShadows: plasmoid.configuration.enableShadows
property string placement: plasmoid.configuration.placement // Values: top-right, top-left, bottom-right, bottom-left
property string displayment: plasmoid.configuration.displayment // Values: always, hover, hover-hints

Expand Down Expand Up @@ -254,6 +256,17 @@ Item {
}
]
}

DropShadow {
visible: enableShadows
anchors.fill: textContainer
radius: 3
samples: 8
spread: 0.8
fast: true
color: theme.backgroundColor
source: textContainer
}
}

function canSeeSecondLine() {
Expand Down
6 changes: 6 additions & 0 deletions package/contents/ui/config/ConfigAppearance.qml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ QtLayouts.ColumnLayout {
property alias cfg_graphMargin: graphMargin.value
property alias cfg_graphFillOpacity: graphFillOpacity.value

property alias cfg_enableShadows: enableShadows.checked
property alias cfg_fontScale: fontScale.value
property string cfg_placement: ""
property string cfg_displayment: ""
Expand Down Expand Up @@ -120,6 +121,11 @@ QtLayouts.ColumnLayout {
id: textPage
wideMode: true

QtControls.CheckBox {
id: enableShadows
text: i18n("Drop shadows")
}

RMControls.SpinBox {
id: fontScale
Kirigami.FormData.label: i18n("Font scale:")
Expand Down
2 changes: 1 addition & 1 deletion package/metadata.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ Icon=utilities-system-monitor
Name[fr]=Moniteur des ressources (fork)
Name[nl]=Systeembronmonitor (afsplitsing)
Comment[fr]=Plasmoid pour surveiller l'utilisation du CPU, de la mémoire et du traffic réseau. Ceci est un fork de "Resources Monitor" de Kotelnik
Comment[nl]=Een plasmoid voor het monitoren van de cpu, het werkgeheugen en netwerkverkeer. Dit is een afsplitsing van Resources Monitor van Kotelnik.
Comment[nl]=Een plasmoid voor het monitoren van de cpu, het werkgeheugen en netwerkverkeer. Dit is een afsplitsing van "Resources Monitor" van Kotelnik.
6 changes: 3 additions & 3 deletions package/translate/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ Or if you know how to make a pull request

| Locale | Lines | % Done|
|----------|---------|-------|
| Template | 68 | |
| fr | 68/68 | 100% |
| nl | 68/68 | 100% |
| Template | 69 | |
| fr | 69/69 | 100% |
| nl | 69/69 | 100% |
72 changes: 38 additions & 34 deletions package/translate/fr.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ msgid ""
msgstr ""
"Project-Id-Version: resourcesMonitor-fork\n"
"Report-Msgid-Bugs-To: https://github.com/orblazer/plasma-applet-resources-monitor\n"
"POT-Creation-Date: 2021-12-05 19:54+0100\n"
"PO-Revision-Date: 2021-12-05 12:09+0100\n"
"POT-Creation-Date: 2021-12-19 13:25+0100\n"
"PO-Revision-Date: 2021-12-19 13:25+0100\n"
"Last-Translator: orblazer\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
Expand Down Expand Up @@ -53,119 +53,123 @@ msgctxt "kibibyte suffix"
msgid "iB/s"
msgstr "io/s"

#: ../contents/ui/config/ConfigAppearance.qml:45
#: ../contents/ui/config/ConfigAppearance.qml:46
msgid "Graph"
msgstr "Graphique"

#: ../contents/ui/config/ConfigAppearance.qml:50
#: ../contents/ui/config/ConfigAppearance.qml:51
msgid "Text"
msgstr "Texte"

#: ../contents/ui/config/ConfigAppearance.qml:55
#: ../contents/ui/config/ConfigAppearance.qml:56
msgid "Colors"
msgstr "Couleurs"

#: ../contents/ui/config/ConfigAppearance.qml:70
#: ../contents/ui/config/ConfigAppearance.qml:71
msgid "Vertical layout"
msgstr "Disposition verticale"

#: ../contents/ui/config/ConfigAppearance.qml:75
#: ../contents/ui/config/ConfigAppearance.qml:76
msgid "Sample count:"
msgstr "Nombre d'échantillons :"

#: ../contents/ui/config/ConfigAppearance.qml:82
#: ../contents/ui/config/ConfigAppearance.qml:83
msgid "Width:"
msgstr "Largeur :"

#: ../contents/ui/config/ConfigAppearance.qml:89
#: ../contents/ui/config/ConfigAppearance.qml:90
msgid "Height:"
msgstr "Hauteur :"

#: ../contents/ui/config/ConfigAppearance.qml:96
#: ../contents/ui/config/ConfigAppearance.qml:97
msgid "Margin:"
msgstr "Marge :"

#: ../contents/ui/config/ConfigAppearance.qml:107
#: ../contents/ui/config/ConfigAppearance.qml:108
msgid "Fill opacity:"
msgstr "Opacité du remplissage :"

#: ../contents/ui/config/ConfigAppearance.qml:125
#: ../contents/ui/config/ConfigAppearance.qml:126
msgid "Drop shadows"
msgstr "Ombres portées"

#: ../contents/ui/config/ConfigAppearance.qml:131
msgid "Font scale:"
msgstr "Taille de la police :"

#: ../contents/ui/config/ConfigAppearance.qml:137
#: ../contents/ui/config/ConfigAppearance.qml:143
msgid "Text displayment:"
msgstr "Affichage du texte :"

#: ../contents/ui/config/ConfigAppearance.qml:140
#: ../contents/ui/config/ConfigAppearance.qml:146
msgid "Always"
msgstr "Toujours"

#: ../contents/ui/config/ConfigAppearance.qml:143
#: ../contents/ui/config/ConfigAppearance.qml:149
msgid "On hover"
msgstr "Au survol"

#: ../contents/ui/config/ConfigAppearance.qml:146
#: ../contents/ui/config/ConfigAppearance.qml:152
msgid "Hints when hover"
msgstr "Indices au survol"

#: ../contents/ui/config/ConfigAppearance.qml:162
#: ../contents/ui/config/ConfigAppearance.qml:168
msgid "Placement:"
msgstr "Placement :"

#: ../contents/ui/config/ConfigAppearance.qml:165
#: ../contents/ui/config/ConfigAppearance.qml:171
msgid "Top left"
msgstr "En haut à gauche"

#: ../contents/ui/config/ConfigAppearance.qml:168
#: ../contents/ui/config/ConfigAppearance.qml:174
msgid "Top right"
msgstr "En haut à droite"

#: ../contents/ui/config/ConfigAppearance.qml:171
#: ../contents/ui/config/ConfigAppearance.qml:177
msgid "Bottom left"
msgstr "En bas à gauche"

#: ../contents/ui/config/ConfigAppearance.qml:174
#: ../contents/ui/config/ConfigAppearance.qml:180
msgid "Bottom right"
msgstr "En bas à droite"

#: ../contents/ui/config/ConfigAppearance.qml:195
#: ../contents/ui/config/ConfigAppearance.qml:201
msgid "CPU color:"
msgstr "Couleur du CPU :"

#: ../contents/ui/config/ConfigAppearance.qml:197
#: ../contents/ui/config/ConfigAppearance.qml:203
msgid "Choose CPU graph color"
msgstr "Choisissez la couleur du graphique du CPU"

#: ../contents/ui/config/ConfigAppearance.qml:203
#: ../contents/ui/config/ConfigAppearance.qml:209
msgid "Memory color:"
msgstr "Couleur de la mémoire"

#: ../contents/ui/config/ConfigAppearance.qml:205
#: ../contents/ui/config/ConfigAppearance.qml:211
msgid "Choose memory graph color"
msgstr "Choisissez la couleur du graphique de la mémoire"

#: ../contents/ui/config/ConfigAppearance.qml:210
#: ../contents/ui/config/ConfigAppearance.qml:216
msgid "Swap color:"
msgstr "Couleur du Swap :"

#: ../contents/ui/config/ConfigAppearance.qml:212
#: ../contents/ui/config/ConfigAppearance.qml:218
msgid "Choose Swap graph color"
msgstr "Choisissez la couleur du graphique Swap"

#: ../contents/ui/config/ConfigAppearance.qml:218
#: ../contents/ui/config/ConfigAppearance.qml:224
msgid "Network receiving color:"
msgstr "Couleur du traffic entrant :"

#: ../contents/ui/config/ConfigAppearance.qml:220
#: ../contents/ui/config/ConfigAppearance.qml:226
msgid "Choose network receiving graph color"
msgstr "Choisissez la couleur du graphique du traffic entrant"

#: ../contents/ui/config/ConfigAppearance.qml:225
#: ../contents/ui/config/ConfigAppearance.qml:231
msgid "Network sending color:"
msgstr "Couleur du traffic sortant :"

#: ../contents/ui/config/ConfigAppearance.qml:227
#: ../contents/ui/config/ConfigAppearance.qml:233
msgid "Choose network sending graph color"
msgstr "Choisissez la couleur du graphique du traffic sortant"

Expand Down Expand Up @@ -281,14 +285,14 @@ msgstr "Cocher pour utiliser une couleur personnalisée"
msgid "Check for use customized graph width"
msgstr "Cocher pour l'utilisation d'une largeur de graphique personnalisée"

#: ../contents/ui/main.qml:135
#: ../contents/ui/main.qml:136
msgid "⏲ Clock"
msgstr "⏲ Horl."

#: ../contents/ui/main.qml:210
#: ../contents/ui/main.qml:193
msgid "⇘ Down"
msgstr "⇘ Tél."

#: ../contents/ui/main.qml:212
#: ../contents/ui/main.qml:195
msgid "⇗ Up"
msgstr "⇗ Env."
Loading

0 comments on commit b2966a2

Please sign in to comment.