ObaraEmmanuel / Formation

Tools for building gorgeous graphical user interfaces in tkinter
MIT License
277 stars 24 forks source link

[FEATURE] .get/.set for checkButton #47

Open mrx23dot opened 1 week ago

mrx23dot commented 1 week ago

For simplicity could we just access a checkButton with .get/.set(True) functions?

As an alternative to creating a variable for them. (framework could do this automatically)

Same way we can read/write content of Entry boxes without variables.

Creating variables is mandating, naming them, keeping them in sync etc.

Advanced users could still use variables.

ObaraEmmanuel commented 1 day ago

This would be nice but changing the signature of ttk.Chekbutton and any built in Tk widgets for that matter is beyond the scope of this framework. If you need this feature, try creating your own custom widget with those methods added.

mrx23dot commented 21 hours ago

Or framework could auto create a variable for each Chekbutton in the background. and mentioning the name on right panel variable = {name}var or a tickbox for 'auto variable' which disables the variable field and fills {name}var, seems intuitive. And simply reduces the work by half, not having to manage variables too.

I would imagine this is the most common use case, or user could override it if needed.