com.iver.cit.gvsig.fmap.core.v02
Class FSymbol

java.lang.Object
  extended bycom.iver.cit.gvsig.fmap.core.v02.FSymbol

public class FSymbol
extends java.lang.Object

Símbolo utilizado para guardar las características que se deben de aplicar a los Shapes a dibujar.

Author:
Vicente Caballero Navarro

Field Summary
 java.awt.Color m_BackColor
           
 java.awt.Paint m_BackFill
           
 java.lang.String m_LinePattern
           
 
Constructor Summary
FSymbol(int tipoSymbol)
          Crea un nuevo FSymbol.
FSymbol(int tipoSymbol, java.awt.Color c)
          Creates a new FSymbol object.
 
Method Summary
 void calculateRgb()
          Calcula el RGB del símbolo.
 FSymbol cloneSymbol()
          Clona el símbolo actual.
static FSymbol createFromXML(XMLEntity xml)
          Crea el símbolo a partir del xml.
 FSymbol fastCloneSymbol()
          Se usa para el símbolo de selección.
 int getAlingHoriz()
          Devuelve la alineación en horizontal.
 int getAlingVert()
          Devuelve la alineación en vertical.
 java.awt.Color getColor()
          Devuelve el color del símbolo.
 java.lang.String getDescription()
          Devuelve la descripción del símbolo.
 java.awt.Paint getFill()
          Devuelve el relleno.
 java.awt.Font getFont()
          Devuelve el Font del símbolo.
 java.awt.Color getFontColor()
          Devuelve el color de la fuente.
 float getFontSize()
          Devuelve el tamaño de la fuente.
 java.awt.Image getIcon()
          Devuelve el icono.
 java.awt.Color getOutlineColor()
          Devuelve el color de la línea de borde.
 int getRgb()
          Devuelve el rgb del símbolo.
 int getRotation()
          Devuelve la rotación.
static java.awt.Color getSelectionColor()
          Devuelve el color que se aplica a los shapes seleccionados.
 int getSize()
          Devuelve el tamaño del símbolo.
 java.awt.Stroke getStroke()
          Devuelve el Stroke.
 int getStyle()
          Devuelve el estilo del símbolo.
static FSymbol getSymbolForSelection(FSymbol sym)
          A partir de un símbolo devuelve otro similar pero con el color de selección.
 int getSymbolType()
          Devuelve el tipo de símbolo.
 XMLEntity getXMLEntity()
           
 boolean isFontSizeInPixels()
          Devuelve true si el tamaño de la fuente esta seleccionado en pixels.
 boolean isOutlined()
          Devuelve si el símbolo contiene o no linea de borde.
 boolean isShapeVisible()
          Devuelve true si el shape es visible.
 boolean isSizeInPixels()
          Devuelve si el tamaño del símbolo está en pixels.
 void setAlingHoriz(int m_AlingHoriz)
          Introduce la alineación en horizontal.
 void setAlingVert(int m_AlingVert)
          Introduce la alineación en vertical.
 void setColor(java.awt.Color m_Color)
          Introduce el color del símbolo.
 void setDescription(java.lang.String m_Descrip)
          Introduce la descripción del símbolo.
 void setFill(java.awt.Paint m_Fill)
          Introduce el relleno.
 void setFont(java.awt.Font m_Font)
          Introduce el Font del símbolo.
 void setFontColor(java.awt.Color m_FontColor)
          Introduce el color de la fuente.
 void setFontSize(float m_FontSize)
          Introduce el tamaño de la fuente.
 void setFontSizeInPixels(boolean m_bUseFontSize)
          Introduce si se usa el tamaño de la fuente en pixels.
 void setIcon(java.awt.Image m_Icon)
          Introduce la imagen que hace de icono.
 void setOutlineColor(java.awt.Color m_outlineColor)
          Introduce el color de la línea de borde.
 void setOutlined(boolean m_useOutline)
          Introduce si el símbolo contiene linea de brode o no.
 void setRotation(int m_Rotation)
          Introduce la rotación.
static void setSelectionColor(java.awt.Color selectionColor)
          Introduce el color que se aplica a los shapes seleccionados.
 void setShapeVisible(boolean m_bDrawShape)
          Introduce si el shape e visible o no lo es.
 void setSize(int m_Size)
          Introduce el tamaño del símbolo.
 void setSizeInPixels(boolean m_bUseSize)
          Introduce si el tamaño del simbolo está en pixels.
 void setStroke(java.awt.Stroke m_Stroke)
          Introduce el Stroke.
 void setStyle(int m_Style)
          Introduce el estilo del símbolo.
 void setSymbolType(int m_symbolType)
          Introduce el tipo de símbolo.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_LinePattern

public java.lang.String m_LinePattern

m_BackColor

public java.awt.Color m_BackColor

m_BackFill

public java.awt.Paint m_BackFill
Constructor Detail

FSymbol

public FSymbol(int tipoSymbol,
               java.awt.Color c)
Creates a new FSymbol object.

Parameters:
tipoSymbol - Tipo de símbolo.
c - Color.

FSymbol

public FSymbol(int tipoSymbol)
Crea un nuevo FSymbol.

Parameters:
tipoSymbol - Tipo de Símbolo.
Method Detail

getSymbolForSelection

public static FSymbol getSymbolForSelection(FSymbol sym)
A partir de un símbolo devuelve otro similar pero con el color de selección.

Parameters:
sym - Símbolo a modificar.
Returns:
Símbolo modificado.

cloneSymbol

public FSymbol cloneSymbol()
Clona el símbolo actual.

Returns:
Nuevo símbolo clonado.

fastCloneSymbol

public FSymbol fastCloneSymbol()
Se usa para el símbolo de selección. Es una forma rápida de clonar un símbolo, sin hacerlo via XML. Vicente, no lo borres!!!

Returns:

calculateRgb

public void calculateRgb()
Calcula el RGB del símbolo.


getRgb

public int getRgb()
Devuelve el rgb del símbolo.

Returns:
rgb del símbolo.

getXMLEntity

public XMLEntity getXMLEntity()
See Also:
com.iver.cit.gvsig.gui.layout.fframes.IFFrame#getXMLEntity()

createFromXML

public static FSymbol createFromXML(XMLEntity xml)
Crea el símbolo a partir del xml.

Parameters:
xml - xml que contiene la información para crear el símbolo.
Returns:
Símbolo creado a partir del XML.

setStyle

public void setStyle(int m_Style)
Introduce el estilo del símbolo.

Parameters:
m_Style - The m_Style to set.

getStyle

public int getStyle()
Devuelve el estilo del símbolo.

Returns:
Returns the m_Style.

setSymbolType

public void setSymbolType(int m_symbolType)
Introduce el tipo de símbolo.

Parameters:
m_symbolType - The m_symbolType to set.

getSymbolType

public int getSymbolType()
Devuelve el tipo de símbolo.

Returns:
Returns the m_symbolType.

setOutlined

public void setOutlined(boolean m_useOutline)
Introduce si el símbolo contiene linea de brode o no.

Parameters:
m_useOutline - The m_useOutline to set.

isOutlined

public boolean isOutlined()
Devuelve si el símbolo contiene o no linea de borde.

Returns:
Returns the m_useOutline.

setColor

public void setColor(java.awt.Color m_Color)
Introduce el color del símbolo.

Parameters:
m_Color - The m_Color to set.

getColor

public java.awt.Color getColor()
Devuelve el color del símbolo.

Returns:
Returns the m_Color.

setOutlineColor

public void setOutlineColor(java.awt.Color m_outlineColor)
Introduce el color de la línea de borde.

Parameters:
m_outlineColor - The m_outlineColor to set.

getOutlineColor

public java.awt.Color getOutlineColor()
Devuelve el color de la línea de borde.

Returns:
Returns the m_outlineColor.

setFont

public void setFont(java.awt.Font m_Font)
Introduce el Font del símbolo.

Parameters:
m_Font - The m_Font to set.

getFont

public java.awt.Font getFont()
Devuelve el Font del símbolo.

Returns:
Returns the m_Font.

setFontColor

public void setFontColor(java.awt.Color m_FontColor)
Introduce el color de la fuente.

Parameters:
m_FontColor - The m_FontColor to set.

getFontColor

public java.awt.Color getFontColor()
Devuelve el color de la fuente.

Returns:
Returns the m_FontColor.

setFontSizeInPixels

public void setFontSizeInPixels(boolean m_bUseFontSize)
Introduce si se usa el tamaño de la fuente en pixels.

Parameters:
m_bUseFontSize - The m_bUseFontSize to set.

isFontSizeInPixels

public boolean isFontSizeInPixels()
Devuelve true si el tamaño de la fuente esta seleccionado en pixels.

Returns:
Returns the m_bUseFontSize.

setShapeVisible

public void setShapeVisible(boolean m_bDrawShape)
Introduce si el shape e visible o no lo es.

Parameters:
m_bDrawShape - The m_bDrawShape to set.

isShapeVisible

public boolean isShapeVisible()
Devuelve true si el shape es visible.

Returns:
Returns the m_bDrawShape.

setSize

public void setSize(int m_Size)
Introduce el tamaño del símbolo.

Parameters:
m_Size - The m_Size to set.

getSize

public int getSize()
Devuelve el tamaño del símbolo.

Returns:
Returns the m_Size.

setIcon

public void setIcon(java.awt.Image m_Icon)
Introduce la imagen que hace de icono.

Parameters:
m_Icon - The m_Icon to set.

getIcon

public java.awt.Image getIcon()
Devuelve el icono.

Returns:
Returns the m_Icon.

setRotation

public void setRotation(int m_Rotation)
Introduce la rotación.

Parameters:
m_Rotation - The m_Rotation to set.

getRotation

public int getRotation()
Devuelve la rotación.

Returns:
Returns the m_Rotation.

setFill

public void setFill(java.awt.Paint m_Fill)
Introduce el relleno.

Parameters:
m_Fill - The m_Fill to set.

getFill

public java.awt.Paint getFill()
Devuelve el relleno.

Returns:
Returns the m_Fill.

setStroke

public void setStroke(java.awt.Stroke m_Stroke)
Introduce el Stroke.

Parameters:
m_Stroke - The m_Stroke to set.

getStroke

public java.awt.Stroke getStroke()
Devuelve el Stroke.

Returns:
Returns the m_Stroke.

setSizeInPixels

public void setSizeInPixels(boolean m_bUseSize)
Introduce si el tamaño del simbolo está en pixels.

Parameters:
m_bUseSize - The m_bUseSize to set.

isSizeInPixels

public boolean isSizeInPixels()
Devuelve si el tamaño del símbolo está en pixels.

Returns:
Returns the m_bUseSize.

setDescription

public void setDescription(java.lang.String m_Descrip)
Introduce la descripción del símbolo.

Parameters:
m_Descrip - The m_Descrip to set.

getDescription

public java.lang.String getDescription()
Devuelve la descripción del símbolo.

Returns:
Returns the m_Descrip.

setAlingVert

public void setAlingVert(int m_AlingVert)
Introduce la alineación en vertical.

Parameters:
m_AlingVert - The m_AlingVert to set.

getAlingVert

public int getAlingVert()
Devuelve la alineación en vertical.

Returns:
Returns the m_AlingVert.

setAlingHoriz

public void setAlingHoriz(int m_AlingHoriz)
Introduce la alineación en horizontal.

Parameters:
m_AlingHoriz - The m_AlingHoriz to set.

getAlingHoriz

public int getAlingHoriz()
Devuelve la alineación en horizontal.

Returns:
Returns the m_AlingHoriz.

getSelectionColor

public static java.awt.Color getSelectionColor()
Devuelve el color que se aplica a los shapes seleccionados.

Returns:
DOCUMENT ME!

setSelectionColor

public static void setSelectionColor(java.awt.Color selectionColor)
Introduce el color que se aplica a los shapes seleccionados.

Parameters:
selectionColor - DOCUMENT ME!

setFontSize

public void setFontSize(float m_FontSize)
Introduce el tamaño de la fuente.

Parameters:
m_FontSize - The m_FontSize to set.

getFontSize

public float getFontSize()
Devuelve el tamaño de la fuente.

Returns:
Returns the m_FontSize.