Search found 2095 matches

by caseih
Dec 17, 2016 15:35
Forum: Libraries & Headers
Topic: ustring: Dynamic zstring library.
Replies: 12
Views: 6264

Re: ustring: Dynamic zstring library.

Just curious why you are using a zstring buffer when a normal dynamic string would work as well, and you could use the existing dynamic properties of it (automatic allocation of memory, expanding when necessary, etc). Also a dynamic string will cast to zstring easily, and has an implicit null termin...
by caseih
Dec 13, 2016 6:48
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

QB was both an interpreter and a compiler. By default it ran as an interpreter in the IDE, and code was live as you developed, which was a super great way to do things. Then you could have it crank out an EXE that was either an interpreter bound to a parsed version of your BASIC code (PCODE I think ...
by caseih
Dec 12, 2016 5:39
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

Yes visual studio does have a very powerful debugger and you can recompile sections of code while it's still running. Replace running code. I don't know of any other debugger that can do that. But a debugger isn't what I was talking about with qb. Intermediate mode is not just about inspecting varia...
by caseih
Dec 10, 2016 21:16
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

Yeah I always forget the semicolons too. They are nice in that they allow lines to continue without having to have a special character like FB requires (_) or Python (\) but generally I could do without. And after programming in Python for quite a while I now despise braces. They look so ugly to me ...
by caseih
Dec 10, 2016 20:50
Forum: Beginners
Topic: How does Unicode work in FreeBASIC?
Replies: 10
Views: 3874

Re: How does Unicode work in FreeBASIC?

Bear in mind that for FB to properly recognize unicode string literals in your source code, you have to make sure the .BAS file is saved as a UTF-8 or UTF-16 file with the byte-order marker. UTF-8 does not normally use a BOM, as it's not needed normally, but FBC needs that to recognize that the file...
by caseih
Dec 10, 2016 13:42
Forum: Beginners
Topic: How does Unicode work in FreeBASIC?
Replies: 10
Views: 3874

Re: How does Unicode work in FreeBASIC?

All FB can natively work with are WStrings, where each character or codepoint is made up of 1 wchar. A wchar on Linux is 4-bytes (can represent all of current unicode with one wchar per codepoint). On Windows, wchar is 2-bytes. This means that for unicode codepoints that fall inside what's called th...
by caseih
Dec 10, 2016 5:39
Forum: Beginners
Topic: How does Unicode work in FreeBASIC?
Replies: 10
Views: 3874

Re: How does Unicode work in FreeBASIC?

Utf-8 is a variable length encoding. You look at the first byte to tell if there's another byte to look at or more to decode to a Unicode codepoint. Now fb doesn't know anything about utf-8. All it understands are wide characters which is 2-bytes per codepoint in Windows (actually it's utf-16 but fb...
by caseih
Nov 28, 2016 7:35
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

That was the main question as in practice I understand the Python interpreter to be written in languages like C and Java. The version of Python most used is written in C. There are versions written in c# (ironpython) and Java (jython). I have no need to extend Python only to translate FreeBASIC pro...
by caseih
Nov 28, 2016 7:28
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

Python is a very high level language so all hardware access is done via c libraries and calls. I'm not sure what kind of hardware libraries you are taking about that are based on Python. I'm sure under it there are c libraries or c code and that could be ported to fb or used from fb. What is this ha...
by caseih
Nov 26, 2016 5:16
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

sadly fbfrog cannot translate the Python .h files. It's getting hung up on a symbol __WORDSIZE, which is really supposed to be internal to glibc and gcc. Even though Python's .h files are importing a linux header file that defines that, fbfrog isn't seeing it for some reason.
by caseih
Nov 26, 2016 4:59
Forum: Community Discussion
Topic: Can Python be written in FreeBASIC?
Replies: 25
Views: 7981

Re: Can Python be written in FreeBASIC?

Yeah Boost will be of no use to FreeBASIC programmers since it's about C++, which FB has little support for. But actually the Python C API is not that bad really. The beauty of it is that there's no difference whether you embed Python in your C program or whether you are extending Python with a C mo...
by caseih
Nov 24, 2016 0:01
Forum: Community Discussion
Topic: Windows cmd.exe to be deposed by PowerShell
Replies: 14
Views: 4154

Re: Windows cmd.exe to be deposed by PowerShell

Surface Pro is nearly a complete laptop, just more expensive. It attacks the Apple Air, not the IPad. Yes it is, but the people I've seen using them are using them almost exclusively in tablet mode. They see it as a Tablet that can run full MS Excel. And they use the onscreen keyboard too, leaving ...
by caseih
Nov 23, 2016 17:09
Forum: Community Discussion
Topic: Windows cmd.exe to be deposed by PowerShell
Replies: 14
Views: 4154

Re: Windows cmd.exe to be deposed by PowerShell

Well, MS has always been a software company. So it makes sense that they would focus on the software platform to enable mobile rather than try to do hardware themselves, such as the Lumia phone. Strangely enough my laptop is more mobile than my tablet is :_) I agree, for most of the things I do. For...
by caseih
Nov 23, 2016 14:01
Forum: Community Discussion
Topic: Windows cmd.exe to be deposed by PowerShell
Replies: 14
Views: 4154

Re: Windows cmd.exe to be deposed by PowerShell

Don't mistake Windows Phone for mobile. UWP is all about mobile. That's it's whole point. The idea is one UI and platform that can adapt to any size screen from a phone or tablet to a HiDPI desktop. Microsoft very much has not deprecated mobile. The difference is that there's no more mobile operatin...
by caseih
Nov 23, 2016 4:28
Forum: Community Discussion
Topic: Windows cmd.exe to be deposed by PowerShell
Replies: 14
Views: 4154

Re: Windows cmd.exe to be deposed by PowerShell

Are you sure about that? As far as I know universal windows apps (metro) are all dot net. And they run on arm mobile or x86. So no dot net is not dead or deprecated in mobile. And actually ms is pushing dot net as a cross platform mobile development system now that they bought Xamarin. With one code...