csGridView Class Reference
[Grid]
The GridView displays a continuous rectangular region of the grid.
More...
#include <csgrid.h>
Inheritance diagram for csGridView:

Public Methods | |
csGridView (csGrid *pParent, const csRect ®ion, int iStyle=CSGVS_DEFAULTVALUE) | |
Create a grid view covering given subregion of the grid. | |
csGridView (const csGridView &view, int iStyle=-1) | |
Create a copy of given grid view, and copy its style (or use a new style). | |
virtual void | Draw () |
Draw the grid view. | |
virtual bool | HandleEvent (iEvent &Event) |
Handle a event. | |
virtual bool | SetRect (int xmin, int ymin, int xmax, int ymax) |
Set grid view position and size. | |
const csRect & | GetArea () |
return this views area | |
virtual void | FixSize (int &newW, int &newH) |
Snap size to nearest grid cell. | |
virtual void | SuggestSize (int &w, int &h) |
Suggest the optimal size for this grid view. | |
csGridView * | SplitX (int x, int iStyle=-1) |
Create a new grid view by splitting this view along X axis. | |
csGridView * | SplitY (int y, int iStyle=-1) |
Create a new grid view by splitting this view along Y axis. | |
void | SetViewArea (const csRect &rc) |
Restrict the area that this view can display. | |
Public Attributes | |
float | areafactor |
if view was split and this is the newly created view, then this value tells us what part of the old area this one covers - needed for resizing view hierachy | |
Protected Methods | |
void | CooAt (int theX, int theY, int &theRow, int &theCol) |
get the row and column at the pixel (theX, theY) | |
virtual csGridView * | CreateCopy (int iStyle) |
Create a new copy of this view. | |
void | PlaceItems () |
Place all the items in their places. | |
Protected Attributes | |
csRect | area |
The subcells this view is restricted to. | |
csGrid * | pGrid |
The parent grid object. | |
int | row |
Row and column of the first visible cell (upper left). | |
int | col |
Row and column of the first visible cell (upper left). | |
bool | fPlaceItems |
True if items should be re-positioned (due to a new item inserted etc). | |
int | Style |
The style of this view. | |
csScrollBar * | hscroll |
The horizontal and vertical scrollbar objects. | |
csScrollBar * | vscroll |
The horizontal and vertical scrollbar objects. |
Detailed Description
The GridView displays a continuous rectangular region of the grid.It can be subdivided horizontally or vertically into two smaller views, and can contain a horizontal and a vertical scrollbar for scrolling the contents of the grid.
Definition at line 261 of file csgrid.h.
Constructor & Destructor Documentation
|
Create a grid view covering given subregion of the grid.
|
|
Create a copy of given grid view, and copy its style (or use a new style).
|
Member Function Documentation
|
get the row and column at the pixel (theX, theY)
|
|
Create a new copy of this view.
|
|
Draw the grid view.
Reimplemented from csComponent. |
|
Snap size to nearest grid cell.
Reimplemented from csComponent. |
|
return this views area
|
|
Handle a event.
Reimplemented from csComponent. |
|
Place all the items in their places.
|
|
Set grid view position and size.
Reimplemented from csComponent. |
|
Restrict the area that this view can display.
Definition at line 321 of file csgrid.h. References col, row, csRect::Set(), csRect::xmax, csRect::xmin, csRect::ymax, and csRect::ymin. |
|
Create a new grid view by splitting this view along X axis. If values are not positive the split in that direction does not happen. |
|
Create a new grid view by splitting this view along Y axis. If values are not positive the split in that direction does not happen. |
|
Suggest the optimal size for this grid view.
Reimplemented from csComponent. |
Member Data Documentation
|
The subcells this view is restricted to.
|
|
if view was split and this is the newly created view, then this value tells us what part of the old area this one covers - needed for resizing view hierachy
|
|
Row and column of the first visible cell (upper left).
Definition at line 269 of file csgrid.h. Referenced by SetViewArea(). |
|
True if items should be re-positioned (due to a new item inserted etc).
|
|
The horizontal and vertical scrollbar objects.
|
|
The parent grid object.
|
|
Row and column of the first visible cell (upper left).
Definition at line 269 of file csgrid.h. Referenced by SetViewArea(). |
|
The style of this view.
|
|
The horizontal and vertical scrollbar objects.
|
The documentation for this class was generated from the following file:
- csws/csgrid.h
Generated for Crystal Space by doxygen 1.2.18