Added the use of OTF fonts

This commit is contained in:
Raykosan
2026-03-16 20:54:24 +03:00
parent 942535315a
commit cc800415bb
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -11,7 +11,7 @@ print("\033[93m🦊\033[0m \033[93mRaykoStudio - RS Save Image \033[92mLOADED\03
def get_font_list(font_dir):
if not os.path.isdir(font_dir):
return []
return [f for f in os.listdir(font_dir) if f.lower().endswith('.ttf')]
return [f for f in os.listdir(font_dir) if f.lower().endswith('.ttf', '.otf')]
def create_text_panel(width, height, text, font_path, font_size, text_color, bg_color):
panel = Image.new('RGB', (width, height), color=bg_color)
+1 -1
View File
@@ -11,7 +11,7 @@ print("\033[93m🦊\033[0m \033[93mRaykoStudio - RS Save Image Pair \033[92mLOAD
def get_font_list(font_dir):
if not os.path.isdir(font_dir):
return []
return [f for f in os.listdir(font_dir) if f.lower().endswith('.ttf')]
return [f for f in os.listdir(font_dir) if f.lower().endswith('.ttf', '.otf')]
def create_text_panel(width, height, text, font_path, font_size, text_color, bg_color):
panel = Image.new('RGB', (width, height), color=bg_color)