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

[RFC] Add mappings for first and last text objects in current line? #84

Open
wellle opened this issue Aug 22, 2014 · 3 comments
Open

[RFC] Add mappings for first and last text objects in current line? #84

wellle opened this issue Aug 22, 2014 · 3 comments
Labels

Comments

@wellle
Copy link
Owner

wellle commented Aug 22, 2014

Inspired by #80.

It could be useful to have mappings like

  • ciF" to change inside the first quotes in the current line
  • ciL" to change inside the last quotes in the current line

This should not be confused with the current word last meaning previous.

I think the current L and N mappings are not really useful, so I think we could use F and L for this.

Any comments?

@wellle
Copy link
Owner Author

wellle commented Aug 25, 2014

Also a count could be used to select the second c2iF" or penultimate c2iL" text object in the current line.

@arkwright
Copy link

A slight tangent, but I think I would prefer l and n to always select the next proper quote, similar to the functionality of L and N. I almost never want the pseudo-quote. Ideally I could then do:

cin'[some changes]
cin'[some changes]
cin'[some changes]

... to change every quoted string on a line.

This would better free up L and N so that you can implement the F and L functionality described above, without removing the utility of L and N.

I do think that the F and L mappings would be useful, but I don't anticipate using them very much. It's one of those things where if I have it available, it might creep into my Vim workflow, but it might take a while. It's not much harder to type $cil' instead of ciL'. It's also less to memorize.

@wellle
Copy link
Owner Author

wellle commented Sep 2, 2014

Solid points. Thinking about it I can't remember using any quote text objects to operate on pseudo quotes. I will consider your suggestion. 👍

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

No branches or pull requests

2 participants