-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle_pitft.css
More file actions
87 lines (74 loc) · 2.41 KB
/
Copy pathstyle_pitft.css
File metadata and controls
87 lines (74 loc) · 2.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
/*
* DVB Monitor - stylesheet for the Adafruit PiTFT (480x320)
*
* Same rules as style.css, retuned for a small screen you read from arm's length:
* bigger departure text, and everything around it shrunk to make room for it.
*
* There is very little spare height here. 12pt is the largest departure text that
* still fits 6 rows, a heading, the timestamp and the buttons -- with room around
* the buttons, which matters when they are touch targets -- into 320px.
* Go bigger and the bottom will be cut off - the app prints a warning on
* startup when the table no longer fits the window.
*
* See style.css for the fuller commentary; this file is the same rules with
* different numbers.
*/
/* ============================================================
* THE KNOBS
* ============================================================ */
/* the departure rows. the whole point of the screen, so it gets the space. */
QLabel[class="grid_cell"] {
font-size: 12pt;
color: #ffffff;
background-color: #1a1a1a;
border: 1px solid #2a2a2a;
padding: 2px;
}
/* the "# / Dest / t" headings. small, they only need to be readable once. */
QLabel[class="grid_header"] {
font-size: 9pt;
font-weight: bold;
color: #ffffff;
background-color: #333333;
border: 1px solid #555555;
padding: 2px;
}
/* the stop name. smaller than on the desktop, to buy rows their height back. */
QLabel[class="haltestelle_header"] {
font-size: 13pt;
font-weight: bold;
color: yellow;
}
/* the timestamp line. as small as stays legible. */
QLabel[class="footer"] {
font-size: 7pt;
color: #ffffff;
}
/* ============================================================
* EVERYTHING ELSE
* ============================================================ */
QMainWindow, QWidget {
background-color: #1a1a1a;
}
/* generous padding: these are touch targets on the PiTFT, not mouse targets */
QPushButton {
background-color: #333333;
color: #ffffff;
border: 1px solid #555555;
padding: 6px;
}
QPushButton:pressed {
background-color: #555555;
}
/* stop name when the API failed but old departures are still on screen */
QLabel[class="haltestelle_header_stale"] {
font-size: 13pt;
font-weight: bold;
color: #cc9900;
}
/* stop name when the API failed and there is nothing left to show */
QLabel[class="haltestelle_header_error"] {
font-size: 13pt;
font-weight: bold;
color: #ff6666;
}