Re: How to make a "zoom" in the gtkplot

Al Hooton <[email protected]> Wed, 08 Feb 2006 21:45:14 -0800
Newsgroups gmane.comp.scigraphica.gtkextra
Message-ID <[email protected]>
On Wed, 2006-02-08 at 17:11 -0300, Alexandre wrote:
>   I want to know how can I make a zoom in my plot. The first thing
> that came to my mind is rescale, putting a lower range. But when I do
> it sometimes things goes wrong (when there is no major ticks in the
> range), subject that I've already discussed in teh list..
>   Someone knows a way for zoom any area of the plot?

	I think you've got it there already -- you need to reset the X axis so
there is always at least one major tick.  In my app it is possible that
I only have a single major tick, at the far end of the axis, but I
always have at least that one.  I also have to rescale the X axis at
times in my app (although always larger, never smaller), and I just do
it by changing the X axis scale, redrawing the plot (which calls the
tick handler to define the new tick values based on the new X axis
scale), and replotting my data.

	Why would you want to rescale the Xaxis so there is not at least one
major tick at the very end?  I've never tried it, but I wouldn't think
it would work...   Adrian?

-Al





-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642