org.eclipse.datatools.sqltools.sqleditor.internal.utils
Class SQLColorProvider

java.lang.Object
  extended by org.eclipse.datatools.sqltools.sqleditor.internal.utils.SQLColorProvider

public class SQLColorProvider
extends java.lang.Object

This class defines colors used in the SQL editor.


Field Summary
static java.lang.String SQL_COMMENT
           
static org.eclipse.swt.graphics.RGB SQL_COMMENT_COLOR
           
static java.lang.String SQL_DEFAULT
           
static org.eclipse.swt.graphics.RGB SQL_DEFAULT_COLOR
           
static java.lang.String SQL_DELIMITED_IDENTIFIER
           
static org.eclipse.swt.graphics.RGB SQL_DELIMITED_IDENTIFIER_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_COMMENT_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_DEFAULT_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_DELIMITED_IDENTIFIER_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_IDENTIFIER_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_KEYWORD_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_MULTILINE_COMMENT_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_QUOTED_LITERAL_COLOR
           
static org.eclipse.swt.graphics.RGB SQL_HC_TYPE_COLOR
           
static java.lang.String SQL_IDENTIFIER
           
static org.eclipse.swt.graphics.RGB SQL_IDENTIFIER_COLOR
           
static java.lang.String SQL_KEYWORD
           
static org.eclipse.swt.graphics.RGB SQL_KEYWORD_COLOR
           
static java.lang.String SQL_MULTILINE_COMMENT
           
static org.eclipse.swt.graphics.RGB SQL_MULTILINE_COMMENT_COLOR
           
static java.lang.String SQL_QUOTED_LITERAL
           
static org.eclipse.swt.graphics.RGB SQL_QUOTED_LITERAL_COLOR
           
static java.lang.String SQL_TYPE
           
static org.eclipse.swt.graphics.RGB SQL_TYPE_COLOR
           
 
Constructor Summary
SQLColorProvider()
           
 
Method Summary
 org.eclipse.jface.text.TextAttribute createTextAttribute(java.lang.String syntax)
          Creates a TextAttribute object for the given syntax value.
 org.eclipse.jface.text.rules.IToken createToken(java.lang.String syntax)
          Creates a IToken object for the given syntax value.
 void dispose()
          Release all of the color resources held onto by the receiver.
 org.eclipse.swt.graphics.Color getColor(org.eclipse.swt.graphics.RGB rgb)
          Gets a Color object for the given RGB value.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SQL_COMMENT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_COMMENT_COLOR

SQL_MULTILINE_COMMENT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_MULTILINE_COMMENT_COLOR

SQL_QUOTED_LITERAL_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_QUOTED_LITERAL_COLOR

SQL_KEYWORD_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_KEYWORD_COLOR

SQL_TYPE_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_TYPE_COLOR

SQL_IDENTIFIER_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_IDENTIFIER_COLOR

SQL_DELIMITED_IDENTIFIER_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_DELIMITED_IDENTIFIER_COLOR

SQL_DEFAULT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_DEFAULT_COLOR

SQL_HC_COMMENT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_COMMENT_COLOR

SQL_HC_MULTILINE_COMMENT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_MULTILINE_COMMENT_COLOR

SQL_HC_QUOTED_LITERAL_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_QUOTED_LITERAL_COLOR

SQL_HC_KEYWORD_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_KEYWORD_COLOR

SQL_HC_TYPE_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_TYPE_COLOR

SQL_HC_IDENTIFIER_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_IDENTIFIER_COLOR

SQL_HC_DELIMITED_IDENTIFIER_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_DELIMITED_IDENTIFIER_COLOR

SQL_HC_DEFAULT_COLOR

public static final org.eclipse.swt.graphics.RGB SQL_HC_DEFAULT_COLOR

SQL_COMMENT

public static final java.lang.String SQL_COMMENT

SQL_MULTILINE_COMMENT

public static final java.lang.String SQL_MULTILINE_COMMENT

SQL_QUOTED_LITERAL

public static final java.lang.String SQL_QUOTED_LITERAL

SQL_DELIMITED_IDENTIFIER

public static final java.lang.String SQL_DELIMITED_IDENTIFIER

SQL_KEYWORD

public static final java.lang.String SQL_KEYWORD

SQL_TYPE

public static final java.lang.String SQL_TYPE

SQL_IDENTIFIER

public static final java.lang.String SQL_IDENTIFIER

SQL_DEFAULT

public static final java.lang.String SQL_DEFAULT
Constructor Detail

SQLColorProvider

public SQLColorProvider()
Method Detail

dispose

public void dispose()
Release all of the color resources held onto by the receiver.


getColor

public org.eclipse.swt.graphics.Color getColor(org.eclipse.swt.graphics.RGB rgb)
Gets a Color object for the given RGB value.

Parameters:
rgb - the RGB value for which the Color object is needed
Returns:
the Color object corresponding to the RGB value

createToken

public org.eclipse.jface.text.rules.IToken createToken(java.lang.String syntax)
Creates a IToken object for the given syntax value.

Parameters:
syntax - the value representing a syntax
Returns:
the IToken object corresponding to the value saved in preference store

createTextAttribute

public org.eclipse.jface.text.TextAttribute createTextAttribute(java.lang.String syntax)
Creates a TextAttribute object for the given syntax value.

Parameters:
syntax - the value representing a syntax
Returns:
the TextAttribute object corresponding to the value saved in preference store