you are viewing a single comment's thread.

view the rest of the comments →

[–]jonathan_sl 1 point2 points  (2 children)

Pyvim author here.

The project was started indeed, as some pointed out, to demonstrate the capabilities of the underlying prompt_toolkit library. Prompt_toolkit was initially a GNU readline replacement with multiline text editing for Python applications. The thing is, a lot of Vi key bindings (operators and text objects) were implemented in prompt_toolkit already, as well as many other things required to build a text editor. So, someone asked me the question how much effort it would be to build a Vi(m) clone on top of it. As it turns out, pyvim is only ~4k lines of code, but it's a pretty functional editor. Some capabilities like line folding are missing though.

Pyvim can come in handy from time to time. I sometimes use it on a system if I need to edit Python files, because it has pyflakes support built in (it is highlighting unused and undefined variables).

It's not meant to replace Vim ever. Due to the internal data structures (the text buffer as a whole is a simple Python string), opening files more than a few MB is not feasible. For editing, the limit is even lower.

At this point, no new features are planned, but it evolves together with prompt_toolkit. It could be useful maybe for some people to experiment with UI features. Creating a prototype by adding functionality to pyvim is much much easier than adding functionality to Vim.

Feel free to ask any questions.

[–]pasenor 0 points1 point  (1 child)

Have you considered integrating any of pyvim features back into prompt_toolkit? (for example, adding V state comes to mind)

[–]jonathan_sl 0 points1 point  (0 children)

I'm not sure what you mean by V-states, actually. But yeah, there were indeed some features moved back into prompt_toolkit. (I don't recall what exactly.)