CTkCheckBox _ CustomTkinter
CTkCheckBox _ CustomTkinter
Ads by EthicalAds
CTkCheckBox
Example Code
def checkbox_event():
print("checkbox toggled, current value:", check_var.get())
check_var = customtkinter.StringVar(value="on")
checkbox = customtkinter.CTkCheckBox(app, text="CTkCheckBox", command=checkbox_event,
variable=check_var, onvalue="on",
offvalue="off")
Arguments
argument value
1 of 3 10/04/2025, 07:36
CTkCheckBox | CustomTkinter https://customtkinter.tomschimansky.com/documentation...
argument value
text string
2 of 3 10/04/2025, 07:36
CTkCheckBox | CustomTkinter https://customtkinter.tomschimansky.com/documentation...
Methods
• .configure(attribute=value, ...)
checkbox.configure(state="disabled")
• .cget(attribute_name)
Pass attribute name as string and get current value of attribute, for example.
text = checkbox.cget("text")
• .get()
• .select()
• .deselect()
• .toggle()
3 of 3 10/04/2025, 07:36