PuppyLinux : WxBasic

PuppyLinuxMainPage :: Categories :: PageIndex :: RecentChanges :: RecentlyCommented :: Login/Register
Most recent edit on 2007-11-23 14:55:45 by Wosh

Additions:

CategoryDevelopment




Edited on 2007-03-13 23:56:10 by BostonVaulter

Additions:
The special Puppy version of WxBasic is WxBasicscript:

Deletions:
The special Puppy version of WxBasic is wxbasicscript:



Edited on 2007-03-13 23:54:22 by BostonVaulter

Additions:
See also: PuppyBasic and WxBasicscript

Deletions:
See also: PuppyBasic



Edited on 2005-12-02 13:55:24 by KethD

Additions:
See also: PuppyBasic The special Puppy version of WxBasic is wxbasicscript:
http://noforum.de/wxBasicscript-documentation/wxbasic/frameset.htm
http://noforum.de/wxBasicscript-documentation/wxbasicscript/index.htm
wxbasicscript is included in Puppy 1.0.5 and 1.0.6
* Change to executable with ROX (or use manual method to execute directly)


Deletions:
* Change to executable with ROX



Edited on 2005-11-07 06:18:31 by CrustyLobster

Additions:
Puppybasic is a command line version optimized for Puppy usage with xmessage and xdialog
Programs using wxBasic (not PuppyBasic)


Deletions:
Puppbasic is a command line version optimized for Puppy usage with xmessage and xdialog
Programs using wxBasic (not Puppybasic)
Wxbasicscript
It will be installed together with the example:
http://www.murga.org/%7Epuppy/viewtopic.php?t=2182




Edited on 2005-11-07 06:16:36 by CrustyLobster

Additions:
Puppbasic is a command line version optimized for Puppy usage with xmessage and xdialog
Programs using wxBasic (not Puppybasic)
PuppyBasic scripts should have the suffix ".wxbs" to avoid confusion with ".wxb" programs


Deletions:
wxbasicsh is a command line version optimized for Puppy usage with xmessage and xdialog
Programs using wxBasic (not wxbasicscript)
wxbasicscript- scripts should have the suffix ".wxbs" to avoid confusion with ".wxb" programs




Edited on 2005-11-07 06:07:35 by CrustyLobster

Deletions:
image

Running Programs

How does one execute a wxbasic program?
Do you just type 'wxbasix [filename]'?
When in Puppy any file with the extension .wxbs would be interpreted as a runnable program
For now use rxvt
Create a program in a text editor and save for example
helloworld.wxbs
#!/usr/bin/wxbasicscript
Tutorial for Puppy 1.0.5 wxBasic - Lobster Sep 2005, uses Puppy wxbasicscript created by Mark Ulrich

include "/usr/lib/wxbasicscript/basefunctions.inc"

result = xmessage ( "-buttons About_Basic,Lesson1,Lesson2,Lesson3,Reference Welcome to the Puppy wxBasic Tutorial Please choose" )
xmessage ( result )

MSG = ""
if result = "About_Basic" then MSG = "you chose about"
if result = "Lesson1" then MSG = "you chose Lesson 1"
if result = "Lesson2" then MSG = "you chose Lesson 2"
if result = "Lesson3" then MSG = "you chose Lesson 3"
if result = "Reference" then MSG = "you chose Reference"
if result = nothing then MSG = "you closed the window"
xmessage ( MSG )
Running the code:
#wxbasicsh helloworld.wxbs (you must have wxbasicscript - details to follow shortly - this page being developed)
or
wxbasicsh myprogram.wxbsh
You also might add the line
#!/usr/bin/wxbasicscript
to your program file as the first line to main.wxb, and make it executable:
chmod 755 main.wxb
Then you can start it like a "main.exe":
./main.wxb
(or click on it in rox)
Nb:
Lines beginning with
are comments and will be ignored during execution.




Oldest known version of this page was edited on 2005-10-26 13:54:51 by BarryDavidKauler []
Page view:
image

WxBasic is written primarily in C, with some C++ linking it to the wxWidgets library. The Puppy version has the WxWidgets components removed

WxBasic is a small interpreted version of the BASIC (Beginners All-purpose Symbolic Instruction Code) programming language - available in Puppy 1.0.5
WxBasic is based on the easy-to-use syntax of the BASIC language, it is simple to learn and understand, allowing novice programmers to write nice-looking Puppy applications with graphical environments and is being made available as a dotpup/pupget

It can create stand-alone executables by binding together source code with the interpreter. Executables produced by WxBasic do not require any external resource file, or installer to run. The executable is distributed alone and can be run immediately by end users. As with programs written in any interpreted language, WxBasic programs may also be run straight from the source code if wxBasic is present on the system, regardless of which system they were written on. This saves download time, as generated executables tend to be several orders of magnitude greater than the source code from which they were compiled.

WxBasic is a bytecode based language, like Perl or Java.

wxbasicsh is a command line version optimized for Puppy usage with xmessage and xdialog
wxbasic is the graphical version with "inbuilt" dialogue windows - available as a dotpup

Installing


Wxbasic Tutorial
Programs using wxBasic (not wxbasicscript)

add download location of wxbasic
and wxbasicscript

Wxbasicscript
It will be installed together with the example:
http://www.murga.org/%7Epuppy/viewtopic.php?t=2182

wxbasicscript- scripts should have the suffix ".wxbs" to avoid confusion with ".wxb" programs

WxBasic use:


* Write your program using a text editor (even Leafpad / Beaver) into a file with the .wxbs extension;
* Change to executable with ROX

Advanced use:
* Use ConText editor, after configurig it
http://www.geocities.com/lcassioli/wxbasic/

Running Programs


How does one execute a wxbasic program?
Do you just type 'wxbasix [filename]'?

When in Puppy any file with the extension .wxbs would be interpreted as a runnable program

For now use rxvt
Create a program in a text editor and save for example

helloworld.wxbs

#!/usr/bin/wxbasicscript

Tutorial for Puppy 1.0.5 wxBasic - Lobster Sep 2005, uses Puppy wxbasicscript created by Mark Ulrich

include "/usr/lib/wxbasicscript/basefunctions.inc"

result = xmessage ( "-buttons About_Basic,Lesson1,Lesson2,Lesson3,Reference Welcome to the Puppy wxBasic Tutorial Please choose" )
xmessage ( result )

MSG = ""
if result = "About_Basic" then MSG = "you chose about"
if result = "Lesson1" then MSG = "you chose Lesson 1"
if result = "Lesson2" then MSG = "you chose Lesson 2"
if result = "Lesson3" then MSG = "you chose Lesson 3"
if result = "Reference" then MSG = "you chose Reference"
if result = nothing then MSG = "you closed the window"
xmessage ( MSG )

Running the code:
#wxbasicsh helloworld.wxbs (you must have wxbasicscript - details to follow shortly - this page being developed)

or
wxbasicsh myprogram.wxbsh

You also might add the line
#!/usr/bin/wxbasicscript
to your program file as the first line to main.wxb, and make it executable:

chmod 755 main.wxb

Then you can start it like a "main.exe":
./main.wxb
(or click on it in rox)

Nb:
Lines beginning with
are comments and will be ignored during execution.
Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by Wikka Wakka Wiki 1.1.6.0
Page was generated in 0.2930 seconds