aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Mason <chris.mason@fusionio.com>2013-09-24 15:30:35 -0400
committerChris Mason <clm@fb.com>2014-09-24 12:02:08 -0700
commite4d4b5dc17dd1b2ec78e409efc8a36230772a377 (patch)
tree3e3c88b4a6ec23fbba7ed509ff9d1fd6667faaab
parentade854b0de75ecbd585aa323fd0cc7ccd92039f0 (diff)
downloadblktrace-e4d4b5dc17dd1b2ec78e409efc8a36230772a377.tar.gz
iowatcher: Fine tune the ticks
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
-rw-r--r--iowatcher/main.c2
-rw-r--r--iowatcher/plot.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/iowatcher/main.c b/iowatcher/main.c
index d23e3b2..a419324 100644
--- a/iowatcher/main.c
+++ b/iowatcher/main.c
@@ -53,7 +53,7 @@ static int opt_graph_width = 0;
static int opt_graph_height = 0;
static int columns = 1;
-static int num_xticks = 7;
+static int num_xticks = 9;
static int num_yticks = 4;
static double min_time = 0;
diff --git a/iowatcher/plot.c b/iowatcher/plot.c
index d486f29..6d652dd 100644
--- a/iowatcher/plot.c
+++ b/iowatcher/plot.c
@@ -563,7 +563,7 @@ void set_xticks(struct plot *plot, int num_ticks, int first, int last)
* We don't want last two ticks to be too close together so subtract
* 20% of the step from the interval
*/
- num_ticks = (double)(last - first - step / 5) / step + 1;
+ num_ticks = (double)(last - first - step) / step + 1;
pixels_per_tick = graph_width * step / (double)(last - first);
for (i = 0; i < num_ticks; i++) {