Version II is a port to FreeBASIC of the original version written using PowerBASIC.
Paul Squires wrote a similar tool very quickly, he writes at a blazingly fast speed compared to me, but it fell short of what I wanted. I then had to decide whether to develop Paul's work or port mine to FreeBASIC. I was better acquainted with my work so I went with mine.
Paul's compiler description is a fixed length so anyone wanting to 'ramble on' a bit will get clipped. On opening all the radio boxes are unselected and I wanted the compiler currently in use to be selected.
My original version catered for four pairs of compiler paths and that was increased to six. If we only had three in our ini file then three radio buttons were shown as 'Empty'. Paul's code showed only the number of pairs in the ini file. I took that idea on board. There was some interesting techniques in Paul's code and I made some use of them as well so the credit for this application should go to myself and Paul Squires.
So why did I bother? Version II is high dpi aware - my original version was not. With Paul's 4K monitor my form looked like it was in the early stages of falling into a black hole. I don't have access to greater than 96 dpi but since I am using WinFBX and CWindow.inc by José Roca then high dpi aware is assured.
The ini file no longer has "WinFBE" as the initial string. Here is an example ini file.
Code: Select all
"E:\Downloads\WinFBE_Suite\Settings\WinFBE.ini"
"5.2", "C:\Program Files (x86)\FreeBASIC\fbc.exe", "E:\Downloads\FreeBASIC-1.07.0-win64\fbc.exe"
"7.4", "E:\Downloads\FreeBASIC-1.08.0-win32\fbc.exe", "E:\Downloads\FreeBASIC-1.08.0-win64\fbc.exe"
"8.3", "E:\Downloads\fb108-win32-gcc830\FreeBASIC-1.08.0-win32\fbc.exe", "E:\Downloads\fb108-win64-gcc830\FreeBASIC-1.08.0-win64\fbc.exe"
"9.2", "E:\Downloads\fb108-win32-gcc920\FreeBASIC-1.08.0-win32\fbc.exe", "E:\Downloads\fb108-win64-gcc920\FreeBASIC-1.08.0-win64\fbc.exe"
"10.0", "E:\Downloads\FreeBASIC-1.07.1-win32\fbc.exe", "E:\Downloads\FreeBASIC-1.07.1-win64\fbc.exe"
This is what a two compiler set up looks like.
A longer description may look like this - but I doubt it.
Paul added some code to WinFBE to allow my tool to work and that will be included in the next release of WinFBE. In the meantime you can get a copy of just the revised WinFBE32.exe and WinFBE64.exe here.
Drop SetCompilerPathsII.exe and SetCompilerPathsII.ini into WinFBE's UserTools folder.
Now go to 'Tools/User Tools...' and complete the form exactly as follows.
If you type into the 'Tools Name:' edit box this populates the box on the far left simultaneously.
Make sure that you look all over the form, there are some entries needing attention at the bottom right.
You are now good to go.
SetComPilerPathsII uses 'Tahoma, 8'. If you rename the exe to SetComPilerPathsIIL.exe, that is with 'l' or 'L' at the end of the filename, then you will get 'Tahoma, 12' provided also that the command in the 'User Tools' form has 'l' or 'L' at the end of the filename. I actually use the 'L' version.
Like this.
You may have seen me getting into a 'right state' at the end of last week writing this and thanks to José Roca and Paul Squires I managed to see the light at the end of the tunnel and eventually a blue sky above. I could have posted this late last Friday but decided to 'kick it around' over the weekend to make sure that it was in a release state.
Thanks to José's teachings I have only used Cast once and that was his recommendation. [Grasshopper]
Download: SetCompilerPathsII.zip
######################################################################################
SetCompilerSwitches
In WinFBE's Compiler Setup we have
'Additional compiler option switches (optional)'
It is easy enough to edit that and they will be used at the next compilation. However, if we want to test a bunch it can be tedious to keep opening that form. On the other hand with SetCompilerSwitches we can quickly change from a preset list like this.
If the last set of switches used is one of your presets then the corresponding radio button will be selected when SetCompilerSwitches opens. If no match is found then the last set used is not one of your presets and no radio button will be selected.
Here is an example ini file. (SetCompilerSwitches.ini)
Code: Select all
"E:\Downloads\WinFBE_Suite\Settings\WinFBE.ini"
"-gen gcc -Wc -O1"
"-gen gcc -Wc -O2"
"-gen gcc -Wc -O3"
This is how my WinFBE now looks.
Download: SetCompilerSwitches.zip