Re: axis color

The doc for showAxesScales() and setAxesScalesFont() is in
visad.python.JPythonMethods.  Neither of these has any options for
setting the colors, however.  You'll have to roll your own...

...something like (Don will correct me if this is wrong):

as = scalarmap.getAxisScale()
as.setColor(java.awt.Color.black)

for each 'scalarmap' for your axes...

tom

On Mon, 29 Apr 2002, Campbell, Garrett wrote:

> In Jython I managed to make a white background, but now I do not
> know where to flip the axis color to black.
>
> In the following there is reference to the axis, but I guess I am still
> searching for the documentation as I do not know where the doc is for
>
> showAxesScales(disp, 1)
>   setAxesScalesFont(axes, Font("Monospaced", Font.PLAIN, 18))
>
>
> There might be some reference there to the axis color
>
>
> def lineplot(data, panel=None, color=None, width=400, height=400,
> title="Line Plot"):
>   domt = domainType(data)
>   rngt = rangeType(data)
>   xaxis = ScalarMap(domt[0], Display.XAxis)
>   yaxis = ScalarMap(rngt, Display.YAxis)
>   axes = (xaxis, yaxis)
>
>   disp = subs.makeDisplay( axes )
>   constmap = None
>   if color is not None:
>     from visad import ConstantMap
>     from java.awt import Color
>     red = float(color.getRed())/255.
>     green = float(color.getGreen())/255.
>     blue = float(color.getBlue())/255.
>
>     constmap = ( ConstantMap(red,Display.Red),
> ConstantMap(green,Display.Green),
>            ConstantMap(blue,Display.Blue) )
>
>
>   dr=subs.addData("Lineplot", data, disp, constmap)
>   subs.setBoxSize(disp, .70)
>   showAxesScales(disp, 1)
>   setAxesScalesFont(axes, Font("Monospaced", Font.PLAIN, 18))
>
>   subs.setAspectRatio(disp, float(width)/float(height))
>   subs.showDisplay(disp,width,height,title,None,None,panel)
>
>   return disp
>
>
> G. Garrett Campbell Ph. D.
> Cooperative Institute for Research in the Atmosphere
> Colorado State University
> Ft. Collins, CO, USA
> 970 491 8497
> campbell@xxxxxxxxxxxxxxxxxx
>
>

--
Tom Whittaker
University of Wisconsin-Madison
Space Science and Eng. Center
ph:  608.262.2759