    All Packages  Class Hierarchy  This Package  Previous  Next  Index

# Class xv.xv_XmlStyleContext

    java.lang.Object
       |
       +----com.sun.java.swing.text.StyleContext
               |
               +----xv.xv_XmlStyleContext

public class xv_XmlStyleContext
extends StyleContext

A collection of styles used to render an XML source.

##

xv_XmlStyleContext()
  Default constructor.

##

getFont(int)
  Get the font to use for a lexical token with the given scan value.
getForeground(int)
  Get the foreground colour to use for a lexical token with the given value.
getStyleForScanValue(int)
  Get the attribute set to use for the given scan code.

##

xv_XmlStyleContext

     public xv_XmlStyleContext()

  Default constructor. Construct a set of styles to represent XML lexical tokens. By default there are no colours or fonts specified.

##

getForeground

     public Color getForeground(int code)

  Get the foreground colour to use for a lexical token with the given value.

  Parameters:
    attr - attribute set from a token element that has a Token in the set.

getFont

     public Font getFont(int code)

  Get the font to use for a lexical token with the given scan value.

getStyleForScanValue

     public Style getStyleForScanValue(int code)

  Get the attribute set to use for the given scan code. The set is stored in a table to facilitate relatively fast access to use in conjunction with the scanner.

    All Packages  Class Hierarchy  This Package  Previous  Next  Index