defaxis

[Function]
  (`defaxis` name ([class]) {keyword value}* {(meta-info)}*)

Defines a new axis prototype named name. An axis prototype is an axis instance that acts as a template for instantiating plotter display axes with similar characteristics. Class is the class of the prototype, either `axis` or `log-axis`. Defaults to `axis` if no class is supplied. Following class comes the prototype's initialization list. See axis initializations for the list of available initializations. Following the initializations comes any "meta-info" that should be associated with the prototype. This is information that may be of use to the prototype but not to the axes that are derived from it. Meta-info consists of lists of information; the system currently defines two:

(:appropriate-slots :horizontal ({slot}*) :vertical ({slot}* ))
  Provides the prototype with lists of possible slots to access if no :slot is specified when a derived axis is instantiated for the horizontal or vertical dimension. In this case Plotter checks the first point object in each data set and uses the first slot in the meta-info list that returns true for `slot-exists-p`.
(:insurer function)
  a function of three arguments that is called to insure that all slots have been set in the instance allocated from the prototype.

#### Examples:

Example 1. The system definition of the :seconds axis prototype.

    (defaxis :seconds ()
      :minimum 0 :maximum nil  :increment 1
      :ticks-per-increment 4
      :labeler "~,2F"
      (:appropriate-slots
       :horizontal (time start start-time
                         begin duration dur x z)))

#### See also:

- `axis` [Function]
- `axis` [Class]
- `log-axis` [Class]
- `plotter` [Function]
- Plotter [Topic]