2

I'm creating a memory quiz app for people with dementia where it asks them about their day and they have to answer the question. A family/friend has to first fill in their memories which gets entered into a database.

I'm trying to increase the size of the text in the buttons, however the size of the button increases instead. I'm unsure on how to fix this. The answers are saved to an SQL database and retrieved from there. I am using a Guizero GUI. Here's my code:

box1=Box(Todays_Quiz, layout = "auto", width = 1000, height = 700)
emptyspace =Text(box1, text="")
question1= Text(box1, "What time did you wake up?", width = "fill")
question1.bg= "#A1A9A9"
question1.text_size= 20
emptyspace =Text(box1, text="""


""")

wakeupAnswer1 = get_q1_answers(0)
wakeupAnswer2 = get_q1_answers(1)
wakeupAnswer3 = get_q1_answers(2)

wakeup1 = PushButton(box1, width = 50, height = 5, text = wakeupAnswer1, command=change_score1) # correct answer
emptyspace =Text(box1, text="")
wakeup2 = PushButton(box1, width = 50, height = 5, text = wakeupAnswer2, command=next_question1)
emptyspace =Text(box1, text="")
wakeup3 = PushButton(box1, width = 50, height = 5, text = wakeupAnswer3, command=next_question1)

wakeup1.bg="#fa7a7a"
wakeup1.text_size = 15
wakeup2.bg="#fa7a7a"
wakeup2.text_size =15
wakeup3.bg="#fa7a7a"
wakeup3.text_size = 15
Ben the Coder
  • 539
  • 2
  • 5
  • 21

0 Answers0