Tk Source Code

View Ticket
Login
Ticket UUID: 4d2baa56c8215d5081a47c61b32ad8ec2817a012
Title: Improve the look of the ttk::spinbox widgets in the built-in themes
Type: Patch Version: all
Submitter: nemethi Created on: 2025-11-22 17:42:52
Subsystem: 88. Themed Tk Assigned To: nemethi
Priority: 5 Medium Severity: Minor
Status: Closed Last Modified: 2025-11-24 11:02:24
Resolution: Fixed Closed By: nemethi
    Closed on: 2025-11-24 11:02:24
Description:

The arrows of the ttk::spinbox widget in the themes alt, default, clam, and classic are currently ridiculously tiny:  On an unscaled display the arrows are 3x2 px small in a 10x9 px box in the case of the alt theme, and 5x3 px in a 11x9 px box in the case of the other three themes.

By inserting just one line into the files ttkDefaultTheme.c, ttkClamTheme.c, and ttkElements.c, the above-mentioned dimensions will become: 5x3 px in a 12x10 px box for the alt theme, and 7x4 px in a 13x10 px box for the other three themes.  Note that the Tk core spinbox widget has the same arrow size (of 7x4 px).  The result of this change will be a significant improvement of the appearance of the ttk::spinbox widgets in all four themes.

User Comments: nemethi (claiming to be Csaba Nemethi) added on 2025-11-24 11:02:24:

Fixed by commits [32c40c03], [d7645c62], and [f458548a]. Closing the ticket.


nemethi (claiming to be Csaba Nemethi) added on 2025-11-22 17:54:27:

I have attached the file diff.txt containing the proposed patch and a small fix in the Widget Demo.


nemethi (claiming to be Csaba Nemethi) added on 2025-11-22 17:44:51:

Assigned to myself.


Attachments: