format_range
Get formatting edits for specific lines or characters in a document using LSP range formatting. Apply formatting to functions, blocks, or selections without modifying the entire file.
Instructions
Get formatting edits for a specific range within a document via LSP (textDocument/rangeFormatting). Returns TextEdit[] for the selected lines/characters only. Use this when you want to format a function, block, or selection rather than the entire file. The edits are NOT applied automatically.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes | ||
| language_id | No | ||
| start_line | Yes | ||
| start_column | Yes | ||
| end_line | Yes | ||
| end_column | Yes | ||
| tab_size | No | ||
| insert_spaces | No |