v.0.3.2 font 8x8 16x16 pretty

This commit is contained in:
tiijay
2025-10-24 12:09:57 +02:00
parent 9fcc7712e6
commit fcc23a2ff5
5 changed files with 2042 additions and 1900 deletions

View File

@@ -22,6 +22,21 @@ def char_width(char_matrix) -> int:
return cw
def font_height(font) -> int:
"""Höhe in Pixeln eines Fonts
Args:
font ([int]): der Font für den die Höhe bestimmt wird
Returns:
int: Höhe in Pixeln
"""
# wir nehmen uns ein Zeichen des Fonts
# die Anzahl der Werte entspricht der Höhe in Pixeln
return len(font['a'])
def shift_letter_right(char, letter, debug=False) -> bool:
"""Prüfe ob das Zeichen auch komplett nach rechts gezogen ist