April 10, 2020, 08:04:46 AM

Author Topic: 0.12.18 released  (Read 775 times)

Offline lettersquash

  • Jr. Member
  • **
  • Posts: 58
    • Lettersquash Blog
Re: 0.12.18 released
« Reply #15 on: March 24, 2020, 11:50:08 PM »
here's a better example for being a bit simpler.

I have tried your example. The problem of "Inkey" is typematic delay: when I press a key but don't release, the "@" will move one step, then will stop a moment, then will move again. I see, "@" did not move continuously. It is a problem.
Hmm, yes, thanks, maybe that's all it is. It is of course dependent on the typematic delay, but it will also depend on the speed the interpreter processes the command. Maybe it's as fast as it should be, whatever that means, I was just surprised that I can't write code with flow control via some keys in the way I expected. However, I checked out the same kind of test in BBC BASIC for Windows, and that wasn't any better.

The repeat rate in my keyboard settings is on maximum (it isn't continuous, of course, but repeated). I also realise the speed isn't going to be like it is in a text box, and I'm printing at the graphics cursor - changing to a suitable locate y,x command speeds up both loops to the eye and the physical distance moved across the screen - but proportionally; the keyboard polling takes a good lump of time (technical term ;) ). Oh well, another lesson. I have a feeling my old Acorn Electron from 1983 used to respond to key presses much faster - maybe because it only had a very limited set of tasks.

Offline lettersquash

  • Jr. Member
  • **
  • Posts: 58
    • Lettersquash Blog
Re: 0.12.18 released
« Reply #16 on: March 25, 2020, 12:01:37 AM »
sbasicg.exe -- It is an editor with dark texts(dark green, dark grey, etc.) and black background. Therefore, it is hard to view. If colours can be changed, this editor will be suitable for editing.

Did you see this? Scroll down to "How to help design a better looking editor color theme" https://smallbasic.github.io/pages/sdl.html

I've not tried it yet, and it describes a manual method rewriting the settings file, but I intend to have a go soon....or just trying one of the others with alt-t might suit you.

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #17 on: March 25, 2020, 12:25:12 PM »
Did you see this? Scroll down to "How to help design a better looking editor color theme" https://smallbasic.github.io/pages/sdl.html

Thank you!!! I have edited the text file and the file name is settings.txt. I uploaded to this forum. You can download in this post and the colour combination may be liked by you.

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #18 on: March 25, 2020, 01:35:16 PM »

Cheers,

A proposal: a theme for sbasicg.exe was made by me. If you think that this theme is okay, you can set this theme as one of the default themes for the next version of SmallBASIC. Here:
https://www.syntaxbomb.com/index.php/topic,7521.msg347040931.html#msg347040931


Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #19 on: March 25, 2020, 10:49:39 PM »

Hmm, yes, thanks, maybe that's all it is. It is of course dependent on the typematic delay, but it will also depend on the speed the interpreter processes the command. Maybe it's as fast as it should be, whatever that means, I was just surprised that I can't write code with flow control via some keys in the way I expected. However, I checked out the same kind of test in BBC BASIC for Windows, and that wasn't any better.


First, I am only a learner of programming. Second, I am not too familiar with SmallBASIC. I hope that chrisws will solve the keyboard control problem in the next version of SmallBASIC.

Nevertheless, I know that BBC BASIC for Windows is suitable for game development. I think that there is no keyboard control problem with BBC BASIC for Windows.:)

Many games made with BBC BASIC for Windows can be downloaded from this website. Ha...no keyboard control problem.
http://www.proggies.uk

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #20 on: March 26, 2020, 12:24:08 AM »

Cheers,

Hi...

Another proposal: add this feature to the next version of sbasicg.exe: make EXE file -- pack sbasicg.exe and one source code file into one single executable file.

Two purposes:
1. SmallBASIC users can distribute their finished programs to end-users easily.
2. Source code will not be viewed easily by end-users. Thus source code will be protected.

Offline bplus

  • Full Member
  • ***
  • Posts: 131
Re: 0.12.18 released
« Reply #21 on: March 26, 2020, 02:41:31 PM »

Cheers,

Hi...

Another proposal: add this feature to the next version of sbasicg.exe: make EXE file -- pack sbasicg.exe and one source code file into one single executable file.

Two purposes:
1. SmallBASIC users can distribute their finished programs to end-users easily.
2. Source code will not be viewed easily by end-users. Thus source code will be protected.

It's a lot of work building a compiler for an interpreter!

If you want EXE's I suggest trying QB64, 0 interpreter. Funny some of the guys at that forum are asking for Interpreter too, like the old QB45 when a highly paid professional team of software engineers put together a package that could do both!

And it is a hell of allot easier to distribute SmallBASIC programs, it is not much more than a txt file, you can email them! What's so hard getting SmallBASIC to run them?

Accept it for what it is, a damn fine Basic Interpreter.

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #22 on: March 27, 2020, 04:07:59 AM »

Cheers,

Hi...

Another proposal: add this feature to the next version of sbasicg.exe: make EXE file -- pack sbasicg.exe and one source code file into one single executable file.

Two purposes:
1. SmallBASIC users can distribute their finished programs to end-users easily.
2. Source code will not be viewed easily by end-users. Thus source code will be protected.

It's a lot of work building a compiler for an interpreter!


Hi... I didn't mean "compile". Not "compile". I said "pack". I meant "embed" or "attach". I try to explain with my insufficient knowledge:

The interpreter(sbasicg.exe) and the source code are embedded in one EXE file, but there is no compilation in the process. "Combine" may be a suitable adjective. The source code is hidden because it is inside the EXE file. Moreover, if obfuscation or encryption can be done for the source code before "comblne", the source code will be safely protected(not only hidden).

A near comparison is Python(not exactly the same). Python source code files are .py files. Some small softwares can convert .py files to EXE files, so finished program distribution will be easier.

Offline bplus

  • Full Member
  • ***
  • Posts: 131
Re: 0.12.18 released
« Reply #23 on: March 27, 2020, 02:20:40 PM »
Quote
Hi... I didn't mean "compile". Not "compile". I said "pack". I meant "embed" or "attach". I try to explain with my insufficient knowledge:

Oh yeah! the SDLBasic method, OK now I understand. Crypt the bas source, and attach to the end of a special version of SB that tells itself to find the encrypted part of itself at the end of normal SB.exe, decrypt and run that decryption, piece of cake!  ;-)

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #24 on: March 28, 2020, 12:46:55 AM »
Quote
Hi... I didn't mean "compile". Not "compile". I said "pack". I meant "embed" or "attach". I try to explain with my insufficient knowledge:

Oh yeah! the SDLBasic method, OK now I understand. Crypt the bas source, and attach to the end of a special version of SB that tells itself to find the encrypted part of itself at the end of normal SB.exe, decrypt and run that decryption, piece of cake!  ;-)

Thanks for your kind support! Chris may not have this kind of programming knowledge or skill. I expect that Chris searches other programming webpages for this kind of programming skill and learns how to apply this kind of skill in version 0.12.19.

"Generate EXE file" feature will be very helpful to SmallBASIC users.


Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #25 on: March 28, 2020, 07:34:01 AM »

Cheers,


One more proposal for version 0.12.19: it is about sbasicg.exe. On the "source code page", after I changed the colours of the texts, it is easy to view the texts on this page. However, the colours of the three kinds of texts on the "directory page" cannot be changed. It is still difficult to view the three colours of the texts on this page. My proposal is that SmallBASIC users can set the colours of the three kinds of texts of the "directory page" by editing the settings.txt file.

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #26 on: March 28, 2020, 07:37:04 AM »

Cheers,

Another proposal: typematic delay makes game control development impossible.
??? :(
https://www.syntaxbomb.com/index.php/topic,7552.0.html

Offline round157

  • Sr. Member
  • ****
  • Posts: 318
Re: 0.12.18 released
« Reply #27 on: March 31, 2020, 11:59:15 PM »
One more proposal: source code files of SmallBASIC are .bas files. Source code files of many other BASIC dialects are .bas files as well. Some SmallBASIC users will be in confusion. I have an idea. Using .sb as the file extension in future versions of SmallBASIC can avoid confusion.

Offline k1

  • Jr. Member
  • **
  • Posts: 8
Re: 0.12.18 released
« Reply #28 on: April 01, 2020, 07:31:25 PM »
@author

Is there something like "continue" (skip a for-loop iteration)? Referece/language does not yield any such.

Offline lettersquash

  • Jr. Member
  • **
  • Posts: 58
    • Lettersquash Blog
Re: 0.12.18 released
« Reply #29 on: April 01, 2020, 07:51:40 PM »
@author

Is there something like "continue" (skip a for-loop iteration)? Referece/language does not yield any such.
I noticed that. I can't find anything, and it would be useful, but you can use the goto method.
repeat
  blah
  if blah then goto misstherest
  blah blah blah
  blah, this is actually how I program, blah
  label misstherest
until damned

Unfortunately, I also find the internal NEXT doesn't work:

for x=1 to 5
blah
if x=2 then next
...
other numbers are fine blah
...
next

That gives an error about missing a NEXT on the same level as the FOR.

 

SimplePortal 2.3.6 © 2008-2014, SimplePortal