gettingstarted
[Top] [All Lists]

Re: Scrolling graphs

To: Getting Started <gettingstarted at lists dot realsoftware dot com>
Subject: Re: Scrolling graphs
From: Barrie Jones <barrie at spamcop dot net>
Date: Mon, 25 Oct 2004 11:51:11 -0400
Delivered-to: gettingstarted at lists dot realsoftware dot com
References: <F72BBDEF-262A-11D9-9A86-000D93C6DE52 at spamcop dot net> <a05300b1dbda21f02e259 at [10 dot 10 dot 13 dot 6]>

On Oct 24, 2004, at 11:10 PM, Joseph J. Strout wrote:

At 10:09 PM -0400 10/24/04, Barrie Jones wrote:

Here is a basic question:
If I draw on a canvas with coordinates that extend beyond the window, will the window scroll bars be set up automatically?

No, you have to handle that yourself. Any drawing beyond the bounds of the canvas is simply clipped off. But when a scrollbar value changes, you get a ValueChanged event (or something like that), which you can use to redraw the canvas content -- such drawing to take into account the current values of the scrollbars, of course.

Thanks for the starter Joe. I have found some examples and need another guideline before I start. My graphs could be much larger than the computer screen. They are not too complex and draw very quickly. 1) Should I instantiate a canvas big enough for the oversize graphic such that only part of it shows in the window with scroll bars? Then just draw the graphs using coordinates of the oversize canvas. I then read scroll bars etc...
or
2) Having created the big canvas, should I use NewPicture to draw offscreen then place it on the big canvas.
or
3) Could I make a window sized canvas (locked to the window) and do my oversize graphics in a NewPicture, apply part of the NewPicture to the canvas and scroll the NewPicure on the smaller canvas.
Barrie

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://www.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>