diff --git a/api/services/poster.py b/api/services/poster.py index acbc43c..e77cce2 100644 --- a/api/services/poster.py +++ b/api/services/poster.py @@ -911,7 +911,7 @@ class PosterService: "width": canvas_width - 100, "height": 60 if key != 'content' else 120, "fill": config['fill'], - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": config['fontWeight'], "fontSize": config['fontSize'], "text": text_content, @@ -1100,7 +1100,7 @@ class PosterService: "fill": "#ffffff", "stroke": "#001e50", "strokeWidth": 4, # 与VibrantTemplate一致的描边宽度 - "fontFamily": "Arial Black, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial Black, sans-serif", "fontWeight": "bold", "fontSize": title_size, "text": title, @@ -1172,7 +1172,7 @@ class PosterService: "height": subtitle_size + 15, "fill": "#ffffff", "shadow": "rgba(0, 0, 0, 0.7) 2px 2px 5px", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": subtitle_size, "text": slogan, @@ -1297,7 +1297,7 @@ class PosterService: "width": width, "height": font_size + 10, "fill": "#ffffff", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": font_size, "text": f"• {item}", @@ -1330,7 +1330,7 @@ class PosterService: "height": price_size + 20, "fill": "#ffffff", "shadow": "rgba(0, 0, 0, 0.7) 2px 2px 5px", - "fontFamily": "Arial Black, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial Black, sans-serif", "fontWeight": "bold", "fontSize": price_size, "text": f"¥{price}", @@ -1379,7 +1379,7 @@ class PosterService: "height": ticket_size + 10, "fill": "#ffffff", "shadow": "rgba(0, 0, 0, 0.5) 1px 1px 3px", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": ticket_size, "text": ticket_type, @@ -1410,7 +1410,7 @@ class PosterService: "width": width // 2, "height": font_size + 5, "fill": "#ffffff", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": font_size, "text": tag, @@ -1434,7 +1434,7 @@ class PosterService: "width": width // 2, "height": font_size + 5, "fill": "#ffffff", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": font_size, "text": pagination, @@ -1576,7 +1576,7 @@ class PosterService: "height": price_size + 20, "fill": "#ffffff", "shadow": "rgba(0, 0, 0, 0.7) 2px 2px 5px", - "fontFamily": "Arial Black, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial Black, sans-serif", "fontWeight": "bold", "fontSize": price_size, "text": f"¥{price}", @@ -1606,7 +1606,7 @@ class PosterService: "width": suffix_estimated_width, "height": suffix_size + 5, "fill": "#ffffff", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": suffix_size, "text": suffix_text, @@ -1666,7 +1666,7 @@ class PosterService: "height": ticket_size + 10, "fill": "#ffffff", "shadow": "rgba(0, 0, 0, 0.5) 1px 1px 3px", - "fontFamily": "Arial, sans-serif", + "fontFamily": "兰亭粗黑简, 微软雅黑, Microsoft YaHei, PingFang SC, Hiragino Sans GB, Arial, sans-serif", "fontWeight": "normal", "fontSize": ticket_size, "text": ticket_type,