Tuesday, February 23, 2010

Re: omnicompletion for javascript

On Tue, Feb 23, 2010 at 4:55 AM, Gareth Oakes <juicejuice@gmail.com> wrote:
...
> There is a custom object model in use on this application platform and
> I would like to omnicomplete my Javascript objects according to their
> methods and properties. What is the best way to let omnicomplete
> recognise my new object structures? (The object definitions are "baked
> in" to the application, although I do have access to the completion
> files for Eclipse JSDT).

Hmm, I would be interested in seeing the format of the JSDT files.

What I did for the Adobe Flex MXML completion was used the framework
that Mikolaj wrote (see vim72/xmlcomplete vim72/htmlcomplete).

What it allows you to do is define some Vim Lists and Dictionaries
(since you have a static list of classes and methods this should work)
and then copy autoload/htmlcomplete.vim to use javascript syntax
instead of <tags> for html and xml.

That is the reason I asked about the format of the JSDT files. I
wrote a simple Vim script which converted one output format into the
above format for the MXML tags.

HTH,
Dave

--
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php

No comments: