Search found 1232 matches

by jj2007
Dec 07, 2017 15:25
Forum: General
Topic: Range Check (feature request)
Replies: 46
Views: 1442

Re: Range Check (feature request)

For comparison, the Masm32 implementation with case lower .. upper : include \masm32\include\masm32rt.inc .data a dd 46h .code start: .Repeat print "testing " print hex$(a), 9 switch a case 48h .. 4ah print "inside the range", 13, 10 default print "outside the range", 1...
by jj2007
Dec 07, 2017 8:07
Forum: General
Topic: (Z)String UTF8 Aware
Replies: 35
Views: 1347

Re: (Z)String UTF8 Aware

But the differences are not minor. For example, UTF-8 is 100% ASCII compatible while UTF-16 and UTF-32 are not. So I perfectly understand why UTF-8 was chosen over other encodings for most network data exchange. UTF-8 is often a very good solution, but it has its downsides. For example, 1.x Billion...
by jj2007
Dec 07, 2017 0:57
Forum: Windows
Topic: Does anyone know what algo XP -> full screen DOS?
Replies: 95
Views: 6534

Re: Does anyone know what algo XP -> full screen DOS?

Hi lizard, That works fine on Win7-64, but I am not sure if this is DOS fullscreen mode. If, for example, you use... IF SCREENRES(swidth /2 , sheight /2 ,8, ...then you get some kind of DOS-looking small window, plus a windowed DOS prompt. Not exactly "full". It seems more like FB trying t...
by jj2007
Dec 07, 2017 0:42
Forum: Community Discussion
Topic: What happened to the code of conduct thread?
Replies: 32
Views: 2578

Re: What happened to the code of conduct thread?

Some people put a lot of thought into their posting. The moderator just declared that the effort of these people have no value, no meaning. Right. Same for the "Making FreeBasic appealing to a wider audience" thread, which may not have pleased everybody but was an interesting clash of opi...
by jj2007
Dec 06, 2017 18:39
Forum: Projects
Topic: UTF-8 Variable Length String Library
Replies: 35
Views: 3189

Re: UTF-8 Variable Length String Library

This looks very promising, compliments for your hard work!
by jj2007
Dec 06, 2017 14:08
Forum: Beginners
Topic: ATARI basic to Free Basic
Replies: 7
Views: 913

Re: ATARI basic to Free Basic

JasonBF wrote:indeed it was in 1980 in the Atari company.
thanks for information
Attention that link is not what it seems!
by jj2007
Dec 06, 2017 9:43
Forum: Community Discussion
Topic: FreeBASIC Discussion December 2017
Replies: 42
Views: 5454

Re: FreeBASIC Discussion December 2017

BASIC is the Best Approach to Simple and Intelligent Coding, and FreeBasic is probably the best among the "serious" BASIC dialects that are alive and kickin'. It is fast, easy to learn, flexible and straightforward, and gives access to popular libraries.
by jj2007
Dec 06, 2017 8:29
Forum: General
Topic: (Z)String UTF8 Aware
Replies: 35
Views: 1347

Re: (Z)String UTF8 Aware

Anyway, I'm reminded of this very old article: https://www.joelonsoftware.com/2003/10/08/the-absolute-minimum-every-software-developer-absolutely-positively-must-know-about-unicode-and-character-sets-no-excuses/ That's a good read, really funny. And beware of peeling onions for 6 months in a submar...
by jj2007
Dec 06, 2017 1:26
Forum: General
Topic: (Z)String UTF8 Aware
Replies: 35
Views: 1347

Re: (Z)String UTF8 Aware

Not sure why there'd be flame wars over the length of the byte-encoded string, "€." I guess the guys on MASM32 forum don't really know much about character encodings and how they relate to unicode. You'd be surprised how much they know - assembler coders debug their code at processor leve...
by jj2007
Dec 05, 2017 15:01
Forum: General
Topic: (Z)String UTF8 Aware
Replies: 35
Views: 1347

Re: ZSTRING UTF8 AWARE

So something along these lines would be preferable: dim s as string = "€5,- sale" print uleft(s, 1) I had a clever idea: shell("chcp 65001") dim s as string = "€5,- sale" print left(s, len("€")) Sleep But it won't work, strangely enough. Apparently, FreeBasic...
by jj2007
Dec 05, 2017 8:47
Forum: General
Topic: (Z)String UTF8 Aware
Replies: 35
Views: 1347

Re: ZSTRING UTF8 AWARE

Printing a UTF-8 string on Windows will likely result in mojibake since by default the Windows console does not speak UTF-8. You can set codepage 65001 on Windows, and it will print exotic alphabets if they are installed . For example, I can see Russian with my Italian OS, but I can't see Chinese (...
by jj2007
Dec 03, 2017 23:08
Forum: Community Discussion
Topic: The RETURN of GOSUB
Replies: 34
Views: 8746

Re: The RETURN of GOSUB

So if that is your percentage in a BASIC source, one GOTO every 200 lines, that's OK ;-) As you might have expected, I don't agree with your math.: you'll have to convert HLL (FB) to ASM first, before counting the jump's (je, jnz, ..., simply all of them). A GOTO is an unconditional jump. That is a...
by jj2007
Dec 03, 2017 21:45
Forum: Tips and Tricks
Topic: benchmark sorts
Replies: 13
Views: 1259

Re: benchmark sorts

no problems here, tested with FB versions 1.04, 1.05 and 1.06 both 32 and 64 bit, what version are you using? FreeBASIC Compiler - Version 1.05.0 (01-31-2016), built for win32 (32bit) Copyright (C) 2004-2016 The FreeBASIC development team. standalone var s = 0f, mesg = "" if tA<tB then s ...
by jj2007
Dec 03, 2017 21:38
Forum: Community Discussion
Topic: The RETURN of GOSUB
Replies: 34
Views: 8746

Re: The RETURN of GOSUB

Munair wrote:cause of much debate and BASIC's bad reputation, it is just as legitimate as ASM jumps.

Just checked the presence of jmp in two big sources, about 0.5% of all lines. So if that is your percentage in a BASIC source, one GOTO every 200 lines, that's OK ;-)
by jj2007
Dec 03, 2017 17:12
Forum: Community Discussion
Topic: Passing command line arguments to FB programs
Replies: 20
Views: 1791

Re: Passing command line arguments to FB programs

Your code is crashing on my PC (Win 7). There is an asm int 3 that permits to run it with a debugger. If you have a just-in-time debugger configured, Windows will stop at the int 3 and invite you to debug it. Otherwise, open the exe e.g. in Olly (but if you are not familiar with assembler, it will ...

Go to advanced search