Shop OBEX P1 Docs P2 Docs Learn Events
rookie needing help — Parallax Forums

rookie needing help

DFDF Posts: 10
edited 2010-06-16 18:08 in Propeller 1
I am about 5 days in using the Prop demo board, and have little experience programming in spin or otherwise. In the vga demo programs there are boxes that look like buttons. Is there any way to make these buttons interactive and possibly bring up another screen? I would eventual like a create a start up menu of sorts with different options available. Any pointers at this point would be helpful. Thanks in advance...

Comments

  • StefanL38StefanL38 Posts: 2,292
    edited 2010-06-15 21:38
    quite a challenging project after 5 days with the propeller

    Text based GUI for VGA_HiRes_Text Driver

    best regards

    Stefan
  • ElectricAyeElectricAye Posts: 4,561
    edited 2010-06-16 02:25
    DF said...
    .... In the vga demo programs there are boxes that look like buttons. ....

    Yes, I got tricked by that, too. In the demo, those "buttons" are just for show but they are non-functional. Too bad the code in the VGA demo doesn't warn you about those buttons. However, there are indeed ways, as Stefan has indicated, to make VGA buttons or even texts that are clickable with a mouse, etc.

    Have fun!
  • jazzedjazzed Posts: 11,803
    edited 2010-06-16 02:55
    Try Rayman's window/forms code.
    www.rayslogic.com/propeller/Programming/BasicWindowForm/BasicForm.htm

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Pages: Propeller JVM
  • Paul BakerPaul Baker Posts: 6,351
    edited 2010-06-16 17:36
    Hi DF,
    Welcome to the Propeller and the forums.

    The buttons do not work as others have mentioned, they are there to demonstrate that there are special characters in the Propeller Font that display a beveled edge useful for displaying a button.

    Transforming the demo into an interactive program is certainly possible but may be a little difficult having just started to learn Spin. What is necessary is a program running on a an unused cog which monitors the mouse driver's button and current location. Comparing these coordinates to the button's coordinates upon a button event and performing the desired reaction.

    I would suggest starting off slow. Create the monitoring program and when you detect the button press do something simple like changing the color of the button, the text on the button or changing the colors on the bevel to make it look like the button has been pressed.

    From there you can start to tackle more complex behaviors like displaying menus and what not.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Paul Baker
  • DFDF Posts: 10
    edited 2010-06-16 18:08
    Thanks everyone for all the helpful tips. I can't wait to try some of the code. It looks exactly like what I wanted.
Sign In or Register to comment.