Button

class pyto_ui.Button(type: ButtonType = SYSTEM, title: str = '', image: Image = None)

A control that executes your custom code in response to user interactions. To add an action, set action.

For types of buttons, see Button Type constants.

property font: Font

The font to be applied to the text.

Return type:

pyto_ui.Font

property image: Image

The image displayed on the button. Can be a PIL image or an UIKit symbol image. For more information about symbols, see image_with_system_name().

Return type:

PIL.Image.Image

property menu_primary_action: bool

Show the context menu attached to the button as the primary action. Default is False. See menu().

Return type:

bool

property subtitle: str

The title of the button.

Return type:

str

property title: str

The title of the button.

Return type:

str

property title_color: Color

The color of the title.

Return type:

pyto_ui.Color