//
// Created: 17-March-2000
// RCS-ID: $Id$
-// Copyright: (c) 1998 by Total Control Software
+// Copyright: (c) 2000 by Total Control Software
// Licence: wxWindows license
/////////////////////////////////////////////////////////////////////////////
if (m_myInst.findCallback(#CBNAME)) \
m_myInst.callCallback( \
Py_BuildValue("(Oii)", \
- wxPyConstructObject((void*)attr, "_wxGridCellAttr_p"), \
+ wxPyConstructObject((void*)attr, "wxGridCellAttr"), \
a, b)); \
else \
PCLASS::CBNAME(attr, a, b); \
if (m_myInst.findCallback(#CBNAME)) \
m_myInst.callCallback( \
Py_BuildValue("(Oi)", \
- wxPyConstructObject((void*)attr, "_wxGridCellAttr_p"), \
+ wxPyConstructObject((void*)attr, "wxGridCellAttr"), \
val)); \
else \
PCLASS::CBNAME(attr, val); \
{
public:
void SetParameters(const wxString& params);
+ void IncRef();
+ void DecRef();
virtual void Draw(wxGrid& grid,
wxGridCellAttr& attr,
void SetControl(wxControl* control);
void SetParameters(const wxString& params);
+ void IncRef();
+ void DecRef();
virtual void Create(wxWindow* parent,
wxWindowID id,
virtual void SetSize(const wxRect& rect);
virtual void Show(bool show, wxGridCellAttr *attr = NULL);
virtual void PaintBackground(const wxRect& rectCell, wxGridCellAttr *attr);
+ virtual bool IsAcceptedKey(wxKeyEvent& event);
virtual void StartingKey(wxKeyEvent& event);
virtual void StartingClick();
virtual void HandleReturn(wxKeyEvent& event);
if (m_myInst.findCallback("Show"))
m_myInst.callCallback(
Py_BuildValue("(iO)", show,
- wxPyConstructObject((void*)attr, "_wxGridCellAttr_p")));
+ wxPyConstructObject((void*)attr, "wxGridCellAttr")));
else
wxGridCellEditor::Show(show, attr);
wxPySaveThread(doSave);
if (m_myInst.findCallback("PaintBackground"))
m_myInst.callCallback(
Py_BuildValue("(OO)",
- wxPyConstructObject((void*)&rectCell, "_wxRect_p"),
- wxPyConstructObject((void*)attr, "_wxGridCellAttr_p")));
+ wxPyConstructObject((void*)&rectCell, "wxRect"),
+ wxPyConstructObject((void*)attr, "wxGridCellAttr")));
else
wxGridCellEditor::PaintBackground(rectCell, attr);
wxPySaveThread(doSave);
DEC_PYCALLBACK___pure(Reset);
DEC_PYCALLBACK__constany(SetSize, wxRect);
+ DEC_PYCALLBACK_bool_any(IsAcceptedKey, wxKeyEvent);
DEC_PYCALLBACK__any(StartingKey, wxKeyEvent);
DEC_PYCALLBACK__any(HandleReturn, wxKeyEvent);
DEC_PYCALLBACK__(StartingClick);
IMP_PYCALLBACK__STRING( wxPyGridCellEditor, wxGridCellEditor, SetParameters);
IMP_PYCALLBACK___pure(wxPyGridCellEditor, wxGridCellEditor, Reset);
IMP_PYCALLBACK__constany(wxPyGridCellEditor, wxGridCellEditor, SetSize, wxRect);
+IMP_PYCALLBACK_bool_any(wxPyGridCellEditor, wxGridCellEditor, IsAcceptedKey, wxKeyEvent);
IMP_PYCALLBACK__any(wxPyGridCellEditor, wxGridCellEditor, StartingKey, wxKeyEvent);
IMP_PYCALLBACK__any(wxPyGridCellEditor, wxGridCellEditor, HandleReturn, wxKeyEvent);
IMP_PYCALLBACK__(wxPyGridCellEditor, wxGridCellEditor, StartingClick);
int GetNumberCols();
+
+#ifdef NOTNEEDED // ????
// ------ display update functions
//
void CalcRowLabelsExposed( wxRegion& reg );
-
void CalcColLabelsExposed( wxRegion& reg );
void CalcCellsExposed( wxRegion& reg );
-
-#ifdef NOTNEEDED // ????
// ------ event handlers
//
void ProcessRowLabelMouseEvent( wxMouseEvent& event );
void GetTextBoxSize( wxDC& dc,
wxArrayString& lines,
- long *width, long *height );
+ long *OUTPUT, long *OUTPUT );
// ------
void SelectRow( int row, bool addToSelected = FALSE );
void SelectCol( int col, bool addToSelected = FALSE );
- void SelectBlock( int topRow, int leftCol, int bottomRow, int rightCol );
+ void SelectBlock( int topRow, int leftCol, int bottomRow, int rightCol,
+ bool addToSelected = FALSE );
// TODO: ??? void SelectBlock( const wxGridCellCoords& topLeft,
// TODO: ??? const wxGridCellCoords& bottomRight )
wxRect BlockToDeviceRect( const wxGridCellCoords & topLeft,
const wxGridCellCoords & bottomRight );
- // This function returns the rectangle that encloses the selected cells
- // in device coords and clipped to the client size of the grid window.
- //
- wxRect SelectionToDeviceRect();
// Access or update the selection fore/back colours
wxColour GetSelectionBackground() const;