|
From: sfeam <sf...@us...> - 2014-10-05 03:27:32
|
I have made a set of changes in 5.1 CVS related to timefmt.
These changes are not yet in 5.0, but unless they produce unforseen
problems I expect they will be added before the final release of 5.0.
The changes can be summarized briefly.
- The per-axis flag for how to interpret input/output format statements
has been split into two separate flags
axis->datatype continues to select between numeric or time data on input
axis->tictype (new) specifies how the axis tics are to be handled (output)
- The new flag is set/unset by a corresponding new command option
set xtics {numeric|time|geographic}
For now the command "set xdata time" implicitly also does "set xtics time"
so all old scripts should continue to act as they did previously with
regard to time formats
- The per-axis string axis->timefmt has been replaced by a single global
timefmt string. This is what the documentation always described,
although it was not true in the code.
Existing scripts will only see a change if they used the undocumented
command: set timefmt y 'something-different-from-x'.
This case is handled more flexibly in version 5 by
plot ... using (timecolumn(N,format1)):(timecolumn(M,format2))
- XYZ positions are printed using time/date formatting if it is active.
This makes the output consistent with input requirements.
I.e. the sequence of commands
set xdata time
set label "FOO" at "01/02/14,11:23", graph 0.5
save 'temp'
load 'temp'
show label
Did not act as you would expect in version 4. Now it does.
- The timecolumn(N,format) command tries to detect being called
with only 1 parameter, as was the case in version 4. In this
case the version 5 code now emulates version 4 behavior, so this
is an improvement, albeit imperfect, in backwards-compatibility.
In short these changes are intended to both extend the flexibility
of time format handling in version 5 and increase the backwards
compatibility with scripts written for version 4. Please report
any use cases where these goals not succeeded.
Ethan
|