NCBI C++ ToolKit
Public Types | Public Member Functions | Protected Types | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
CSplitter Class Reference

Search Toolkit Book for CSplitter

CSplitter - container with resizable separators. More...

#include <gui/widgets/wx/splitter.hpp>

+ Inheritance diagram for CSplitter:
+ Collaboration diagram for CSplitter:

Public Types

enum  ESplitType { eVertical , eHorizontal , eGrid }
 ESplitMode - splitter orientation. More...
 
typedef wxPanel TParent
 
typedef vector< intTPosVector
 
typedef vector< intTSizeVector
 

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=wxT("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. More...
 
virtual void Split (ESplitType type, const TPosVector &sizes)
 Creates a splitter with cells defined by "sizes". More...
 
virtual void Split (ESplitType type, const int ar_size[])
 Creates a splitter with cells defined by "sizes". More...
 
virtual void Split (ESplitType type, const TPosVector &widths, const TPosVector &heights)
 Creates splitter, "widths" and "height" define number and sizes of cells. More...
 
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. More...
 
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 More...
 
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. More...
 
void AddColumn ()
 
void AddRow ()
 
virtual void RemoveChild (wxWindowBase *child)
 overriding wxWindowBase function More...
 
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) const
 
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 More...
 
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 More...
 
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
 

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.

Member Typedef Documentation

◆ TCells

typedef vector<wxWindow*> CSplitter::TCells
protected

Definition at line 230 of file splitter.hpp.

◆ TParent

typedef wxPanel CSplitter::TParent

Definition at line 57 of file splitter.hpp.

◆ TPosVector

typedef vector<int> CSplitter::TPosVector

Definition at line 58 of file splitter.hpp.

◆ TSizeVector

typedef vector<int> CSplitter::TSizeVector

Definition at line 59 of file splitter.hpp.

Member Enumeration Documentation

◆ ESplitType

ESplitMode - splitter orientation.

Enumerator
eVertical 
eHorizontal 

vertical space is splitted

eGrid 

horizontal space is splitted

cells are separated with in both directions

Definition at line 62 of file splitter.hpp.

Constructor & Destructor Documentation

◆ CSplitter() [1/3]

CSplitter::CSplitter ( )

Definition at line 77 of file splitter.cpp.

◆ CSplitter() [2/3]

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

Definition at line 84 of file splitter.cpp.

References x_Init().

◆ CSplitter() [3/3]

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

Definition at line 92 of file splitter.cpp.

References x_Init().

◆ ~CSplitter()

CSplitter::~CSplitter ( )
virtual

Definition at line 130 of file splitter.cpp.

Member Function Documentation

◆ AddColumn()

void CSplitter::AddColumn ( )

◆ AddRow()

void CSplitter::AddRow ( void  )

◆ BlockLayout()

void CSplitter::BlockLayout ( bool  block = true)
virtual

◆ FindChild()

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

Definition at line 504 of file splitter.cpp.

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

Referenced by CDockSplitter::Cont_Replace().

◆ GetCell() [1/2]

wxWindow * CSplitter::GetCell ( int  col,
int  row 
)

Definition at line 657 of file splitter.cpp.

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

Referenced by x_ResizeToCell().

◆ GetCell() [2/2]

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

Definition at line 669 of file splitter.cpp.

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

◆ GetColumnsCount()

int CSplitter::GetColumnsCount ( void  ) const

◆ GetColumnWidth()

int CSplitter::GetColumnWidth ( int  col) const
inline

Definition at line 128 of file splitter.hpp.

References x_GetWidth().

◆ GetHeights()

void CSplitter::GetHeights ( TPosVector heights) const

◆ GetRowHeight()

int CSplitter::GetRowHeight ( int  row) const
inline

Definition at line 129 of file splitter.hpp.

References row, and x_GetHeight().

◆ GetRowsCount()

int CSplitter::GetRowsCount ( ) const

◆ GetSeparatorSize()

int CSplitter::GetSeparatorSize ( ) const

Definition at line 141 of file splitter.cpp.

References m_SepSize.

◆ GetSplitType()

CSplitter::ESplitType CSplitter::GetSplitType ( ) const

Definition at line 135 of file splitter.cpp.

References m_Type.

◆ GetWidths()

void CSplitter::GetWidths ( TPosVector widths) const

◆ InsertToCell()

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

◆ IsValidCell()

bool CSplitter::IsValidCell ( int  col,
int  row 
) const

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

Definition at line 367 of file splitter.cpp.

References int, m_vSplitPosX, and m_vSplitPosY.

Referenced by GetCell(), and x_GetCellIndex().

◆ Layout()

bool CSplitter::Layout ( void  )
virtual

Definition at line 590 of file splitter.cpp.

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

Referenced by BlockLayout(), and Show().

◆ OnContextMenu()

void CSplitter::OnContextMenu ( wxContextMenuEvent &  event)
protected

Definition at line 830 of file splitter.cpp.

◆ OnKeyDown()

void CSplitter::OnKeyDown ( wxKeyEvent &  event)
protected

Definition at line 902 of file splitter.cpp.

References x_EndDrag(), and x_IsDragging().

◆ OnLeftDown()

void CSplitter::OnLeftDown ( wxMouseEvent &  event)
protected

◆ OnLeftUp()

void CSplitter::OnLeftUp ( wxMouseEvent &  event)
protected

Definition at line 882 of file splitter.cpp.

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

◆ OnMouseEnter()

void CSplitter::OnMouseEnter ( wxMouseEvent &  event)
protected

Definition at line 891 of file splitter.cpp.

◆ OnMouseLeave()

void CSplitter::OnMouseLeave ( wxMouseEvent &  event)
protected

Definition at line 896 of file splitter.cpp.

◆ OnMouseMove()

void CSplitter::OnMouseMove ( wxMouseEvent &  event)
protected

◆ OnPaint()

void CSplitter::OnPaint ( wxPaintEvent &  event)
protected

◆ RemoveAll()

void CSplitter::RemoveAll ( )
virtual

Definition at line 491 of file splitter.cpp.

References i, m_Cells, NULL, and x_RequestUpdate().

◆ RemoveChild()

void CSplitter::RemoveChild ( wxWindowBase *  child)
virtual

overriding wxWindowBase function

Definition at line 427 of file splitter.cpp.

References _ASSERT, int, m_Cells, and x_RemoveChild().

◆ RemoveFromCell()

bool CSplitter::RemoveFromCell ( int  col,
int  row 
)
virtual

Definition at line 420 of file splitter.cpp.

References x_GetCellIndex(), and x_RemoveChild().

◆ SetHeights()

void CSplitter::SetHeights ( const TPosVector heights)

◆ SetResizableCell()

void CSplitter::SetResizableCell ( int  col,
int  row 
)

◆ SetWidths()

void CSplitter::SetWidths ( const TPosVector widths)

◆ Show()

bool CSplitter::Show ( bool  show = true)
virtual

Definition at line 612 of file splitter.cpp.

References Layout().

Referenced by COpenDlg::x_SetCurrentPanel().

◆ Split() [1/6]

void CSplitter::Split ( ESplitType  type)
virtual

◆ Split() [2/6]

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 173 of file splitter.cpp.

References _ASSERT, i, kMaxCells, and Split().

◆ Split() [3/6]

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 194 of file splitter.cpp.

References _ASSERT, i, kMaxCells, and x_Split().

◆ Split() [4/6]

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 155 of file splitter.cpp.

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

◆ Split() [5/6]

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 188 of file splitter.cpp.

References x_Split().

◆ Split() [6/6]

void CSplitter::Split ( int  col_n,
int  row_n 
)
virtual

Definition at line 217 of file splitter.cpp.

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

◆ x_CalculateMinSizes()

void CSplitter::x_CalculateMinSizes ( TPosVector min_widths,
TPosVector min_heights 
) const
protected

Definition at line 1206 of file splitter.cpp.

References GetColumnsCount(), GetRowsCount(), and row.

Referenced by x_Resize(), and x_StartDrag().

◆ x_Clear()

void CSplitter::x_Clear ( void  )
protected

Definition at line 767 of file splitter.cpp.

References i, m_Cells, m_vNormSizeX, m_vNormSizeY, m_vSplitPosX, m_vSplitPosY, and NULL.

Referenced by Split(), and x_Split().

◆ x_Deprecated()

void CSplitter::x_Deprecated ( ) const
inlineprotected

Definition at line 227 of file splitter.hpp.

References _ASSERT.

◆ x_DistributeEvenly()

void CSplitter::x_DistributeEvenly ( bool  b_x,
bool  b_y 
)
protected

◆ x_DoDistributeEvenly()

void CSplitter::x_DoDistributeEvenly ( TPosVector vSplitPos,
int  size 
)
protected

Definition at line 1116 of file splitter.cpp.

References i, int, m_SepSize, max(), n, and ncbi::grid::netcache::search::fields::size.

Referenced by x_DistributeEvenly().

◆ x_DoDragSeparator()

void CSplitter::x_DoDragSeparator ( wxMouseEvent &  event,
bool  b_final 
)
protectedvirtual

◆ x_DoResize()

void CSplitter::x_DoResize ( TPosVector sizes,
TSizeVector norm_sizes,
TPosVector min_sizes,
int  size,
int  new_size,
int  resizable_index 
)
protected

Definition at line 1172 of file splitter.cpp.

References _ASSERT, delta(), i, int, ncbi::grid::netcache::search::fields::size, x_GrowCell(), and x_ShrinkCell().

Referenced by x_Resize().

◆ x_DrawSeparator()

void CSplitter::x_DrawSeparator ( wxDC &  dc,
int  x,
int  y,
int  w,
int  h 
)
protectedvirtual

Reimplemented in CDockSplitter.

Definition at line 560 of file splitter.cpp.

References context, and info.

Referenced by OnPaint().

◆ x_EndDrag()

void CSplitter::x_EndDrag ( )
protectedvirtual

Definition at line 1030 of file splitter.cpp.

References m_iDragSepX, m_iDragSepY, and m_PrevFocus.

Referenced by OnKeyDown(), and OnLeftUp().

◆ x_GetBottom()

int CSplitter::x_GetBottom ( int  i_y) const
protected

Definition at line 749 of file splitter.cpp.

References _ASSERT, int, and m_vSplitPosY.

Referenced by OnPaint().

◆ x_GetCellIndex() [1/2]

int CSplitter::x_GetCellIndex ( int  i_x,
int  i_y 
) const
protected

Definition at line 681 of file splitter.cpp.

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

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

◆ x_GetCellIndex() [2/2]

int CSplitter::x_GetCellIndex ( wxWindow *  widget) const
protected

Definition at line 705 of file splitter.cpp.

References i, and m_Cells.

◆ x_GetColumn()

int CSplitter::x_GetColumn ( int  i_cell) const
protected

Definition at line 689 of file splitter.cpp.

References _ASSERT, int, m_Cells, and m_vSplitPosX.

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

◆ x_GetHeight()

int CSplitter::x_GetHeight ( int  i_y) const
protected

Definition at line 757 of file splitter.cpp.

References _ASSERT, int, m_SepSize, m_vSplitPosY, and next().

Referenced by GetRowHeight(), and x_ResizeToCell().

◆ x_GetLeft()

int CSplitter::x_GetLeft ( int  i_x) const
protected

Definition at line 716 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosX.

Referenced by OnPaint(), and x_ResizeToCell().

◆ x_GetMinimized()

void CSplitter::x_GetMinimized ( vector< bool > &  min_cols,
vector< bool > &  min_rows 
) const
protected

Definition at line 1231 of file splitter.cpp.

◆ x_GetRight()

int CSplitter::x_GetRight ( int  i_x) const
protected

Definition at line 724 of file splitter.cpp.

References _ASSERT, int, and m_vSplitPosX.

Referenced by OnPaint().

◆ x_GetRow()

int CSplitter::x_GetRow ( int  i_cell) const
protected

Definition at line 697 of file splitter.cpp.

References _ASSERT, int, m_Cells, and m_vSplitPosX.

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

◆ x_GetTop()

int CSplitter::x_GetTop ( int  i_y) const
protected

Definition at line 741 of file splitter.cpp.

References _ASSERT, m_SepSize, and m_vSplitPosY.

Referenced by OnPaint(), and x_ResizeToCell().

◆ x_GetWidth()

int CSplitter::x_GetWidth ( int  i_x) const
protected

Definition at line 732 of file splitter.cpp.

References _ASSERT, int, m_SepSize, m_vSplitPosX, and next().

Referenced by GetColumnWidth(), and x_ResizeToCell().

◆ x_GrowCell()

void CSplitter::x_GrowCell ( TPosVector sizes,
TPosVector norm_sizes,
int  index,
int delta,
bool  unlimited = false 
)
staticprotected

Definition at line 1154 of file splitter.cpp.

References delta(), and min().

Referenced by x_DoResize(), and x_MoveSeparator().

◆ x_HitTest()

void CSplitter::x_HitTest ( int  z,
TPosVector vpos,
int i_cell,
int i_sep 
)
protected

Definition at line 1071 of file splitter.cpp.

References i, int, m_SepSize, and n.

◆ x_HitTestSeparator()

int CSplitter::x_HitTestSeparator ( int  z,
TPosVector vpos 
)
protected

returns Separator index if hit or -1

Definition at line 1058 of file splitter.cpp.

References i, int, m_SepSize, and n.

Referenced by OnLeftDown(), and OnMouseMove().

◆ x_Init()

void CSplitter::x_Init ( void  )
protected

◆ x_IsDragging()

bool CSplitter::x_IsDragging ( ) const
protectedvirtual

Definition at line 1045 of file splitter.cpp.

References m_iDragSepX, and m_iDragSepY.

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

◆ x_MoveSeparator()

void CSplitter::x_MoveSeparator ( TPosVector sizes,
TSizeVector norm_sizes,
TPosVector min_sizes,
int  i_sep,
int  delta,
int  resizable_index 
)
protected

Definition at line 1268 of file splitter.cpp.

References delta(), i, int, x_GrowCell(), and x_ShrinkCell().

Referenced by x_DoDragSeparator().

◆ x_NewSplit()

void CSplitter::x_NewSplit ( TPosVector split_positions,
TSizeVector v_norm_size,
int  size 
)
protected

Definition at line 1367 of file splitter.cpp.

References i, int, m_SepSize, and ncbi::grid::netcache::search::fields::size.

◆ x_PreserveNormalSize()

void CSplitter::x_PreserveNormalSize ( bool  preserve)
virtual

Definition at line 1051 of file splitter.cpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

◆ x_RemoveChild()

bool CSplitter::x_RemoveChild ( int  index)
protected

Definition at line 451 of file splitter.cpp.

References i, m_Cells, NULL, and s_Contains().

Referenced by RemoveChild(), and RemoveFromCell().

◆ x_RequestUpdate()

void CSplitter::x_RequestUpdate ( )
protected

◆ x_Resize()

void CSplitter::x_Resize ( const wxSize &  old_size,
const wxSize &  new_size,
bool  b_size_changes 
)
protectedvirtual

◆ x_ResizeAllCells()

void CSplitter::x_ResizeAllCells ( )
protected

Definition at line 820 of file splitter.cpp.

References i, int, m_Cells, and x_ResizeToCell().

Referenced by SetHeights(), SetWidths(), and x_Resize().

◆ x_ResizeToCell() [1/2]

void CSplitter::x_ResizeToCell ( int  i_cell)
protected

Definition at line 794 of file splitter.cpp.

References x_GetColumn(), and x_GetRow().

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

◆ x_ResizeToCell() [2/2]

void CSplitter::x_ResizeToCell ( int  i_x,
int  i_y 
)
protected

Definition at line 802 of file splitter.cpp.

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

◆ x_ShrinkCell()

void CSplitter::x_ShrinkCell ( TPosVector sizes,
TPosVector min_sizes,
TPosVector norm_sizes,
int  index,
int delta 
)
staticprotected

Definition at line 1140 of file splitter.cpp.

References delta(), and max().

Referenced by x_DoResize(), and x_MoveSeparator().

◆ x_SizesToSplitPositions()

void CSplitter::x_SizesToSplitPositions ( const TPosVector sizes,
TPosVector split_positions 
)
protected

Definition at line 1415 of file splitter.cpp.

References i, and m_SepSize.

Referenced by x_DoDragSeparator(), and x_Resize().

◆ x_Split()

void CSplitter::x_Split ( ESplitType  type,
const TPosVector widths,
const TPosVector heights 
)
protected

◆ x_SplitPositionsToSizes()

void CSplitter::x_SplitPositionsToSizes ( const TPosVector split_positions,
int  total_size,
TPosVector sizes 
) const
protected

Definition at line 1397 of file splitter.cpp.

References i, m_SepSize, max(), min(), and total_size.

Referenced by GetHeights(), GetWidths(), x_DoDragSeparator(), and x_Resize().

◆ x_StartDrag()

void CSplitter::x_StartDrag ( int  i_sep_x,
int  i_sep_y 
)
protectedvirtual

◆ x_UpdateRegion()

void CSplitter::x_UpdateRegion ( int  start_x,
int  stop_x,
int  start_y,
int  stop_y 
)
protected

Definition at line 1347 of file splitter.cpp.

References int, m_vSplitPosX, m_vSplitPosY, x_RequestUpdate(), and x_ResizeToCell().

Referenced by x_DoDragSeparator().

Member Data Documentation

◆ m_BlockLayout

bool CSplitter::m_BlockLayout
protected

Definition at line 234 of file splitter.hpp.

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

◆ m_Cells

TCells CSplitter::m_Cells
protected

◆ m_HighlightCell

int CSplitter::m_HighlightCell
protected

Definition at line 261 of file splitter.hpp.

Referenced by x_Init().

◆ m_iDragSepX

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().

◆ m_iDragSepY

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().

◆ m_LayoutedSize

wxSize CSplitter::m_LayoutedSize
protected

Definition at line 235 of file splitter.hpp.

Referenced by Layout(), and x_Init().

◆ m_MaxSepPosX

int CSplitter::m_MaxSepPosX
protected

Definition at line 258 of file splitter.hpp.

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

◆ m_MaxSepPosY

int CSplitter::m_MaxSepPosY
protected

Definition at line 259 of file splitter.hpp.

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

◆ m_MinHeights

TPosVector CSplitter::m_MinHeights
protected

Definition at line 257 of file splitter.hpp.

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

◆ m_MinSepPosX

int CSplitter::m_MinSepPosX
protected

Definition at line 258 of file splitter.hpp.

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

◆ m_MinSepPosY

int CSplitter::m_MinSepPosY
protected

Definition at line 259 of file splitter.hpp.

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

◆ m_MinWidths

TPosVector CSplitter::m_MinWidths
protected

Definition at line 257 of file splitter.hpp.

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

◆ m_MouseDownX

int CSplitter::m_MouseDownX
protected

Definition at line 252 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

◆ m_MouseDownY

int CSplitter::m_MouseDownY
protected

Definition at line 252 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

◆ m_PrevFocus

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().

◆ m_PrevSepPos

wxPoint CSplitter::m_PrevSepPos
protected

Definition at line 255 of file splitter.hpp.

Referenced by OnLeftDown(), and x_DoDragSeparator().

◆ m_ResizableColumn

int CSplitter::m_ResizableColumn
protected

Definition at line 246 of file splitter.hpp.

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

◆ m_ResizableRow

int CSplitter::m_ResizableRow
protected

Definition at line 247 of file splitter.hpp.

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

◆ m_SepSize

int CSplitter::m_SepSize
protected

◆ m_SplitSize

wxSize CSplitter::m_SplitSize
protected

Definition at line 236 of file splitter.hpp.

Referenced by Layout(), SetHeights(), SetWidths(), x_Init(), and x_Split().

◆ m_StartPosX

int CSplitter::m_StartPosX
protected

Definition at line 253 of file splitter.hpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

◆ m_StartPosY

int CSplitter::m_StartPosY
protected

Definition at line 253 of file splitter.hpp.

Referenced by x_DoDragSeparator(), and x_StartDrag().

◆ m_Type

ESplitType CSplitter::m_Type
protected

Definition at line 232 of file splitter.hpp.

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

◆ m_vNormSizeX

TSizeVector CSplitter::m_vNormSizeX
protected

◆ m_vNormSizeY

TSizeVector CSplitter::m_vNormSizeY
protected

◆ m_vSplitPosX

TPosVector CSplitter::m_vSplitPosX
protected

◆ m_vSplitPosY

TPosVector CSplitter::m_vSplitPosY
protected

The documentation for this class was generated from the following files:
Modified on Fri Sep 20 14:57:12 2024 by modify_doxy.py rev. 669887