IonicWind Software

Aurora Compiler => Software Projects => Topic started by: sapero on March 30, 2009, 01:50:50 PM

Title: Intellisense project
Post by: sapero on March 30, 2009, 01:50:50 PM
Im working on Intellisense plugin for Aurora compiler. It will show a popup window with current function/constant declaration, as you see in the attached image.
The database it creates is pretty small: 1.11MB for the following includes: acommon, mshtml, shlobj, shlwapi. It stores only keywords and links to include files, where the keyword is declared.
The database is divided into groups. Each group includes keywords starting from same character: A, B, C ... Z, so memory usage in read-only mode will be under 1MB.

The popup window is created by scintilla - SCI_CALLTIPSHOW, with small delay equal to default tooltip popup time (GetDoubleClickTime api).

Database writer is very slow for now. Memory is allocated as needed, without preallocation. Ithandles #ifdef, #ifndef, #else, #define, #include, const, enum, sub, struct, declare (4 cases), extern (3 cases), import, interface, class keywords.
While creating the database i've found a bug in WinUser.inc - missing #endif, not reported by the compiler.
Open the include, find * Standard Icon IDs and remove below the line with #ifdef RC_INVOKED
Title: Re: Intellisense project
Post by: sapero on March 31, 2009, 05:37:00 PM
Here is the first public alpha. This is the continuation of External Help system for Aurora and EBasic (http://www.ionicwind.com/forums/index.php/topic,2462.0.html). I have used it because there was already implemented the "plugin" loader.
The aexplore tool has been extended a little (added index view and namespace viewer/editor/registration).
Please give feedback how it works (is the TOC working for you?)

EDIT: Third upload.
Title: Re: Intellisense project
Post by: Haim on March 31, 2009, 11:41:56 PM
Hello,
I downloaded it but I do not understand what it does and how to check/test it.
Could you explain please?

Haim
Title: Re: Intellisense project
Post by: Haim on March 31, 2009, 11:59:20 PM
Hello
I found the info .txt file. and set up intellisense for Aurora.
This is a great program! Thanks
I will try it out thoroughly during the week end.

Thanks for sharing this,
Haim

Title: Re: Intellisense project
Post by: sapero on April 01, 2009, 05:41:23 PM
Sorry Haim, i forgot to say this.
There is a info.txt file with instructions how to use it. The third line "You'll need to download the attachment" is incorrect because the required tool is included in this attachment.

EDIT: I have updated it. Found memory leak, saved two seconds in the database maker and much more (see in changelog.txt). The tokenizer allocates filesize*0.4 tokens as array which is expanded if needed, and reallocated at the end to the required size.

Database query is very fast: always below 0.2ms (isLookupKeyword subroutine), so you can view at least 5000 different tooltips in single second... I am also surprised.
The query is still case sensitive.
Title: Re: Intellisense project
Post by: Haim on April 01, 2009, 10:14:01 PM
Thanks for the update
Haim
Title: Re: Intellisense project
Post by: Haim on April 02, 2009, 12:02:28 AM
Hi,
I noticed that on my laptop the window is distorted (see the attached image)
Any idea?

Haim

Title: Re: Intellisense project
Post by: sapero on April 03, 2009, 12:19:30 PM
Topic Edited.

I'm not sure what to say, the missing TAB control is a direct child of the right (IDD_BROWSER) pane, and it is not moved by SetParent api.
Both right and left panes are child dialogs of application dialog.
Could you check if the blank space over the browser accepts dropping topics, url's or right-click? What happends after resizing the window, and how behaves the original project (link in info.txt) ?

This is a screenshoot of the windows order:
(http://i42.tinypic.com/2uny00g.png)
The selected tab control is the browser tab.
The first treevew originally was a child of the ATL window (table of contents). I needed the treeview handle in order to implement drag-drop.


EDIT: again uploaded, version 3.0.3.
Played a bit with memory preallocation for the database creation phase, but still 13 seconds needed. There is a new dbnew function that allocates at least 64KB of heap and returns the free chunks from the allocated block, instead calling NEW every time memory is needed.

New features:
If you right click a keyword in scintilla editor and that keyword is stored in your database, a new item appears in the context menu. If you haven't noticed till now, the string right to #include has also additional options in the context menu (no support for non-global include path yet is now working).
More infos in changelog.
Title: Re: Intellisense project
Post by: Ionic Wind Support Team on April 03, 2009, 12:44:44 PM
Moved to proper category.

Paul.
Title: Re: Intellisense project
Post by: Haim on April 04, 2009, 08:15:34 AM
Works now perfectly.
Thanks for a graet program.
screenshot attached.

Haim