Label

Labels display text to users

class kivycupertino.uix.label.CupertinoLabel(*args: Any, **kwargs: Any)

iOS style Label

../_images/demo3.png
bold = False

If text CupertinoLabel is bold

../_images/bold.png

Python

CupertinoLabel(bold=True)

KV

CupertinoLabel:
    bold: True
color = [0, 0, 0, 1]

Color of text CupertinoLabel

../_images/color3.png

Python

CupertinoLabel(color=(1, 0, 0, 1))

KV

CupertinoLabel:
    color: 1, 0, 0, 1
font_name = 'San Francisco'

Font of CupertinoLabel. To comply with iOS standard, use San Francisco or New York

../_images/font_name.png

Python

CupertinoLabel(font_name='New York')

KV

CupertinoLabel:
    font_name: 'New York'
font_size = '15sp'

Size of the font of CupertinoLabel

../_images/font_size2.png

Python

CupertinoLabel(font_size='20sp')

KV

CupertinoLabel:
    font_size: '20sp'
italic = False

If text of CupertinoLabel is italic

../_images/italic.png

Python

CupertinoLabel(italic=True)

KV

CupertinoLabel:
    italic: True
text = ' '

A StringProperty defining the text of CupertinoLabel

../_images/text3.png

Python

CupertinoLabel(text='Hello World')

KV

CupertinoLabel:
    text: 'Hello World'