• Steam recently changed the default privacy settings for all users. This may impact tracking. Ensure your profile has the correct settings by following the guide on our forums.

meh another osk.

RedHate

I can has hax nao?
upper case
54b16fa5470522.png


lower case
54b16fa54ae847.png


This osk was made to be used with graphics.c and graphics.h

----------------------------------------------
how to use:
----------------------------------------------
to use this just place this:

#include "redskeys.h"

with your includes and this:

load_kb_images();

in your main function BEFORE your main loop (if you are using a loop)
you dont want it repeatedly reloading images.

next the call to the keyboard should be placed under a button press but
feel free to call it how you want here is the function's call

kb_input(mybuffer, 100, 60); //100 and 60 are x y co-ordinates.

this will open the buffer: "mybuffer" for editing and draw the keyboard
int the center of the screen, at the moment the keyboard only supports
typing in 46 chars so a target buffer longer then that will have un-used
blocks.

*a tip, if you open the keyboard and it glitches out the background..
adding another call to your menu draw function will help smooth it out.

for example:

Draw_Menu();
kb_input(mybuffer, 100, 60);

----------------------------------------------
making your own keys?:
----------------------------------------------
name dimensions
----------------------------
kbkey1.png 30 x 30
kbkey2.png 30 x 30
kbrow.png 30 x 390

----------------------------------------------
don't use alpha image keys:
----------------------------------------------
alpha image's are only ok if the alpha is 100% tranclucent. tinted areas
will draw until they are a solid color and look like complete CRAP. since
the main ui bg isnt cleared each time the keyboard cycles, it draws its
own buffer screen buffer until it exits.

good luck
 

Attachments

  • redskeys.zip
    18.2 KB · Views: 110

Roe

Well-Known Member
Nice one RedHate, is easily adapted to my own code. I'll be using this one instead of the sony one.
 

RedHate

I can has hax nao?
glad you like it. though there is one thing that bothers me... the buffer is 47 chars max ... D: would be nice to update it so it expands the input buffer's little graphical area to suit the amount of characters in the string.. but the gu one also max's out @ a certain amount also so it's a toss up.
 
Top