WinFBE Editor and FreeBASIC Compiler (All-in-One Package) (Updated June 3, 2018)

User projects written in or related to FreeBASIC.
deltarho[1859]
Posts: 1219
Joined: Jan 02, 2017 0:34
Location: UK

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby deltarho[1859] » Feb 24, 2018 13:44

Hi Paul

#print is not working. Never got it to work. Just tried it with poseidonFB, should have tried before now, and it works fine.
fxm
Posts: 8052
Joined: Apr 22, 2009 12:46
Location: Paris suburb, FRANCE

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby fxm » Feb 24, 2018 13:58

One can presently find the output in "Compiler Log File" (of "View Output Window").
Other IDEs also add it in "Compiler Results".
deltarho[1859]
Posts: 1219
Joined: Jan 02, 2017 0:34
Location: UK

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby deltarho[1859] » Feb 24, 2018 14:12

I made a point of checking that before posting. I did not spot it. The Log File had 13 lines and the #Print was in the sixth line - it was a single word. I must prefix with a bunch of '%', or something, to catch my eye.
fxm
Posts: 8052
Joined: Apr 22, 2009 12:46
Location: Paris suburb, FRANCE

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby fxm » Feb 24, 2018 14:15

It's why I proposed:
fxm wrote:Other IDEs also add it in "Compiler Results".
kcvinu
Posts: 137
Joined: Oct 07, 2015 16:44
Location: Keralam, India

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby kcvinu » Mar 05, 2018 19:24

Hi,
I am learning some new stuff from WinFBX framework. Such a giant library and it gives more simplicity to FreeBasic. Especially i love Cwstr library. It is must have for any language. Dynamic unicode string handling is a must have feature. By the way, i got stumbled upon the usage of period in some functions. For example, in CreateFont function.

Code: Select all

lPointSize = (lPointSize * m_DPI) \ .GetDeviceCaps(hDC, LOGPIXELSY)

See this line ? What is the meaning of that period in the left side of GetDeviceCaps. It is used in here too.

Code: Select all

tlfw.lfHeight         = -MulDiv(lPointSize, .GetDeviceCaps(hDC, LOGPIXELSY), 72)  ' logical font height

Can somebody please tell me how to understand this period usage. Thanks in advance
MrSwiss
Posts: 2585
Joined: Jun 02, 2013 9:27
Location: Switzerland

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby MrSwiss » Mar 05, 2018 19:51

First and foremost: this isn't the propper thread, for such question(s). Since it has no re-
lation to WinFBE (IDE for Windows).

Secondly "tlfw.lfHeight" it's most likely to be a: type.member access (type being a struct,
containing one or more member variables).

However, the ".GetDeviceCaps(hDC, LOGPIXELSY)" could probably also be used, without
the leading 'full stop' (period): GetDeviceCaps(hDC, LOGPIXELSY) afaik ... it's a WIN-API
call.
See: https://msdn.microsoft.com/en-us/library/windows/desktop/dd144877(v=vs.85).aspx
Josep Roca
Posts: 329
Joined: Sep 27, 2016 18:20
Location: Valencia, Spain

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby Josep Roca » Mar 05, 2018 20:17

> Can somebody please tell me how to understand this period usage.

To avoid possible name conflicts, present or future. It makes sure that it calls that symbol in the global namespace and not a duplicate symbol in another namespace.
kcvinu
Posts: 137
Joined: Oct 07, 2015 16:44
Location: Keralam, India

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby kcvinu » Mar 06, 2018 7:56

@MrSwiss,
I am really sorry for postting it here. I can't find any posts related to WinFBX. So i thought post it here.

Second - I dont have any doubts related to the member access. I asked about the win api function call. AFAIK, win api functions are calling without the period. And thanks for your reply.

@Josep Roca,
Thanks for your reply.
So you mean, you used the period because it should use the function from your afx namespace, right ?. But that statement araises some doubts to me. What is the difference between GetDeviceCaps() in Afx namespace and in the windows.bi ?
Josep Roca
Posts: 329
Joined: Sep 27, 2016 18:20
Location: Valencia, Spain

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby Josep Roca » Mar 06, 2018 8:08

> So you mean, you used the period because it should use the function from your afx namespace, right ?

No, it is just the opposite. I use the period to make sure that it will call the function in the FreeBasic's global namespace, not in the Afx namespace. It is a way to avoid present or future conflicts. Usually it is not needed.

There must be a better explanation in the FreeBasic documentation, although I only have found a mention in the "Namespaces" topic.

> AFAIK, win api functions are calling without the period.

Yes, but when you are inside a namespace or a WITH loop, you can use a ".", and when you are both inside a namespace and a WITH loop, you can use "..".
kcvinu
Posts: 137
Joined: Oct 07, 2015 16:44
Location: Keralam, India

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby kcvinu » Mar 06, 2018 10:27

@ Josep Roca,
Thank you for the reply. Well explained. Now, i got the answer. I have posted the same thing in Planset Square forum too. I will make the status to solved in that post.
MrSwiss
Posts: 2585
Joined: Jun 02, 2013 9:27
Location: Switzerland

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby MrSwiss » Mar 06, 2018 12:32

kcvinu wrote:I can't find any posts related to WinFBX. So i thought post it here.
Well, that sort of thing will happen again ... (most likely).
Just to give you a idea, how I decide, where to post what (can't speak for others):
    1) Does a section title fit straight away (then go there)
    2) If (as in this case) more than one section, might fit (choose the best fit)
    3) In case, there is no fitting thread existing, create a new one (try, to find a well fitting, short title)
    (Warning: its considered "bad news", to "rewarm dead threads",
    aka: for very long time unused threads (see last posts date).
    The reason should be obvious -- FBC's advancements over time.)
e.g. here -- you have: Beginners/General/Libraries to choose from, IMHO.
I'd vote for Libraries since, it seems to be the best fit (others might tend to General).
I'd rule out Beginners, since Libraries in any "shade or form" can be called advanced.
kcvinu
Posts: 137
Joined: Oct 07, 2015 16:44
Location: Keralam, India

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby kcvinu » Mar 06, 2018 15:12

@MrSwiss,
Thanks. for the suggestions. this will be in my mind next time i post something in this forum.
deltarho[1859]
Posts: 1219
Joined: Jan 02, 2017 0:34
Location: UK

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby deltarho[1859] » Mar 10, 2018 20:42

The freebasic_keywords.txt, in the Settings folder, that ships with WinFBE is 4,151 bytes. Mine is currently at 29,968 bytes because it has some APIs thrown in. I hope Paul dos not mind. You will not find every API under the sun but there are a few in there.

Unfortunately to get this to work I could not keep any capitalization within an API name otherwise it got ignored and showed black. So, QueryPerformanceCounter shows as Queryperformancecounter. I don't know why but there is 'WinAPI Keywords' in the Colors and Fonts dialog but I could not see how that could be implemented.

Make sure that you keep a copy of the original freebasic_keywords.txt - always makes sense to copy originals. <smile>

Here is a screenshot.

Image

freebasic_keywords.txt
dmontaine
Posts: 1
Joined: Mar 15, 2018 7:13

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby dmontaine » Mar 15, 2018 7:16

Is there any way to turn off the capitalization of Basic keywords? i know it is the common style for BASIC programming. It's just not the Style I usually use.
deltarho[1859]
Posts: 1219
Joined: Jan 02, 2017 0:34
Location: UK

Re: WinFBE FreeBASIC Editor for Windows (Updated September 27, 2017)

Postby deltarho[1859] » Mar 15, 2018 13:24

Options>Environment Options>Code Editor

At the bottom right there is a drop down menu, Case:

You can choose from Lower case, Upper case, Mixed case and Original case.

Return to “Projects”

Who is online

Users browsing this forum: No registered users and 4 guests