-
Notifications
You must be signed in to change notification settings - Fork 137
Would it be possible to highlight words or line which are before or after cursor ? #71
Comments
This is what I've added in #60. |
Yes it’s on-going. I need to review several PRs and I’ve been a little busy lately but it should land ~soonish. |
This first commit allows to apply the hints to only the previous part of the cursor or what comes after. This commit doesn’t currently check the column, only the line. The next commit will add support for before / after on the current line and should also add support for a way to reduce apply hints only to the current line. This is an alternative implementation of #59. Relates to #71, #91.
This is now implemented in #93 and is going to be merged on |
Thanks :) |
That was one of the feature I was missing from easymotion, it's so great that it's now also available on hop ! I'm sorry to ask this but easymotion had another cool thing I was using also all the time, some motion operators for more precise jumps. For example, I was using those bindings all the time :
There is also another distinction with f and t:
These features may seem like a nice to have and maybe they are, but they add some more precision to your jumps and instead of doing a jump followed by a motion, if you know exactly where you want to go you can do both at the same time. It would be great to add for example a command HopWordEnd (AC / BC) and HopTillChar1 (AC / BC) What are your thoughts on this ? |
@Nico-Guyon It seems like this was being worked on in #48. |
@luiz00martins is it being worked on right now? I kinda got lost and if no one is looking into it I'm willing to do the work |
@FelipeLema It seems like this was being worked on by jhgarner on his fork, but looking by the age of the last commit, I think it was abandoned. It may be a good idea to, if not fork it, at least take a look at it to avoid repeated work. Also, by reading #59 and #60's close messages by phaazon, it seems like in his opinion these features are already sufficiently implemented, or were "superseded" by #93. I would disagree with that. For example, it seems like there's no separation between Nonetheless, it'd be best if you talked to @phaazon directly to get his opinion. This might avoid unnecessary work and help the future PR go in the right direction. |
It's less that the fork was abandoned and more that it had all the features I used and it sounded like phaazon had a better way of implementing it. For now, I use the "mergedall" branch of my fork although I hope to switch back to mainline hop once phaazon adds the remaining features. |
@jhgarner could you expand on the "remaining features"? are these currently work in progress? are they any specific pull requests? |
The remaining features that still need to be added from "mergedall" are basically the things mentioned a couple messages up ( #71 (comment)) and stuff like issue #125. It sounds like #123 is one of the pull requests needed to add these features in a more sustainable way. |
Damn, I completely missed the rest of the discussion; sorry for that. The idea of adding a For Clearly preserving the column is a low hanging fruit here. |
It is now possible to switch to either the beginning or the end position of a matched jump target. I’m going to close this PR as it contained a lot of elements. Please don’t hesitate to comment if you thing something is still missing (or open a PR for that specific thing, I’d rather like). Thank you. |
* docs: update to current implementation * docs: add manh_distance and readwise_distance
First thank you for this great plugin !
I was using easymotion until now and unfortunately it became unusable after enabling diagnostics since the labels are shortly parsed as the buffer is modified.
Hop is a great replacement for my usage of easymotion except for one thing: the ability to highlight before or after the cursor position.
For example with easymotion if you press:
<easymotion-prefix>w
it will highlight all words after the cursor<easymotion-prefix>b
it will highlight all words before the cursor<easymotion-prefix>
with j or k will highlight lines below or above the current lineThis is quite practical because if you know where you want to jump, it can show less labels.
Is it already possible with hop ?
If not would it be possible to add some functions for example HopWordNext, HopWordPrev, HopLineAbove, HopLineBelow ?
The text was updated successfully, but these errors were encountered: