[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [paragui-users] Several questions concerning paraGUI
From: |
Ulf Lorenz |
Subject: |
Re: [paragui-users] Several questions concerning paraGUI |
Date: |
Tue, 20 Dec 2005 12:12:15 +0100 |
User-agent: |
Mutt/1.5.11 |
On Fri, Dec 16, 2005 at 03:54:31PM +0200, ??????? wrote:
> 1.please, show me how to change the look of Scroll in ListBox. Give me the
> example, please.
Would liek to help, bu I don't understand what you want. Which look do
you want to change?
> 2.how to use the timer (every second should be read from the file as a
> symbol) with example, please
Derive from PG_TimerObject and use AddTimer and eventTimer. I have
attached an example from our game.ch contains a lot of noise, but I
wasn't sure how much to remove. Look at the functions
SmallMap::restartTimer() and SmallMap::eventTimer().
> 3.how to generate the signal of pressing the key at any event (without
> actually pressing the key on keyboard), for example, keys UP DOWN.
> With example, please.
I cannot provide an example yet. Want to do two other patches first. But
since I once decided to have a look at this mechanism anyway, there will
be one hopefully till Christmas.
Until then, as general pointers:
- Take the cvs sources (the mechanism changed a lot since 1.1.8 and is
now much easier).
- Derive a new class from PG_EventSupplier and rewrite the abstract
functions, so that they generates keyboard events from whatever source
you prefer. (most important is PollEvents; a blueprint for the others
can be found in the class PG_SDLEventSupplier)
- call PG_Application::SetEventSupplier and set your own class as event
supplier.
Maybe this gets you started a bit.
cu,
Ulf
--
recursive:
see recursive
smallmap.cpp
Description: Text Data
smallmap.h
Description: Text Data