Extend date axis resolution to microseconds
Extend date axis resolution to microseconds

Fix a bug that caused a near-infinite loop when diplaying the X axis
in date mode and then zooming in until the grid increment was less
than one second (trying to display grid lines from 1970-01-01 00:00:00
until the end time in steps of less than one second).

Extend the possible formats for grid labels to include "000000" to
display microseconds.

Change the upper line prefix labels for the leftmost and rightmost
X-axis grid lines to show just the portion of "%Y-%m-%d %H:%M:%S."
that is needed to prefix the grid label below it.  The two labels may
include different portions since the format of each individual grid
line label can vary depending upon how major a boundary it marks.
Also make the upper label be centered on the grid line.  The rightmost
upper label now has the value of the rightmost grid line rather than
the right edge of the window and the loop to draw grid lines now
extends to <=Xend rather than just <Xend.  Ditto for Yend.

Rather than using floor() analogously to the integer technique of
adding increment-1 and truncating, which does not work well for
microseconds, use ceil() in several places.  But we have to fix up
ceil(0.0) to be 0.0 rather than -0.0.

kernelsid/graf,kernelsid/graf