0.6.4: copertina con Casa e Acqua, attuale / impostata su due righe etichettate

This commit is contained in:
2026-10-11 08:14:12 +02:00
parent e3e365cbfc
commit c237818e3c
9 changed files with 127 additions and 87 deletions
+3 -1
View File
@@ -40,7 +40,9 @@ e ripiega sull'inglese; la si può scegliere anche nelle impostazioni dell'app.
riscaldamento, acqua calda attiva) che mostrano lo stato e lo cambiano in un
tocco, più i pulsanti per quello che uno stato non ce l'ha: ciclo legionella e
night mode per un'ora. Gli interruttori seguono l'impianto, non lo anticipano
- **Copertina** con la temperatura della casa
- **Copertina** con casa e acqua calda, ognuna con il valore che l'impianto sta
tenendo adesso e il suo obiettivo ("22,9 / 19,0 °C"), più il pallino di stato
come nella Home
- Indirizzo e token del bridge stanno nelle impostazioni dell'app (QSettings),
mai nel binario
+3 -1
View File
@@ -35,7 +35,9 @@ status, domestic hot water, and the house target temperature per zone.
water active) that show the state of the plant and change it in one tap, plus
the buttons for what has no state: legionella cycle and night mode for one
hour. The switches follow the plant — they never anticipate it
- **Cover page** showing the house temperature
- **Cover page** showing the house and the hot water, each with the value the
plant is keeping right now and its target ("22.9 / 19.0 °C"), plus a status dot
that matches the home screen
- Address and bridge token live in the app settings (QSettings), never in the
binary
- **Languages: English and Italian.** The interface follows the phone language by
Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 23 KiB

+49 -19
View File
@@ -3,6 +3,11 @@ import Sailfish.Silica 1.0
// Copertina: legge api.summary (context property C++), quindi non dipende
// dallo scope delle property della pagina principale.
//
// Due righe con l'etichetta davanti: "attuale / impostata" per la casa e per
// l'acqua. Prima erano frasi lunghe ("casa · obiettivo 19,0 °C", "ACS 53,4 °C ·
// obiettivo 55 °C") e sulla cover, che e' stretta, venivano tagliate a meta':
// il numero vero spariva proprio dove serve di sfuggita.
CoverBackground {
id: cover
@@ -11,6 +16,11 @@ CoverBackground {
return api.formatValue(v)
}
// "22,9 / 19,0 °C": attuale e impostata, con l'unita' una volta sola.
function coppia(attuale, impostata) {
return cover.t(attuale) + " / " + cover.t(impostata) + " °C"
}
// Colore del pallino: gli stessi criteri della Home (vedi MainPage.qml).
// Un dato vecchio e' ambra come un modo attivo: un dato vecchio non e' un
// dato buono, e la copertina e' il posto dove si guarda di sfuggita.
@@ -53,34 +63,54 @@ CoverBackground {
Column {
anchors.centerIn: parent
width: parent.width - 2 * Theme.paddingLarge
width: parent.width - 2 * Theme.paddingMedium
spacing: Theme.paddingMedium
Row {
width: parent.width
spacing: Theme.paddingSmall
Label {
width: parent.width
horizontalAlignment: Text.AlignHCenter
text: qsTr("House")
color: Theme.secondaryColor
font.pixelSize: Theme.fontSizeExtraSmall
width: parent.width * 0.32
anchors.verticalCenter: parent.verticalCenter
}
Label {
text: cover.coppia("zone1_temperature", "zone1_setpoint")
// Spenta quando i numeri sono vecchi: non deve sembrare fresca.
color: api.stale ? Theme.secondaryColor : Theme.primaryColor
text: cover.t("zone1_temperature") + " °C"
font.pixelSize: Theme.fontSizeHuge
font.pixelSize: Theme.fontSizeSmall
font.bold: true
elide: Text.ElideRight
width: parent.width - parent.width * 0.32 - parent.spacing
anchors.verticalCenter: parent.verticalCenter
}
}
Row {
width: parent.width
spacing: Theme.paddingSmall
Label {
text: qsTr("Water")
color: Theme.secondaryColor
font.pixelSize: Theme.fontSizeExtraSmall
width: parent.width * 0.32
anchors.verticalCenter: parent.verticalCenter
}
Label {
width: parent.width
horizontalAlignment: Text.AlignHCenter
text: qsTr("house · target %1 °C").arg(cover.t("zone1_setpoint"))
color: Theme.secondaryColor
font.pixelSize: Theme.fontSizeExtraSmall
truncationMode: TruncationMode.Fade
text: cover.coppia("dhw_current", "dhw_target")
color: api.stale ? Theme.secondaryColor : Theme.primaryColor
font.pixelSize: Theme.fontSizeSmall
font.bold: true
elide: Text.ElideRight
width: parent.width - parent.width * 0.32 - parent.spacing
anchors.verticalCenter: parent.verticalCenter
}
Label {
width: parent.width
horizontalAlignment: Text.AlignHCenter
text: qsTr("DHW %1 °C · target %2 °C").arg(cover.t("dhw_current")).arg(cover.t("dhw_target"))
color: Theme.secondaryColor
font.pixelSize: Theme.fontSizeExtraSmall
truncationMode: TruncationMode.Fade
}
}
+6 -1
View File
@@ -1,6 +1,6 @@
Name: harbour-aira
Summary: Control your Aira heat pump through a local bridge
Version: 0.6.3
Version: 0.6.4
Release: 1
Group: Qt/Qt
License: MIT
@@ -37,6 +37,11 @@ Address and token of the bridge live in the app settings (AppConfigLocation);
no personal data is stored in the binary.
%changelog
* Sun Oct 11 2026 Carlo <carlo@carlobaratto.it> - 0.6.4-1
- copertina: due righe con l'etichetta davanti, "Casa" e "Acqua", ognuna con
temperatura attuale / impostata ("22,9 / 19,0 °C"). Prima erano frasi lunghe
("casa · obiettivo 19,0 °C", "ACS 53,4 °C · obiettivo 55 °C") che sulla cover,
stretta, venivano tagliate a meta' e il numero vero non si leggeva
* Sun Oct 11 2026 Carlo <carlo@carlobaratto.it> - 0.6.3-1
- nuova icona: casa con l'onda calda dentro, scelta fra le quattro proposte in
scripts/icon_proposals.py. Ridisegnata a 344 px e rigenerata alle quattro
+14 -13
View File
@@ -370,6 +370,8 @@ TEXTS["en"].update({
"signature_lights": "Signature lights",
"save_and_test": "Save and test",
"cover_outdoor": "outside",
"cover_house": "House",
"cover_water": "Water",
})
TEXTS["it"].update({
@@ -411,6 +413,8 @@ TEXTS["it"].update({
"save_and_test": "Salva e prova",
"cover_outdoor": "esterna",
"night_one_hour": "Modalità notte per un'ora",
"cover_house": "Casa",
"cover_water": "Acqua",
})
@@ -561,19 +565,16 @@ def cover_screen() -> Image.Image:
d.ellipse([card[2] - 56, card[1] + 48, card[2] - 32, card[1] + 72], fill=OK)
d.line([(card[0] + 34, card[1] + 100), (card[2] - 34, card[1] + 100)],
fill=BTN_EDGE, width=2)
y = card[1] + 132
big = dec(23.0) + " °C"
d.text(((W - d.textlength(big, font=font(76, bold=True))) / 2, y),
big, font=font(76, bold=True), fill=PRIMARY)
y += 108
for lab, val in ((T("cover_target"), dec(19.0) + " °C"),
(T("cover_acs"), dec(51.0) + " °C"),
(T("cover_outdoor"), dec(18.0) + " °C")):
d.text((card[0] + 34, y), lab, font=font(24), fill=SECONDARY)
vw = d.textlength(val, font=font(24))
d.text((card[2] - 34 - vw, y), val, font=font(24), fill=PRIMARY)
y += 52
d.text((card[0] + 34, card[3] - 60), T("cover_footer"), font=font(22), fill=SECONDARY)
y = card[1] + 150
# due righe: etichetta a sinistra, "attuale / impostata" a destra
for lab, val in ((T("cover_house"), dec(22.9) + " / " + dec(19.0) + " °C"),
(T("cover_water"), dec(51.5) + " / " + dec(55.0) + " °C")):
d.text((card[0] + 34, y + 10), lab, font=font(22), fill=SECONDARY)
vw = d.textlength(val, font=font(30, bold=True))
d.text((card[2] - 34 - vw, y), val, font=font(30, bold=True), fill=PRIMARY)
y += 72
d.text((card[0] + 34, card[3] - 62),
T("cover_outdoor") + " " + dec(18.0) + " °C", font=font(22), fill=SECONDARY)
return img
+2 -2
View File
@@ -21,7 +21,7 @@ Q_DECL_EXPORT int main(int argc, char *argv[])
app->setOrganizationName(QStringLiteral("harbour"));
app->setApplicationName(QStringLiteral("aira"));
app->setApplicationVersion(QStringLiteral("0.6.3"));
app->setApplicationVersion(QStringLiteral("0.6.4"));
Settings settings;
ApiClient api(&settings);
@@ -36,7 +36,7 @@ Q_DECL_EXPORT int main(int argc, char *argv[])
// Prima riga del log: dice subito se il device sta girando la build nuova
// o una stale (trappola nota del build engine).
qDebug() << "harbour-aira v0.6.3 build" << __DATE__ << __TIME__;
qDebug() << "harbour-aira v0.6.4 build" << __DATE__ << __TIME__;
view->rootContext()->setContextProperty(QStringLiteral("appSettings"), &settings);
view->rootContext()->setContextProperty(QStringLiteral("api"), &api);
+47 -47
View File
@@ -64,87 +64,87 @@
<translation>errore HTTP %1</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="225"/>
<location filename="../src/airajson.cpp" line="238"/>
<source>No data</source>
<translation>Nessun dato</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="229"/>
<location filename="../src/airajson.cpp" line="242"/>
<source>Attention: one error</source>
<translation>Attenzione: un errore</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="230"/>
<location filename="../src/airajson.cpp" line="243"/>
<source>Attention: %1 errors</source>
<translation>Attenzione: %1 errori</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="232"/>
<location filename="../src/airajson.cpp" line="245"/>
<source>Away mode</source>
<translation>Assenza</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="234"/>
<location filename="../src/airajson.cpp" line="247"/>
<source>Night mode</source>
<translation>Modalità notte</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="236"/>
<location filename="../src/airajson.cpp" line="249"/>
<source>Heating at full power</source>
<translation>Riscaldamento al massimo</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="238"/>
<location filename="../src/airajson.cpp" line="251"/>
<source>Heating the hot water</source>
<translation>Sta scaldando l&apos;acqua</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="240"/>
<location filename="../src/airajson.cpp" line="253"/>
<source>Working</source>
<translation>In funzione</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="241"/>
<location filename="../src/airajson.cpp" line="254"/>
<source>Everything is fine</source>
<translation>Tutto regolare</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="251"/>
<location filename="../src/airajson.cpp" line="264"/>
<source>Attention: one error on the plant</source>
<translation>Attenzione: un errore sull&apos;impianto</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="252"/>
<location filename="../src/airajson.cpp" line="265"/>
<source>Attention: %1 errors on the plant</source>
<translation>Attenzione: %1 errori sull&apos;impianto</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="254"/>
<location filename="../src/airajson.cpp" line="267"/>
<source>Away mode: the house is saving energy.</source>
<translation>Modalità assenza: la casa sta risparmiando.</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="256"/>
<location filename="../src/airajson.cpp" line="269"/>
<source>Night mode is on.</source>
<translation>Modalità notte attiva.</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="258"/>
<location filename="../src/airajson.cpp" line="271"/>
<source>Boost: the house is heating at full power.</source>
<translation>Boost: la casa sta scaldando a pieno regime.</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="260"/>
<location filename="../src/airajson.cpp" line="273"/>
<source>The heat pump is heating the hot water.</source>
<translation>La pompa di calore sta scaldando l&apos;acqua calda.</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="262"/>
<location filename="../src/airajson.cpp" line="275"/>
<source>The heat pump is working.</source>
<translation>La pompa di calore sta lavorando.</translation>
</message>
<message>
<location filename="../src/airajson.cpp" line="263"/>
<location filename="../src/airajson.cpp" line="276"/>
<source>Relax: the heat pump is running smoothly.</source>
<translation>Relax: la pompa di calore funziona regolarmente.</translation>
</message>
@@ -337,22 +337,22 @@
<context>
<name>CoverPage</name>
<message>
<location filename="../qml/cover/CoverPage.qml" line="67"/>
<source>house · target %1 °C</source>
<translation>casa · obiettivo %1 °C</translation>
<location filename="../qml/cover/CoverPage.qml" line="74"/>
<source>House</source>
<translation>Casa</translation>
</message>
<message>
<location filename="../qml/cover/CoverPage.qml" line="76"/>
<source>DHW %1 °C · target %2 °C</source>
<translation>ACS %1 °C · obiettivo %2 °C</translation>
<location filename="../qml/cover/CoverPage.qml" line="98"/>
<source>Water</source>
<translation>Acqua</translation>
</message>
<message>
<location filename="../qml/cover/CoverPage.qml" line="89"/>
<location filename="../qml/cover/CoverPage.qml" line="123"/>
<source>Not updated · last %1</source>
<translation>Non aggiornato · ultimo %1</translation>
</message>
<message>
<location filename="../qml/cover/CoverPage.qml" line="90"/>
<location filename="../qml/cover/CoverPage.qml" line="124"/>
<source>outside %1 °C</source>
<translation>esterna %1 °C</translation>
</message>
@@ -488,109 +488,109 @@
<context>
<name>MainPage</name>
<message>
<location filename="../qml/pages/MainPage.qml" line="57"/>
<location filename="../qml/pages/MainPage.qml" line="62"/>
<source>No data yet</source>
<translation>Nessun dato</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="59"/>
<location filename="../qml/pages/MainPage.qml" line="64"/>
<source>Not updated · last %1</source>
<translation>Non aggiornato · ultimo %1</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="62"/>
<location filename="../qml/pages/MainPage.qml" line="67"/>
<source>Updated at %1</source>
<translation>Aggiornato alle %1</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="98"/>
<location filename="../qml/pages/MainPage.qml" line="107"/>
<source>Refresh</source>
<translation>Aggiorna</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="110"/>
<location filename="../qml/pages/MainPage.qml" line="139"/>
<location filename="../qml/pages/MainPage.qml" line="119"/>
<location filename="../qml/pages/MainPage.qml" line="148"/>
<source>Settings</source>
<translation>Impostazioni</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="196"/>
<location filename="../qml/pages/MainPage.qml" line="205"/>
<source>House</source>
<translation>Casa</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="198"/>
<location filename="../qml/pages/MainPage.qml" line="207"/>
<location filename="../qml/pages/MainPage.qml" line="216"/>
<source>target %1 °C</source>
<translation>obiettivo %1 °C</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="205"/>
<location filename="../qml/pages/MainPage.qml" line="214"/>
<source>Hot water</source>
<translation>Acqua calda</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="219"/>
<location filename="../qml/pages/MainPage.qml" line="228"/>
<source>Tap a value to adjust it</source>
<translation>Tocca un valore per regolarlo</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="227"/>
<location filename="../qml/pages/MainPage.qml" line="236"/>
<source>Quick actions</source>
<translation>Azioni rapide</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="239"/>
<location filename="../qml/pages/MainPage.qml" line="248"/>
<source>Boost</source>
<translation>Boost</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="248"/>
<location filename="../qml/pages/MainPage.qml" line="257"/>
<source>Back home</source>
<translation>Torna a casa</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="251"/>
<location filename="../qml/pages/MainPage.qml" line="260"/>
<source>Away mode off</source>
<translation>Assenza disattivata</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="254"/>
<location filename="../qml/pages/MainPage.qml" line="263"/>
<source>Away mode on</source>
<translation>Assenza attivata</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="262"/>
<location filename="../qml/pages/MainPage.qml" line="271"/>
<source>Commands</source>
<translation>Comandi</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="282"/>
<location filename="../qml/pages/MainPage.qml" line="291"/>
<source>Outside %1 °C · Thermostat %2 °C · Zones %3</source>
<translation>Esterno %1 °C · Termostato %2 °C · Zone %3</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="102"/>
<location filename="../qml/pages/MainPage.qml" line="111"/>
<source>Data</source>
<translation>Dati</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="130"/>
<location filename="../qml/pages/MainPage.qml" line="139"/>
<source>Bridge not configured. Open the settings and enter the server address and the token.</source>
<translation>Bridge non configurato. Apri le impostazioni e inserisci l&apos;indirizzo del server e il token.</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="240"/>
<location filename="../qml/pages/MainPage.qml" line="249"/>
<source>Starting DHW boost</source>
<translation>Avvio del boost ACS</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="106"/>
<location filename="../qml/pages/MainPage.qml" line="115"/>
<source>Plant</source>
<translation>Impianto</translation>
</message>
<message>
<location filename="../qml/pages/MainPage.qml" line="248"/>
<location filename="../qml/pages/MainPage.qml" line="257"/>
<source>Away mode</source>
<translation>Assenza</translation>
</message>