Inherits from SGridCellStyle : NSObject
Declared in SGridColRowStyle.h
Availability
Related samples

Overview

An object of type SGridColRowStyle represents a style to be applied to an entire row or column. The methods shinobiGrid:styleForRowAtIndex:inSection: and shinobiGrid:styleForColAtIndex: of the object that implements the SGridDelegate protocol are intended to return objects of this type in order to apply a style to an entire row or column.

See SGridCellStyle for details regarding style precedence and conflicts.

Tasks

Initializing a SGridColRowStyle Object

Col/Row Dimensions

  •   size

    This property either represents the width of a column or the height of a row.

    property
  •   minimumSize

    If the grid is unable to find a size to use (col width or row height) then the grid will calculate some to use. The grid will try to fit all content into an unscrollable grid, but will not reduce a given size below minimumSize. Minimum size is also adhered to when the user is pinching to resize a column.

    property

Properties

minimumSize

If the grid is unable to find a size to use (col width or row height) then the grid will calculate some to use. The grid will try to fit all content into an unscrollable grid, but will not reduce a given size below minimumSize. Minimum size is also adhered to when the user is pinching to resize a column.

@property (nonatomic, retain) NSNumber *minimumSize

Discussion

Default value is nil.

Declared In

SGridColRowStyle.h

size

This property either represents the width of a column or the height of a row.

@property (nonatomic, retain) NSNumber *size

Discussion

Default value is nil. Having this set at nil results in auto-sizing of a cell’s appropriate dimension. If auto-sizing is not desired then set this to be non-nil. A size of zero will mean that the column or row is not displayed.

Declared In

SGridColRowStyle.h

Class Methods

styleWithSize:withBackgroundColor:withTextColor:withFont:

Creates an autoreleased object using the corresponding initWithSize:withBackgroundColor:withTextColor:withFont:.

+ (id)styleWithSize:(NSNumber *)newSize withBackgroundColor:(UIColor *)backgroundColor withTextColor:(UIColor *)textColor withFont:(UIFont *)font

Declared In

SGridColRowStyle.h

styleWithSize:withBackgroundColor:withTextColor:withTextAlignment:withVerticalTextAlignment:withFont:

Creates an autoreleased object using the corresponding initWithSize:withBackgroundColor:withTextColor:withFont:.

+ (id)styleWithSize:(NSNumber *)newSize withBackgroundColor:(UIColor *)backgroundColor withTextColor:(UIColor *)textColor withTextAlignment:(NSTextAlignment)textAlignment withVerticalTextAlignment:(UIControlContentVerticalAlignment)textVerticalAlignment withFont:(UIFont *)font

Declared In

SGridColRowStyle.h

styleWithSize:withCellStyle:

Uses a cell style to create an object of this class.

+ (id)styleWithSize:(NSNumber *)newSize withCellStyle:(SGridCellStyle *)cellStyle

Declared In

SGridColRowStyle.h

Instance Methods

initWithSize:withBackgroundColor:withTextColor:withFont:

Creates and returns an object that represents the style of an entire row or column with the specified parameters.

- (id)initWithSize:(NSNumber *)newSize withBackgroundColor:(UIColor *)backgroundColor withTextColor:(UIColor *)textColor withFont:(UIFont *)font

Declared In

SGridColRowStyle.h

initWithSize:withBackgroundColor:withTextColor:withTextAlignment:withVerticalTextAlignment:withFont:

Creates and returns an object that represents the style of an entire row or column with the specified parameters.

- (id)initWithSize:(NSNumber *)newSize withBackgroundColor:(UIColor *)backgroundColor withTextColor:(UIColor *)textColor withTextAlignment:(NSTextAlignment)textAlignment withVerticalTextAlignment:(UIControlContentVerticalAlignment)textVerticalAlignment withFont:(UIFont *)font

Declared In

SGridColRowStyle.h