generate-grid-lines (&key x-offset y-offset x-spacing y-spacing horizontal-count vertical-count width height thickness major-x-step major-y-step vertical-thickness minor-thickness minor-vertical-thickness left-thickness right-thickness top-thickness bottom-thickness color vertical-color minor-color minor-vertical-color left-color right-color top-color bottom-color ) => list
A list of drawing-objects.
generate-grid-lines returns a list of drawing-objects which when drawn display a grid of horizontal and vertical lines, according to the supplied specification.
The grid is made of vertical lines spaced regularly in the horizontal dimension, and horizontal lines spaced regularly in the vertical dimension. The specification of the graph is conceptual starting from 0 and increasing in both dimensions. This does not affect what values the graph shows, because these are defined by the labels which are produced separately (typically by generate-labels).
x-offset / y-offset specify the offset of the origin of the graph, which means the position of the first vertical/horizontal line respectively, and where the start point of the horizontal/vertical line respectively. The default value of both x-offset and y-offset is 0.
x-spacing and y-spacing specify the gaps in the horizontal and vertical dimensions respectively (that is, the distance between vertical/horizontal lines). The default value of both x-spacing and y-spacing is 1.
are used only when
nil, to compute the value of the
, by truncating the
major-x-step and major-y-step specify that each major-x-step 'th (horizontally) or major-y-step 'th (vertically) line is "major", which means drawn with (potentially) different thickness and color (see below).
thickness and the other *-thickness arguments specify the thickness of the lines. color and the other *-color arguments specify the color of the lines. All the *-thickness variables default, directly or indirectly, to the value of thickness , and the *-color arguments default to the value of color . Default values for *-thickness and *-color arguments to generate-grid-lines gives the details:
The top-* , bottom-* , left-* , right-* variables specify the values for the outer lines of the grid. The major-* variables specify the values for the major lines, the other variables specify the values for the ordinary lines. The vertical-* variables specify the values for the vertical lines, the other variables for the horizontal.
generate-grid-linesmust be in a hierarchy which is rooted in an objects-displayer or a pinboard-objects-displayer.
generate-grid-linesis a list of drawing-object, so it is a valid "drawing-object-spec". It will be typically be grouped together with some other "drawing-object-specs", for example labels for the graph, by simply listing them, and then positioned and fitted by passing it to position-object or fit-object or position-and-fit-object.
CAPI User Guide and Reference Manual (Unix version) - 3 Aug 2017