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

Dynamic objects for verbs #218

Open
syntonym opened this issue May 3, 2015 · 3 comments
Open

Dynamic objects for verbs #218

syntonym opened this issue May 3, 2015 · 3 comments
Labels
Milestone

Comments

@syntonym
Copy link
Contributor

syntonym commented May 3, 2015

vim commands are implemented in a modular way, most (all?) "commands" do not simply "delete" but can be used to construct "sentences" like "delete line" or "delete word", "delete until next char 'x'". It is intuitiv to think of "verbs" and "nouns".

You can read about text objects here or in the official help

vai currently thas no concept of "nouns" or "verbs" or even "commands". It does have "states" like the "YankState" that basically would have the posibillity to "emulate" that kind of behaviour.

I suggest to implement a similar approach as vim: commands like "delete" and ranges that can be further divided into motions and text objects and possible more (it looks like "visual selection" can be used as "objects" too?).

This could also fix #217 by not remembering input/delete but "commands".

@stefanoborini
Copy link
Owner

needs advanced parsing and infrastructure. Probably too much at this stage, but the parser should be powerful enough to grant this level of power, at least if plugins want to take advantage of it.

I put it into backlog. unfeasible with current resources, but a vision for the future.

@stefanoborini stefanoborini added this to the Backlog milestone May 3, 2015
@syntonym
Copy link
Contributor Author

syntonym commented May 3, 2015

Would you accept pull requests that go into that direction?

@stefanoborini
Copy link
Owner

Absolutely.

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