01-20-2025, 09:54 PM
(01-15-2025, 05:50 AM)bplus Wrote: Also I noticed 2 things comparing QBJS code and QB64:
1) str$(number) in QBJS does not leave that space before a positive number as in QB64, so you have to _TRIM$() in QB64 so they look the same in print.
2) the _delay amounts aren't matching up, ie flashing that solved message in QB64 is way faster than in QBJS. had to fiddle to get a compromise.
Yeah I am still into having both codes work as closley to the same way as possible.
Hey @bplus, I looked into the _Delay issue a bit further and found that, at least on my box, I'm seeing a slightly more consistent delay in QBJS than in QB64. Consider the following program:
Code: (Select All)
Dim first
first = Timer
_Delay 2
Print Timer - first
first = Timer
_Delay 1
Print Timer - first
first = Timer
_Delay .5
Print Timer - first
first = Timer
_Delay .25
Print Timer - first
first = Timer
_Delay .1
Print Timer - first
When I run this in QBJS (in Edge/Chromium), I get the following:
(I get an almost identical result in Firefox too)
For QB64 2.0.2:
For latest QB64PE:
I suspect that what you were seeing may be more related to how quickly (or often) the browser updates the title or some other aspect of the program.