insert method

insert

Inserts a formatted text fragment into the collection at a given index.

def insert(self, index, text):
    ...
Parameter Type Description
index int The zero-based index at which formatted text fragment should be inserted.
text str The fragment text.

insert

Inserts a formatted text fragment into the collection at a given index.

def insert(self, index, text, font):
    ...
Parameter Type Description
index int The zero-based index at which formatted text fragment should be inserted.
text str The fragment text.
font Font The font of the text.

insert

Inserts a formatted text fragment into the collection at a given index.

def insert(self, index, text, font, foreground_color):
    ...
Parameter Type Description
index int The zero-based index at which the formatted text fragment should be inserted.
text str The fragment text.
font Font The font of the text.
foreground_color Color The foreground color of the text.

insert

Inserts a formatted text fragment into the collection at a given index.

def insert(self, index, text, font, foreground_color, background_color):
    ...
Parameter Type Description
index int The zero-based index at which formatted text fragment should be inserted.
text str The fragment text.
font Font The font of the text.
foreground_color Color The foreground color of the text.
background_color Color The background color of the text.

See Also