http://xoomer.virgilio.it/infinity77/wxPython/grid/wx.grid.html
The following example shows a simple implementation that utilizes wx.grid.Grid:
import wx
import wx.grid as gridlib
class SimpleGrid(gridlib.Grid):
def __init__(self, parent):
gridlib.Grid.__init__(self, parent, -1)
self.moveTo = None
self.Bind(wx.EVT_IDLE, self.OnIdle)
self.CreateGrid(25, 25)
# simple cell formatting
self.SetColSize(3, 200)
self.SetRowSize(4, 45)
self.SetCellValue(0, 0, "First cell")
self.SetCellValue(1, 1, "Another cell")
self.SetCellValue(2, 2, "Yet another cell")
self.SetCellValue(3, 3, "This cell is read-only")
self.SetCellFont(0, 0, wx.Font(12, wx.ROMAN, wx.ITALIC, wx.NORMAL))
self.SetCellTextColour(1, 1, wx.RED)
self.SetCellBackgroundColour(2, 2, wx.CYAN)
self.SetReadOnly(3, 3, True)
self.SetCellEditor(5, 0, gridlib.GridCellNumberEditor(1,1000))
self.SetCellValue(5, 0, "123")
self.SetCellEditor(6, 0, gridlib.GridCellFloatEditor())
self.SetCellValue(6, 0, "123.34")
self.SetCellEditor(7, 0, gridlib.GridCellNumberEditor())
self.SetCellValue(6, 3, "You can veto editing this cell")