Smooth Cursor
Fluid caret movement with a lightweight, Kitty-inspired afterimage trail for Visual Studio Code.
Smooth Cursor uses VS Code's built-in smooth caret animation for the actual cursor movement, and draws brief, fading character-edge markers along its path. The real kitty terminal cursor trail is GPU-rendered and cannot be reproduced pixel-for-pixel through VS Code's official extension API. This extension does not inject styles, patch VS Code, or intercept typing.
Features
- Smooth caret movement during typing, Enter, arrow-key movement and navigation.
- Discrete afterimages that fade from the old position toward the new one.
- Kitty, Subtle and Snappy presets.
- Configurable trail length, duration, minimum movement, and color.
- Automatic light/dark theme colors; customizable
#RRGGBB color.
- A status-bar toggle and Command Palette commands.
- No telemetry, runtime dependencies, network calls, or editor CSS modifications.
Quick start
- Install Smooth Cursor.
- Open a text file and type or press Enter. Smooth Cursor supplies a default value of
on for the built-in setting editor.cursorSmoothCaretAnimation; explicitly configured user or workspace settings take precedence.
- Run Smooth Cursor: Choose Animation Preset in the Command Palette (
Ctrl+Shift+P, or Cmd+Shift+P on macOS) to select Kitty, Subtle, Snappy, or Off.
- Click Smooth Cursor in the status bar to switch afterimages on or off.
If the native caret is not smooth, run Smooth Cursor: Enable VS Code Smooth Caret (this explicitly changes your user setting).
Settings
| Setting |
Default |
Purpose |
smoothCursor.enabled |
true |
Master switch for extra trail effects |
smoothCursor.trail.enabled |
true |
Toggles the cursor trail |
smoothCursor.trail.length |
7 |
Afterimage count, 2–12 |
smoothCursor.trail.duration |
210 |
Fade time in ms, 60–600 |
smoothCursor.trail.minDistance |
1 |
Minimum moved cells; increase to reduce trails during typing |
smoothCursor.trail.color |
auto |
auto or a six-digit hex color |
smoothCursor.trail.maxJumpLines |
50 |
Ignore jumps spanning more than this many lines |
Limitations
- The VS Code extension API cannot draw a continuous, GPU-accelerated, curved or stretched Kitty cursor. Trails are discrete decorations attached to character edges.
- Empty lines cannot host a non-empty character-range decoration, but VS Code's native caret movement still animates on them.
- Line wrapping and proportional fonts may not match the simple document-position interpolation precisely.
- Only the active editor's primary caret is decorated; multi-cursor and selected-text states are deliberately left alone.
- The integrated terminal is not affected. For terminal-specific animation, use kitty itself.
Development
Requires Node.js 20+ and VS Code 1.96+.
npm install
npm test
npm run check
npm run package
Press F5 in a VS Code window containing this folder to launch an Extension Development Host, or use Extensions → … → Install from VSIX… for the packaged file.
Before Marketplace publication, set publisher in package.json to your real Publisher ID and rebuild the VSIX.
License
MIT