public class

TextColumnStyle

extends Object
java.lang.Object
   ↳ com.shinobicontrols.grids.supplement.TextColumnStyle

Class Overview

A convenience style object that is used to set the style of various items within the TextColumnSpec. It can optionally have a OnStyleChangedListener which will be notified whenever a style property is changed.

Summary

Public Constructors
TextColumnStyle()
Public Methods
float getAlpha()

Returns the Alpha value for the this ColumnSpec.

int getBackgroundColor()

Returns the BackgroundColor for the this ColumnSpec.

int getGravity()

Returns the Gravity for the this ColumnSpec.

int getTextColor()

Returns the TextColor for this ColumnSpec.

float getTextSize()

Returns the size, in pixels, of the text in the Views for this ColumnSpec.

Typeface getTypeface()

Returns the Typeface for the this ColumnSpec.

void setAlpha(float alpha)

Sets the Alpha value for this ColumnSpec.

void setBackgroundColor(int backgroundColor)

Sets the BackgroundColor for this ColumnSpec.

void setGravity(int gravity)

Sets the Gravity for this ColumnSpec.

void setOnStyleChangedListener(OnStyleChangedListener listener)

Sets the OnStyleChangedListener that responds to style changes in the grid.

void setTextColor(int textColor)

Sets the TextColor for this ColumnSpec.

void setTextSize(float textSize)

Sets the size, in pixels, of the text in the Views for this ColumnSpec.

void setTypeface(Typeface typeface)

Sets the Typeface for this ColumnSpec.

[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public TextColumnStyle ()

Public Methods

public float getAlpha ()

Returns the Alpha value for the this ColumnSpec. This is a value from 0 to 1, where 0 means the view is completely transparent and 1 means the view is completely opaque.

By default this is 1.0f.

Returns
  • the header alpha value for the this ColumnSpec
See Also

public int getBackgroundColor ()

Returns the BackgroundColor for the this ColumnSpec.

Returns
  • the BackgroundColor for the this ColumnSpec

public int getGravity ()

Returns the Gravity for the this ColumnSpec. The gravity value determines the horizontal and vertical alignment of text of any Column to which this ColumnSpec is applied.

Returns
  • the Gravity for the this ColumnSpec
See Also

public int getTextColor ()

Returns the TextColor for this ColumnSpec.

Returns
  • the TextColor for this ColumnSpec

public float getTextSize ()

Returns the size, in pixels, of the text in the Views for this ColumnSpec.

Returns
  • the size, in pixels, of the text in the Views for this ColumnSpec

public Typeface getTypeface ()

Returns the Typeface for the this ColumnSpec. May be null.

Returns
  • the Typeface for the this ColumnSpec, may be null

public void setAlpha (float alpha)

Sets the Alpha value for this ColumnSpec. This is a value from 0 to 1, where 0 means the view is completely transparent and 1 means the view is completely opaque.

By default this is 1.0f.

Parameters
alpha the alpha value to set
See Also

public void setBackgroundColor (int backgroundColor)

Sets the BackgroundColor for this ColumnSpec.

Setting this value will take precedence over, and override, any equivalent value in a ShinobiGridTheme set on the grid.

Parameters
backgroundColor the background color to set

public void setGravity (int gravity)

Sets the Gravity for this ColumnSpec. The gravity value determines the horizontal and vertical alignment of text of any Column to which this ColumnSpec is applied.

Setting this value will take precedence over, and override, any equivalent value in a ShinobiGridTheme set on the grid.

Parameters
gravity the gravity to set
See Also

public void setOnStyleChangedListener (OnStyleChangedListener listener)

Sets the OnStyleChangedListener that responds to style changes in the grid.

Parameters
listener the listener that responds to style changes

public void setTextColor (int textColor)

Sets the TextColor for this ColumnSpec. This color will be applied to all text, in any Column to which this ColumnSpec is applied.

Setting this value will take precedence over, and override, any equivalent value in a ShinobiGridTheme set on the grid.

Parameters
textColor the text color to set
See Also

public void setTextSize (float textSize)

Sets the size, in pixels, of the text in the Views for this ColumnSpec.

Setting this value will take precedence over, and override, any equivalent value in a ShinobiGridTheme set on the grid.

Parameters
textSize the size, in pixels, of the text in the Views for this ColumnSpec
See Also

public void setTypeface (Typeface typeface)

Sets the Typeface for this ColumnSpec. May be null.

Parameters
typeface the typeface to set
See Also