DBTreeGrid::TDBTreeGrid Class Reference

#include <DBTreeGrid.h>

List of all members.

Public Member Functions

__fastcall TDBTreeGrid (TComponent *Owner)
virtual __fastcall ~TDBTreeGrid ()
virtual void __fastcall SetBounds (int ALeft, int ATop, int AWidth, int AHeight)
bool StartEditing (void)
void StopEditing (bool commit)
void EditorKeyDown (Word &Key, Classes::TShiftState Shift)
void EditorExit (void)
void FocusRow (TDBTreeGridRow *row, bool ensureVisible, bool immediately=false)
void FocusDataSetRow (bool immediately=false)
void FocusColumn (TDBTreeGridColumn *column, bool ensureVisible)
void ResyncWithDataSet (void)
TDBTreeGridRowGetCurrentDataSetRow (void)
bool RowIsCurrentDataSetRow (TDBTreeGridRow *row)
void DefaultDrawFixedCell (unsigned int flags, Graphics::TCanvas *Canvas, const TRect &destRect, TDBTreeGridColumn *column, TDBTreeGridRow *row)
void DefaultDrawDataCell (unsigned int flags, Graphics::TCanvas *Canvas, const TRect &destRect, TDBTreeGridColumn *column, TDBTreeGridRow *row)
int GetRowExpanderSize (TDBTreeGridRow *row)
int GetColumnsCount (void) const
TDBTreeGridColumnAddColumn (void)
TDBTreeGridColumnGetColumn (int index) const
TDBTreeGridColumnGetFieldColumn (const AnsiString &fieldName) const
void RemoveColumn (int index)
void SetColumnIndex (TDBTreeGridColumn *column, int newIndex)
void SetColumnSortIndex (TDBTreeGridColumn *column, int newSortIndex)
std::vector< TDBTreeGridColumn * > GetSortColumns (void)
void ClearSortColumns (void)
void ClearColumns (void)
void UpdateColumns (void)
void RecalcColumnWidth (TDBTreeGridColumn *column)
TPoint GetScrollOffset (void)
void GetCellText (TDBTreeGridColumn *column, TDBTreeGridRow *row, bool displayText, AnsiString &text)
void SetCellText (TDBTreeGridColumn *column, TDBTreeGridRow *row, const AnsiString &text)
Types::TSize CalcTextSize (const AnsiString &text, TFont *font, bool multiLine, int maxWidth=0)
bool GetCellAt (int X, int Y, TDBTreeGridColumn **column, TDBTreeGridRow **row, int *posInCell=NULL, int *cellWidth=NULL, TRect *cellRect=NULL)
TRect GetCellRect (TDBTreeGridColumn *column, TDBTreeGridRow *row)
void GetCellTextOffsets (Graphics::TCanvas *Canvas, TDBTreeGridColumn *column, TDBTreeGridRow *row, int &offsetLeft, int &offsetRight)
void GetCellTextSize (Graphics::TCanvas *Canvas, TDBTreeGridColumn *column, TDBTreeGridRow *row, Types::TSize &sz)
bool IsCellEditable (TDBTreeGridColumn *column, TDBTreeGridRow *row)
void EnsureRowVisible (TDBTreeGridRow *row)
void EnsureColumnVisible (TDBTreeGridColumn *column)
void Freeze (void)
void Thaw (void)
bool IsFrozen (void)
void NotifyChanged (int changeType, TDBTreeGridColumn *column, TDBTreeGridRow *row)
void FillRowsFlat (void)
void RefillRows (void)
void HighlightRow (TDBTreeGridRow *row)
void DehighlightRow (TDBTreeGridRow *row)
void UpdateDataSetData (void)
virtual void __fastcall Dispatch (void *Message)

Static Public Member Functions

static bool CanSortDataType (TFieldType ft)

Public Attributes

__property TDBTreeGridRowRootRow = {read=mRootRow}
__property TDBTreeGridSelectionSelection = {read=mSelection}
__property TPoint HitTest = {read=mHitTest}
__property TDBTreeGridColumnExpanderColumn = {read=mExpanderColumn, write=SetExpanderColumn}
__property TDBTreeGridRowFocusedRow = {read=mFocusedRow}
__property TDBTreeGridColumnFocusedColumn = {read=mFocusedColumn}
__property int MovingColumn = {read=mMovingColumn}
__property int SizingColumn = {read=mSizingColumn}
__property bool IsEditing = {read=mIsEditing}
__property int SortColumnsCount = {read=mSortColumnsCount}
__property Align
__property Anchors
__property BiDiMode
__property TBorderStyle BorderStyle = {read=mBorderStyle, write=SetBorderStyle, default=bsSingle}
__property Color
__property Constraints
__property Ctl3D
__property DragCursor
__property DragKind
__property TDragMode DragMode = {read=mDragMode, write=mDragMode, default=dmManual}
__property Enabled
__property Font
__property ParentBiDiMode
__property ParentColor
__property ParentCtl3D
__property ParentFont
__property PopupMenu
__property TabOrder
__property TabStop
__property Visible
__property Controls::TMargins * CellMargins = {read=mCellMargins, write=SetCellMargins}
__property TDBTreeGridOptions Options = {read=mOptions, write=SetOptions, default=0x3B0FDFF}
__property AnsiString NoDataSetText = {read=mNoDataSetText, write=SetNoDataSetText}
__property AnsiString NoRowText = {read=mNoRowText, write=SetNoRowText}
__property bool KeepColumns = {read=mKeepColumns, write=mKeepColumns, default=false}
__property int IndicatorWidth = {read=mIndicatorWidth, write=SetIndicatorWidth, default=11 }
__property TFont * TitleFont = {read=mTitleFont}
__property Db::TDataSource * DataSource = {read=GetDataSource, write=SetDataSource}
__property TColor FixedColor = {read=mFixedColor, write=mFixedColor, default=clBtnFace}
__property TColor OddRowColor = {read=mOddRowColor, write=mOddRowColor, default=clNone}
__property TColor EvenRowColor = {read=mEvenRowColor, write=mEvenRowColor, default=clNone}
__property int AlternateRowColorShift = {read=mAlternateRowColorShift, write=mAlternateRowColorShift, default=10}
__property int Indent = {read=mIndent, write=SetIndent, default=16}
__property int ChangeDelay = {read=mChangeDelay, write=mChangeDelay, default=250}
__property bool ForceFocus = {read=mForceFocus, write=mForceFocus, default=true}
__property TColor InactiveSelectionBg = {read=mInactiveSelectionBg, write=mInactiveSelectionBg, default=clNone}
__property TColor InactiveSelectionFg = {read=mInactiveSelectionFg, write=mInactiveSelectionFg, default=clNone}
__property TCustomImageList * Images = {read=mImages, write=SetImages, default=NULL}
__property AnsiString HighlightText = {read=mHighlightText, write=SetHighlightText}
__property TColor HighlightTextBg = {read=mHighlightTextBg, write=SetHighlightTextBg, default=clNone}
__property TColor HighlightTextFg = {read=mHighlightTextFg, write=SetHighlightTextFg, default=clNone}
__property bool HighlightTextIC = {read=mHighlightTextIC, write=SetHighlightTextIC, default=false}
__property TColor UrlColor = {read=mUrlColor, write=SetUrlColor, default=clNone}
__property TColor UrlHoverColor = {read=mUrlHoverColor, write=SetUrlHoverColor, default=clNone}
__property OnCanResize
__property OnClick
__property OnConstrainedResize
__property OnContextPopup
__property OnDblClick
__property OnDragDrop
__property OnDragOver
__property OnEndDock
__property OnEndDrag
__property OnEnter
__property OnExit
__property OnKeyDown
__property OnKeyPress
__property OnKeyUp
__property OnMouseActivate
__property OnMouseDown
__property OnMouseUp
__property OnMouseMove
__property OnMouseLeave
__property OnMouseEnter
__property OnMouseWheelDown
__property OnMouseWheelUp
__property OnResize
__property OnStartDock
__property OnStartDrag
__property
TDBTreeGridGetCellTextEvent 
OnGetCellText = {read=mOnGetCellText, write=mOnGetCellText}
__property
TDBTreeGridGetCellTextOffsetsEvent 
OnGetCellTextOffsets = {read=mOnGetCellTextOffsets, write=mOnGetCellTextOffsets}
__property
TDBTreeGridGetCellTextSizeEvent 
OnGetCellTextSize = {read=mOnGetCellTextSize, write=mOnGetCellTextSize}
__property
TDBTreeGridSetCellTextEvent 
OnSetCellText = {read=mOnSetCellText, write=mOnSetCellText}
__property TDBTreeGridRowEvent OnRowDelete = {read=mOnRowDelete, write=mOnRowDelete}
__property TDBTreeGridRowEvent OnRowExpandedChanged = {read=mOnRowExpandedChanged, write=mOnRowExpandedChanged}
__property TNotifyEvent OnFillRows = {read=mOnFillRows, write=mOnFillRows}
__property TNotifyEvent OnColumnsFilled = {read=mOnColumnsFilled, write=mOnColumnsFilled}
__property TDBTreeGridDrawCellEvent OnDrawFixedCell = {read=mOnDrawFixedCell, write=mOnDrawFixedCell}
__property TDBTreeGridDrawCellEvent OnDrawDataCell = {read=mOnDrawDataCell, write=mOnDrawDataCell}
__property
TDBTreeGridCellClickEvent 
OnCellClick = {read=mOnCellClick, write=mOnCellClick}
__property
TDBTreeGridCellClickEvent 
OnCellDblClick = {read=mOnCellDblClick, write=mOnCellDblClick}
__property
TDBTreeGridCellClickEvent 
OnCellReClick = {read=mOnCellReClick, write=mOnCellReClick}
__property
TDBTreeGridCalcRowHeightEvent 
OnCalcRowHeight = {read=mOnCalcRowHeight, write=mOnCalcRowHeight}
__property
TDBTreeGridCellAllowEvent 
OnIsCellEditable = {read=mOnIsCellEditable, write=mOnIsCellEditable}
__property
TDBTreeGridCellValidateEvent 
OnCellValidate = {read=mOnCellValidate, write=mOnCellValidate}
__property
TDBTreeGridCellValidateErrorEvent 
OnCellValidateError = {read=mOnCellValidateError, write=mOnCellValidateError}
__property TNotifyEvent OnResyncWithDataSet = {read=mOnResyncWithDataSet, write=mOnResyncWithDataSet}
__property TNotifyEvent OnSortingChanged = {read=mOnSortingChanged, write=mOnSortingChanged}
__property TNotifyEvent OnRowsFilled = {read=mOnRowsFilled, write=mOnRowsFilled}
__property TDBTreeGridRowEvent OnRowChanging = {read=mOnRowChanging, write=mOnRowChanging}
__property TDBTreeGridRowEvent OnRowChanged = {read=mOnRowChanged, write=mOnRowChanged}
__property TDBTreeGridRowEvent OnRowSelect = {read=mOnRowSelect, write=mOnRowSelect}
__property TDBTreeGridColumnEvent OnColumnVisibleChanged = {read=mOnColumnVisibleChanged, write=mOnColumnVisibleChanged}
__property TDBTreeGridColumnEvent OnColumnMoved = {read=mOnColumnMoved, write=mOnColumnMoved}
__property TDBTreeGridColumnEvent OnColumnResized = {read=mOnColumnResized, write=mOnColumnResized}
__property
TDBTreeGridCellTooltipEvent 
OnCellTooltip = {read=mOnCellTooltip, write=mOnCellTooltip}
__property TDBTreeGridCellEvent OnCellChanged = {read=mOnCellChanged, write=mOnCellChanged}
__property TNotifyEvent OnRowsLayoutChanged = {read=mOnRowsLayoutChanged, write=mOnRowsLayoutChanged}
__property
TDBTreeGridCellAllowEvent 
OnCellDragStart = {read=mOnCellDragStart, write=mOnCellDragStart}
__property
TDBTreeGridTextHighlightTextRangesEvent 
OnGetHighlightTextRanges = {read=mOnGetHighlightTextRanges, write=mOnGetHighlightTextRanges}
__property TDBTreeGridUrlClickEvent OnUrlClick = {read=mOnUrlClick, write=mOnUrlClick}

Protected Member Functions

void InvalidateRect (const TRect &rect)
virtual void __fastcall CreateWindowHandle (const TCreateParams &Params)
virtual void __fastcall Notification (Classes::TComponent *AComponent, Classes::TOperation Operation)
DYNAMIC void __fastcall KeyDown (Word &Key, Classes::TShiftState Shift)
DYNAMIC void __fastcall KeyPress (wchar_t &Key)
DYNAMIC void __fastcall KeyUp (Word &Key, Classes::TShiftState Shift)
DYNAMIC void __fastcall MouseDown (Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int Y)
DYNAMIC void __fastcall MouseMove (Classes::TShiftState Shift, int X, int Y)
DYNAMIC void __fastcall MouseUp (Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int Y)
DYNAMIC bool __fastcall DoMouseWheelUp (Classes::TShiftState Shift, const Types::TPoint &MousePos)
DYNAMIC bool __fastcall DoMouseWheelDown (Classes::TShiftState Shift, const Types::TPoint &MousePos)
DYNAMIC void __fastcall DragOver (System::TObject *Source, int X, int Y, TDragState State, bool &Accept)
void __fastcall ColumnsPtrIndexChanged (void *ptr, int newIndex)
void __fastcall SetBorderStyle (TBorderStyle bs)
void __fastcall SetOptions (TDBTreeGridOptions value)
void __fastcall SetNoDataSetText (const AnsiString value)
void __fastcall SetNoRowText (const AnsiString value)
void __fastcall SetIndicatorWidth (int value)
Db::TDataSource *__fastcall GetDataSource (void)
void __fastcall SetDataSource (Db::TDataSource *value)
void __fastcall SetExpanderColumn (TDBTreeGridColumn *column)
void __fastcall SetIndent (int pIndent)
void __fastcall SetImages (TCustomImageList *pImages)
void __fastcall SetCellMargins (Controls::TMargins *margins)
void __fastcall SetHighlightText (const AnsiString value)
void __fastcall SetHighlightTextBg (TColor value)
void __fastcall SetHighlightTextFg (TColor value)
void __fastcall SetHighlightTextIC (bool value)
void __fastcall SetUrlColor (TColor value)
void __fastcall SetUrlHoverColor (TColor value)
Db::TDataSet * GetDataSet (void)
void __fastcall CellMarginChanged (System::TObject *Sender)
void __fastcall TitleFontChanged (System::TObject *Sender)
void __fastcall FontChanged (System::TObject *Sender)
int GetInfoTextMaxWidth (void)
void RecalcRowSizes (bool onlyTitles)
void RecalcColSizes (void)
void RecalcContentSize (void)
void RecalcScrollInfo (void)
void UpdateScrollBar (int bar, bool needBar, int clientSz, int contentSz)
void ModifyScrollBar (int bar, int scrollCode, int pos)
void RecalcFirstVisibleRow (void)
void RedrawRow (TDBTreeGridRow *row)
void RedrawSelection (void)
void PlaceEditorControl (void)
bool isFocused (bool ignoreEditor=false)
bool EnsureFocused (bool ignoreEditor=false)
bool CanPickFocusRow (void)
void ResetMaybeDrag (void)
virtual void RemoveRow (TDBTreeGridRow *row)
void ManageSelection (Classes::TShiftState shift, TDBTreeGridRow *row)
void LocateRowInDataSet (TDBTreeGridRow *row, bool pretendChanged)
bool EnumHighlightTextRanges (TDBTreeGridColumn *column, TDBTreeGridRow *row, const AnsiString &cellText, TDBTreeGridRangesVector &ranges)
bool EnumUrlRanges (const AnsiString &text, std::vector< struct TDBTreeGridUrlRect > &ranges)
virtual void __fastcall CreateParams (TCreateParams &Params)
virtual void __fastcall Paint (void)
void DrawFixedCell (Graphics::TCanvas *Canvas, const TRect &destRect, TDBTreeGridColumn *column, TDBTreeGridRow *row)
void DrawDataCell (Graphics::TCanvas *Canvas, const TRect &destRect, TDBTreeGridColumn *column, TDBTreeGridRow *row)
void DrawColumnSizingLine (void)
void DrawColumnMovingLine (void)
TDBTreeGridColumnGetSizingColumnByXY (int X, int Y, TDBTreeGridColumn **hitColumn)
bool EditBoolCell (TDBTreeGridColumn *column, TDBTreeGridRow *row)
virtual void DoResyncWithDataSet (void)

Protected Attributes

TBorderStyle mBorderStyle
TImageList * mIndicators
Types::TSize mContentSize
int mTitlesHeight
Controls::TMargins * mCellMargins
TDBTreeGridOptions mOptions
AnsiString mNoDataSetText
AnsiString mNoRowText
TDBTreeGridRowmRootRow
std::map< TBookmark,
TDBTreeGridRow
*, TDBTreeGridBookmarkCmp
mBookmarkToRow
PtrArray::TPtrArray mColumns
bool mKeepColumns
int mIndicatorWidth
TFont * mTitleFont
TDBTreeGridDataLinkmDataLink
TColor mFixedColor
TDBTreeGridRowmFirstVisibleRow
TDBTreeGridRowmInsertStateRow
TDBTreeGridRowmFocusedRow
TDBTreeGridColumnmFocusedColumn
TColor mEvenRowColor
TColor mOddRowColor
int mAlternateRowColorShift
TDBTreeGridColumnmExpanderColumn
int mIndent
int mMovingColumn
int mMovingColumnAt
int mSizingColumn
int mSizingColumnAt
TPoint mMouseDownFromXY
TDBTreeGridColumnmMouseDownColumn
TDBTreeGridRowmMouseDownRow
bool mMouseDownReclick
TDBTreeGridSelectionmSelection
TDBTreeGridRowmShiftSelectionRow
int mSortColumnsCount
TDBTreeGridColumnmMaybeSortColumn
bool mIsEditing
TDBTreeGridCellEditormTextEditor
TWinControl * mTextEditorControl
TDBTreeGridCellEditormActiveEditor
TWinControl * mActiveEditorControl
int mChangeDelay
bool mRootRowClearing
bool mForceFocus
AnsiString mLookupText
bool mLookupProcessKey
DWORD mLookupLastTick
TDragMode mDragMode
TDBTreeGridColumnmaybeDragColumn
TDBTreeGridRowmaybeDragRow
int maybeDragX
int maybeDragY
TColor mInactiveSelectionBg
TColor mInactiveSelectionFg
TCustomImageList * mImages
AnsiString mHighlightText
TColor mHighlightTextBg
TColor mHighlightTextFg
bool mHighlightTextIC
TColor mUrlColor
TColor mUrlHoverColor
TDBTreeGridGetCellTextEvent mOnGetCellText
TDBTreeGridGetCellTextOffsetsEvent mOnGetCellTextOffsets
TDBTreeGridGetCellTextSizeEvent mOnGetCellTextSize
TDBTreeGridSetCellTextEvent mOnSetCellText
TDBTreeGridRowEvent mOnRowDelete
TDBTreeGridRowEvent mOnRowExpandedChanged
TNotifyEvent mOnFillRows
TNotifyEvent mOnColumnsFilled
TDBTreeGridDrawCellEvent mOnDrawFixedCell
TDBTreeGridDrawCellEvent mOnDrawDataCell
TDBTreeGridCellClickEvent mOnCellClick
TDBTreeGridCellClickEvent mOnCellDblClick
TDBTreeGridCellClickEvent mOnCellReClick
TDBTreeGridCalcRowHeightEvent mOnCalcRowHeight
TDBTreeGridCellAllowEvent mOnIsCellEditable
TNotifyEvent mOnSortingChanged
TDBTreeGridCellValidateEvent mOnCellValidate
TDBTreeGridCellValidateErrorEvent mOnCellValidateError
TNotifyEvent mOnResyncWithDataSet
TNotifyEvent mOnRowsFilled
TDBTreeGridRowEvent mOnRowChanging
TDBTreeGridRowEvent mOnRowChanged
TDBTreeGridRowEvent mOnRowSelect
TDBTreeGridColumnEvent mOnColumnVisibleChanged
TDBTreeGridColumnEvent mOnColumnMoved
TDBTreeGridColumnEvent mOnColumnResized
TDBTreeGridCellTooltipEvent mOnCellTooltip
TDBTreeGridCellEvent mOnCellChanged
TNotifyEvent mOnRowsLayoutChanged
TDBTreeGridCellAllowEvent mOnCellDragStart
TDBTreeGridTextHighlightTextRangesEvent mOnGetHighlightTextRanges
TDBTreeGridUrlClickEvent mOnUrlClick
__property Hint
__property ParentShowHint
__property ShowHint

Friends

class TDBTreeGridRow
class TDBTreeGridDataLink


Constructor & Destructor Documentation

__fastcall DBTreeGrid::TDBTreeGrid::TDBTreeGrid ( TComponent *  Owner  ) 

virtual __fastcall DBTreeGrid::TDBTreeGrid::~TDBTreeGrid (  )  [virtual]


Member Function Documentation

void DBTreeGrid::TDBTreeGrid::InvalidateRect ( const TRect &  rect  )  [protected]

virtual void __fastcall DBTreeGrid::TDBTreeGrid::CreateWindowHandle ( const TCreateParams &  Params  )  [protected, virtual]

virtual void __fastcall DBTreeGrid::TDBTreeGrid::Notification ( Classes::TComponent *  AComponent,
Classes::TOperation  Operation 
) [protected, virtual]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::KeyDown ( Word &  Key,
Classes::TShiftState  Shift 
) [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::KeyPress ( wchar_t &  Key  )  [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::KeyUp ( Word &  Key,
Classes::TShiftState  Shift 
) [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::MouseDown ( Controls::TMouseButton  Button,
Classes::TShiftState  Shift,
int  X,
int  Y 
) [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::MouseMove ( Classes::TShiftState  Shift,
int  X,
int  Y 
) [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::MouseUp ( Controls::TMouseButton  Button,
Classes::TShiftState  Shift,
int  X,
int  Y 
) [protected]

DYNAMIC bool __fastcall DBTreeGrid::TDBTreeGrid::DoMouseWheelUp ( Classes::TShiftState  Shift,
const Types::TPoint &  MousePos 
) [protected]

DYNAMIC bool __fastcall DBTreeGrid::TDBTreeGrid::DoMouseWheelDown ( Classes::TShiftState  Shift,
const Types::TPoint &  MousePos 
) [protected]

DYNAMIC void __fastcall DBTreeGrid::TDBTreeGrid::DragOver ( System::TObject *  Source,
int  X,
int  Y,
TDragState  State,
bool &  Accept 
) [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::ColumnsPtrIndexChanged ( void *  ptr,
int  newIndex 
) [protected]

Volana automaticky z mColumns pri zmene pozice sloupce.

void __fastcall DBTreeGrid::TDBTreeGrid::SetBorderStyle ( TBorderStyle  bs  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetOptions ( TDBTreeGridOptions  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetNoDataSetText ( const AnsiString  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetNoRowText ( const AnsiString  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetIndicatorWidth ( int  value  )  [protected]

Db::TDataSource* __fastcall DBTreeGrid::TDBTreeGrid::GetDataSource ( void   )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetDataSource ( Db::TDataSource *  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetExpanderColumn ( TDBTreeGridColumn column  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetIndent ( int  pIndent  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetImages ( TCustomImageList *  pImages  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetCellMargins ( Controls::TMargins *  margins  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetHighlightText ( const AnsiString  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetHighlightTextBg ( TColor  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetHighlightTextFg ( TColor  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetHighlightTextIC ( bool  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetUrlColor ( TColor  value  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::SetUrlHoverColor ( TColor  value  )  [protected]

Db::TDataSet* DBTreeGrid::TDBTreeGrid::GetDataSet ( void   )  [protected]

Returns currently used TDataSet. Returns NULL when there is none active.

void __fastcall DBTreeGrid::TDBTreeGrid::CellMarginChanged ( System::TObject *  Sender  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::TitleFontChanged ( System::TObject *  Sender  )  [protected]

void __fastcall DBTreeGrid::TDBTreeGrid::FontChanged ( System::TObject *  Sender  )  [protected]

int DBTreeGrid::TDBTreeGrid::GetInfoTextMaxWidth ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::RecalcRowSizes ( bool  onlyTitles  )  [protected]

void DBTreeGrid::TDBTreeGrid::RecalcColSizes ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::RecalcContentSize ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::RecalcScrollInfo ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::UpdateScrollBar ( int  bar,
bool  needBar,
int  clientSz,
int  contentSz 
) [protected]

void DBTreeGrid::TDBTreeGrid::ModifyScrollBar ( int  bar,
int  scrollCode,
int  pos 
) [protected]

void DBTreeGrid::TDBTreeGrid::RecalcFirstVisibleRow ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::RedrawRow ( TDBTreeGridRow row  )  [protected]

void DBTreeGrid::TDBTreeGrid::RedrawSelection ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::PlaceEditorControl ( void   )  [protected]

bool DBTreeGrid::TDBTreeGrid::isFocused ( bool  ignoreEditor = false  )  [protected]

bool DBTreeGrid::TDBTreeGrid::EnsureFocused ( bool  ignoreEditor = false  )  [protected]

bool DBTreeGrid::TDBTreeGrid::CanPickFocusRow ( void   )  [protected]

void DBTreeGrid::TDBTreeGrid::ResetMaybeDrag ( void   )  [protected]

virtual void DBTreeGrid::TDBTreeGrid::RemoveRow ( TDBTreeGridRow row  )  [protected, virtual]

void DBTreeGrid::TDBTreeGrid::ManageSelection ( Classes::TShiftState  shift,
TDBTreeGridRow row 
) [protected]

void DBTreeGrid::TDBTreeGrid::LocateRowInDataSet ( TDBTreeGridRow row,
bool  pretendChanged 
) [protected]

bool DBTreeGrid::TDBTreeGrid::EnumHighlightTextRanges ( TDBTreeGridColumn column,
TDBTreeGridRow row,
const AnsiString &  cellText,
TDBTreeGridRangesVector ranges 
) [protected]

bool DBTreeGrid::TDBTreeGrid::EnumUrlRanges ( const AnsiString &  text,
std::vector< struct TDBTreeGridUrlRect > &  ranges 
) [protected]

virtual void __fastcall DBTreeGrid::TDBTreeGrid::CreateParams ( TCreateParams &  Params  )  [protected, virtual]

virtual void __fastcall DBTreeGrid::TDBTreeGrid::Paint ( void   )  [protected, virtual]

void DBTreeGrid::TDBTreeGrid::DrawFixedCell ( Graphics::TCanvas *  Canvas,
const TRect &  destRect,
TDBTreeGridColumn column,
TDBTreeGridRow row 
) [protected]

Draws column title or row indicator. Both column and row can be NULL, that's how it recognizes what is drawn. The Canvas is already locked (TCanvas::Lock) and has set correct Font, Brush and Pen. The destRect is a rectangle where to draw. This will be moved to TreeGrid afterwards. There is called OnDrawFixedCell too, which can use DefaultDrawFixedCell.

void DBTreeGrid::TDBTreeGrid::DrawDataCell ( Graphics::TCanvas *  Canvas,
const TRect &  destRect,
TDBTreeGridColumn column,
TDBTreeGridRow row 
) [protected]

Similar to DrawFixedCell, only for data cells. If the row is not NULL, and it has assigned a row in DataSet, then the DataSet has selected the correct row. There is called OnDrawDataCell too, which can use DefaultDrawDataCell. An expander is drawn to this row if either the column is NULL, or the column's State contains csWithExpander. Note the column can be NULL for TDBTreeGridRow::Virtual and TDBTreeGridRow::VirtualFullRow.

void DBTreeGrid::TDBTreeGrid::DrawColumnSizingLine ( void   )  [protected]

Draws a XOR line on the TreeGrid where the mouse cursor is (mSizingColumnAt)

void DBTreeGrid::TDBTreeGrid::DrawColumnMovingLine ( void   )  [protected]

Draws a XOR line on the TreeGrid where the dragged column will be placed

TDBTreeGridColumn* DBTreeGrid::TDBTreeGrid::GetSizingColumnByXY ( int  X,
int  Y,
TDBTreeGridColumn **  hitColumn 
) [protected]

Calculates column width change from X and Y. The hitColumn is a column where point [X,Y] is above, in case it's above a title.

bool DBTreeGrid::TDBTreeGrid::EditBoolCell ( TDBTreeGridColumn column,
TDBTreeGridRow row 
) [protected]

In case the cell [column,row] is editable, and it is a boolean field, then it inverts the field value. Returns whether it tried to edit the value.

virtual void DBTreeGrid::TDBTreeGrid::DoResyncWithDataSet ( void   )  [protected, virtual]

A worker function for ResyncWithDataSet, if there is set OnResyncWithDataSet, then it calls it, otherwise is called RefillRows.

virtual void __fastcall DBTreeGrid::TDBTreeGrid::SetBounds ( int  ALeft,
int  ATop,
int  AWidth,
int  AHeight 
) [virtual]

bool DBTreeGrid::TDBTreeGrid::StartEditing ( void   ) 

Tries to start editing on the currently focused cell. Does nothing, if it is in an editor mode already (IsEditing). Returns, whether the grid is the editor mode.

void DBTreeGrid::TDBTreeGrid::StopEditing ( bool  commit  ) 

Stops editing of the focused cell. if the commit is true, then the editor value sis saved into the cell, otherwise the editing is cancelled. Does nothing if not in an editor mode (IsEditing).

void DBTreeGrid::TDBTreeGrid::EditorKeyDown ( Word &  Key,
Classes::TShiftState  Shift 
)

An editor calls this function when a user pressed a key down in the editor.

void DBTreeGrid::TDBTreeGrid::EditorExit ( void   ) 

An editor calls this function when a user exited the editor control.

void DBTreeGrid::TDBTreeGrid::FocusRow ( TDBTreeGridRow row,
bool  ensureVisible,
bool  immediately = false 
)

Focuses the row. The DataSet, if the row has assigned DataSet's row, is synchronized only after ChangeDelay, if the immediately is false, otherwise it's synchronized immediately. The ensureVisible says whether the TreeGrid should scroll the view to show the focused row.

void DBTreeGrid::TDBTreeGrid::FocusDataSetRow ( bool  immediately = false  ) 

Focuses row base don the currently active DataSet's row. If the TreeGrid is frozen (IsFrozen), then only after Thaw, if not forced by immediately being true.

void DBTreeGrid::TDBTreeGrid::FocusColumn ( TDBTreeGridColumn column,
bool  ensureVisible 
)

Focuses the column. ensureVisible says whether the view should be scrolled to show the column.

void DBTreeGrid::TDBTreeGrid::ResyncWithDataSet ( void   ) 

Called when row count in DataSet changes.

See also:
DoResyncWithDataSet

TDBTreeGridRow* DBTreeGrid::TDBTreeGrid::GetCurrentDataSetRow ( void   ) 

Returns corresponding TDBTreeGridRow associated with the current row of the DataSet, or NULL if there is no such row in the TreeGrid. The returned pointer can be different from the FocusedRow, because the move can be delayed by ChangeDelay.

bool DBTreeGrid::TDBTreeGrid::RowIsCurrentDataSetRow ( TDBTreeGridRow row  ) 

Returns whether the row is the row for the current DataSet row. Returns false, if the TreeGrid doesn't have assigned any DataSet.

void DBTreeGrid::TDBTreeGrid::DefaultDrawFixedCell ( unsigned int  flags,
Graphics::TCanvas *  Canvas,
const TRect &  destRect,
TDBTreeGridColumn column,
TDBTreeGridRow row 
)

Default method to draw column title and row indicator. The flags is a bit-OR of parts to draw, namely DEFAULT_DRAW_BACKGROUND, DEFAULT_DRAW_EDGE, DEFAULT_DRAW_TEXT, DEFAULT_DRAW_EXTRA, or DEFAULT_DRAW_ALL. Both column and row can be NULL, that's how it recognizes what is drawn. The Canvas is already locked (TCanvas::Lock) and has set correct Font, Brush and Pen. The destRect is a rectangle where to draw. This will be moved to TreeGrid afterwards. There is called OnDrawFixedCell too, which can use DefaultDrawFixedCell.

void DBTreeGrid::TDBTreeGrid::DefaultDrawDataCell ( unsigned int  flags,
Graphics::TCanvas *  Canvas,
const TRect &  destRect,
TDBTreeGridColumn column,
TDBTreeGridRow row 
)

Similar to DefaultDrawFixedCell, only for data cells. If the row is not NULL, and it has assigned a row in DataSet, then the DataSet has selected the correct row. There is called OnDrawDataCell too, which can use DefaultDrawDataCell. An expander is drawn to this row if either the column is NULL, or the column's State contains csWithExpander. Note the column can be NULL for TDBTreeGridRow::Virtual and TDBTreeGridRow::VirtualFullRow.

int DBTreeGrid::TDBTreeGrid::GetRowExpanderSize ( TDBTreeGridRow row  ) 

Returns pixel-size for an expander and tree level lines of the row parents. It's a required indentation of text from the left side. Returns zero, if the Options doesn't contain tgTree.

int DBTreeGrid::TDBTreeGrid::GetColumnsCount ( void   )  const

Returns count of columns in the TreeGrid.

TDBTreeGridColumn* DBTreeGrid::TDBTreeGrid::AddColumn ( void   ) 

Adds a new column into the TreeGrid. This does not have set TDBTreeGridColumn::FieldName yet.

TDBTreeGridColumn* DBTreeGrid::TDBTreeGrid::GetColumn ( int  index  )  const

Returns column with the given index; counts from 0. Throws an exception, if the index is out of range.

TDBTreeGridColumn* DBTreeGrid::TDBTreeGrid::GetFieldColumn ( const AnsiString &  fieldName  )  const

Returns a column, which is used for fieldName; or NULL, if not found.

void DBTreeGrid::TDBTreeGrid::RemoveColumn ( int  index  ) 

Removes column with index index. Throws an exception, if the index is out of range.

void DBTreeGrid::TDBTreeGrid::SetColumnIndex ( TDBTreeGridColumn column,
int  newIndex 
)

Moves column column to index newIndex. The newIndex can be equal to GetColumnsCount, then the column is moved to the end. Throws an exception, the column is not part of the TreeGrid, or if the newIndex is out of range.

void DBTreeGrid::TDBTreeGrid::SetColumnSortIndex ( TDBTreeGridColumn column,
int  newSortIndex 
)

Sets TDBTreeGridColumn::SortIndex at column to newSortIndex, or the nearest possible.

std::vector<TDBTreeGridColumn *> DBTreeGrid::TDBTreeGrid::GetSortColumns ( void   ) 

Returns list of columns with non-zero TDBTreeGridColumn::SortIndex, in order by the TDBTreeGridColumn::SortIndex.

void DBTreeGrid::TDBTreeGrid::ClearSortColumns ( void   ) 

Clears sort information on all columns, which basically means setting TDBTreeGridColumn::SortIndex to zero.

void DBTreeGrid::TDBTreeGrid::ClearColumns ( void   ) 

Removes all columns from the TreeGrid. If the KeepColumns is set to true, then removes only associations with the current DataSet fields.

void DBTreeGrid::TDBTreeGrid::UpdateColumns ( void   ) 

Automatically set list of columns based on those being available in the DataSet. If the KeepColumns is true, and the remembered columns are the same as those in the current DataSet, then only assigns data columns to DataSet fields, otherwise removes all columns and rebuilds them from scratch.

void DBTreeGrid::TDBTreeGrid::RecalcColumnWidth ( TDBTreeGridColumn column  ) 

Recalculates column width based on the values stored in the rows. The column can be NULL, which means 'all columns'.

static bool DBTreeGrid::TDBTreeGrid::CanSortDataType ( TFieldType  ft  )  [static]

Returns, whether the field type ft is a sortable type.

TPoint DBTreeGrid::TDBTreeGrid::GetScrollOffset ( void   ) 

Returns offset of the scrollbars (position of the vertical and horizontal scrollbar).

void DBTreeGrid::TDBTreeGrid::GetCellText ( TDBTreeGridColumn column,
TDBTreeGridRow row,
bool  displayText,
AnsiString &  text 
)

Gets text for column and row. For displayText true should set a value to be shown in the TreeGrid, otherwise a 'raw' value for the cell. For a column which has associated the DataSet's field is read the value from DataSet first, and then called the OnGetCellText event, if set. For virtual rows, which have set also TDBTreeGridRow::VirtualFullRow is column set to NULL. The DataSet should be located on the correct row already.

void DBTreeGrid::TDBTreeGrid::SetCellText ( TDBTreeGridColumn column,
TDBTreeGridRow row,
const AnsiString &  text 
)

Set text to cel identified by a column and a row. It calls also OnSetCellText.

Types::TSize DBTreeGrid::TDBTreeGrid::CalcTextSize ( const AnsiString &  text,
TFont *  font,
bool  multiLine,
int  maxWidth = 0 
)

Returns size of text if drawn by font, which cannot be NULL. The multiLine says whether the text has multiple lines. The maxWidth can limit width of the text, and the lines longer than this limit will be automatically wrapped. A value less or equal to zero means no wrapping.

bool DBTreeGrid::TDBTreeGrid::GetCellAt ( int  X,
int  Y,
TDBTreeGridColumn **  column,
TDBTreeGridRow **  row,
int *  posInCell = NULL,
int *  cellWidth = NULL,
TRect *  cellRect = NULL 
)

Finds a cell at X, Y (in TreeGrid's coordinates). Both column and row are output parameters and the function can set them to NULL when the point corresponds to a column title or a row indicator. Returns false, if the point is out of the content of the TreeGrid. Also TDBTreeGridRow::VirtualFullRow rows set column, in case the point is in a data columns. posInCell can return horizontal position in the cell itself. cellWidth can return used cell width during computation. cellRect is a cell rectangle, without tgShowColLines and tgShowRowLines.

TRect DBTreeGrid::TDBTreeGrid::GetCellRect ( TDBTreeGridColumn column,
TDBTreeGridRow row 
)

Returns cell rectangle identified by column and row. The function can return incorrect rectangle if the TreeGrid wasn't drawn yet. If the column or row is not visible, then returns [-1,-1,-1,-1]. This does not include the scroll offset (returned by GetScrollOffset).

void DBTreeGrid::TDBTreeGrid::GetCellTextOffsets ( Graphics::TCanvas *  Canvas,
TDBTreeGridColumn column,
TDBTreeGridRow row,
int &  offsetLeft,
int &  offsetRight 
)

Gets text offset from the left and from the right at a cell identified by column and row.

void DBTreeGrid::TDBTreeGrid::GetCellTextSize ( Graphics::TCanvas *  Canvas,
TDBTreeGridColumn column,
TDBTreeGridRow row,
Types::TSize &  sz 
)

Gets text size at a cell identified by column and row. The Canvas has set correct font for the column.

bool DBTreeGrid::TDBTreeGrid::IsCellEditable ( TDBTreeGridColumn column,
TDBTreeGridRow row 
)

Returns whether the cell identified by column and row is editable. Also calls OnIsCellEditable.

void DBTreeGrid::TDBTreeGrid::EnsureRowVisible ( TDBTreeGridRow row  ) 

Makes sure the row is visible in the view. Changes only vertical scrollbar position.

void DBTreeGrid::TDBTreeGrid::EnsureColumnVisible ( TDBTreeGridColumn column  ) 

Makes sure the column is visible in the view. Changes only horizontal scrollbar position.

void DBTreeGrid::TDBTreeGrid::Freeze ( void   ) 

Disables redraw of the TreeGrid. It can be called multiple times, only each call should have its pair Thaw.

void DBTreeGrid::TDBTreeGrid::Thaw ( void   ) 

A pair function for Freeze, which enables drawing again. If the TreeGrid have been notified about changes during the frozen state, then a complete content recalculation is done. Throws an exception, if the TreeGrid is not frozen.

bool DBTreeGrid::TDBTreeGrid::IsFrozen ( void   ) 

Returns whether the TreeGrid has frozen drawing. This is not only after Freeze call, but also when the associated DataSet has ControlsDisabled.

void DBTreeGrid::TDBTreeGrid::NotifyChanged ( int  changeType,
TDBTreeGridColumn column,
TDBTreeGridRow row 
)

Notify TreeGrid about change in column or row. In case the TreeGrid is frozen (see IsFrozen), then stores the change for later.

void DBTreeGrid::TDBTreeGrid::FillRowsFlat ( void   ) 

Fills RootRow as a flat list, without levels, from the associated DataSet.

void DBTreeGrid::TDBTreeGrid::RefillRows ( void   ) 

Forces a refill of the TreeGrid rows, it calls also OnFillRows, but if it's not set, then calls FillRowsFlat.

void DBTreeGrid::TDBTreeGrid::HighlightRow ( TDBTreeGridRow row  ) 

Highlights the row. There can be highlighted more than one row. The caller is responsible to unset the highlight flag with DehighlightRow. The function does nothing, if the row is already highlighted.

void DBTreeGrid::TDBTreeGrid::DehighlightRow ( TDBTreeGridRow row  ) 

Unsets highlight of the row, previously set by HighlightRow. The function does nothing, if the row is not highlighted.

void DBTreeGrid::TDBTreeGrid::UpdateDataSetData ( void   ) 

Updates data in DataSet from an editor.

virtual void __fastcall DBTreeGrid::TDBTreeGrid::Dispatch ( void *  Message  )  [virtual]


Friends And Related Function Documentation

friend class TDBTreeGridRow [friend]

friend class TDBTreeGridDataLink [friend]


Member Data Documentation

TBorderStyle DBTreeGrid::TDBTreeGrid::mBorderStyle [protected]

TImageList* DBTreeGrid::TDBTreeGrid::mIndicators [protected]

Types::TSize DBTreeGrid::TDBTreeGrid::mContentSize [protected]

Controls::TMargins* DBTreeGrid::TDBTreeGrid::mCellMargins [protected]

AnsiString DBTreeGrid::TDBTreeGrid::mNoRowText [protected]

AnsiString DBTreeGrid::TDBTreeGrid::mLookupText [protected]

TDragMode DBTreeGrid::TDBTreeGrid::mDragMode [protected]

TCustomImageList* DBTreeGrid::TDBTreeGrid::mImages [protected]

TNotifyEvent DBTreeGrid::TDBTreeGrid::mOnFillRows [protected]

TNotifyEvent DBTreeGrid::TDBTreeGrid::mOnRowsFilled [protected]

__property DBTreeGrid::TDBTreeGrid::Hint [protected]

__property DBTreeGrid::TDBTreeGrid::ShowHint [protected]

The root row. This is never drawn and cannot be NULL. All the row operations begin at this root row.

Selection object for the TreeGrid. Includes only selected row, thus if the row is only focused, then it is not part of the selection.

__property TPoint DBTreeGrid::TDBTreeGrid::HitTest = {read=mHitTest}

The last place where the mouse was above the TreeGrid.

__property TDBTreeGridColumn* DBTreeGrid::TDBTreeGrid::ExpanderColumn = {read=mExpanderColumn, write=SetExpanderColumn}

An expander column when drawing TreeGrid as tree (tgTree). If this is NULL, then the first visible column will be used. The expander column should be left NULL, in case of any row being a TDBTreeGridRow::VirtualFullRow.

Currently focused row, NULL if none.

Currently focused column, NULL if none. This is changed even if tgRowSelect is used.

An index of a column which is currently moving. -1 when no column is moving.

An index of a column which is currently changing its width. -1 when no column is sizing.

Whether the TreeGrid is in an editor mode, aka any cell is editing.

Count of columns used for sorting.

__property TBorderStyle DBTreeGrid::TDBTreeGrid::BorderStyle = {read=mBorderStyle, write=SetBorderStyle, default=bsSingle}

__property TDragMode DBTreeGrid::TDBTreeGrid::DragMode = {read=mDragMode, write=mDragMode, default=dmManual}

__property Controls::TMargins* DBTreeGrid::TDBTreeGrid::CellMargins = {read=mCellMargins, write=SetCellMargins}

Cell text margins

__property TDBTreeGridOptions DBTreeGrid::TDBTreeGrid::Options = {read=mOptions, write=SetOptions, default=0x3B0FDFF}

Options of the TreeGrid.

__property AnsiString DBTreeGrid::TDBTreeGrid::NoDataSetText = {read=mNoDataSetText, write=SetNoDataSetText}

Text shown when the TreeGrid has not set an active DataSet and there are no rows defined. The text can contain URLs, see TDBTreeGridUrlClickEvent for more information.

__property AnsiString DBTreeGrid::TDBTreeGrid::NoRowText = {read=mNoRowText, write=SetNoRowText}

Text shown when the TreeGrid has no rows and it has either an active DataSet or any column added. The text can contain URLs, see TDBTreeGridUrlClickEvent for more information.

__property bool DBTreeGrid::TDBTreeGrid::KeepColumns = {read=mKeepColumns, write=mKeepColumns, default=false}

Keep columns after the DataSet close or unset. If set to true, then after the DataSet close, only the TDBTreeGridColumn::Field is set to NULL and is assigned again after DataSet's open, thus the column order and sort information is kept unchanged. In case of assigning a DataSet with different fields, ten the current columns are all removed and the columns are refilled, together with the OnColumnsFilled call. The default value is false.

__property int DBTreeGrid::TDBTreeGrid::IndicatorWidth = {read=mIndicatorWidth, write=SetIndicatorWidth, default=11 }

Width, in pixels, of the indicator column, which is the first (fixed) column, if tgShowIndicator is used. The default value is 11.

__property TFont* DBTreeGrid::TDBTreeGrid::TitleFont = {read=mTitleFont}

Font used for the column titles.

__property Db::TDataSource* DBTreeGrid::TDBTreeGrid::DataSource = {read=GetDataSource, write=SetDataSource}

Assigned DataSource, with the DataSet, to show in the TreeGrid

__property TColor DBTreeGrid::TDBTreeGrid::FixedColor = {read=mFixedColor, write=mFixedColor, default=clBtnFace}

Background color for the fixed cells, aka column titles and row indicators.

__property TColor DBTreeGrid::TDBTreeGrid::OddRowColor = {read=mOddRowColor, write=mOddRowColor, default=clNone}

Background color of an odd row. This is used only if Options contains tgAlternateRowColor. The default value is clNone, and if the EvenRowColor is also clNone, then the background color is calculated dynamically, based on the current cell background.

__property TColor DBTreeGrid::TDBTreeGrid::EvenRowColor = {read=mEvenRowColor, write=mEvenRowColor, default=clNone}

Background color of an even row. This is used only if Options contains tgAlternateRowColor. The default value is clNone, and if the OddRowColor is also clNone, then the background color is calculated dynamically, based on the current cell background.

__property int DBTreeGrid::TDBTreeGrid::Indent = {read=mIndent, write=SetIndent, default=16}

> A color shift to use when both OddRowColor and EvenRowColor are clNone and the Options contains tgAlternateRowColor. Default value is 10. Indent width for one tree level. It is used only if Options contains tgTree. Default value is 16, which is also the minimum indent width.

__property int DBTreeGrid::TDBTreeGrid::ChangeDelay = {read=mChangeDelay, write=mChangeDelay, default=250}

How long to wait, in milliseconds, before the Dataset row is synchronized with the current FocusedRow. Default value is 250, and the value lower than or equal to zero means to synchronize the rows immediately in FocusRow.

__property bool DBTreeGrid::TDBTreeGrid::ForceFocus = {read=mForceFocus, write=mForceFocus, default=true}

Whether to require having focus on the TreeGrid for cell operations. The default value is true, which means the cell events, like OnCellClick, will not be triggered when a click happens with not-focused TreeGrid and the component resize will ensures the currently focused row being shown in the view.

Background color of a selection, when the TreeGrid doesn't have focus. This is used only if Options contains tgAlwaysShowSelection. Default value is clNone, which will use clBtnFace. See also InactiveSelectionFg.

Foreground (text) color of a selection, when the TreeGrid doesn't have focus. This is used only if Options contains tgAlwaysShowSelection. Default value is clNone, which will use clBtnText. See also InactiveSelectionBg.

__property TCustomImageList* DBTreeGrid::TDBTreeGrid::Images = {read=mImages, write=SetImages, default=NULL}

An image list to use when drawing an image into an expander column.

See also:
TDBTreeGridRow::ImageIndex, ExpanderColumn

__property AnsiString DBTreeGrid::TDBTreeGrid::HighlightText = {read=mHighlightText, write=SetHighlightText}

A text to highlight in data cells. Empty string to not highlight. The default text checker searches for exact inclusion of the text, but it can be overwritten with OnGetHighlightTextRanges.

See also:
HighlightTextBg, HighlightTextFg, HighlightTextIC.

__property TColor DBTreeGrid::TDBTreeGrid::HighlightTextBg = {read=mHighlightTextBg, write=SetHighlightTextBg, default=clNone}

Background color of a highlighted text. This is used only if HighlightText is not an empty string. Default value is clNone, which will use clHightlight.

See also:
HighlightText, HighlightTextFg

__property TColor DBTreeGrid::TDBTreeGrid::HighlightTextFg = {read=mHighlightTextFg, write=SetHighlightTextFg, default=clNone}

Foreground (text) color of a highlighted text. This is used only if HighlightText is not an empty string. Default value is clNone, which will use clHighlightText.

See also:
HightlightText, HighlightTextBg

__property bool DBTreeGrid::TDBTreeGrid::HighlightTextIC = {read=mHighlightTextIC, write=SetHighlightTextIC, default=false}

Whether the default text highlight routine should check content case insensitively. Default is false.

See also:
HighlightText, OnGetHighlightTextRanges

__property TColor DBTreeGrid::TDBTreeGrid::UrlColor = {read=mUrlColor, write=SetUrlColor, default=clNone}

Font color for URLs defined in NoDataSetText or NoRowText. If set to clNone, then clNavy is used.

__property TColor DBTreeGrid::TDBTreeGrid::UrlHoverColor = {read=mUrlHoverColor, write=SetUrlHoverColor, default=clNone}

Font color for URLs defined in NoDataSetText or NoRowText when a mouse is hovering above it. If set to clNone, then the UrlColor is used.

User's callback to read text of a cell.

See also:
GetCellText, OnGetCellTextOffsets

Add any extra horizontal space for the cell to use as a gap between text and the cell border. This can ensure that any drawing like images will not overlap with the text.

Get the minimum cell size to ensure the whole text is visible.

User's callback to write text of a cell. TDBTreeGridColumn::OnSetCellText has precedence from this callback.

An event called the the row is deleted (in its destructor). Te caller should not do anything with the row itself, except of a destroy of the user's data stored on the row.

An event called on change of TDBTreeGridRow::Expanded, for both expand and collapse calls.

__property TNotifyEvent DBTreeGrid::TDBTreeGrid::OnFillRows = {read=mOnFillRows, write=mOnFillRows}

An event called after the DataSet connect or open, to fill TreeGrid rows. If set, then the functions is responsible for proper fill of the TreeGrid. The callback can call FillRowsFlat, which is also called by default.

An event called after columns are filled, at the end of UpdateColumns.

An event called when drawing a column title or a row indicator.

See also:
DefaultDrawFixedCell

An event called when drawing a data cell. See DefaultDrawDataCell. If the column has set it's own TDBTreeGridColumn::OnDrawDataCell, then it is called instead of this callback.

Called when user clicks on a cell. If the click happened above a column title, or a row indicator, then the row and/or the column will be NULL.

Called when user double-clicks on a cell. If the double-click happened above a column title, or a row indicator, then the row and/or the column will be NULL.

Similar to OnCellClick, only called when user clicks on a cell which had focus already. Neither row, nor column, will be NULL.

Calculates height of the row. The passed-in height is a minimum height for the row. Any value below the minimum height is automatically changed to the minimum height. This event is called only if the Options does not contain tgHomogenousRows.

An event called before the cell edit, to check whether the cell is editable.

An event called before writing value from editor to the cell, to validate the input. If the editor has set its own TDBTreeGridCellEditor::OnCellValidate then there's called it, instead of this callback. Throw an exception on any error.

See also:
OnCellValidateError

An event called when OnCellValidate threw an exception. If not set, then the exception is propagated further.

An event called when the content of the DataSet changed in a way that requires rebuild/resync of the TreeGrid rows/content, like if the row count of the DataSet changes after insert or delete.

An event called whenever a sort information changes.

__property TNotifyEvent DBTreeGrid::TDBTreeGrid::OnRowsFilled = {read=mOnRowsFilled, write=mOnRowsFilled}

An event called when RefillRows is done.

An event called immediately after a change of FocusedRow. Note the DataSet may not be set on the correct row yet, due to ChangeDelay.

See also:
OnRowChanged

An event called after a change of FocusedRow, but, instead of OnRowChanging, the DataSet is set on the correct row. This event is influenced by ChangeDelay.

An event called when the row is added or removed from selection. Check the TDBTreeGridRow::State for rsSelected whether the row is selected or not.

An event called when TDBTreeGridColumn::Visible changes.

An event called when TDBTreeGridColumn::Index changes.

An event called when TDBTreeGridColumn::Width changes.

An event called when querying a tooltip for the cell. The useTooltip is a tooltip as calculated by the TreeGrid, which can the event change. In case the result is an empty string, then the tooltip is hidden. Both the row and the column can be NULL. Note this called only if Options contains tgShowCellTooltips.

An event called when value of the cell changed. This is called after OnCellValidate. If the cell has associated the DataSet field, then this is called only if the value changed, otherwise always.

An event called when rows layout changes (add, remove, sort, move of an existing row to a different place, and so on). It's not called on the TreeGrid destroy or when removing all rows.

See also:
OnRowDelete

An event called before a drag of the cell starts. If the Allow is set to false, then the drag operation will not start. This is called only if the DragMode is set to dmAutomatic.

An event called to find inclusion of HighlightText in a cellText. The ranges vector contains all the ranges for the text contain, as indexes into cellText; counts from 0. Any invalid ranges are ignored, overlapping ranges are merged. If not set, then default text position function is used.

An event called when user clicks on a URL defined either in NoDataSetText or in NoRowText. See these and TDBTreeGridUrlClickEvent for more information.


The documentation for this class was generated from the following file:

Generated on Fri Dec 27 12:21:46 2013 for TDBTreeGrid by  doxygen 1.5.6