screenshot_from_file
Generate syntax-highlighted code screenshots from file paths with line selection and theme customization for documentation and sharing purposes.
Instructions
Screenshot code directly from a file path, with optional line range selection. Auto-detects language from file extension.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
endLine | No | End line number (optional) | |
filePath | Yes | Path to the code file | |
startLine | No | Start line number (1-indexed, optional) | |
theme | No | Color theme (dracula, nord, monokai, github-light, github-dark) |
Input Schema (JSON Schema)
{
"properties": {
"endLine": {
"description": "End line number (optional)",
"type": "number"
},
"filePath": {
"description": "Path to the code file",
"type": "string"
},
"startLine": {
"description": "Start line number (1-indexed, optional)",
"type": "number"
},
"theme": {
"description": "Color theme (dracula, nord, monokai, github-light, github-dark)",
"enum": [
"dracula",
"nord",
"monokai",
"github-light",
"github-dark"
],
"type": "string"
}
},
"required": [
"filePath"
],
"type": "object"
}