FreeBasic IDE-poseidonFB(Update 2024.10.09)

User projects written in or related to FreeBASIC.
Post Reply
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by ilya-master »

I did everything according to your instructions and it worked :D
Thanks for the help!
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by ilya-master »

I have created several color themes for Poseidon. The editorSettings.ini file lists the freebasic keywords and types, the main keywords from the crt.bi, and some winapi functions.
https://github.com/ilya-master/PoseidonFB_ColorThemes
Image
Image
shadow008
Posts: 111
Joined: Nov 26, 2013 2:43

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by shadow008 »

PoseidonFB crashes if you have an open executable and you hit the Build -> Clear All button

Reproduction steps:
- Build an executable
- Run the executable, make sure it doesn't close
- Click the Build -> Clear All button
- PoseidonFB crashes
aurelVZAB
Posts: 675
Joined: Jul 02, 2008 14:55
Contact:

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by aurelVZAB »

version i use not crash
but just don't do coloring if is not .bas
but that is fine :)
Kuan Hsu
Posts: 607
Joined: Sep 16, 2007 15:12
Location: Taiwan

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by Kuan Hsu »

shadow008 wrote: Aug 04, 2024 3:44 PoseidonFB crashes if you have an open executable and you hit the Build -> Clear All button

Reproduction steps:
- Build an executable
- Run the executable, make sure it doesn't close
- Click the Build -> Clear All button
- PoseidonFB crashes
aurelVZAB wrote: Aug 05, 2024 6:17 version i use not crash
but just don't do coloring if is not .bas
but that is fine :)
(1) It should be show an error message about "Access denied" but no crash, I'm not found the bugs from my sources yet......
(2) Haha, only *.bas/*.bi, in truth, the modified iup_scintilla.dll only had FreeBASIC and D language lexers
Kuan Hsu
Posts: 607
Joined: Sep 16, 2007 15:12
Location: Taiwan

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by Kuan Hsu »

ilya-master wrote: Jul 30, 2024 9:24 I have created several color themes for Poseidon. The editorSettings.ini file lists the freebasic keywords and types, the main keywords from the crt.bi, and some winapi functions.
https://github.com/ilya-master/PoseidonFB_ColorThemes
Can I add your theme at next posedonFB reversion? I like 'night' theme :D
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by ilya-master »

Of course ! :)
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by ilya-master »

"Auto Convert Keyword Case" doesn't work for me. It stays on "None" all the time. If I select a keyword from the autocomplete list, then everything works. But it's not convenient. I think this should fire automatically after pressing spacebar.
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by ilya-master »

Tools->Convert Keyword Case->... works correctly
Kuan Hsu
Posts: 607
Joined: Sep 16, 2007 15:12
Location: Taiwan

Re: FreeBasic IDE-poseidonFB(Update 2024.07.13)

Post by Kuan Hsu »

ilya-master wrote: Aug 11, 2024 15:34 "Auto Convert Keyword Case" doesn't work for me. It stays on "None" all the time. If I select a keyword from the autocomplete list, then everything works. But it's not convenient. I think this should fire automatically after pressing spacebar.
Sorry, because the changed result not be saved, maybe I deleted the code section in a certain time....... :shock:
I'll fix it and update it on the weekend.

2024/8/18 Done at rev.541
ilya-master
Posts: 15
Joined: Jul 08, 2024 15:36

Re: FreeBasic IDE-poseidonFB(Update 2024.08.18)

Post by ilya-master »

Thanks :D
demosthenesk
Posts: 265
Joined: Jul 15, 2021 7:23
Location: Greece
Contact:

Re: FreeBasic IDE-poseidonFB(Update 2024.08.18)

Post by demosthenesk »

The "Build" command fails for window9 project...
But "Rebuild" command succeed for the same project...

poseidon version:
0.540, 2024-07-13
0.541, 2024-08-18
os: win11
window9: unicode version

1) Create a Project for window9
2) Build Project output
Buinding Project: [Tests]......

c:/users/demos/bin/freebasic-1.10.1-winlibs-gcc-9.3.0/fbc64.exe -c -m "main" -b "main.bas" -i "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/inc" -p "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/lib/win64"


Compile Success!!

************************************

Continue Link Project: [Tests]......

c:/users/demos/bin/freebasic-1.10.1-winlibs-gcc-9.3.0/fbc64.exe -x "Tests.exe" -a "main.o" -i "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/inc" -p "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/lib/win64"

c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x11e): undefined reference to `LOAD_IMAGE'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x177): undefined reference to `LOAD_IMAGE'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x1da): undefined reference to `LOAD_IMAGE'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x23d): undefined reference to `LOAD_IMAGE'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x2d9): undefined reference to `OPENWINDOW'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x333): undefined reference to `LISTVIEWGADGET'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x389): undefined reference to `ADDLISTVIEWCOLUMN'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x448): undefined reference to `ADDLISTVIEWITEM'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x480): undefined reference to `WAITEVENT'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x4b9): undefined reference to `EVENTNUMBERLISTVIEW'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x4cf): undefined reference to `GETSUBITEMLISTVIEW'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x4db): undefined reference to `GETITEMLISTVIEW'
c:\users\demos\bin\freebasic-1.10.1-winlibs-gcc-9.3.0\bin\win64\ld.exe: main.o:fake:(.text+0x50e): undefined reference to `REPLACEIMAGELISTVIEW'

Compile Error...

3) Rebuild Project Output
Building Project: Tests......

c:/users/demos/bin/freebasic-1.10.1-winlibs-gcc-9.3.0/fbc64.exe -x "Tests.exe" -m "main" -b "main.bas" -i "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/inc" -p "C:/Users/demos/Bin/FreeBASIC-1.10.1-winlibs-gcc-9.3.0/lib/win64"

Compile Success!!

4) Code

Code: Select all

#Include "window9.bi"

Dim As HBITMAP bmp(3)
bmp(0) = Load_image("1.png")
bmp(1) = Load_image("2.png")
bmp(2) = Load_image("3.png")
bmp(3) = Load_image("4.png")

OpenWindow("Hello",10,10,150,150)
ListViewGadget(1,10,10,100,140)
AddListViewColumn(1, "Column",0,0,100)

For aa As Integer=0 To 2
  AddListViewItem(1,"item №"+Str(aa),bmp(aa),aa,0)
Next

Do 
   Var event=WaitEvent()
   If Event=EventClose Then End
   If event=EventLBDown Then
       If EventNumberListView=1 Then
           ReplaceImageListView(1,GetItemListView,GetSubItemListView,bmp(3))
       EndIf
   EndIf
Loop
Kuan Hsu
Posts: 607
Joined: Sep 16, 2007 15:12
Location: Taiwan

Re: FreeBasic IDE-poseidonFB(Update 2024.08.18)

Post by Kuan Hsu »

demosthenesk wrote: Aug 30, 2024 13:52 The "Build" command fails for window9 project...
But "Rebuild" command succeed for the same project...
Because Linker not link with window9 library.

The difference of 'Build" and "Rebuild" is:
"Rebuild": force re-compile all files and link, so poseidon just pass all files to FBC
"Build": poseidon will compare the the buite time of source file (*.bas) and obj file(*.o), if source file is newer, compile it to obj, then pass objs to FBC

We can see the windows9.bi line #112, when compile sources to object files, it will not run inclib "window9", so the linker don't know window9 library is needed.

Without modify the windows9.bi, please add -l window9 to Project's Compile Opts or add #inclib "window9" in our source
OR
Modify Line #112

Code: Select all

#if __fb_out_exe__ Or __fb_out_dll__
to

Code: Select all

#if not __FB_OUT_LIB__
Last edited by Kuan Hsu on Sep 03, 2024 7:48, edited 1 time in total.
demosthenesk
Posts: 265
Joined: Jul 15, 2021 7:23
Location: Greece
Contact:

Re: FreeBasic IDE-poseidonFB(Update 2024.08.18)

Post by demosthenesk »

Kuan Hsu wrote: Sep 03, 2024 3:05
demosthenesk wrote: Aug 30, 2024 13:52 The "Build" command fails for window9 project...
But "Rebuild" command succeed for the same project...
Because Linker not link with window9 library.

The difference of 'Build" and "Rebuild" is:
"Rebuild": force re-compile all files and link, so poseidon just pass all files to FBC
"Build": poseidon will compare the the buite time of source file (*.bas) and obj file(*.o), if source file is newer, compile it to obj, then pass objs to FBC
We can see the windows9.bi line #112, when compile sources to object files, it will not run inclib "window9", so the linker don't know window9 library is needed.

Without modify the windows9.bi, please add -l window9 to Project's Compile Opts or add #inclib "window9" in our source
ok, thanks...
i have add -l window9 to compile options and it is all ok
shadow008
Posts: 111
Joined: Nov 26, 2013 2:43

Re: FreeBasic IDE-poseidonFB(Update 2024.09.09)

Post by shadow008 »

I have a feature request: Macro created type names can be handled as a literal type name. This would allow a types created through macro expansion to still retain all the features of type treeview, jump to definition, autocomplete, etc.

Minimally, it could be implemented so that any type name created with a macro is treated as that type ID as long as the name is literally equal. This would not require the IDE to do any kind of macro expansion, just parsing a different label.

For instance:

Code: Select all

type myUDT
	dim x as integer
end type

dim a as myUDT
a.[popup suggestions for member 'x' come up]
The IDE handles that case, as expected.
I would like to request that the following also works:

Code: Select all

#macro TYPE_NAME(_NAME)
_NAME##_macro_type
#endmacro

type TYPE_NAME(myUDT)
	dim x as integer
end type

dim a as TYPE_NAME(myUDT)
a.[popup suggestions for member 'x' come up]
Again, I think avoiding any kind of macro expansion is totally sufficient. The IDE does not need to parse out that the type is actually "myUDT_macro_type" and can instead call the type "TYPE_NAME(myUDT)" and not go any more specific. Thus, the literal string used to create the type is treated exactly like a normal type identifier token.

The only possible complication I can think of is if a #macro or #define was subsequently undefined(#undef). That would be nice to have, but still not really that necessary.

This feature could either be a built in default, or a toggle in the options, it doesn't matter to me.

Thoughts? Would it be too complicated/not worth it? I hope you can at least consider it. Thank you.
Post Reply