Vim clones are a dime a dozen; this is actually an entirely different thing, and although I can't imagine actually using it for anything... it's interesting to see people work on different approaches to text editors.
A simple hackable python text editor may not be useful in the long term for anything (for all the reasons about distributing python and python performance limitations), but its certainly viable for prototyping interesting features.
Devil's advocate: relative to C (which vim is written in), Python 2 is considerably slower, especially with CPython as its interpreter. Optimization is also tougher.
Personally, I admit I'm not sure that the difference is significant for this particular project.
Honestly, python might perform better overall. Not because C is slower than python (ha), but because python probably outperforms vim script. Especially likely because vim plug-ins can be fairly complex.
Realistically this is like saying you could rewrite git in python and just push the hard bits down into C; the problem is that you end up writing a significant portion of both the core, and plugins, in C.
When you're writing all of the main parts of the editor in C, at this point, why are you using python at all?
I'm not necessarily defending the rewrite here, but writing something like git in Python, profiling then optimising the parts that are slow doesn't sound like a bad idea.
You can write C, and pretend its python, but if you're writing C, why are you pretending your project is written in python?
Text editors are surprisingly demanding; they require complex bulk operations like search, replace and per word highlighting, which is not inconsiderable in magnitude.
Ever tried open a 100MB log file in vim?
Now try that in atom... and javascript is easily a magnitude or more faster than pure python.
I work with python and love it; its hackable, fun to write. ...but fast it is not.
You'd be surprised. All editors written in scripting languages I've suffer get to their knees for larger files (sometimes even 10MB or so, even more so for really large ones), as stuff like highlighting, parsing etc gets CPU bound soon.
To be fair, only very large text files trouble Atom. And when does any dev ever actually open massive text files in text editors. I'm a Vim guy and have only briefly tried Atom, but I still wouldn't dream of opening a huge text file in Vim, even though it would cope a lot better than Atom. If it's a log file or something I'm going to be using tail/grep etc. to deal with it.
Yeah exactly emacs is hackable if you want to write lisp, which has a very small audience. So sure there is absolutely a desire for an editor written in a 'nice', hackable language like Python or JS (forgive me JS haters) to prosper.
Depends on your definition of huge. On my computer, vim takes about a second to load a 100MB text file, 1.4 million lines - not as fast as less (although less's search feature is slower). Vy's slower but it appears to load the file asynchronously, so at least you can start browsing while it's doing that. But 100MB is fifty times the sibling comment's 2MB for Atom...
For the record, while Python's pure interpreter is always going to be slow at this type of thing, JS's overhead factor compared to C is small enough that it's certainly possible to write an editor in it that feels just as fast as vim - maybe faster in some cases, e.g. since JavaScript engines JIT compile regexes and C regex libraries generally don't, or by making relatively slow operations asynchronous/multithreaded (while vim is highly synchronous). Atom seems to be just badly designed.
Atom's filesize limit is 2MB, so it's not really 'massive.' When I was using it, I ran into that limit more often than I would have expected. Mostly when taking a peak at a db dump, or misc files from the odd CTF challenge.
Tkinter actually isn't _that_ bad. I've written several fairly large applications with it. You have to re-invent the wheel for several things due to its limited number of "widgets". It used to look very non-native, but that's been largely fixed. Other than that, though, it has a worse reputation than it deserves.
Sure, I'd rather use Qt for something large, but honestly, for a quick-and-dirty gui, it's hard to beat Tk. You can get something reasonably nice looking (at least with recent versions) and reasonably cross-platform very quickly.
The first thing that comes to mind are help tooltips (a.k.a. balloons). There are a few third-party libraries, but none of them that I'm aware of get it quite right (especially for tooltips on menu items).
There are couple of other common widgets as well, but I'm having trouble thinking of them at the moment.
At any rate, there aren't too many (and ttk helps immensely in this regard), but it's something you miss coming from Qt.
On the other hand, being able to put a minimal, but very usable gui together with just a few lines of code is a real strength of Tcl/Tk. (Though I usually use Python+Tkinter as I tend to write scientific applications.) There's a lot to be said for the right level simplicity vs batteries-included.
Yeah, I chuckled a little bit when I read this. I suspect that either the author uses English as a second language, or the author is on the young side and enthusiastic.
Tkinter is not a top GUI toolkit, but I use it all the time because it is built in to Python and requires no libraries. This is very valuable in my job. Thankfully it is fairly well documented and perfectly capable of useful desktop interfaces.
"I'm working on a ncurses based library with a symmetrical archicture to python tkinter". That sounds nice.
I'd suggest don't work trying to replace vim in the future. Work to learn and to fix any necessity that by some reason vim is not fulfilling for you. Then the world will say...
The project has a good architecture (plugins seem interesting). But it could use some tidying up.
Hm, maybe. I quite like the look of 'plugins', even the vi-ness is handled by one. But it seems a strange thing to say in the readme - it's clearly a long way off being close to a contender.
Also: the modularity and extensibility doesn't come at the expense of vim's traditional portability: Python 2.7 is a fairly low baseline for Unix servers.
Interesting project. Vim is riddled with issues and we badly need a replacement (coming from a dedicated Vim user). Currently VimR and NeoVim are in the lead for tackling some of the hard problems (async calls, a real plugin system, obvious features like fuzzy finder with good UI integration, etc).
I found this part amusing: "What did Bram Moolenaar say". After using Vim for a few years, and seeing his design choices, I wouldn't personally be interested in his opinion of an editor!
I don't think it's "common", but people do it so they can scroll to the last line and have it appear near the top of the page. It's a matter of personal preference. Some editors allow you to scroll that far without the extra lines, many don't.
What editors don't do that? I'm only familiar with Emacs and Sublime which do. I'd hate to use an editor that didn't. Hopefully he added that functionality to Vy :)
In vim, j and k will only move the cursor between lines that exist, and the screen will follow the cursor. You can scroll the screen past the end of the file using ctrl+e and ctrl+y, but it's annoying.
Yes, I absolutely agree. I'm sure I've been guilty of it (I'd rid them if I noticed of course) but it's a pretty sloppy-looking project. Not holding my breath for it to replace vim.
Am I wrong in thinking that this is a Tk Text widget (or possibly several), with a selection of functions atop? Plugins for the most part are just key press callbacks which manipulate this Text widget and associated state?
I know every project must start somewhere but this doesn't seem to have considerable substance for a purported next gen vi(m), and given its heavy reliance on pre-made tools (like text areas), without much abstraction, it seems like it would be hard to get over the hump to make it competitive with existing editors.
No kidding! This thread is filled with sniping jerks. I've seen criticism of the coding style, the white space, the Readme grammar, the enthusiasm of the Readme.. Just a constant barrage of nonsense from what seems to be a bunch of grumpy old men complaining about whippersnappers on their lawn. We should certainly be honest when it adds to the discussion but seriously, people were griping about the Readme grammar? The project is open source; how about submitting a pull request instead of bike shedding bull----.
I guess someone valuing code more than perfection in prose doesn't deserve to be writing code.
Remember not everyone speaks English as a first language, and not everyone has the time, the knowledge or the resources to proof-read their project description. And most people don't care that much when they see such errors.
But for me the hardest part in reading the readme is the presentation - such a wall of text, and a lot of it seems to be trying to sell the idea of vim to me, when I'm presumably already onboard with that if I'm looking at a self-described "vim-like" project.
"A wall of text" used to mean a large body of text, unparagraphed and hard to follow. The author's prose may not conform to all points of Strunk & White, but it doesn't look a wall of text to me.
(The youngsters these days! :)
If the content is good, there's no need for fancy styles or images. In this case, though, the content is not super duber either. But I wouldn't call it a wall of text, especially with paragraphs so small.
(A book is like a Steve Yegge blog post, or maybe a Mencius Moldbug one, but printed out in a thing that looks a bit like a large version of a Moleskine. Maybe ask your grandparents.)
Seems kind of a rude comment to insult the Readme without you having even tried the editor. Do you claim Ruby is a failure because English isn't Matz's first language? Let's be supportive instead of sniping over trivia.
Good luck!
Vim clones are a dime a dozen; this is actually an entirely different thing, and although I can't imagine actually using it for anything... it's interesting to see people work on different approaches to text editors.
A simple hackable python text editor may not be useful in the long term for anything (for all the reasons about distributing python and python performance limitations), but its certainly viable for prototyping interesting features.