## Define custom user panels for the Raspberry Pi Python console for WeatherFlow
## Tempest and Smart Home Weather stations.
## Copyright (C) 2018-2022 Peter Davis
## This program is free software: you can redistribute it and/or modify it under
## the terms of the GNU General Public License as published by the Free Software
## Foundation, either version 3 of the License, or (at your option) any later
## version.
## This program is distributed in the hope that it will be useful, but WITHOUT
## ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
## FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
## details.
## You should have received a copy of the GNU General Public License along with
## this program. If not, see .
## customPanels.kv
## =============================================================================
## TIDES PANEL AND BUTTON
## =============================================================================
:
PanelBackground:
_panelTitle: 'Tides'
Image:
keep_ratio: 1
allow_stretch: 0
source: 'icons/misc/rainIntensity' + app.scaleSuffix
pos_hint: {'x': 0, 'y': 0}
Label:
id: tides_label
text: ''
pos_hint: {'x': 0, 'y': 0}
size_hint: (1, 1)
font_name: 'fonts/Inter-Light.ttf'
font_size: dp(20 * app.scaleFactor)
color: utils.rgba('#c8c8c8ff')
valign: 'center'
halign: 'center'
markup: 1
## Time and date
TimeDateField:
text: app.CurrentConditions.System['Date']
pos_hint: {'x': 0/262, 'y': 24/202}
size_hint_x: (262/262)
TimeDateField:
text: app.CurrentConditions.System['Time']
pos_hint: {'x': 0/262, 'y': 3/202}
size_hint_x: (262/262)
:
PanelButton:
text: 'Tides'
on_release: app.CurrentConditions.switchPanel(self)