From 8595ca0939a1d7a800d132ff5c7b09fe152ba506 Mon Sep 17 00:00:00 2001 From: Ace Date: Fri, 24 May 2019 00:59:46 +0200 Subject: [PATCH] Updated file for new features Switched from image-based weather-icons to font-based weather-icons. Added font names (and paths) for easier re-usage. --- Calendar/image_data.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/Calendar/image_data.py b/Calendar/image_data.py index 56bc876..469afe3 100644 --- a/Calendar/image_data.py +++ b/Calendar/image_data.py @@ -18,6 +18,10 @@ dpath = path+'days/' opath = path+'other/' fpath = path+'fonts/' +NotoSansCJK = 'NotoSansCJK/NotoSansCJKsc-' +NotoSans = 'NotoSans/NotoSans-SemiCondensed' +weather_font = 'WeatherFont/weathericons-regular-webfont.ttf' + weekday = im_open(opath+'weekday.png') eventicon = im_open(opath+'event.png') dateicon = im_open(opath+'today.png') @@ -129,12 +133,10 @@ weekday_pos = { } weathericons = { - '01d': 'wi-day-sunny', '02d':'wi-day-cloudy', '03d': 'wi-cloudy', - '04d': 'wi-cloudy-windy', '09d': 'wi-showers', '10d':'wi-rain', - '11d':'wi-thunderstorm', '13d':'wi-snow', '50d': 'wi-fog', - '01n': 'wi-night-clear', '02n':'wi-night-cloudy', - '03n': 'wi-night-cloudy', '04n': 'wi-night-cloudy', - '09n': 'wi-night-showers', '10n':'wi-night-rain', - '11n':'wi-night-thunderstorm', '13n':'wi-night-snow', - '50n': 'wi-night-alt-cloudy-windy' + '01d': '\uf00d', '02d': '\uf002', '03d': '\uf013', + '04d': '\uf012', '09d': '\uf01a', '10d': '\uf019', + '11d': '\uf01e', '13d': '\uf01b', '50d': '\uf014', + '01n': '\uf02e', '02n': '\uf013', '03n': '\uf013', + '04n': '\uf013', '09n': '\uf037', '10n': '\uf036', + '11n': '\uf03b', '13n': '\uf038', '50n': '\uf023' }