mirror of
https://github.com/TomSchimansky/CustomTkinter.git
synced 2023-08-10 21:13:13 +03:00
removed Settings class, moved settings to widgets and windows, added 'jusitfy' attribute to combobox and 'anchor' to optionmenu #528, added 'hover' attribute to all widgets and configure and cget methods, fixed missing attributes in configure
This commit is contained in:
@ -56,20 +56,6 @@ class App(customtkinter.CTk):
|
||||
self.textbox = customtkinter.CTkTextbox(self)
|
||||
self.textbox.grid(row=0, column=1, padx=(20, 10), pady=(20, 10), sticky="nsew")
|
||||
|
||||
# create optionemnu and combobox frame
|
||||
self.optionemnu_combobox_frame = customtkinter.CTkFrame(self)
|
||||
self.optionemnu_combobox_frame.grid(row=0, column=2, padx=(10, 10), pady=(20, 10), sticky="nsew")
|
||||
self.optionmenu_1 = customtkinter.CTkOptionMenu(self.optionemnu_combobox_frame,
|
||||
dynamic_resizing=False,
|
||||
values=["Value 1", "Value 2", "Value Long Long Long"])
|
||||
self.optionmenu_1.grid(row=0, column=0, padx=20, pady=(20, 10), sticky="ew")
|
||||
self.combobox_1 = customtkinter.CTkComboBox(self.optionemnu_combobox_frame,
|
||||
values=["Value 1", "Value 2", "Value Long....."])
|
||||
self.combobox_1.grid(row=1, column=0, padx=20, pady=(10, 10), sticky="ew")
|
||||
self.string_input_button = customtkinter.CTkButton(self.optionemnu_combobox_frame, text="Open CTkInputDialog",
|
||||
command=self.open_input_dialog)
|
||||
self.string_input_button.grid(row=2, column=0, padx=20, pady=(10, 10), sticky="ew")
|
||||
|
||||
# create radiobutton frame
|
||||
self.radiobutton_frame = customtkinter.CTkFrame(self)
|
||||
self.radiobutton_frame.grid(row=0, column=3, padx=(10, 10), pady=(20, 10), sticky="nsew")
|
||||
@ -118,6 +104,22 @@ class App(customtkinter.CTk):
|
||||
# create tabview
|
||||
self.tabview = customtkinter._CTkTabview(self)
|
||||
self.tabview.grid(row=1, column=3, columnspan=2, padx=(10, 20), pady=(10, 10), sticky="nsew")
|
||||
self.tabview.add("CTkTabview")
|
||||
self.tabview.add("Tab 2")
|
||||
self.tabview.add("Tab 3")
|
||||
|
||||
self.tabview.tab("CTkTabview").grid_columnconfigure(0, weight=1)
|
||||
self.optionmenu_1 = customtkinter.CTkOptionMenu(self.tabview.tab("CTkTabview"),
|
||||
dynamic_resizing=False,
|
||||
values=["Value 1", "Value 2", "Value Long Long Long"])
|
||||
self.optionmenu_1.grid(row=0, column=0, padx=20, pady=(20, 10))
|
||||
self.combobox_1 = customtkinter.CTkComboBox(self.tabview.tab("CTkTabview"),
|
||||
values=["Value 1", "Value 2", "Value Long....."])
|
||||
self.combobox_1.grid(row=1, column=0, padx=20, pady=(10, 10))
|
||||
self.string_input_button = customtkinter.CTkButton(self.tabview.tab("CTkTabview"),
|
||||
text="Open CTkInputDialog",
|
||||
command=self.open_input_dialog)
|
||||
self.string_input_button.grid(row=2, column=0, padx=20, pady=(10, 10))
|
||||
|
||||
# set default values
|
||||
self.sidebar_button_3.configure(state="disabled", text="Disabled CTkButton")
|
||||
|
Reference in New Issue
Block a user