0
アンカーラベルの位置に問題がありました。 Kivyは中央/中央でこのコードを実行します。それは画面表示の一部です。kivyの入力テキストによるラベルの位置
with open('weatherdata.txt', encoding='utf-8') as weatherdata:
read_weatherdata = weatherdata.read()
label_position = AnchorLayout(anchor_x='right',
anchor_y='bottom')
label_settings = Label(text=read_weatherdata,
font_size='12sp',
size=(200, 200),
color=(0.4, 0.4, 0.4, 1))
label_position.add_widget(label_settings)
self.add_widget(label_position)
Ex。
Weather now in Warsaw, pl
Clouds: 20 %
Rain: 15 %
Wind speed: 2.6
Wind degree: 340
Humidity: 75 %
Temperature: 5.0 celsius
Max temperature: 5.0 celsius
Min temperature: 5.0 celsius
Weather status: few clouds