documentation index ◦ reference manual ◦ function index

# theme.image_buttons

Function: | theme.image_buttons | (d):

Used to define buttons in terms of 5-tuples of image filenames. This expects its single parameter, d, to be a dictionary mapping untranslated button names to 5-tuples. Each 5-tuple should contain 5 filenames, giving the image used for the button when:

- The button is idle.
- The button is hovered.
- The button is selected and idle.
- The button is selected and hovered.
- The button is insensitive.

in that order.

    init python hide:
        buttons = dict()
        buttons["Start Game"] = (
            "theme/Start Game.idle.png",
            "theme/Start Game.hover.png",
            "theme/Start Game.selidle.png",
            "theme/Start Game.selhover.png",
            "theme/Start Game.idle.png",
            "theme/Start Game.insensitive.png"
            )

        theme.image_buttons(buttons)

documentation index ◦ reference manual ◦ function index