Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could the avy-goto-line be configured for different directions? #106

Closed
ReneFroger opened this issue Oct 9, 2015 · 8 comments
Closed

Could the avy-goto-line be configured for different directions? #106

ReneFroger opened this issue Oct 9, 2015 · 8 comments

Comments

@ReneFroger
Copy link

For example, [] is the cursor.

1
2
3
4 []
5
6
7
8

When calling avy-goto-line-down, the keys to navigate are only appearing on line 5-6-7-8.
When calling avy-goto-line-up, the keys to navigate are only appearing on line 1-2-3.

I knew this is possible with Vim's Easymotion.

Would that be possible with Avy? With avy-goto-line, I got too many keys in both directions up and down, especially on a 2560x1600 16:10 screen 😄

@ReneFroger
Copy link
Author

I was wondering if I have described my issue clear enough? My English proficiency is not very well.

@abo-abo
Copy link
Owner

abo-abo commented Oct 15, 2015

This issue is clear. However, it's not trivial to implement and not a high priority. I'll get to those functions eventually.

@abo-abo
Copy link
Owner

abo-abo commented Oct 19, 2015

Thanks.

@ReneFroger
Copy link
Author

Just updated it, and it works. Thanks abo-abo!

@momomo5717
Copy link
Contributor

avy-goto-line-above/below returned the following error message
when I used three windows two of which had the same buffer and the other of which had another buffer.

save-restriction: Args out of range: 132723, 132771

It seems narrow-to-region in avy--line took the invalid region
due to non selected window's buffer whose (point-max) was 7222.

It would be helpful if you could add (avy-all-windows nil) to let* form of avy-goto-line-above/below.

Thank you.

abo-abo added a commit that referenced this issue Dec 3, 2015
* avy.el (avy-goto-line-above):
(avy-goto-line-below): Bind `avy-all-windows' to nil.

Re #106
@abo-abo
Copy link
Owner

abo-abo commented Dec 3, 2015

@momomo5717 thanks.

@momomo5717
Copy link
Contributor

Thank you for the fix!

It seems the candidates of avy-goto-line-above includes the current line when the cursor position isn't the beginning of the line
and avy-goto-line-below includes the current point.

Could avy-goto-line-above/below use (line-beginning-position)/(line-beginning-position 2) as end/beg to exclude the current line?

Thank you.

abo-abo added a commit that referenced this issue Dec 3, 2015
* avy.el (avy-goto-line-below): Exclude the current line

Re #106
@momomo5717
Copy link
Contributor

Thank you for adding this!
This feature is very useful.

Thank you again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants