Spaces:
Runtime error
Runtime error
Fix ui title size
Browse files
app.py
CHANGED
@@ -58,7 +58,7 @@ class TextGeneration:
|
|
58 |
self.model_name_or_path = "flax-community/t5-recipe-generation"
|
59 |
self.list_division = 5
|
60 |
self.point = "-"
|
61 |
-
self.h1_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Bold.ttf",
|
62 |
self.h2_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Bold.ttf", 50)
|
63 |
self.p_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Regular.ttf", 30)
|
64 |
set_seed(42)
|
@@ -100,7 +100,7 @@ class TextGeneration:
|
|
100 |
ws, hs = 120, 500
|
101 |
im_editable.text(
|
102 |
(ws, hs),
|
103 |
-
textwrap.fill(recipe["title"],
|
104 |
(61, 61, 70),
|
105 |
font=self.h1_font,
|
106 |
)
|
58 |
self.model_name_or_path = "flax-community/t5-recipe-generation"
|
59 |
self.list_division = 5
|
60 |
self.point = "-"
|
61 |
+
self.h1_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Bold.ttf", 75)
|
62 |
self.h2_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Bold.ttf", 50)
|
63 |
self.p_font = ImageFont.truetype("asset/fonts/PT_Serif/PTSerif-Regular.ttf", 30)
|
64 |
set_seed(42)
|
100 |
ws, hs = 120, 500
|
101 |
im_editable.text(
|
102 |
(ws, hs),
|
103 |
+
textwrap.fill(recipe["title"], 25),
|
104 |
(61, 61, 70),
|
105 |
font=self.h1_font,
|
106 |
)
|