Feature hasn't been suggested before.
Describe the enhancement you want to request
Opencode's TUI has a default block cursor, it would be really nice to have bar/line cursor (like |) also.
Even better would be an option to just use whatever cursor style my terminal is already configured with.

Current behavior
- In regular Ghostty: cursor is a bar
| ✓
- In opencode TUI: cursor is a block █ (overrides my terminal setting)
I tried adding shell-integration-features = no-cursor in addition to cursor-style = bar to my Ghostty config as suggested in Ghostty discussions, but opencode still shows a block cursor.
What would be nice
Options to choose between:
- Block (current default)
- Bar/line (my preference)
- Underline (bonus)
- Terminal default (use whatever the terminal is configured with)
Technical details (discovered with AI assistance)
Note: The following technical analysis was done with the help of an AI assistant exploring the opencode codebase
Why this happens:
Opencode uses the charmbracelet/bubbles library for its TUI components. The cursor is hardcoded to "block" style in that library using color inversion (Reverse(true)).
Relevant code locations:
-
Upstream dependency - charmbracelet/bubbles/cursor/cursor.go
-
Opencode usage - internal/tui/components/chat/editor.go
Possible approaches:
- Request the upstream
charmbracelet/bubbles library add support for different cursor shapes
- Implement a custom cursor component in opencode that supports block/bar/underline styles
- Support DECSCUSR escape sequences for terminals that handle cursor styling natively
Similar issues in other projects
This isn't unique to opencode - other TUI apps have faced similar cursor override issues:
Related opencode issues
- Cursor blinking issue: Terminal cursor blinks in opencode even though it shouldn't
Environment
- Terminal: Ghostty
- Config tried:
cursor-style = bar + shell-integration-features = no-cursor
- Result: Still seeing block cursor in opencode TUI
Thanks for considering this! Let me know if you need any more info.
Feature hasn't been suggested before.
Describe the enhancement you want to request
Opencode's TUI has a default block cursor, it would be really nice to have bar/line cursor (like

|) also.Even better would be an option to just use whatever cursor style my terminal is already configured with.
Current behavior
|✓I tried adding
shell-integration-features = no-cursorin addition tocursor-style = barto my Ghostty config as suggested in Ghostty discussions, but opencode still shows a block cursor.What would be nice
Options to choose between:
Technical details (discovered with AI assistance)
Why this happens:
Opencode uses the
charmbracelet/bubbleslibrary for its TUI components. The cursor is hardcoded to "block" style in that library using color inversion (Reverse(true)).Relevant code locations:
Upstream dependency -
charmbracelet/bubbles/cursor/cursor.goReverse(true)to create the block effectOpencode usage -
internal/tui/components/chat/editor.goPossible approaches:
charmbracelet/bubbleslibrary add support for different cursor shapesSimilar issues in other projects
This isn't unique to opencode - other TUI apps have faced similar cursor override issues:
Claude Code: Has a similar issue where it overrides terminal cursor settings
Ghostty discussions: Multiple users have reported cursor style being overridden by TUI applications
Related opencode issues
Environment
cursor-style = bar+shell-integration-features = no-cursorThanks for considering this! Let me know if you need any more info.