octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: rudimentary tick positions


From: Michael Goffioul
Subject: Re: rudimentary tick positions
Date: Mon, 4 Feb 2008 23:03:32 +0100

On 2/4/08, Shai Ayal <address@hidden> wrote:
> attached is a patch for rudimentary tick position calculations. It is
> a translation of Tom Holroyd's python code which he posted to this
> list some weeks ago (Tom, I hope that by posting the code here you
> agreed to it's use in octave ...).
> What is missing is:
> *) log axes ticks
> *) minor ticks
> *) does not take into account the axes size and font size to eliminate
> tick overruns
> *) gnuplot interaction
> *) your favorite feature here
>
> Still, I think it is good enough to serve as a basis to the above 
> improvements.

Shouldn't autoscale and autotick be combined (axis limits are extended to
the next tick)?

I was thinking about something like (in algorithmic language):

if (axis_mode == "auto")
  limits = get_raw_limits(); // compute raw limits based on children
else
  limits = get_manual_limits();
tick_step = get_best_tick (limits);
if (axis_mode == "auto")
  limits = extend _limits_to_next_tick (limits, tick_step);
ticks = compute_ticks (limits, tick_step);

Michael.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]