From e19f96049e01373e61f7e767011ae3b7f9d76910 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Mon, 5 Jun 2006 15:57:30 +0000 Subject: [PATCH] New methods for dragging coloumns git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39560 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/src/grid.i | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/wxPython/src/grid.i b/wxPython/src/grid.i index dfab9d1215..e2c63de53a 100644 --- a/wxPython/src/grid.i +++ b/wxPython/src/grid.i @@ -1746,7 +1746,7 @@ public: } int YToRow( int y ); - int XToCol( int x ); + int XToCol( int x, bool clipToMinMax = false ); int YToEdgeOfRow( int y ); int XToEdgeOfCol( int x ); @@ -1829,6 +1829,9 @@ public: void EnableDragColSize( bool enable = true ); void DisableDragColSize(); bool CanDragColSize(); + void EnableDragColMove( bool enable = true ); + void DisableDragColMove() { EnableDragColMove( false ); } + bool CanDragColMove() { return m_canDragColMove; } void EnableDragGridSize(bool enable = true); void DisableDragGridSize(); bool CanDragGridSize(); @@ -1894,6 +1897,10 @@ public: void SetColSize( int col, int width ); + int GetColAt( int colPos ) const; + void SetColPos( int colID, int newPos ); + int GetColPos( int colID ) const; + // automatically size the column or row to fit to its contents, if // setAsMin is True, this optimal width will also be set as minimal width // for this column