[comp.sys.amiga.programmer] Scrolling a SuperBitMap

swildner@channelz.gun.de (Sascha Wildner) (04/27/91)

I have some problems scolling a BitMap in a Window. I've opened a window
with width 320 and height 256. It is a SuperBitMap Window (the BitMap has
the dimensions 640x512). In the right and bottom borders of the window there
are proportional gadgets for scrolling the BitMap around.

Which IDCMPFlags (and other flags) do I have to set to get a IntuiMessage
each time the gadgets are used? If I set FollowMouse in the Gadget structures
and MouseMove in the Window structure I get a message every time the mouse
is pressed over a gadget and moved. But since the BitMap can sometimes have
the same dimensions as my window (thus the user can see the whole BitMap)
this is not exactly what I want as I then also get messages (although those
gadgets are useless).

Can anybody help me?


--
sascha wildner         swildner@channelz.gun.de
am druvendriesch 27    ...!{tmpmbx|mcshh|smurf|unido}!easix!channelz!swildner
5030 huerth 6
++49-2233-15571        "A sucker is born every minute."

ken@cbmvax.commodore.com (Ken Farinsky - CATS) (04/29/91)

In article <swildner.3198@channelz.gun.de> swildner@channelz.gun.de (Sascha Wildner) writes:
>I have some problems scolling a BitMap in a Window. I've opened a window
>with width 320 and height 256. It is a SuperBitMap Window (the BitMap has
>the dimensions 640x512). In the right and bottom borders of the window there
>are proportional gadgets for scrolling the BitMap around.
>
>Which IDCMPFlags (and other flags) do I have to set to get a IntuiMessage
>each time the gadgets are used? If I set FollowMouse in the Gadget structures
>and MouseMove in the Window structure I get a message every time the mouse
>is pressed over a gadget and moved. But since the BitMap can sometimes have
>the same dimensions as my window (thus the user can see the whole BitMap)
>this is not exactly what I want as I then also get messages (although those
>gadgets are useless).
>--
>sascha wildner         swildner@channelz.gun.de
>am druvendriesch 27    ...!{tmpmbx|mcshh|smurf|unido}!easix!channelz!swildner

Read the example "lines.c" in the Libs&Devs ROM Kernel manual (the blue one).
It is a very good example of using a super bitmap window (although the prop
gadgets do not adjust properly for the font changes in a 2.0 window...)
I believe that the examples from libs&devs are on one of the fish disks (344?).
-- 
--
Ken Farinsky - CATS - (215) 431-9421 - Commodore Business Machines
uucp: ken@cbmvax.commodore.com   or  ...{uunet,rutgers}!cbmvax!ken
bix:  kfarinsky