awlight ttk theme

Current Version: 7.8 (2020-3-8)

Available at:

bll 2019-11-30: Version 7.0 splits out the theme specific data into separate files.

bll 2019-11-23: Version 6.0 adds the winxpblue scalable theme.

bll 2019-11-19: Version 5.0 features an additional scaling setting for use by the application, and the ability to create a scaled style, giving different graphics sizes for the same theme using the new style.

bll 2019-10-4: With version 4.0, support for other themes has been added. A scalable 'black' theme has been implemented.

bll 2019-10-7: With version 3.0, if tksvg is present, the graphics will scale according to the tk scaling setting.

bll 2018-9-1: See also: awdark ttk theme. Uses graphics for the checkbuttons and radiobuttons. The notebook tab top color is created dynamically. Everything else is based on the clam theme.

  • Focus box around notebook tabs is larger.
  • Focus box for checkbuttons and radiobuttons covers both the indicator and the text.
  • Includes helper routines to set the colors for menu, listbox and text.

On Mac OS X for versions prior to 8.6.10, to override the aqua styled scrollbars, use:

ttk::scrollbar .sb -style Vertical.TScrollbar
ttk::scrollbar .sb -style Horizontal.TScrollbar

The -style option must be present when the scrollbar is created, an aqua scrollbar cannot be reconfigured.

 Application Scaling

In order to match the theme graphics size to the font size, the application can:

   tk scaling 1.3888 ; # set the tk scaling appropriate to the user's computer

   set sz1 [font metrics TkDefaultFont -ascent] ; # the default font size for Tk
   set sz2 [font metrics appfont -ascent]       ; # the application font default size
   set scale [expr {double(sz2)/double(sz1)}]   ; # calculate the scaling ratio
   package require awthemes
   ::themeutils::setThemeColors awdark \
       scale.factor $scale
   package require awdark 

 Scaled Styles

Same theme, different styles, different graphics sizes:

A new style with appropriately sized graphics can be created. For example, the application may have a base application font size used everywhere, and an alternate sized font for data listings.

The application can then:

  package require awdark
  if { [info commands ::ttk::theme::[ttk::style theme use]::scaledStyle] ne {} } {
    ::ttk::theme::[ttk::style theme use]::scaledStyle Listing mainfont listingfont

Then the data listings are created using Listing.TCheckbutton, Listing.TCombobox, etc. which match the font size specified.

All of the Listing.* widgets have re-configured graphics sizes to match the specified font.

 Change Log

7.8 (2020-308)

  • set listbox and text widget highlight color, highlight background color.

7.7 (2020-1-17)

  • fix crash when tksvg not present.
  • improve awdark border colors.

7.6 (2019-12-7)

  • better grip design

7.5 (2019-12-4)

  • reworked all .svg files.
  • cleaned up notebook colors.
  • fixed scaling issue with scaled style scaling.
  • fixed combobox scaling.
  • fixed scrollbar arrows.
  • scaled combobox listbox scrollbar.

7.4 (2019-12-3)

  • added hasImage routine for use by checkButtonToggle
  • Fix menu highlight color

7.3 (2019-12-2)

  • fix spinbox scaled styling

7.2 (2019-12-2)

  • setBackground will not do anything if the background color is unchanged.
  • fixed a bug with graphical buttons.
  • make setbackground more robust.

7.1 (2019-12-1)

  • fix border/padding scaling, needed for rounded buttons/tabs.

7.0 (2019-11-30)

  • clean up .svg files to use alpha channel for disabled colors.
  • calculate some disabled colors.
  • fix doc.
  • split out theme specific code into separate files.
  • Fix scaledStyle set of treeview indicator.
  • make the tab topbar a generalized option.
  • merge themeutils package
  • clean up notebook tabs.
  • winxpblue: notebook tab graphics.
  • winxpblue: disabled images.
  • black: disabled cb/rb images.
  • black: add labelframe color.

6.0 (2019-11-23)

  • fix !focus colors
  • slider border color
  • various styling fixes and improvements
  • separate scrollbar color
  • optional scrollbar grip
  • button images are now supported
  • added winxpblue scalable theme
  • fixed missing awdark and awlight labelframe


  • add more colors to support differing spinbox and scroll arrow colors.
  • awlight, awdark, black theme cleanup
  • rename menubutton arrow .svg files.
  • menubutton styling fixes


  • rewrite so that the procedures are no longer duplicated.
  • rewrite set of arrow height/width and combobox arrow height.
  • Add scaledStyle procedure to add a scaled style to the theme.
  • Added a user configurable scaling factor.


  • rewrite pkgIndex.tcl


  • fix scaling of images.
  • adjust sizing for menu checkbutton and radiobutton.
  • add support for flexmenu.


  • breaking change: renamed tab.* color names to*
  • fix bugs in setBackground and setHighlight caused by the color renaming.
  • fix where the hover color for check and radio buttons is set.


  • add support for other clam based themes.
  • breaking change: the .svg files are now loaded from the filesystem in order to support multiple themes.
  • breaking change: All of the various colors and derived colors have been renamed.
  • awdark/awlight: Fixed empty treeview indicator.
  • added scalable 'black' theme.


  • Allow user configuration of colors.


  • Breaking change: The package name has been renamed so that 'package require awdark' works.
  • Support for tksvg has been added. New graphics have been added to support tksvg, and the graphics will scale according to the 'tk scaling' setting. 'tk scaling' must be set prior to the package require statement.
  • demottk.tcl has been updated to have scalable fonts. The 'tk scaling' factor may be specified on the command line: demottk.tcl <theme> [-scale <tk-scaling>]


  • Fix mac colors


  • Added missing TFrame style setup.


  • Some cleanup for text field background.


  • Added padding for Menu.TCheckbutton and Menu.TRadiobutton styles


  • Added support for flexmenu.
  • Fixed listbox frame.


  • Added Menu.TCheckbutton and Menu.TRadiobutton styles to support menu creation.


  • Add setBackground(), setHighlight() routines. If wanted, these require the colorutils package.
  • Remove the 'option add' statements and use a bind to set the combobox's listbox colors.
  • Merge awdark and awlight themes into a single package.
  • More color cleanup.
  • Make notebook top bar use dynamic colors.

1.1: change button anchor to default to center to follow majority of themes

::ttk::theme::awlight::setMenuColors .menuwidget

Sets the menu colors and also changes any checkbutton and radiobutton types to use thematic images. Run this after adding all the menu items to the menu.

Side effect: The menu will have -hidemargin set to true.

If you don't want the thematic images, run it before adding your menu items (and set -hidemargin back to false).

::ttk::theme::awlight::setTextColors .textwidget ?-dark?

Sets the text widget colors. If -dark is specified, the darker background color (as for entry) will be used.

::ttk::theme::awlight::setListboxColors .listboxwidget

Sets the listbox widget colors.

::ttk::theme::awdark::setBackground color

Changes the background color and all other colors to match. (like tk_setPalette). This will also call setTextColors, setListboxColors and setMenuColors on all registered widgets.

::ttk::theme::awdark::setHighlight color

Changes the highlight color.


After: ::ttk::theme::[ttk::style theme use]::setBackground #9fe6e8


Jeff Smith 2019-07-04 : Below is an online demo using CloudTk

See also: List of ttk Themes