Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Week 6 - CustomTkinter Quiz

Total questions: 15

Worksheet time: 8mins

Name
Class
Date
1.

What does the mainloop() function do?

a)

Closes the GUI

b)

Creates buttons

c)

Starts the GUI event loop

d)

Sets the title

2.

What method is used to set the size of the window?

a)

set_size()

b)

geometry()

c)

resize()

d)

dimensions()

3.

What parameter is used to assign an action to a CTkButton?

a)

set_event

b)

on_click

c)

command

d)

bind

4.

What is the correct syntax to change label text dynamically?

a)

label.update()

b)

label.config()

c)

label.configure(text="new")

d)

label.change("new")

5.

What is the purpose of pack() in CustomTkinter?

a)

Create padding

b)

Arrange widgets in a window

c)

Import widgets

d)

Close the app

6.

What does pady=10 do?

a)

Adds horizontal space

b)

Adds vertical padding

c)

Creates a margin

d)

Sets text position

7.

What is the purpose of CTkFrame?

a)

Store data

b)

Display a message

c)

Group and organize widgets

d)

Create an image

8.

Which of these makes the frame expand to fill space?

a)

pack(fill="none")

b)

expand=True

c)

geometry()

d)

corner_radius=0

9.

What is corner_radius used for?

a)

Font styling

b)

Button sizing

c)

Roundness of corners

d)

Border color

10.

Which property is used to add space outside a widget horizontally?

a)

pady

b)

padx

c)

marginx

d)

offsetx

11.

What is the purpose of fill="both"?

a)

Fills only width

b)

Fills only height

c)

Fills both width and height

d)

Fills with color

12.

What does textbox.insert("0.0", "Hello") do?

a)

Inserts at the end

b)

Replaces all content

c)

Inserts at the beginning

d)

Deletes content

13.

How do you make a textbox read-only?

a)

textbox.readonly()

b)

textbox.configure(state="disabled")

c)

textbox.lock()

d)

textbox.freeze()

14.

What is required to use CTkImage?

a)

tkinter.image

b)

PIL.Image

c)

opencv

d)

pngreader

15.

Which method resizes an image in PIL?

a)

resize()

b)

stretch()

c)

scale()

d)

zoom()