CSplitter Class Reference

Search Toolkit Book for CSplitter

#include <splitter.hpp>

Inheritance diagram for CSplitter:

Inheritance graph
[legend]
List of all members.

Detailed Description

CSplitter - container with resizable separators.

CSplitter arranges child windows in to one- or two-dimensional array. Cells in CSplitter are divided by separators that can be moved by the mouse. Every cell in CSplitter can be occupied by a single child window and every window can occupy only one cell.

Definition at line 52 of file splitter.hpp.

Public Types

typedef wxPanel TParent
typedef vector< int > TPosVector
typedef vector< int > TSizeVector
enum  ESplitType { eVertical, eHorizontal, eGrid }
 ESplitMode - splitter orientation. More...

Public Member Functions

 CSplitter ()
 CSplitter (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name=_T("panel"))
 CSplitter (wxWindow *parent, wxWindowID id=wxID_ANY, ESplitType type=eVertical)
virtual ~CSplitter ()
ESplitType GetSplitType () const
int GetSeparatorSize () const
virtual void Split (ESplitType type)
 Creates a splitter with a single cell.
virtual void Split (ESplitType type, const TPosVector &sizes)
 Creates a splitter with cells defined by "sizes".
virtual void Split (ESplitType type, const int ar_size[])
 Creates a splitter with cells defined by "sizes".
virtual void Split (ESplitType type, const TPosVector &widths, const TPosVector &heights)
 Creates splitter, "widths" and "height" define number and sizes of cells.
virtual void Split (ESplitType type, const int ar_w[], const int ar_h[])
 Creates splitter, "ar_w" and "ar_h" are arrays terminated by -1.
virtual void Split (int col_n, int row_n)
int GetColumnsCount () const
int GetRowsCount () const
void GetWidths (TPosVector &widths) const
void SetWidths (const TPosVector &widths)
void GetHeights (TPosVector &heights) const
void SetHeights (const TPosVector &heights)
void SetResizableCell (int col, int row)
virtual bool Layout ()
virtual bool Show (bool show=true)
virtual void BlockLayout (bool block=true)
bool IsValidCell (int col, int row) const
 returns "true" if cell specified by (col, row) exists in the splitter
int GetColumnWidth (int col) const
int GetRowHeight (int row) const
bool InsertToCell (wxWindow *child, int col, int row)
 If cell [col, row] exists and vacant - adds widget to the container.
void AddColumn ()
void AddRow ()
virtual void RemoveChild (wxWindowBase *child)
 overriding wxWindowBase function
virtual bool RemoveFromCell (int col, int row)
virtual void RemoveAll ()
wxWindow * GetCell (int col, int row)
const wxWindow * GetCell (int col, int row) const
bool FindChild (const wxWindow *child, int &col, int &row) const
virtual void x_PreserveNormalSize (bool preserve)

Protected Types

typedef vector< wxWindow * > TCells

Protected Member Functions

virtual void x_DrawSeparator (wxDC &dc, int x, int y, int w, int h)
void x_SplitPositionsToSizes (const TPosVector &split_positions, int total_size, TPosVector &sizes)
void x_SizesToSplitPositions (const TPosVector &sizes, TPosVector &split_positions)
void x_Init ()
void x_Split (ESplitType type, const TPosVector &widths, const TPosVector &heights)
int x_GetCellIndex (int i_x, int i_y) const
int x_GetColumn (int i_cell) const
int x_GetRow (int i_cell) const
int x_GetCellIndex (wxWindow *widget) const
int x_GetLeft (int i_x) const
int x_GetRight (int i_x) const
int x_GetWidth (int i_x) const
int x_GetTop (int i_y) const
int x_GetBottom (int i_y) const
int x_GetHeight (int i_y) const
bool x_RemoveChild (int index)
void x_Clear ()
void x_ResizeToCell (int i_cell)
void x_ResizeToCell (int i_x, int i_y)
void x_ResizeAllCells ()
void OnPaint (wxPaintEvent &event)
void OnMouseMove (wxMouseEvent &event)
void OnLeftDown (wxMouseEvent &event)
void OnLeftUp (wxMouseEvent &event)
void OnMouseEnter (wxMouseEvent &event)
void OnMouseLeave (wxMouseEvent &event)
void OnContextMenu (wxContextMenuEvent &event)
void OnKeyDown (wxKeyEvent &event)
void x_RequestUpdate ()
int x_HitTestSeparator (int z, TPosVector &vpos)
 returns Separator index if hit or -1
void x_HitTest (int z, TPosVector &vpos, int &i_cell, int &i_sep)
virtual void x_StartDrag (int i_sep_x, int i_sep_y)
virtual void x_DoDragSeparator (wxMouseEvent &event, bool b_final)
virtual void x_EndDrag ()
virtual bool x_IsDragging () const
void x_DistributeEvenly (bool b_x, bool b_y)
void x_DoDistributeEvenly (TPosVector &vSplitPos, int size)
virtual void x_Resize (const wxSize &old_size, const wxSize &new_size, bool b_size_changes)
void x_DoResize (TPosVector &sizes, TSizeVector &norm_sizes, TPosVector &min_sizes, int size, int new_size, int resizable_index)
void x_MoveSeparator (TPosVector &sizes, TSizeVector &norm_sizes, TPosVector &min_sizes, int i_sep, int delta, int resizable_index)
void x_GetMinimized (vector< bool > &min_cols, vector< bool > &min_rows) const
void x_CalculateMinSizes (TPosVector &min_widths, TPosVector &min_heights) const
void x_UpdateRegion (int start_x, int stop_x, int start_y, int stop_y)
void x_NewSplit (TPosVector &split_positions, TSizeVector &v_norm_size, int size)
void x_Deprecated () const

Static Protected Member Functions

static void x_ShrinkCell (TPosVector &sizes, TPosVector &min_sizes, TPosVector &norm_sizes, int index, int &delta)
static void x_GrowCell (TPosVector &sizes, TPosVector &norm_sizes, int index, int &delta, bool unlimited=false)

Protected Attributes

ESplitType m_Type
bool m_BlockLayout
wxSize m_LayoutedSize
wxSize m_SplitSize
TPosVector m_vSplitPosX
TPosVector m_vSplitPosY
int m_SepSize
TSizeVector m_vNormSizeX
TSizeVector m_vNormSizeY
TCells m_Cells
int m_ResizableColumn
int m_ResizableRow
wxWindow * m_PrevFocus
 members used for event handling
int m_MouseDownX
int m_MouseDownY
int m_StartPosX
int m_StartPosY
int m_iDragSepX
int m_iDragSepY
wxPoint m_PrevSepPos
TPosVector m_MinWidths
TPosVector m_MinHeights
int m_MinSepPosX
int m_MaxSepPosX
int m_MinSepPosY
int m_MaxSepPosY
int m_HighlightCell


Member Typedef Documentation

typedef vector<wxWindow*> CSplitter::TCells [protected]
 

Definition at line 230 of file splitter.hpp.

typedef wxPanel CSplitter::TParent
 

Definition at line 57 of file splitter.hpp.

typedef vector<int> CSplitter::TPosVector
 

Definition at line 58 of file splitter.hpp.

typedef vector<int> CSplitter::TSizeVector
 

Definition at line 59 of file splitter.hpp.


Member Enumeration Documentation

enum CSplitter::ESplitType
 

ESplitMode - splitter orientation.

Enumerator:
eVertical 
eHorizontal  vertical space is splitted
eGrid  cells are separated with in both directions

Definition at line 62 of file splitter.hpp.


Constructor & Destructor Documentation

CSplitter::CSplitter  ) 
 

Definition at line 78 of file splitter.cpp.

CSplitter::CSplitter wxWindow *  parent,
wxWindowID  id = wxID_ANY,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxDefaultSize,
long  style = wxTAB_TRAVERSAL,
const wxString &  name = _T("panel")
 

Definition at line 85 of file splitter.cpp.

References x_Init().

CSplitter::CSplitter wxWindow *  parent,
wxWindowID  id = wxID_ANY,
ESplitType  type = eVertical
 

Definition at line 93 of file splitter.cpp.

References x_Init().

CSplitter::~CSplitter  )  [virtual]
 

Definition at line 131 of file splitter.cpp.


Member Function Documentation

void CSplitter::AddColumn  ) 
 

Definition at line 434 of file splitter.cpp.

References _ASSERT, eVertical, GetColumnsCount(), GetRowsCount(), m_Cells, m_Type, m_vNormSizeX, and m_vSplitPosX.

Referenced by CDockSplitter::Cont_Add().

void CSplitter::AddRow  ) 
 

Definition at line 422 of file splitter.cpp.

References _ASSERT, eHorizontal, GetColumnsCount(), GetRowsCount(), m_Cells, m_Type, m_vNormSizeY, and m_vSplitPosY.

Referenced by CDockSplitter::Cont_Add().

void CSplitter::BlockLayout bool  block = true  )  [virtual]
 

Definition at line 648 of file splitter.cpp.

References Layout(), and m_BlockLayout.

Referenced by CDockContainer::x_CreateContainerWindow().

bool CSplitter::FindChild const wxWindow *  child,
int &  col,
int &  row
const
 

Definition at line 531 of file splitter.cpp.

References m_Cells, x_GetColumn(), and x_GetRow().

Referenced by CDockSplitter::Cont_Replace().

const wxWindow * CSplitter::GetCell int  col,
int  row
const
 

Definition at line 696 of file splitter.cpp.

References _ASSERT, IsValidCell(), m_Cells, and x_GetCellIndex().

wxWindow * CSplitter::GetCell int  col,
int  row
 

Definition at line 684 of file splitter.cpp.

References _ASSERT, IsValidCell(), m_Cells, and x_GetCellIndex().

Referenced by x_ResizeToCell().

int CSplitter::GetColumnsCount  )  const
 

Definition at line 280 of file splitter.cpp.

References m_vSplitPosX.

Referenced by AddColumn(), AddRow(), CDockSplitter::Cont_Add(), InsertToCell(), OnPaint(), SetResizableCell(), x_CalculateMinSizes(), x_DoDragSeparator(), x_GetCellIndex(), and x_StartDrag().

int CSplitter::GetColumnWidth int  col  )  const [inline]
 

Definition at line 128 of file splitter.hpp.

References x_GetWidth().

void CSplitter::GetHeights TPosVector heights  )  const
 

Definition at line 349 of file splitter.cpp.

References ITERATE, m_SepSize, m_vSplitPosY, pos, and size.

Referenced by FSaveSplitterLayout::operator()(), and CItemSelectionPanel::SaveSettings().

int CSplitter::GetRowHeight int  row  )  const [inline]
 

Definition at line 129 of file splitter.hpp.

References x_GetHeight().

int CSplitter::GetRowsCount  )  const
 

Definition at line 286 of file splitter.cpp.

References m_vSplitPosY.

Referenced by AddColumn(), AddRow(), CDockSplitter::Cont_Add(), InsertToCell(), OnPaint(), SetResizableCell(), x_CalculateMinSizes(), x_DoDragSeparator(), and x_StartDrag().

int CSplitter::GetSeparatorSize  )  const
 

Definition at line 142 of file splitter.cpp.

References m_SepSize.

CSplitter::ESplitType CSplitter::GetSplitType  )  const
 

Definition at line 136 of file splitter.cpp.

References m_Type.

Referenced by CDockSplitter::Cont_Add().

void CSplitter::GetWidths TPosVector widths  )  const
 

Definition at line 292 of file splitter.cpp.

References ITERATE, m_SepSize, m_vSplitPosX, pos, and size.

Referenced by FSaveSplitterLayout::operator()(), and COpenDlg::SaveSettings().

bool CSplitter::InsertToCell wxWindow *  child,
int  col,
int  row
 

If cell [col, row] exists and vacant - adds widget to the container.

Returns "true" if widget has been added.

Definition at line 393 of file splitter.cpp.

References GetColumnsCount(), GetRowsCount(), m_Cells, x_GetCellIndex(), and x_ResizeToCell().

Referenced by CDockSplitter::Cont_Add(), CDockSplitter::Cont_Replace(), CItemSelectionPanel::CreateControls(), and COpenDlg::CreateControls().

bool CSplitter::IsValidCell int  col,
int  row
const
 

returns "true" if cell specified by (col, row) exists in the splitter

Definition at line 386 of file splitter.cpp.

References m_vSplitPosX, and m_vSplitPosY.

Referenced by GetCell(), and x_GetCellIndex().

bool CSplitter::Layout  )  [virtual]
 

Definition at line 617 of file splitter.cpp.

References eGrid, eHorizontal, eVertical, m_BlockLayout, m_LayoutedSize, m_SplitSize, m_Type, and x_Resize().

Referenced by BlockLayout(), and Show().

void CSplitter::OnContextMenu wxContextMenuEvent &  event  )  [protected]
 

Definition at line 857 of file splitter.cpp.

void CSplitter::OnKeyDown wxKeyEvent &  event  )  [protected]
 

Definition at line 929 of file splitter.cpp.

References x_EndDrag(), and x_IsDragging().

void CSplitter::OnLeftDown wxMouseEvent &  event  )  [protected]
 

Definition at line 862 of file splitter.cpp.

References m_MouseDownX, m_MouseDownY, m_PrevSepPos, m_vSplitPosX, m_vSplitPosY, x_DistributeEvenly(), x_HitTestSeparator(), and x_StartDrag().

void CSplitter::OnLeftUp wxMouseEvent &  event  )  [protected]
 

Definition at line 909 of file splitter.cpp.

References x_DoDragSeparator(), x_EndDrag(), and x_IsDragging().

void CSplitter::OnMouseEnter wxMouseEvent &  event  )  [protected]
 

void CSplitter::OnMouseLeave wxMouseEvent &  event  )  [protected]
 

void CSplitter::OnMouseMove wxMouseEvent &  event  )  [protected]
 

Definition at line 887 of file splitter.cpp.

References x_DoDragSeparator(), and x_IsDragging().

void CSplitter::OnPaint wxPaintEvent &  event  )  [protected]
 

Definition at line 548 of file splitter.cpp.

References GetColumnsCount(), GetRowsCount(), m_SepSize, x_DrawSeparator(), x_GetBottom(), x_GetLeft(), x_GetRight(), and x_GetTop().

void CSplitter::RemoveAll  )  [virtual]
 

Definition at line 518 of file splitter.cpp.

References m_Cells.

void CSplitter::RemoveChild wxWindowBase *  child  )  [virtual]
 

overriding wxWindowBase function

Definition at line 454 of file splitter.cpp.

References m_Cells, and x_RemoveChild().

bool CSplitter::RemoveFromCell int  col,
int  row
[virtual]
 

Definition at line 447 of file splitter.cpp.

References x_GetCellIndex(), and x_RemoveChild().

void CSplitter::SetHeights const TPosVector heights  ) 
 

Definition at line 363 of file splitter.cpp.

References m_SepSize, m_vSplitPosY, and pos.

Referenced by CItemSelectionPanel::LoadSettings().

void CSplitter::SetResizableCell int  col,
int  row
 

Definition at line 332 of file splitter.cpp.

References _ASSERT, GetColumnsCount(), GetRowsCount(), m_ResizableColumn, and m_ResizableRow.

Referenced by CDockSplitter::Cont_Add(), and CItemSelectionPanel::CreateControls().

void CSplitter::SetWidths const TPosVector widths  ) 
 

Definition at line 308 of file splitter.cpp.

References m_SepSize, m_vSplitPosX, and pos.

Referenced by COpenDlg::LoadSettings().

bool CSplitter::Show bool  show = true  )  [virtual]
 

Definition at line 639 of file splitter.cpp.

References Layout().

void CSplitter::Split int  col_n,
int  row_n
[virtual]
 

Definition at line 218 of file splitter.cpp.

References eGrid, eHorizontal, eVertical, m_Type, x_DistributeEvenly(), and x_Split().

void CSplitter::Split ESplitType  type,
const int  ar_w[],
const int  ar_h[]
[virtual]
 

Creates splitter, "ar_w" and "ar_h" are arrays terminated by -1.

Definition at line 195 of file splitter.cpp.

References kMaxCells.

void CSplitter::Split ESplitType  type,
const TPosVector widths,
const TPosVector heights
[virtual]
 

Creates splitter, "widths" and "height" define number and sizes of cells.

Definition at line 189 of file splitter.cpp.

References x_Split().

void CSplitter::Split ESplitType  type,
const int  ar_size[]
[virtual]
 

Creates a splitter with cells defined by "sizes".

If mode == eGrid then ar_sizes will be used as both width and heights. "ar_sizes" is -1 terminated array.

Definition at line 174 of file splitter.cpp.

References kMaxCells.

void CSplitter::Split ESplitType  type,
const TPosVector sizes
[virtual]
 

Creates a splitter with cells defined by "sizes".

If mode == eGrid then size will be used as both width and heights

Definition at line 156 of file splitter.cpp.

References eGrid, eHorizontal, eVertical, x_Clear(), and x_Split().

void CSplitter::Split ESplitType  type  )  [virtual]
 

Creates a splitter with a single cell.

Definition at line 148 of file splitter.cpp.

References m_Type, and x_Clear().

Referenced by CDockSplitter::Cont_Add(), CItemSelectionPanel::CreateControls(), and COpenDlg::CreateControls().

void CSplitter::x_CalculateMinSizes TPosVector min_widths,
TPosVector min_heights
const [protected]
 

Definition at line 1233 of file splitter.cpp.

References GetColumnsCount(), and GetRowsCount().

Referenced by x_Resize(), and x_StartDrag().

void CSplitter::x_Clear  )  [protected]
 

Definition at line 794 of file splitter.cpp.

Referenced by Split(), and x_Split().

void CSplitter::x_Deprecated  )  const [inline, protected]
 

Definition at line 227 of file splitter.hpp.

References _ASSERT.

void CSplitter::x_DistributeEvenly bool  b_x,
bool  b_y
[protected]
 

Definition at line 1117 of file splitter.cpp.

References m_Cells, m_vNormSizeX, m_vNormSizeY, m_vSplitPosX, m_vSplitPosY, x_DoDistributeEvenly(), x_GetColumn(), x_GetRow(), x_RequestUpdate(), and x_ResizeToCell().

Referenced by OnLeftDown(), and Split().

void CSplitter::x_DoDistributeEvenly TPosVector vSplitPos,
int  size
[protected]
 

Definition at line 1143 of file splitter.cpp.

References m_SepSize, and pos.

Referenced by x_DistributeEvenly().

void CSplitter::x_DoDragSeparator wxMouseEvent &  event,
bool  b_final
[protected, virtual]
 

Definition at line 996 of file splitter.cpp.

References GetColumnsCount(), GetRowsCount(), m_iDragSepX, m_iDragSepY, m_MaxSepPosX, m_MaxSepPosY, m_MinHeights, m_MinSepPosX, m_MinSepPosY, m_MinWidths, m_MouseDownX, m_MouseDownY, m_PrevSepPos, m_ResizableColumn, m_ResizableRow, m_StartPosX, m_StartPosY, m_vNormSizeX, m_vNormSizeY, m_vSplitPosX, m_vSplitPosY, size, x_MoveSeparator(), x_PreserveNormalSize(), x_SizesToSplitPositions(), x_SplitPositionsToSizes(), and x_UpdateRegion().

Referenced by OnLeftUp(), and OnMouseMove().

void CSplitter::x_DoResize TPosVector sizes,
TSizeVector norm_sizes,
TPosVector min_sizes,
int  size,
int  new_size,
int  resizable_index
[protected]
 

Definition at line 1199 of file splitter.cpp.

References _ASSERT, and x_ShrinkCell().

Referenced by x_Resize().

void CSplitter::x_DrawSeparator wxDC &  dc,
int  x,
int  y,
int  w,
int  h
[protected, virtual]
 

Reimplemented in CDockSplitter.

Definition at line 587 of file splitter.cpp.

Referenced by OnPaint().

void CSplitter::x_EndDrag  )  [protected, virtual]
 

Definition at line 1057 of file splitter.cpp.

References m_iDragSepX, m_iDragSepY, and m_PrevFocus.

Referenced by OnKeyDown(), and OnLeftUp().

int CSplitter::x_GetBottom int  i_y  )  const [protected]
 

Definition at line 776 of file splitter.cpp.

References _ASSERT, and m_vSplitPosY.

Referenced by OnPaint().

int CSplitter::x_GetCellIndex wxWindow *  widget  )  const [protected]
 

Definition at line 732 of file splitter.cpp.

References m_Cells.

int CSplitter::x_GetCellIndex int  i_x,
int  i_y
const [protected]
 

Definition at line 708 of file splitter.cpp.

References _ASSERT, GetColumnsCount(), and IsValidCell().

Referenced by GetCell(), InsertToCell(), and RemoveFromCell().

int CSplitter::x_GetColumn int  i_cell  )  const [protected]
 

Definition at line 716 of file splitter.cpp.

References _ASSERT, m_Cells, and m_vSplitPosX.

Referenced by FindChild(), x_DistributeEvenly(), and x_ResizeToCell().

int CSplitter::x_GetHeight int  i_y  )  const [protected]
 

Definition at line 784 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosY.

Referenced by GetRowHeight(), and x_ResizeToCell().

int CSplitter::x_GetLeft int  i_x  )  const [protected]
 

Definition at line 743 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosX.

Referenced by OnPaint(), and x_ResizeToCell().

void CSplitter::x_GetMinimized vector< bool > &  min_cols,
vector< bool > &  min_rows
const [protected]
 

Definition at line 1258 of file splitter.cpp.

int CSplitter::x_GetRight int  i_x  )  const [protected]
 

Definition at line 751 of file splitter.cpp.

References _ASSERT, and m_vSplitPosX.

Referenced by OnPaint().

int CSplitter::x_GetRow int  i_cell  )  const [protected]
 

Definition at line 724 of file splitter.cpp.

References _ASSERT, m_Cells, and m_vSplitPosX.

Referenced by FindChild(), x_DistributeEvenly(), and x_ResizeToCell().

int CSplitter::x_GetTop int  i_y  )  const [protected]
 

Definition at line 768 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosY.

Referenced by OnPaint(), and x_ResizeToCell().

int CSplitter::x_GetWidth int  i_x  )  const [protected]
 

Definition at line 759 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosX.

Referenced by GetColumnWidth(), and x_ResizeToCell().

void CSplitter::x_GrowCell TPosVector sizes,
TPosVector norm_sizes,
int  index,
int &  delta,
bool  unlimited = false
[static, protected]
 

Definition at line 1181 of file splitter.cpp.

Referenced by x_MoveSeparator().

void CSplitter::x_HitTest int  z,
TPosVector vpos,
int &  i_cell,
int &  i_sep
[protected]
 

Definition at line 1098 of file splitter.cpp.

References pos.

int CSplitter::x_HitTestSeparator int  z,
TPosVector vpos
[protected]
 

returns Separator index if hit or -1

Definition at line 1085 of file splitter.cpp.

References m_SepSize, and pos.

Referenced by OnLeftDown().

void CSplitter::x_Init  )  [protected]
 

Definition at line 101 of file splitter.cpp.

References kDefSepSize, m_BlockLayout, m_Cells, m_HighlightCell, m_iDragSepX, m_iDragSepY, m_LayoutedSize, m_MaxSepPosX, m_MaxSepPosY, m_MinSepPosX, m_MinSepPosY, m_PrevFocus, m_ResizableColumn, m_ResizableRow, m_SepSize, m_SplitSize, m_vNormSizeX, and m_vNormSizeY.

Referenced by CSplitter().

bool CSplitter::x_IsDragging  )  const [protected, virtual]
 

Definition at line 1072 of file splitter.cpp.

References m_iDragSepX, and m_iDragSepY.

Referenced by OnKeyDown(), OnLeftUp(), and OnMouseMove().

void CSplitter::x_MoveSeparator TPosVector sizes,
TSizeVector norm_sizes,
TPosVector min_sizes,
int  i_sep,
int  delta,
int  resizable_index
[protected]
 

Definition at line 1295 of file splitter.cpp.

References x_GrowCell(), and x_ShrinkCell().

Referenced by x_DoDragSeparator().

void CSplitter::x_NewSplit TPosVector split_positions,
TSizeVector v_norm_size,
int  size
[protected]
 

Definition at line 1394 of file splitter.cpp.

References m_SepSize.

void CSplitter::x_PreserveNormalSize bool  preserve  )  [virtual]
 

Definition at line 1078 of file splitter.cpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

bool CSplitter::x_RemoveChild int  index  )  [protected]
 

Definition at line 478 of file splitter.cpp.

References m_Cells, and s_Contains().

Referenced by RemoveChild(), and RemoveFromCell().

void CSplitter::x_RequestUpdate  )  [protected]
 

Definition at line 939 of file splitter.cpp.

Referenced by x_DistributeEvenly(), and x_Resize().

void CSplitter::x_Resize const wxSize &  old_size,
const wxSize &  new_size,
bool  b_size_changes
[protected, virtual]
 

Definition at line 660 of file splitter.cpp.

References m_MinHeights, m_MinWidths, m_ResizableColumn, m_ResizableRow, m_vNormSizeX, m_vNormSizeY, m_vSplitPosX, m_vSplitPosY, x_CalculateMinSizes(), x_DoResize(), x_RequestUpdate(), x_ResizeAllCells(), x_SizesToSplitPositions(), and x_SplitPositionsToSizes().

Referenced by Layout().

void CSplitter::x_ResizeAllCells  )  [protected]
 

Definition at line 847 of file splitter.cpp.

References m_Cells, and x_ResizeToCell().

Referenced by x_Resize().

void CSplitter::x_ResizeToCell int  i_x,
int  i_y
[protected]
 

Definition at line 829 of file splitter.cpp.

References _ASSERT, GetCell(), x_GetHeight(), x_GetLeft(), x_GetTop(), and x_GetWidth().

void CSplitter::x_ResizeToCell int  i_cell  )  [protected]
 

Definition at line 821 of file splitter.cpp.

References x_GetColumn(), and x_GetRow().

Referenced by InsertToCell(), x_DistributeEvenly(), x_ResizeAllCells(), and x_UpdateRegion().

void CSplitter::x_ShrinkCell TPosVector sizes,
TPosVector min_sizes,
TPosVector norm_sizes,
int  index,
int &  delta
[static, protected]
 

Definition at line 1167 of file splitter.cpp.

Referenced by x_DoResize(), and x_MoveSeparator().

void CSplitter::x_SizesToSplitPositions const TPosVector sizes,
TPosVector split_positions
[protected]
 

Definition at line 1441 of file splitter.cpp.

References m_SepSize.

Referenced by x_DoDragSeparator(), and x_Resize().

void CSplitter::x_Split ESplitType  type,
const TPosVector widths,
const TPosVector heights
[protected]
 

Definition at line 244 of file splitter.cpp.

References _ASSERT, kMaxCells, m_SepSize, m_Type, m_vSplitPosX, pos, and x_Clear().

Referenced by Split().

void CSplitter::x_SplitPositionsToSizes const TPosVector split_positions,
int  total_size,
TPosVector sizes
[protected]
 

Definition at line 1424 of file splitter.cpp.

References m_SepSize.

Referenced by x_DoDragSeparator(), and x_Resize().

void CSplitter::x_StartDrag int  i_sep_x,
int  i_sep_y
[protected, virtual]
 

Definition at line 957 of file splitter.cpp.

References ElementsSum(), GetColumnsCount(), GetRowsCount(), m_iDragSepX, m_iDragSepY, m_MaxSepPosX, m_MaxSepPosY, m_MinHeights, m_MinSepPosX, m_MinSepPosY, m_MinWidths, m_PrevFocus, m_SepSize, m_StartPosX, m_StartPosY, m_vSplitPosX, m_vSplitPosY, x_CalculateMinSizes(), and x_PreserveNormalSize().

Referenced by OnLeftDown().

void CSplitter::x_UpdateRegion int  start_x,
int  stop_x,
int  start_y,
int  stop_y
[protected]
 

Definition at line 1374 of file splitter.cpp.

References m_vSplitPosX, m_vSplitPosY, and x_ResizeToCell().

Referenced by x_DoDragSeparator().


Member Data Documentation

bool CSplitter::m_BlockLayout [protected]
 

Definition at line 234 of file splitter.hpp.

Referenced by BlockLayout(), Layout(), and x_Init().

TCells CSplitter::m_Cells [protected]
 

Definition at line 244 of file splitter.hpp.

Referenced by AddColumn(), AddRow(), FindChild(), GetCell(), InsertToCell(), RemoveAll(), RemoveChild(), x_DistributeEvenly(), x_GetCellIndex(), x_GetColumn(), x_GetRow(), x_Init(), x_RemoveChild(), and x_ResizeAllCells().

int CSplitter::m_HighlightCell [protected]
 

Definition at line 261 of file splitter.hpp.

Referenced by x_Init().

int CSplitter::m_iDragSepX [protected]
 

Definition at line 254 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_EndDrag(), x_Init(), x_IsDragging(), and x_StartDrag().

int CSplitter::m_iDragSepY [protected]
 

Definition at line 254 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_EndDrag(), x_Init(), x_IsDragging(), and x_StartDrag().

wxSize CSplitter::m_LayoutedSize [protected]
 

Definition at line 235 of file splitter.hpp.

Referenced by Layout(), and x_Init().

int CSplitter::m_MaxSepPosX [protected]
 

Definition at line 258 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Init(), and x_StartDrag().

int CSplitter::m_MaxSepPosY [protected]
 

Definition at line 259 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Init(), and x_StartDrag().

TPosVector CSplitter::m_MinHeights [protected]
 

Definition at line 257 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Resize(), and x_StartDrag().

int CSplitter::m_MinSepPosX [protected]
 

Definition at line 258 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Init(), and x_StartDrag().

int CSplitter::m_MinSepPosY [protected]
 

Definition at line 259 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Init(), and x_StartDrag().

TPosVector CSplitter::m_MinWidths [protected]
 

Definition at line 257 of file splitter.hpp.

Referenced by x_DoDragSeparator(), x_Resize(), and x_StartDrag().

int CSplitter::m_MouseDownX [protected]
 

Definition at line 252 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

int CSplitter::m_MouseDownY [protected]
 

Definition at line 252 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

wxWindow* CSplitter::m_PrevFocus [protected]
 

members used for event handling

Definition at line 250 of file splitter.hpp.

Referenced by x_EndDrag(), x_Init(), and x_StartDrag().

wxPoint CSplitter::m_PrevSepPos [protected]
 

Definition at line 255 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

int CSplitter::m_ResizableColumn [protected]
 

Definition at line 246 of file splitter.hpp.

Referenced by SetResizableCell(), x_DoDragSeparator(), x_Init(), and x_Resize().

int CSplitter::m_ResizableRow [protected]
 

Definition at line 247 of file splitter.hpp.

Referenced by SetResizableCell(), x_DoDragSeparator(), x_Init(), and x_Resize().

int CSplitter::m_SepSize [protected]
 

Definition at line 240 of file splitter.hpp.

Referenced by CDockSplitter::CDockSplitter(), GetHeights(), GetSeparatorSize(), GetWidths(), OnPaint(), SetHeights(), SetWidths(), x_DoDistributeEvenly(), x_GetHeight(), x_GetLeft(), x_GetTop(), x_GetWidth(), x_HitTestSeparator(), x_Init(), x_NewSplit(), x_SizesToSplitPositions(), x_Split(), x_SplitPositionsToSizes(), and x_StartDrag().

wxSize CSplitter::m_SplitSize [protected]
 

Definition at line 236 of file splitter.hpp.

Referenced by Layout(), and x_Init().

int CSplitter::m_StartPosX [protected]
 

Definition at line 253 of file splitter.hpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

int CSplitter::m_StartPosY [protected]
 

Definition at line 253 of file splitter.hpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

ESplitType CSplitter::m_Type [protected]
 

Definition at line 232 of file splitter.hpp.

Referenced by AddColumn(), AddRow(), GetSplitType(), Layout(), Split(), and x_Split().

TSizeVector CSplitter::m_vNormSizeX [protected]
 

Definition at line 241 of file splitter.hpp.

Referenced by AddColumn(), x_DistributeEvenly(), x_DoDragSeparator(), x_Init(), and x_Resize().

TSizeVector CSplitter::m_vNormSizeY [protected]
 

Definition at line 242 of file splitter.hpp.

Referenced by AddRow(), x_DistributeEvenly(), x_DoDragSeparator(), x_Init(), and x_Resize().

TPosVector CSplitter::m_vSplitPosX [protected]
 

Definition at line 238 of file splitter.hpp.

Referenced by AddColumn(), GetColumnsCount(), GetWidths(), IsValidCell(), OnLeftDown(), SetWidths(), x_DistributeEvenly(), x_DoDragSeparator(), x_GetColumn(), x_GetLeft(), x_GetRight(), x_GetRow(), x_GetWidth(), x_Resize(), x_Split(), x_StartDrag(), and x_UpdateRegion().

TPosVector CSplitter::m_vSplitPosY [protected]
 

Definition at line 239 of file splitter.hpp.

Referenced by AddRow(), GetHeights(), GetRowsCount(), IsValidCell(), OnLeftDown(), SetHeights(), x_DistributeEvenly(), x_DoDragSeparator(), x_GetBottom(), x_GetHeight(), x_GetTop(), x_Resize(), x_StartDrag(), and x_UpdateRegion().


The documentation for this class was generated from the following files:
Generated on Mon Dec 7 14:41:27 2009 for NCBI C++ ToolKit by  doxygen 1.4.6
Modified on Mon Dec 07 16:24:09 2009 by modify_doxy.py rev. 173732