Types of Widgets in Python
Widgets in Python:
Widgets are the building blocks of GUI programming and are used to display information or get input from the user. Some frequently used widgets are given in the table:
Widgets | Function |
---|---|
Frame | Used as a container to house other widjets and add borders. |
Label | To display text or images. |
Labelframe | By default, this frame displays a border and title. |
Button | Used to call a function when clicked |
Checkbutton | Used to create check box for toggling a value. |
Radiobutton | Used to create standard redio buttons. |
Entry | Used for sinnge line text entry which can be edited. |
Text | Used for multiple line text entry which can be edited. |
Message | Used for multiple line display text that can be styled. |
Combobox | To be a single line text entry with a drop down select list. |
Listbox | To create multiple line select lilst. |
Scrollbar | To create vertical or horizontal scroll. |
Scale | To create a sliding scale that can be clicked and dragged with mouse. |
Canvas | To draw lines, circles, arcs, ovals, and rectangles. |
Menu | To create menu bar for the top of the window, which includes parameters like "File", "edit", and "view". |