Giter VIP home page Giter VIP logo

Comments (7)

msomeone avatar msomeone commented on July 19, 2024 1

Added an option to select jump label assignment algorithm (i think what you prefer may be approximated with 'ViewportRelative' mode).

You may also consider playing with caret sensitivity option and staying with CaretRelative algo. It will help with assigning shortest movements near caret position, while maintaining stable labels for small caret position changes.

Please let me know if it solved the issue.

Also improved performance significantly.

from peasymotion.

msomeone avatar msomeone commented on July 19, 2024

Thanks for your feedback!

  1. Between first and second activation is cursor position the same?
  2. Which cancelation method do you use? ESC key? Arrows key? Something else?
  3. Are you using VsVim or ViEmu plugins or any other that may affect cursor position?

from peasymotion.

isc30 avatar isc30 commented on July 19, 2024

I just noticed that it only happens when the cursor position is different, is there any reasoning for that?

from peasymotion.

msomeone avatar msomeone commented on July 19, 2024

There is,
jump-labels are assigned using distance to cursor. Which is computed as abs(currentCursorPosition - jumpLabelPosition). This is done to assign "shortest" labels (if possible even "single" letter jumps) closer to current cursor position:

[hj] word1 [hk] word2 [ha] word3 [hs] word4
**[a]**word5 #word6 **[b]**word7 [c] word8
[kl] word9 [kj] word10 [kh] word11 [kf] word12
[xx] <- jump label
# - cursor
[a][b][c] - jump labels closest to cursor.

I may consider adding option to switch between current assignment logic and following one:
jump labels will be assigned consequently from top to bottom of visible text, ignoring current cursor position. Will this option help?

from peasymotion.

isc30 avatar isc30 commented on July 19, 2024

Yeah, multiple configuration options sound great, since the hard job is already done 😄
I usually use this from vscode and it works great: vscode-jumpy

from peasymotion.

msomeone avatar msomeone commented on July 19, 2024

Ok, gona add option for this

from peasymotion.

isc30 avatar isc30 commented on July 19, 2024

This sounds great!
Thanks

from peasymotion.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.