Jump to content
Software FX Community

ZoomIn and constant lines


User (Legacy)
 Share

Recommended Posts

Hi

I am using constant lines and am allowing users to drag these along the axes

to reposition them.

I also want the user to be able to zoom in on a particular area (so I set

the chart.zoom = true on clicking of a zoom-label).

All goes well so far - when the label is clicked the user is allowed to

zoom. However, now when I try to drag the constant line again the chart

thinks I am zooming in again.

How can I leave a zoomed area the way it is and set chart.zoom = false so I

can drag my constant lines again?

I also tried to read in the x,y coordinates on mouse-down and again x,y on

mouse-up and used these as the basis for chart.zoomin method. All goes

well - it zooms in but automatically sets the chart.zoom property to true so

I can't drag my constant lines anymore... and when I set this property to

false it restores my chart, which I don't want at that stage.

Regards

Marcel Heeremans

Link to comment
Share on other sites

I've been thinking about this and I came out with this:

What you need is to set Zoom = false but before doing that, you need to make

the scale changes permanent by using SetScrollView.

Here is the procedure:

1.- Use GetScrollView for both the X and Y axis to get the current view

2.- Set Zoom = false

3.- Use SetScrollView to set the current view to the values obtained in 1.

--

FP

Software FX, Inc.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...