Chapter 20. Odometer

Table of Contents

20.1. Introduction
20.1.1. Features
20.2. Creating and formatting basic odometer graphs
20.2.1. A basic odometer
20.2.2. Half and Full Odometers
20.2.3. Adding titles and captions
20.2.4. Adjusting colors
20.2.5. Changing indicator needle style
20.2.6. Adding drop shadows
20.2.7. Changing sizes and margins
20.2.8. Adding color indications in the scale
20.2.9. Changing size of the non-colored center area
20.2.10. Using multiple indicator needles in one odometer
20.2.11. Adding an odometer legend (label)
20.2.12. Adjusting the width and color of the odometer frame (border)
20.3. Working with the odometer scale
20.3.1. Adjusting the scale, ticks and labels
20.3.2. Adjusting scale label format
20.3.3. Adjusting the start and stop angle for the scale
20.4. Adding and positioning multiple odometers to a graph
20.4.1. Manual positioning
20.4.2. Using layout classes
20.5. Adding icon and text objects to the graph
20.5.1. Adding a text object
20.5.2. Adding icons to the graph
20.5.3. Adding background images

20.1. Introduction


This module is only available in the pro-version of the library.

Odometer graphs uses the metaphor of an old fashioned speedometer for cars. It is normally used to give a quick overview of one specific parameter. Experience have shown that this type of metaphor is easily and quickly understood by most people. By adding color indications to the odometer it is very quick to see whether or not a specific value is within a allowed range or outside.

Figure 20.1 shows an overview of some typical odometers created with the library.

Figure 20.1. Odometers


20.1.1. Features

Odometers produced with this package have a wide range of functionality and as you would expect almost every bit of visual layout is in one way or the other customisable. For simple use there are suitable default values for most parameters which will make creation of simple Odometer just a matter of a few lines of code.

Among other things Odometers support the following features:

  • Both half (semi-circle) and full (circle) odometers are supported

  • Fully customizable scales and odometer sizes

  • Different size and shapes of the indicator needles

  • Scale color indicators

  • Multiple dials in the same graph

  • Full support for library standard fonts and colors

  • Automatic layout engine for multiple plots in the same graph which aids in positioning of the graphs without having to specify pixel coordinates