Re: [gnome-love] gnome-vim bonobo component

--- James Hamilton <JAMESH davistl com> wrote:
> The drop comp stuff is good, and I would like to see
> it in Vim.  I 
> posted to comp.editors about that, and have actually
> considered 
> developing it myself.  However, there is more than
> just key bindings 
> that I miss when I switch from Vim to Scintilla.  I
> miss the entire Vim 
> environment, the scripting, the text operators, and
> the regex engine.  
> It would just be great if Anjuta worked with Vim. 
> Then I would use
> Anjuta, and so would many other staunch Vim
> supporters.  I don't
> think Scintilla was really meant to emulate Vi or
> Vim.
> --James

I agree!  I have created a GVim bonobo wrapper that
implements the Desktop::Editor interface.  Let me tell
you my vision of a great editing enviroment, and you
can tell me if it is possible right now, or point me
to where I need to add functionality to make it
possible :)

First off, I love Vim.  I would like to use Vim as my
editor.  Vim has support for scripting, folding,
bookmarking, multiple buffers and split screen
editing, multiple cut buffers, and a ton of other
features (such as the menu's) that make programming in
Vim great.  I would also like to be able to view a
list of functions and classes, run a debugger, design
a gui, and have all of these things talk to each other
and work together nicely.  I see the way to achieve
all of this is to have Anjuta managing everything.    
 I think along with support for Scintilla as an
embedded component, Anjuta should support a MDI type
interface, where the windows that Anjuta opens are in
fact seperate processes.  (It might already, correct
me if I am wrong :)  I think making vim into a
component that is embedded into Anjuta would restrict
some of the features that makes Vim great.  I also
think making Vim into a component would be problematic
if a terminal widget was not used, because this would
require modifications or a patch to the Vim source.

Vim offers an alternative! :)  In Vim 6.0, type :help
remote.  Vim implements a client-server protocal that
travels through the X Server.  When a Vim window
starts up, it registers itself with the Root window on
the X Display as a server.  The Vim window acts as a
command server, allowing any client that is able to
connect to the X Server to execute commands.  I would
like to see Anjuta start up, and then whenever it
needs any editing done, it runs gvim as a seprate
process, and sends the appropriate commands to the
window.  I think this is feasible, because the Vim
protocal allows for the server to send replies back,
which when combined with the vim scripting language,
is a powerful combination.

To this end, I have created a GVim bonobo wrapper that
implements the Desktop::Editor interface.  This
wrapper translates the bonobo methods to commands that
are sent to a vim window via the X Display.  I created
this wrapper just recently for use with CCView.  I
have not tested this wrapper extensivly.  The wrapper
works for CCView, but CCView does not use all of the
Editor methods.  My wrapper does not open up a bunch
of windows, but opens each new file in a buffer in
vim, thus we are able to take advantage of Vim's own
great buffer and split and vertical split support,
instead of having Anjuta manage the multiple files as

CCView can be found here...

You can find the wrapper here...

Is it currenly possible for Anjuta to use a "regular"
(aka non-component) interface for editing?  What would
it take to add this?


Do You Yahoo!?
Send your FREE holiday greetings online!

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]