Paragraph
TheParagraph component renders complex text layouts with automatic line breaking and advanced typography.
| Name | Type | Description |
|---|---|---|
| paragraph | SkParagraph | Paragraph object |
| x | number | X coordinate |
| y | number | Y coordinate |
| width | number | Maximum width for layout |
Creating Paragraphs
ParagraphBuilder
UseParagraphBuilder to construct complex text layouts:
Paragraph Methods
TheSkParagraph interface provides methods for layout and measurement:
Layout
Measurements
Hit Testing
Line Metrics
Get detailed information about each line:Text Selection
Get bounding boxes for text ranges:Placeholders
Get positions of inline placeholders (for images, etc.):Text Styles
Basic Styling
Font Styling
Decorations
Shadows
Paragraph Styles
Text Alignment
Text Direction
Line Height
Max Lines
Rich Text Example
Create multi-styled text in a single paragraph:Related
- Text Rendering - Simple text rendering
- Fonts - Font management
- Paint Properties - Styling options