Class ShaderLegend

java.lang.Object
uk.ac.starlink.ttools.build.ShaderLegend

public class ShaderLegend extends Object
Generates a graphic in SVG format showing labelled colourmaps.
Since:
1 Sep 2022
Author:
Mark Taylor
  • Constructor Details

    • ShaderLegend

      public ShaderLegend(int ncol)
      Constructor.
      Parameters:
      ncol - number of columns for output
  • Method Details

    • toSvg

      public String toSvg(Shader[] shaders)
      Returns an SVG representation of a legend labelling a given list of shaders.
      Parameters:
      shaders - shader list
      Returns:
      SVG output
    • getAllShaders

      public static Shader[] getAllShaders()
      Returns all the shaders generally available from Plot2 graphics.
      Returns:
      somewhat ordered list of shaders
    • main

      public static void main(String[] args)
      Main method invoked to write SVG to standard output. Use -help flag for usage information.
      Parameters:
      args - flag array