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

Incorrect visual selection with g:cycle_auto_visual=1 for subpairs with cursor on end_with #7

Open
kiryph opened this issue Aug 7, 2017 · 0 comments

Comments

@kiryph
Copy link

kiryph commented Aug 7, 2017

I have defined following rule for latex:

let g:cycle_default_groups_for_tex = [
  \   [['(:)',   '\left(:\right)',   '\mleft(:\mright)',   '\bigl(:\bigr)',   '\Bigl(:\Bigr)',   '\biggl(:\biggr)',   '\Biggl(:\Biggr)'],   'sub_pairs', 'hard_case', 'match_case'],
 \ ]

However, it does not work as expected in all circumstances. Consider this

(a+b)

Cursor on (. If I now cycle to the next item in the group, I get what I want:

\left(a+b\right)

However, the cursor remains on ( and cycling now to the next item leads to following result

\left\left(a+b\right\right)

The option g:cycle_auto_visual helps, but does not work correctly if I place the cursor on the closing delimiter:

cycle-auto-visual-on-end-with

Any suggestions to make this group work are helpful.

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

1 participant