GCruz19 commited on
Commit
a4ee567
·
verified ·
1 Parent(s): 8748bba

Changed Arial to Notosans to fix error for pdf

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -13,8 +13,8 @@ def generate_pdf_from_chat(chat_history):
13
  pdf.add_page()
14
 
15
  # Register the Arial font (uploaded to the Space's fonts directory)
16
- pdf.add_font("Arial", "", "fonts/arial.ttf", uni=True)
17
- pdf.set_font("Arial", size=12)
18
 
19
  for user_msg, bot_msg in chat_history:
20
  pdf.multi_cell(0, 10, txt=f"User: {user_msg}", align='L')
 
13
  pdf.add_page()
14
 
15
  # Register the Arial font (uploaded to the Space's fonts directory)
16
+ pdf.add_font("NotoSans", "", "NotoSans-Regular.ttf", uni=True)
17
+ pdf.set_font("NotoSans","", size=12)
18
 
19
  for user_msg, bot_msg in chat_history:
20
  pdf.multi_cell(0, 10, txt=f"User: {user_msg}", align='L')