.ds f. AtAxis.man .\" $Header: /afs/athena.mit.edu/astaff/project/atdev/spec/man/RCS/AtAxis.man,v 3.2 91/02/20 19:52:36 crcraig Exp Locker: crcraig $ .\" Copyright (C) 1990 by the Massachusetts Institute of Technology .\" .TH AtAxis 3X .SH NAME .B AtAxis -- the Axis widget class .SH SYNOPSIS .B #include .SH DESCRIPTION The AtAxis widget is an Xt object that displays an axis in an existing widget or window. An axis may be oriented horizontally or vertically. An axis has an optional label, and can have tics and subtics. Tics can be labeled with numbers or user-supplied strings. Both linear and log axes are supported. Two (or three, if a Y2 axis is desired) axes are automatically created by the AtPlotter widget. If the Axis object is used outside of the AtPlotter widget, the programmer is responsible for resizing and redisplaying the AtAxis object (see USAGE). .SH CLASSES The class pointer is atAxisObjectClass, and the class name is AtAxis. .SH RESOURCES The AtAxis widget inherits all the resources from the Object widget class. In addition, it has the following new resources: .TS .if \n+(b.=1 .nr d. \n(.c-\n(c.-1 .de 35 .ps \n(.s .vs \n(.vu .in \n(.iu .if \n(.u .fi .if \n(.j .ad .if \n(.j=0 .na .. .nf .nr #~ 0 .if \n(.T .if n .nr #~ 0.6n .ds #d .d .if \(ts\n(.z\(ts\(ts .ds #d nl .fc .nr 33 \n(.s .rm 48 49 50 .nr 48 0 .nr 38 \w\f2Name\fP .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNlabel .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNlabelFontFamily .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNlabelSize .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNlabelColor .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNnumberFontFamily .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNnumberSize .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNnumberStyle .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNnumberColor .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNaxisColor .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNmin .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNmax .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNtransform .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNvertical .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNmirror .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNdrawNumbers .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNdrawGrid .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNautoNumber .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticInterval .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNsubtics .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticDensity .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNsubticDensity .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticMultiplier .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticFormat .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticLabels .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticsOutside .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticsInside .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNticLength .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNsubticLength .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNaxisNeedsRedraw .if \n(48<\n(38 .nr 48 \n(38 .nr 38 \wXtNerrorCallback .if \n(48<\n(38 .nr 48 \n(38 .48 .rm 48 .nr 49 0 .nr 38 \w\f2Type\fP .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wString .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wString .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wAtFontSize .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wPixel .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wString .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wAtFontSize .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wAtFontStyle .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wPixel .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wPixel .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wdouble .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wdouble .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wAtTransform .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wdouble .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wshort .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wint .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wint  .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wdouble .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wString .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wString .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wBoolean .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wshort .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wshort .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wXtCallbackList .if \n(49<\n(38 .nr 49 \n(38 .nr 38 \wXtCallbackList .if \n(49<\n(38 .nr 49 \n(38 .49 .rm 49 .nr 50 0 .nr 38 \w\f2Default\fP .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wNULL .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wnew century schoolbook .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wAtFontNORMAL .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wXtDefaultForeground .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wnew century schoolbook .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wAtFontMEDIUM .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wAtFontPLAIN .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wXtDefaultForeground .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wXtDefaultForeground .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w0.0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w1.0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wAtTransformLINEAR .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wTrue .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wFalse .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wTrue .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wFalse .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wTrue .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w1.0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w1.0 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w"%.3lg" .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wNULL .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wTrue .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wFalse .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w5 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \w2 .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wNULL .if \n(50<\n(38 .nr 50 \n(38 .nr 38 \wNULL .if \n(50<\n(38 .nr 50 \n(38 .50 .rm 50 .nr 38 \w\f3AtAxis Resources\fP-\n(48-3n-\n(49-3n-\n(50 .if \n(38>0 .nr 38 \n(38/2 .if \n(38<0 .nr 38 0 .nr 49 +\n(38 .nr 50 +\n(38 .nr 38 1n .nr 47 0 .nr 40 \n(47+((0*\n(38)/2) .nr 48 +\n(40 .nr 41 \n(48+((6*\n(38)/2) .nr 49 +\n(41 .nr 42 \n(49+((6*\n(38)/2) .nr 50 +\n(42 .nr TW \n(50 .if t .if (\n(TW+\n(.o)>7.65i .tm Table at line 70 file AtAxis.man is too wide - \n(TW units .nr #I \n(.i .in +(\n(.lu-\n(TWu-\n(.iu)/2u .fc   .nr #T 0-1 .nr #a 0-1 .eo .de T# .nr 35 1m .ds #d .d .if \(ts\n(.z\(ts\(ts .ds #d nl .mk ## .nr ## -1v .ls 1 .ls .. .ec .ta \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'\f3AtAxis Resources\f\n(31 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'\f2Name\f\n(31\h'|\n(41u'\f2Type\f\n(31\h'|\n(42u'\f2Default\f\n(31 .sp .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNlabel\h'|\n(41u'String\h'|\n(42u'NULL .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNlabelFontFamily\h'|\n(41u'String\h'|\n(42u'new century schoolbook .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNlabelSize\h'|\n(41u'AtFontSize\h'|\n(42u'AtFontNORMAL .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNlabelColor\h'|\n(41u'Pixel\h'|\n(42u'XtDefaultForeground .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNnumberFontFamily\h'|\n(41u'String\h'|\n(42u'new century schoolbook .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNnumberSize\h'|\n(41u'AtFontSize\h'|\n(42u'AtFontMEDIUM .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNnumberStyle\h'|\n(41u'AtFontStyle\h'|\n(42u'AtFontPLAIN .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNnumberColor\h'|\n(41u'Pixel\h'|\n(42u'XtDefaultForeground .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNaxisColor\h'|\n(41u'Pixel\h'|\n(42u'XtDefaultForeground .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNmin\h'|\n(41u'double\h'|\n(42u'0.0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNmax\h'|\n(41u'double\h'|\n(42u'1.0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNtransform\h'|\n(41u'AtTransform\h'|\n(42u'AtTransformLINEAR .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNvertical\h'|\n(41u'Boolean\h'|\n(42u'True .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNmirror\h'|\n(41u'Boolean\h'|\n(42u'False .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNdrawNumbers\h'|\n(41u'Boolean\h'|\n(42u'True .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNdrawGrid\h'|\n(41u'Boolean\h'|\n(42u'False .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNautoNumber\h'|\n(41u'Boolean\h'|\n(42u'True .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticInterval\h'|\n(41u'double\h'|\n(42u'1.0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNsubtics\h'|\n(41u'short\h'|\n(42u'0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticDensity\h'|\n(41u'int\h'|\n(42u'0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNsubticDensity\h'|\n(41u'int \h'|\n(42u'0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticMultiplier\h'|\n(41u'double\h'|\n(42u'1.0 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticFormat\h'|\n(41u'String\h'|\n(42u'"%.3lg" .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticLabels\h'|\n(41u'String\h'|\n(42u'NULL .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticsOutside\h'|\n(41u'Boolean\h'|\n(42u'True .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticsInside\h'|\n(41u'Boolean\h'|\n(42u'False .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNticLength\h'|\n(41u'short\h'|\n(42u'5 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNsubticLength\h'|\n(41u'short\h'|\n(42u'2 .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNaxisNeedsRedraw\h'|\n(41u'XtCallbackList\h'|\n(42u'NULL .ta \n(48u \n(49u \n(50u .nr 35 1m .nr 31 \n(.f \&\h'|\n(40u'XtNerrorCallback\h'|\n(41u'XtCallbackList\h'|\n(42u'NULL .fc .nr T. 1 .T# 1 .in \n(#Iu .35 .TE .if \n-(b.=0 .nr c. \n(.c-\n(d.-38 .IP XtNlabel Specifies the string to display as the axis label. .IP XtNlabelFontFamily Specifies the font family to use for the axis label. .IP XtNlabelSize Specifies the font size for the axis label. .IP XtNlabelColor Specifies the color of the axis label. .IP XtNnumberFontFamily Specifies the font family to number the axes with. .IP XtNnumberSize Specifies the font size used for numbering the axes. .IP XtNnumberStyle Specifies the font style used for numbering the axes. .IP XtNnumberColor Specifies the color of the numbers on the axis. .IP XtNaxisColor Specifies the color to use to draw the axes, and the tics. .IP XtNmin Specifies the minimum value to be displayed on the axis. .IP XtNmax Specifies the maximum value to be displayed on the axis. .IP XtNtransform Specifies the transform to be used for the axis. The options are AtTransformLINEAR and AtTransformLOG. The default is linear. .IP XtNvertical Specifies whether the axis is to be drawn vertically. If this resource is set to false, the axis will be drawn horizontally. The AtPlotter widget forces the value of this resource as appropriate. .IP XtNmirror Specifies whether the axis should be drawn as a mirror image of its "normal" configuration. A "normal" axis is drawn on the left or bottom of the plotting region, with the label on the "outside". An axis with this resource set to True would be appropriate for the top or right of a a plotting area. The AtPlotter widget forces the value of this resource as appropriate. .IP XtNdrawNumbers Specifies whether the axis should be numbered. .IP XtNdrawGrid Specifies whether dotted lines should be drawn at each tic mark perpendicular to the axis across the plotting region. If True, it creates a "graph paper" effect. .IP XtNautoNumber Specifies whether the location of tic marks and subtics should be calculated by the widget. If True (the default) the resources XtNticDensity and XtNsubticDensity are hints to the widget about how many tics and subtics are desired. If False, the resource XtNticInterval specifies the spacing between tics and XtNsubtics specifies the number of subtics between each tic. .IP XtNticInterval If XtNautoNumber is False, this resource directly specifies the interval (in the user coordinate system, not pixels) between tics. If XtNautoNumber is True, this resource can be queried to get the current spacing between tics. .IP XtNsubtics If XtNautoNumber is False, this resource directly specifies the number of subtics between every two tics. Note that the number of subtics is one less than the number of sub-intervals that the space is partitioned into. Thus to divide the space between tics into quarters, specify three tics. If XtNautoNumber is True, this resource can be queried to get the current number of subtics. .IP XtNticDensity If XtNautoNumber is True, this resource provides a hint as to how many tics the user wants. The default of zero will cause the axis to produce an "optimal" number of tics, based on the length of the axis, and the font size. To get more tics, specify a value of 1 to 5 for this resource. To get fewer tics, specify a value from -1 to -5. .IP XtNsubticDensiy If XtNautoNumber is true, this resource provides a hint to the widget about how many subtics should be drawn between tics. The default of zero will produce an "optimal" number of subtics. A positive value between 1 and 5 will produce more subtics, and a negative value between -1 and -5 will produce fewer subtics. .IP XtNticMultiplier The coordinate of each tic on an axis will be multiplied by this value before it is displayed. This is useful when an axis is used with very large or very small numbers, or when displaying data in different units than it is measured in. If XtNautoNumber is True, this multiplier is taken into account when the interval between tics is calculated, so that the numbers will still be on "nice" intervals. If False, the user specified XtNticInterval is multiplied by this amount before the tics are calculated. .IP XtNticFormat This string is used as the format string to the function sprintf when converting the numeric value of a tic to a string. It can be modified to alter then number of digits displayed after the decimal point. Note that it can also contain text, so tics like "3pi" or "5 dB" could be generated. .IP XtNticLabels Specifies labels to be used for tic labels. Each label is separated by a newline (i.e. '\n'). If XtNticLabels is non-NULL, these labels are used to label the tics on the axis instead of the tics' numeric values. If this resource is used, XtNautoNumber should be False, XtNticInterval should be set to an appropriate value, and XtNticFormat and XtNticMultiplier are ignored. If not enough tic labels are given, the extra tics are not labeled. .IP XtNticsOutside Specifies whether tic marks should be drawn on the "outside" of the axis. The outside is the left or bottom if XtNmirror is false and the top or right if it is true. .IP XtNticsInside Specifies whether tic marks should be drawn on the "inside" of the axis. .IP XtNticLength Specifies the length in pixels of tic. This many pixels are drawn on the "outside" or "inside" of the axis, or both, or neither depending on the state of the XtNticsOutside and XtNticsInside resources. .IP XtNsubticLength Specifies the length of pixels of a subtic. This many pixels are drawn on the "outside" or "inside" of the axis, or both, or neither depending on the state of the XtNticsOutside and XtNticsInside resources. .IP XtNaxisNeedsRedraw Specifies procedures to be called when the axis should be redrawn (i.e. one or more of its resources changed). .IP XtNerrorCallback Specifies procedures to be called when an error occurs in the axis. If no procedures are specified, any error messages are output to standard error using \fBXtWarning()\fP. .SH "PUBLIC ROUTINES" .nf .ta 10n void AtAxisComputeTicSpacing(\fIaxis\fP, \fIlength\fP) AtAxisObject \fIaxis\fP; int \fIlength\fP; int AtAxisWidth(\fIaxis\fP) AtAxisObject \fIaxis\fP; void AtAxisChangeBounds(\fIaxis\fP, \fImin\fP, max) AtAxisObject \fIaxis\fP; double \fImin\fP, max; void AtAxisGetBounds(\fIaxis\fP, \fImin\fP, \fImax\fP) AtAxisObject \fIaxis\fP; double *\fImin\fP, *\fImax\fP; void AtAxisSetLocation(\fIaxis\fP, \fIx1\fP, \fIy1\fP, \fIx2\fP, \fIy2\fP) AtAxisObject \fIaxis\fP; int \fIx1\fP, \fIx2\fP, \fIy1\fP, \fIy2\fP; void AtAxisGetLocation(\fIaxis\fP, \fIx1\fP, \fIx2\fP, \fIy1\fP, \fIy2\fP) AtAxisObject \fIaxis\fP; int *\fIx1\fP, *\fIx2\fP, *\fIy1\fP, *\fIy2\fP; void AtAxisDraw(\fIdpy\fP, \fIwin\fP, \fIaxis\fP, \fIbg\fP) Display *\fIdpy\fP; Window \fIwin\fP; AtAxisObject \fIaxis\fP; Pixel \fIbg\fP; void AtAxisDrawGrid(\fIdpy\fP, \fIwin\fP, \fIaxis\fP, \fIstart_pixel\fP, \fIend_pixel\fP) Display *\fIdpy\fP; Window \fIwin\fP; AtAxisObject \fIaxis\fP; int \fIstart_pixel\fP, \fIend_pixel\fP; void AtAxisDrawGridRegion(\fIdpy\fP, \fIwin\fP, \fIaxis\fP, \fIstart_pixel\fP, \fIend_pixel\fP, \fIregion\fP) Display *\fIdpy\fP; Window \fIwin\fP; AtAxisObject \fIaxis\fP; int \fIstart_pixel\fP, \fIend_pixel\fP; Region \fIregion\fP; int AtAxisWidthPS(\fIaxis\fP) AtAxisObject \fIaxis\fP; void AtAxisDrawPS(fp, \fIaxis\fP, \fIx1\fP, \fIy1\fP, \fIx2\fP, \fIy2\fP, \fIgrid_min\fP, \fIgrid_max\fP) FILE *fp; AtAxisObject \fIaxis\fP; int \fIx1\fP, \fIy1\fP, \fIx2\fP, \fIy2\fP, \fIgrid_min\fP, \fIgrid_max\fP; .fi .IP AtAxisComputeTicSpacing() Causes \fIaxis\fP to compute its tic spacing for an approximate length of \fIlength\fP pixels. .IP AtAxisWidth() Returns the width of \fIaxis\fP in pixels. .IP AtAxisChangeBounds() Change the user coordinate bounds of \fIaxis\fP to \fImin\fP and \fImax\fP. .IP AtAxisGetBounds() Return the user coordinate bounds of \fIaxis\fP in \fImin\fP and \fImax\fP. .IP AtAxisSetLocation() Set the pixel location of the endpoints of \fIaxis\fP to \fI(x1, y1)"\fP (corresponding to the axis's minimum value) and \fI(x2, y2)\fP (corresponding to the axis's maximum value). .IP AtAxisGetLocation() Stores the pixel location of the endpoints of \fIaxis\fP in \fI(x1,y1)"\fP (corresponding to the axis's minimum value) and \fI(x2, y2)\fP (corresponding to the axis's maximum value). .IP AtAxisDraw() Draw \fIaxis\fP in window \fIwin\fP on the X display \fIdpy\fP with background color \fIbg\fP. .IP AtAxisDrawGrid() Draw the grid for \fIaxis\fP in window \fIwin\fP on the X display \fIdpy\fP. The grid lines will start at pixel \fIstart_pixel\fP and end at pixel \fIend_pixel\fP. .IP AtAxisDrawGridRegion() Functions like \fBAtAxisDrawGrid()\fP, but restricts the drawing of the grid to the region indicated by \fIregion\fP. .IP AtAxisWidthPS() Returns the width of the Postscript representation of \fIaxis\fP in PS points. .IP AtAxisDrawPS() Write the Postscript representation of \fIaxis\fP to the file pointer \fIfp\fP. The axis representation will be drawn inside the bounding box described by \fI(x1, y1)\fP and \fI(x2, y2)\fP. Grid lines will be drawn from \fIgrid_min\fP to \fIgrid_max\fP. .SH USAGE .nf axis = XtCreateWidget(\fIaxis_name\fP, AtAxisObjectClass, \fIparent\fP, \fIargs\fP, \fInum_args\fP) String \fIaxis_name\fP; WidgetClass AtAxisObjectClass; Widget \fIparent\fP; ArgList \fIargs\fP; Cardinal \fInum_args\fP; .fi When AtAxis is the child of the AtPlotter widget, AtPlotter will control the axis object, place it, and draw it. No outside interaction is necessary. If the AtAxis object is being used outside the AtPlotter widget, the programmer must set up the axis object, place it, and draw it. After creating the axis, .I AtAxisComputeTicSpacing should be called to compute the tic spacing for the object. Next, .I AtAxisSetLocation should be called to set the axis's location. Finally, call .I AtAxisDraw to actually draw the axis. .I AtAxisWidth will not return a valid width unless the axis's tic spacing has already been computed .I (AtAxisComputeTicSpacing). .SH CALLBACK INFORMATION The value of the call_data argument passed to XtNaxisNeedsRedraw callback procedures is undefined. .SH "SEE ALSO" AtPlotter(3X), AtText(3X), AtFontFamily(3X), X(1) .SH BUGS Logarithmic mode still has some problems. Upside down axes don't always work quite right. .SH AUTHORS David Flanagan (MIT Project Athena), Chris Craig (MIT Project Athena) .SH NOTES Postscript is a trademark of Adobe Systems Incorporated. .SH COPYRIGHT Copyright (C) 1990 by the Massachusetts Institute of Technology Export of this software from the United States of America is assumed to require a specific license from the United States Government. It is the responsibility of any person or organization contemplating export to obtain such a license before exporting. WITHIN THAT CONSTRAINT, permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of M.I.T. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. M.I.T. makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty.