>> First, thanks for such a nice package like FloatCanvas! It's really  
>> great!

You're welcome.

>> Is there any code for adding a scrollbar to my window?

This has been asked for a lot, but I haven't had the time to do it, and 
I don't if anyone else has. It really wouldn't be that hard, though.

>> I can't show what  
>> I want without a scrollbar

You have seen the "panning" tool (the hand icon) provided by NavCanvas 
-- it does let you move around the canvas. I know that scrollbars are 
often more appropriate and what people expect, but you can at least do 
the same thing with panning, in the meantime.

>> but I also don't have enough time to  
>> implement it myself. If anyone could support me with some code, this  
>> would be great.

Well, I don't really have time either, but if you get started, we will 
provide technical support.


Nitro wrote:
> I don't have any concrete code at hand, but I guess you can create a  
> wx.ScrollBar and add this to the right side of your canvas via a sizer.  
> Then you bind to wx.EVT_SCROLL and when you receive such an event you call  
> canvas.MoveImage based on the position of the scroll bar slider.

yes, that's the idea. The trick with scrollbars is that they assume that 
you know the virtual size of the contents of the Window. With 
FloatCanvas, the virtual size changes as you zoom, and when the overall 
bounding box changes when you add or remove items from the Canvas.

Depending on your application, these may not be hard to accommodate, but 
to make an all purpose scrolled canvas, these issue would have to be 
dealt with.

Can you describe your application? That would help us determine what you 
need.

-Chris


-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[EMAIL PROTECTED]
_______________________________________________
FloatCanvas mailing list
[email protected]
http://mail.mithis.com/cgi-bin/mailman/listinfo/floatcanvas

Reply via email to