Questions tagged [ttkwidgets]

A collection of widgets for Tkinter's ttk extensions by various authors.

98 questions
3
votes
2 answers

How to expand ttk notebook label or tab button to fill window

I want to expand label to fill window For example we use in tk button parent.columnconfigure(0, weight=1) button.grid(sticky='ew') Can we do something like this to expand both label name to capture all available screen And my second question :…
Manish Pushpam
  • 146
  • 2
  • 16
2
votes
1 answer

How can I change the properties of a Pyplot axis by using a checkbutton?

I tried to display different data in a pyplot depending on the selection from a Ttk.checkbutton. For simplicity, in the example I will only try to change the title. import tkinter as tk from tkinter import ttk import matplotlib.pyplot as plt from…
Markus L
  • 23
  • 5
2
votes
1 answer

Code slow when creating treeview of 100000+ items

Below is a snippet of code I had been working on a few months back but only now is it needed. I believe the main part of it is some code I ammended from a SO post but I lost the URL. Eitherway, I had forgotten how slow it is when hundreds of…
David
  • 127
  • 3
  • 10
2
votes
1 answer

How to apply rowheight dynamically in tkinter Treeview

How to set dynamically rowheight in Treeview widget of tkinter? I mean if I am adding wrapped text into the row then how can I set that particular row's height without affecting other rows' heights. Image 1 is the Treeview object created without…
2
votes
0 answers

Tkinter Treeview style

Why my table isn't changing style according to what I defined? I tried using style and map and it didn't change anything. It seems that the only thing that works is the Theme configuration. also the scroller isn't show in the Treeview. from tkinter…
User1
  • 85
  • 2
  • 15
2
votes
1 answer

How to change just one side border width of a ttk.Entry?

I am trying to display a sudoku layout with tkinter grid and ttk entries (maybe, I am not using the right approach to achieve it). I would like to know if the style option of ttk entry has any way to change the border of just one side. I have…
2
votes
2 answers

How to change row color when mouse over? Tkinter Treeview

I have been working with the Tkinter ttk.Treeview widget lately and I have been able to change a lot the widget's style using a ttk.Style, but sadly I am unable to find a solution to this problem: How can I change the item's colour when the…
2
votes
1 answer

how to make custom messagebox in python tkinter?

I am making a custom messagebox widget.My work is under process.But i cant make it as real as Tkinter Messagebox in terms of functionality. Here is my Code. from tkinter import * from tkinter.ttk import Style,Frame as fp class messagebox(): def…
Hacker6914
  • 247
  • 1
  • 9
1
vote
1 answer

Weird interaction of cget() in tkinter.ttk

Been playing out with tkinter until I stumble upon this. Apparently, it seems that the ttk.Entry does not recognize the configured state until the state is printed. My code is as follow: import tkinter as tk from tkinter import ttk def…
1
vote
1 answer

I want to add a button with a image using tkinter, but my img is too big. How can I resize it, but display it as a png?

I'm learning python and tkinter from scratch, by my own. I have this button: info = tk.PhotoImage(file= "./assets/info.png") boton_info = ttk.Button(f2, width=30, image= info) boton_info.grid(row=2, column=3, sticky="nwe", padx=15) I want to…
Mateo R
  • 48
  • 7
1
vote
1 answer

How to create a subclass of ttk.Button correctly (class function doesnt work)?

I want to create Buttons with a text and define a function that prints me the text on the monitor when i press the button. Everything works well without classes: from tkinter import * from tkinter import ttk def PressButton(): …
1
vote
1 answer

PYTHON - How to change data entry state to normal?

I can disable the calendar widget with the 'Disable' button, but if I want to reactivate it, I get the following error: tkinter.TclError: unknown option "-normal" If i try to use the calendar.config(state="normal") command, I get the following…
Panama
  • 21
  • 3
1
vote
1 answer

Tkinter ttk update label style

I am trying to update the of the background color of a text label. For this I am using the ttk module of tkinter. For some reason it doesn't want to execute the config.xx(style="xx.TLabel. from tkinter import * from tkinter import ttk win =…
Joost
  • 13
  • 2
1
vote
0 answers

Frames in TKinter Bootstrap

I am trying to create a frame in my window using Tkinter Bootstrap - I can't see it appearing, although the text does show up. From what I can see from the demo, the frame should be a slightly lighter colour. Am I doing this right? import…
1
vote
1 answer

Avoid autocompleting when two keys are pressed at once with ttk.widgets.autocomplete

I'm trying to create a form using ttk.widgets library. When using AutocompleteEntry, I noticed that if I don't press only one key at a time the entry is autocompleted with the first match from the first two keys I pressed (when I release the keys it…
Herberts
  • 68
  • 5
1
2 3 4 5 6 7