Page 1 of 1

Ctrl + Double-clik on IncludeFile

Posted: Sun Feb 05, 2012 1:55 pm
by Guimauve
Hello everyone,

I'm not sure if this is a bug or if it's just never considered by the design. However, holding the Ctrl key and double clicking on the IncludeFile keyword open the stated source code.

Example :

Code: Select all

IncludeFile "SOURCES/Maths/Vector3.pb"
Will open the Vector3.pb source file. Unfortunately using the IncludePath keyword just disable the Ctrl+Double click to Open source file functionnality.

Example :

Code: Select all

IncludePath "SOURCES/Maths/"
IncludeFile "Vector3.pb"
I think it will be great to be able to open a source file even if we use the IncludePath or not.

Best regards.
Guimauve

Re: Ctrl + Double-clik on IncludeFile

Posted: Sun Feb 05, 2012 2:09 pm
by luis
Yes, it would be nice but what about this case

Code: Select all

IncludeFile #PB_Compiler_FilePath + "test.pbi"
or this one

Code: Select all

#INCLUDES$ = "c:\includes\"

IncludeFile #INCLUDES$ + "test.pbi"
or others involving macros etc.

I don't think it's going to happen. :(

Re: Ctrl + Double-clik on IncludeFile

Posted: Sun Feb 05, 2012 2:52 pm
by Guimauve
Something I have suggested on the French forum, a mean to specify a ToolBox directory just like FreeMat 4.0* to put some source code to scan for user defined element such as Constants, Structures, Imports, Macros and Procedures.

Yes it's possible the generate Resident for Constants, Structures and Macro as well as library for procedures but we have to recompile them for each platform each time we upgrade them. We spend more time on creating and solving problem related to create these resident and library file than we spend on developing project.

Setting a ToolBox directory will be less subject to modification like Resident and/or library does when PureBasic is Updated from 4.5x to 4.6x version. And this is not very difficult to implement because the IDE generate a "PB_Output_source_file.pb" or something. So scanning the sources files present in the ToolBox directory for missing element and add them to the output source before to popup the error message like
Structure not found : ...
... is not a function, array, macro or linked list.
will be very easy to do and solve the problem to compile resident files and/or create library files and most important they will probably don't need any modification for many many PureBasic version upgrade. For many of my program I use command created many years ago (In 2003 - 2004 - 2005).

It's just a suggestion but I really think it's a very good idea and it should be added for the 4.70. Or if we are very aggressive, for 4.61 final version.

Best regards.
Guimauve

*If you don't know FreeMat, it's an equivalent environment to MatLAB and almost compatible with it. Sometime when I create mathematics function I start by creating a prototype in Freemat then I port it to PureBasic.