The holy war of text editor - Gvim vs Emacs. Which one is better? Difficult to say. Depends on your requirement. Vim is small and great. Emacs is large an great. Both are great. One is small in the size, other is large in the size. Gvim is GUI version of vim. If you want to quickly edit a file and mostly want to remain in the command mode - vim is the better choice. It's real fast. Default vim is much easier to use then default Emacs for programmers. If you do elisp programming in Emacs then you can do an anything you want. Because, elisp is kind of programming language. You can write functions in elips and bind to any suitable key you want. That is where Emacs becomes extremely powerful. However, if your job requires mostly to edit existing code vim would be better choice. Emacs is huge. Very huge. It's not only designed just as a text editor. Vim is purely text editor. Emacs can act like operating system. Lol. Emacs has everything. The main idea behind Emacs was to put everything into one editor so that user will never have to exit from it. You can send receive email through Emacs. You can read news inside Emacs. etc. So, Emacs is not just a text editor. It's much more than that. One thing I didn't like about Emacs is ctrl key. To type any command you have to press ctrl key. This is too much. However, you can always map them to functional keys but there exist only 12 functional keys. Hitting control keys always, it bugs(to me). Things I don't like with vim is every time switching between command and insert mode. Indent capability if vim is poor. Emacs is smart in indenting. Only problem I see with Emacs is the control key. In vim if you are in command mode you don't have to hold control key. Then any key can act like a command. That's not the case with Emacs. In Emacs to invoke a command you have to hold control key always. There is no way out except mapping (up to 12 functional keys). That is why Vim is great when you work in command mode. Working in Emacs is too slow as compared with command mode in vim. From undo point of view both are same. Both provide unlimited undoes and redoes. From block editing point of view Vim is slightly better than Emacs. When you select a block in vim it clearly highlights, whereas in Emacs you have to imagine the block. Goshhh! From shell point of view emacs is better. Working with Emacs can be enjoyable provided you write lots of elisp function in your .emacs file (which I don't have). Emacs has a viper mode which can act like vim. It can emulate vim. I used it once. Was fun using vim inside Emacs. Other way round possible? Emacs inside Vim? I think it would be good idea to make an editor which combines the properties of Emacs and vim.
Showing posts with label GVIM. Show all posts
Showing posts with label GVIM. Show all posts
Wednesday, September 17, 2008
Monday, August 4, 2008
This weekend
Happy Friendship Day
Had a long weekend. 3 days. Fri-Sat-Sun. It was full of coding. Especially for the chat server I am making. Wrote 5 servers in total. Searched on net for any legacy code. Got few codes to play with. It's working now. Multiple users can connect to the chat server. The most important part of socket programming was socket_select and socket_read. I tried both blocking and non-blocking connection. Non-blocking is not recommended as it eats of lots of CPU time. It still however has problems - when transfer is idle for some time say 2-3 minutes. Response after idle time for 2-3 minutes is unpredictable. Server doesn't broadcast the message. Neither it appears to be echoing properly. I am suspecting it's some kind of issue of timeout with client telnet. No fully sure though. May be there is some catch somewhere in the code. Have to look into that.
Secondly, keeping timeout problem apart, I am thoroughly enjoying chatting from telnet. This is the very basic chat and is the fundamental concept being IRC. That's how so many chat protocol have evolved. It worked in windows telnet program, putty, kermit, absolute telnet, wise telnet. I downloaded many telnet programs to make sure that when we press enter it sends LF-CR to the server. This is required by TCP/IP protocol. Hopefully it does. Kermit has option to select CR or LF or LF-CR. I liked kermit.
Thirdly, I also spent a lot time on font for my UNIX. I am looking for Courier New, Font size 12 and bold font applied across Xterm, GVIM and Emacs. Courier New font is available in windows. But, unfortunately it's not available in Linux/Solaris. :(( There are ways to install fonts but that needs superuser account. Wonder why Courier New font is not added in Linux. MS has copyright on it? Meanwhile, I am unhappily managing with Courier-12-bold. Looks good but not as good as if it were Courier New. In case you know how to use courier new font in Linux please care to share.
Labels:
Chat,
courier new,
Emacs,
font,
GVIM,
hanging,
Socket,
socket_read,
socket_select,
Xterm
Subscribe to:
Posts (Atom)