Oxygen Basic
Programming => Example Code => Topic started by: Peter on January 13, 2014, 07:23:50 AM
-
Deleted
-
That's a nice GDI demo Peter and a good start on O2 library. Do you have any interest in SDL?
-
A library for SDL 1.2 is already done. Unfortunately is it very slow.
I need a good keyboard handler for SDL 1.2 as Android SDL doesn't support UNICODE. I'm doing a hack with a C toupper() to shift my alpha keys but I need to handle shifted keys like the single quote and number keys for symbols. Do you have anything that might work you would be willing to share?
-
I need a good keyboard handler for SDL 1.2 as Android SDL doesn't support UNICODE.
Thanks for the reply. I'll keep looking. :-\
-
What I'm looking for is something more like this.
if (ev.key.keysym.mod & KMOD_SHIFT) ch += 0x10;
ch is the non-unicode ev.key.keysym.sym value. My hope is that I can just add/subtract from the SDL given value to create a shifted or control modified key value. I'm trying to create something so I don't have to define a big CASE statement of possible shifted keys that toupper isn't taking care of.
-
I got it working expanding on the existing SWITCH/CASE structure for keyboard processing.
Thanks Peter for making an attempt to help.
I have attached a beta release of Brandy BASIC V for Android. You need to enable off market apps in settings and use adb to install Brandy on your device. I've included some Brandy BASIC V examples you can run off your sdcard. I also included the Ubuntu 64 bit version Brandy BASIC V which will need at least SDL 1.2 runtime installed. Let me know if you run into any issues.
** Install **
1. enable off market apps in settings.
2. adb install brandy.apk
3. copy Brandy examples to your sdcard
LOAD|RUN "/sdcard/brandy/graphdemo"
Remember Brandy (BBC BASIC) likes upper case commands.
Update I was able to get RTB (Return to BASIC) working on Android as well. You can downloaded the Android and Ubuntu 64 bit versions of RTB from the www.AllBASIC.info/forum if your interested.
.