anjuta-gvim Preview

11 07 2008

I closed some big bad bugs yesterday, and managed to get a whole workflow (open a bunch of files, edit, save, close) working without any glitchy-ness. Most of the time. And while I’m no where near the quality required to ship this plugin, it feels great all the same.

A phenomenally boring Youtube screencast:

There’s a very apparent bug in the video; it doesn’t change pages when the option is document is chosen from the Documents menu. I’ve already fixed it.

If you liked this plugin, well, unfortunately you’ll have to wait a while. There is a considerable amount of code required to be reviewed and there’s bound to be a lot of back and forth activity between Johannes and me. Hopefully, we can start the review process once Johannes gets back from GUADEC. If you absolutely can’t wait, I do have the patches required for the anjuta svn tree in my svn repo. The instructions are in the INSTALL file.

Getting this to work was quite a hassle because of the odd quirks of some Vim plugins. While a vanilla vim works fine (so far…), a vanilla vim is boring (not to mention not worth using). The objective of this project is to give you all the power of Vim + all the power of Anjuta, with as few compromises as possible.

One of the more frustrating issues I faced was with a plugin called MiniBufExploerer. MiniBufExplorer is a fantastic plugin that lets you look at all open documents at once, and at cycle through them with ease. I’d ideally like to package this with the Vim plugin, but I have to discuss those issues with Johannes first.

For some crazy reason, MiniBufExplorer (MBE) when opened with a single file gets into a position where the contents of the file are displayed with MBE’s buffer number. So lets say I have a file foo.c open (as buffer 2), and MBE occupies buffer 3. foo.c is a normal file (it’s ‘buftype’ is empty), but MBE has a buftype of ‘nofile’. Now if I open another file bar.c (now MBE is displayed) and close it (MBE goes away), it opens foo.c as MBE, i.e. it’s buffer no. is 3 and buftype is ‘nofile’. Utter nonsense. The only work around I found for this was to set the MBE option: g:MiniBufExplorerMoreThanOne=1, which always keeps the MBE open.

I’m really worried with what other plugins might do. Making this plugin robust looks like a very daunting task. Any tips?

P.S. The glade file shown is the Maemo version of Dasher. The only reason I opened it was that it was in my recent documents list.


Actions

Information

12 responses

11 07 2008
kraptor

Can’t wait to get my hands on Vimjuta… πŸ˜‰

11 07 2008
Ali

This is excellent news for Anjuta, but if you want to try Vim in an IDE with mature support, please try PIDA http://pida.co.uk/. We take the concept of allowing the editor to be a swappable component in an IDE very seriously (we even support Emacs).

Ali

11 07 2008
BeS

This makes me as an emacs user really jealous… πŸ˜‰

11 07 2008
Ali

Bes: sorry I don’t mean to take over this comments list(!) but the same approach should easily be possible with emacs from trunk because it supports embedding in gtk.

Ali

11 07 2008
Eskild Hustvedt

Looks great, good job! πŸ™‚

11 07 2008
C.M

Nice, can’t wait to try it out. πŸ™‚

11 07 2008
asdf

great! now if only anjuta could drop all the gnome dependecies i might think about using it πŸ˜‰

11 07 2008
arunchaganty

@Ali: I’ve seen PIDA, and I must say, you’ve done a great job on it. It’s far more mature than this, for sure, but at the same time, the requirements of the IDE are much less. While in Anjuta, there are interfaces for everything, PIDA (AFAICT; this might be total poppycock), leaves the editors to themselves. Also, initially the architecture of Anjuta was not build for standalone editors. I have had to make a lot of changes (which I pray aren’t too hacky). On the other hand, I’m very impressed with the number of plugins that you’ve created already!

@Bes: As Ali said, support Emacs at this point is pretty easy. I have *tried* to approach all my changes keeping a future Emacs editor in mind.

21 07 2008
Akarsh Simha

Wow!
Neither do I use vim, nor do I use GNOME / Anjuta, so I can’t exclaim as much as others did, but this seems to be great. I like the look of vim changing buffers as and when you select different files. Maybe I’d like the look of the debugger (breakpoints, stepping and all that foo) too.
I shall learn to be satisfied with EMacs πŸ™‚

1 09 2008
name

Hi!,

27 12 2008
Ben Forbes

This is great, I like Anjuta but there is no way I’m programming without Vim. I have a question: does the plugin have, or will it have, symbol lookup directly from the editor, eg through a context menu?

29 12 2008
Arun Chaganty

My feelings exactly :-). I am not exactly sure what you are talking about. There is a symbol menu (the same that comes with any other editor in Anjuta, and it works fine with Vim. It does not have a symbol lookup table within Vim though (Tlist, etc. do the job). I would hopefully have support for auto-complete from the Anjuta side soon (I’ve had some trouble finding time with my semester).

Btw, the site has moved to http://arun.chagantys.org/blog/

Leave a comment