Comments (8)
Doesnt reproduce for me with fish version 3.7.0 and empty fish config, and I dont see how
prompt marking can possibly affect completion. Probably some interaction
with something else in your fish config, bisect it to find out.
from kitty.
I've tested with no fish config, thats’s why I included the shell command with -N
It doesn't happen in iTerm2 with shell integration enabled.
Simplified the reproduction:
- kitty --config NONE /opt/homebrew/bin/fish -N --login --interactive
- Run
printf "\033]133;A\007"; printf "\033]133;B\007"
- Type
g
->g++
will be shown as a completion - Click the mouse in the window (you don't need to, but it seems to trigger it. I've tested with the trackpad too)
- The completion will be triggered, but randomly the cursor goes back to before the first character. (and the completion isn't triggered)
It kinda looks like an issue with selection and/or focus.
It does not seem to reproduce with -o clear_all_mouse_actions=yes
. Any ideas what mouse mappings in kitty could cause it? I disabled all apps that could interfere with input.
Thanks for any pointers!
from kitty.
clicking the mouse will send fake arrow key press events to move the
cursor. These will trigger completion depending on how you have
completion setup. IIRC in fish the right arrow completes. There isnt
anything that can be done to avoid this, as far as I know.
from kitty.
Hm, that makes sense. The cursor doesn't move on click without prompt marks, interesting, so that explains why it only happens with them.
Also, my best guess, that something in my setup must be sending phantom mouse presses to the kitty window periodically then, that's why it sometimes autocompletes without mouse presses.
Thanks a lot for the fast response!
from kitty.
Ideally, fish would have some input function that moves the cursor right
without accepting an auto-suggestion. Then the kitty fish shell integration
could bind that function to some otherwise unused escape sequence and we
would not have this issue. However, there is no such function:
https://fishshell.com/docs/current/cmds/bind.html that I can see.
Even more ideally, fish would add a function that has semantics of
"move cursor to the cell number X on line number Y, where Y is counted
from the line that starts the prompt".
You can try requesting something along these lines, maybe the fish
developers will be kind enough to provide such a function.
from kitty.
As a band-aid, I've disabled the left click prompt event, while keeping the prompt marks working (which is what I needed)
Kitty could send commandline -f suppress-autosuggestion
before moving the cursor, but that would mean the completion would vanish. Though I think that's a little bit better behavior than the current one.
However, after some more debugging, this behavior exists in iTerm2 too, but you have to press alt to move the mouse.
from kitty.
Actually, there is commandline -C <cursor_position>
which sets the cursor position in the current buffer without accepting the suggestion.
from kitty.
from kitty.
Related Issues (20)
- update to python3.12 HOT 1
- Other options in detach_window HOT 2
- Error on start: "EGL: Failed to create window surface: Arguments are inconsistent" HOT 8
- hints kitten with customized processing crashes with slice out of bounds on certain input HOT 1
- Linux Libertine Mono doesn't load HOT 2
- Feature request: show date each window was created in `kitty @ ls`.
- keyboard protocol: clarification on locked modifiers HOT 6
- Support for ESC X character strings
- Cursor doesnt change HOT 6
- Editor configuration not respected when opening file hints HOT 4
- Add Yazi terminal file manager to the list of software implementing kitty's keyboard protocol
- Kitty paste_from_clipboard + <cmd-v> interaction HOT 1
- Kitty @ ls doesn't seem to match properly on mac os HOT 2
- an option for kitty @ send-text to fail if no terminals match HOT 1
- Font rendering HOT 2
- Feature request: tab_title_program HOT 1
- Missing modifier release events on window focus change HOT 2
- allow selecting and copying text using the keyboard HOT 3
- [fish shell integration] repaint removes text printed by fish key binding HOT 2
- Mouse pointer abnormally large under KDE Plasma 6 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kitty.