Skip to content

Latest commit

 

History

History
31 lines (20 loc) · 540 Bytes

SetStretching.md

File metadata and controls

31 lines (20 loc) · 540 Bytes

SetStretching

fpdf.set_stretching(stretching: float = 100.0)

Description

Sets horizontal font stretching.

Version

Since 1.7.3

Parameters

stretching:

Define horizontal stretching (scaling) in percents. Default value 100 (i.e. no stretching).

Example

# Arial regular 14
pdf.set_font('Arial')
# Set stretching to 50%, narrow text
pdf.set_stretching(50.0)

See also

SetFont, SetFontSize, GetStringWidth.