]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/grid.tex
Added config values (commented out) for generating the MS HTML Help
[wxWidgets.git] / docs / latex / wx / grid.tex
CommitLineData
a660d684
KB
1\section{\class{wxGrid}}\label{wxgrid}
2
3wxGrid is a class for displaying and editing tabular information.
4
5\wxheading{Derived from}
6
7\helpref{wxPanel}{wxpanel}\\
8\helpref{wxWindow}{wxwindow}\\
9\helpref{wxEvtHandler}{wxevthandler}\\
10\helpref{wxObject}{wxobject}
11
954b8ae6
JS
12\wxheading{Include files}
13
14<wx/grid.h>
15
a660d684
KB
16\wxheading{Window styles}
17
18There are no specific window styles for this class.
19
20See also \helpref{window styles overview}{windowstyles}.
21
22\wxheading{See also}
23
24\helpref{wxGrid classes overview}{gridoverview}
25
26\latexignore{\rtfignore{\wxheading{Members}}}
27
28\membersection{wxGrid::wxGrid}\label{wxgridconstr}
29
eaaa6a06
JS
30\func{void}{wxGrid}{\param{wxWindow* }{parent}, \param{wxWindowID}{ id}, \param{const wxPoint\&}{ pos},
31\rtfsp\param{const wxSize\&}{ size}, \param{long}{ style=0}, \param{const wxString\& }{name="grid"}}
a660d684
KB
32
33Constructor. Before using a wxGrid object, you must call CreateGrid to set up the required rows and columns.
34
35\membersection{wxGrid::AdjustScrollbars}\label{wxgridadjustscrollbars}
36
37\func{void}{AdjustScrollbars}{\void}
38
39Call this function whenever a change has been made via the API that might alter the scrollbar characteristics:
40particularly when adding or deleting rows, or changing row or column dimensions. For example,
41removing rows might make it unnecessary to show the vertical scrollbar.
42
43\membersection{wxGrid::AppendCols}\label{wxgridappendcols}
44
45\func{bool}{AppendCols}{\param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
46
47Appends {\it n} columns to the grid. If {\it updateLabels} is TRUE,
48the function OnChangeLabels is called to give the application the opportunity to relabel.
49
50\membersection{wxGrid::AppendRows}\label{wxgridappendrows}
51
52\func{bool}{AppendRows}{\param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
53
54Appends {\it n} rows to the grid. If {\it updateLabels} is TRUE,
55the function OnChangeLabels is called to give the application the opportunity to relabel.
56
57\membersection{wxGrid::BeginBatch}\label{wxgridbeginbatch}
58
59\func{void}{BeginBatch}{\void}
60
61Start a BeginBatch/EndBatch pair between which, calls to SetCellValue or
62SetCellBitmap will not cause a refresh. This allows you to speed up some operations
63(for example, setting several hundred cell values). You can nest, but not overlap,
64these two functions.
65
66See also \helpref{wxGrid::EndBatch}{wxgridendbatch}, \helpref{wxGrid::GetBatchCount}{wxgridgetbatchcount}.
67
68\membersection{wxGrid::CellHitTest}\label{wxgridcellhittest}
69
70\func{bool}{CellHitTest}{\param{int}{ x}, \param{int}{ y}, \param{int *}{row}, \param{int *}{col}}
71
72Returns TRUE if the x, y panel position coincides with a cell. If so, {\it row} and {\it col} are
73returned.
74
75\membersection{wxGrid::CreateGrid}\label{wxgridcreategrid}
76
77\func{bool}{CreateGrid}{\param{int}{ rows}, \param{int}{ cols}, \param{wxString **}{cellValues=NULL},
78 \param{short *}{widths=NULL}, \param{short}{ defaultWidth=wxGRID\_DEFAULT\_CELL\_WIDTH},
79 \param{short}{ defaultHeight=wxGRID\_DEFAULT\_CELL\_HEIGHT}}
80
81Creates a grid {\it rows} high and {\it cols} wide. You can optionally specify an array of initial values
82and widths, and/or default cell width and height.
83
84Call this function after creating the wxGrid object.
85
21f280f4
RD
86\pythonnote{Currently the \tt{cellValues} and \tt{widths} parameters
87don't exisit in the wxPython version of this method. So in other
88words, the definition of the wxPython version of this method looks like this:
89\begin{verbatim}
90 CreateGrid(rows, cols,
91 defaultWidth = wxGRID_DEFAULT_CELL_WIDTH,
92 defaultHeight = wxGRID_DEFAULT_CELL_HEIGHT)
93\end{verbatim}
94}
95
a660d684
KB
96\membersection{wxGrid::CurrentCellVisible}\label{wxgridcurrentcellvisible}
97
98\func{bool}{CurrentCellVisible}{\void}
99
100Returns TRUE if the currently selected cell is visible, FALSE otherwise.
101
102\membersection{wxGrid::DeleteCols}\label{wxgriddeletecols}
103
104\func{bool}{DeleteCols}{\param{int}{ pos=0}, \param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
105
106Deletes {\it n} columns from the grid at position {\it pos}. If {\it updateLabels} is TRUE,
107the function OnChangeLabels is called to give the application the opportunity to relabel.
108
109\membersection{wxGrid::DeleteRows}\label{wxgriddeleterows}
110
111\func{bool}{DeleteRows}{\param{int}{ pos=0}, \param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
112
113Deletes {\it n} rows from the grid at position {\it pos}. If {\it updateLabels} is TRUE,
114the function OnChangeLabels is called to give the application the opportunity to relabel.
115
116\membersection{wxGrid::EndBatch}\label{wxgridendbatch}
117
118\func{void}{EndBatch}{\void}
119
120End a BeginBatch/EndBatch pair between which, calls to SetCellValue or
121SetCellBitmap will not cause a refresh. This allows you to speed up some operations
122(for example, setting several hundred cell values). You can nest, but not overlap,
123these two functions.
124
125See also \helpref{wxGrid::BeginBatch}{wxgridbeginbatch}, \helpref{wxGrid::GetBatchCount}{wxgridgetbatchcount}.
126
127\membersection{wxGrid::GetBatchCount}\label{wxgridgetbatchcount}
128
c0ed460c 129\constfunc{int}{GetBatchCount}{\void}
a660d684
KB
130
131Return the level of batch nesting. This is initially zero, and will be incremented
132every time BeginBatch is called, and decremented when EndBatch is called. When the
133batch count is more zero, some functions (such as SetCellValue and SetCellBitmap) will
134not refresh the cell.
135
136See also \helpref{wxGrid::BeginBatch}{wxgridbeginbatch}, \helpref{wxGrid::EndBatch}{wxgridendbatch}.
137
138\membersection{wxGrid::GetCell}\label{wxgridgetcell}
139
c0ed460c 140\constfunc{wxGridCell *}{GetCell}{\param{int}{ row}, \param{int}{ col}}
a660d684
KB
141
142Returns the grid cell object associated with this position.
143
144wxGenericGrid implementation only.
145
146\membersection{wxGrid::GetCellAlignment}\label{wxgridgetcellalignment}
147
c0ed460c 148\constfunc{int}{GetCellAlignment}{\param{int}{ row}, \param{int}{ col}}
a660d684 149
c0ed460c 150\constfunc{int}{GetCellAlignment}{\void}
a660d684
KB
151
152Sets the text alignment for the cell at the given position, or the global alignment value.
153The return value is wxLEFT, wxRIGHT or wxCENTRE.
154
21f280f4
RD
155\pythonnote{In place of a single overloaded method name, wxPython
156implements the following methods:\par
157\indented{2cm}{\begin{twocollist}
158\twocolitem{\bf{GetCellAlignment(row, col)}}{}
159\twocolitem{\bf{GetDefCellAlignment()}}{}
160\end{twocollist}}
161}
162
a660d684
KB
163\membersection{wxGrid::GetCellBackgroundColour}\label{wxgridgetcellbackgroundcolour}
164
c0ed460c 165\constfunc{wxColour\&}{GetCellBackgroundColour}{\param{int}{ row}, \param{int}{ col}}
a660d684 166
c0ed460c 167\constfunc{wxColour\&}{GetCellBackgroundColour}{\void}
a660d684
KB
168
169Gets the background colour for the cell at the given position, or the global background colour.
170
21f280f4
RD
171\pythonnote{In place of a single overloaded method name, wxPython
172implements the following methods:\par
173\indented{2cm}{\begin{twocollist}
174\twocolitem{\bf{GetCellBackgroundColour(row, col)}}{}
175\twocolitem{\bf{GetDefCellBackgroundColourt()}}{}
176\end{twocollist}}
177}
178
a660d684
KB
179\membersection{wxGrid::GetCells}\label{wxgridgetcells}
180
c0ed460c 181\constfunc{wxGridCell ***}{GetCells}{\void}
a660d684
KB
182
183Returns the array of grid cell object associated with this wxGrid.
184
185\membersection{wxGrid::GetCellTextColour}\label{wxgridgetcelltextcolour}
186
c0ed460c 187\constfunc{wxColour\&}{GetCellTextColour}{\param{int}{ row}, \param{int}{ col}}
a660d684 188
c0ed460c 189\constfunc{wxColour\&}{GetCellTextColour}{\void}
a660d684
KB
190
191Gets the text colour for the cell at the given position, or the global text colour.
192
21f280f4
RD
193\pythonnote{In place of a single overloaded method name, wxPython
194implements the following methods:\par
195\indented{2cm}{\begin{twocollist}
196\twocolitem{\bf{GetCellTextColour(row, col)}}{}
197\twocolitem{\bf{GetDefCellTextColour()}}{}
198\end{twocollist}}
199}
200
a660d684
KB
201\membersection{wxGrid::GetCellTextFont}\label{wxgridgetcelltextfont}
202
c0ed460c 203\constfunc{const wxFont\&}{GetCellTextFont}{\param{int}{ row}, \param{int}{ col}}
a660d684 204
c0ed460c 205\constfunc{wxFont\&}{GetCellTextFont}{\void}
a660d684
KB
206
207Gets the text font for the cell at the given position, or the global text font.
208
21f280f4
RD
209\pythonnote{In place of a single overloaded method name, wxPython
210implements the following methods:\par
211\indented{2cm}{\begin{twocollist}
212\twocolitem{\bf{GetCellTextFont(row, col)}}{}
213\twocolitem{\bf{GetDefCellTextFont()}}{}
214\end{twocollist}}
215}
216
a660d684
KB
217\membersection{wxGrid::GetCellValue}\label{wxgridgetcellvalue}
218
c0ed460c 219\constfunc{wxString\&}{GetCellValue}{\param{int}{ row}, \param{int}{ col}}
a660d684
KB
220
221Returns the cell value at the given position.
222
223\membersection{wxGrid::GetCols}\label{wxgridgetcols}
224
c0ed460c 225\constfunc{int}{GetCols}{\void}
a660d684
KB
226
227Returns the number of columns in the grid.
228
229\membersection{wxGrid::GetColumnWidth}\label{wxgridcolumnwidth}
230
c0ed460c 231\constfunc{int}{GetColumnWidth}{\param{int}{ col}}
a660d684
KB
232
233Gets the width in pixels for column {\it col}.
234
235\membersection{wxGrid::GetCurrentRect}\label{wxgridgetcurrentrect}
236
c0ed460c 237\constfunc{wxRectangle *}{GetCurrentRect}{\void}
a660d684
KB
238
239Returns a pointer to the rectangle enclosing the currently selected cell.
240Do not delete this pointer.
241
242\membersection{wxGrid::GetCursorColumn}\label{wxgridgetcursorcolumn}
243
c0ed460c 244\constfunc{int}{GetCursorColumn}{\void}
a660d684
KB
245
246Returns the column position of the currently selected cell.
247
248\membersection{wxGrid::GetCursorRow}\label{wxgridgetcursorrow}
249
c0ed460c 250\constfunc{int}{GetCursorRow}{\void}
a660d684
KB
251
252Returns the row position of the currently selected cell.
253
254\membersection{wxGrid::GetEditable}\label{wxgridgeteditable}
255
c0ed460c 256\constfunc{bool}{GetEditable}{\void}
a660d684
KB
257
258Returns TRUE if the grid cells can be edited.
259
260\membersection{wxGrid::GetHorizScrollBar}\label{wxgridgethorizscrollbar}
261
c0ed460c 262\constfunc{wxScrollBar *}{GetHorizScrollBar}{\void}
a660d684
KB
263
264Returns a pointer to the horizontal scrollbar.
265
266\membersection{wxGrid::GetLabelAlignment}\label{wxgridgetlabelalignment}
267
c0ed460c 268\constfunc{int}{GetLabelAlignment}{\param{int}{ orientation}}
a660d684
KB
269
270Gets the row or column label alignment. {\it orientation} should
271be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.\rtfsp
272{\it alignment} should be wxCENTRE, wxLEFT or wxRIGHT.
273
274\membersection{wxGrid::GetLabelBackgroundColour}\label{wxgridgetlabelbackgroundcolour}
275
c0ed460c 276\constfunc{wxColour\&}{GetLabelBackgroundColour}{\void}
a660d684
KB
277
278Gets a row and column label text colour.
279
280\membersection{wxGrid::GetLabelSize}\label{wxgridgetlabelsize}
281
c0ed460c 282\constfunc{int}{GetLabelSize}{\param{int}{ orientation}}
a660d684
KB
283
284Gets the row label height, or column label width, in pixels. {\it orientation} should
285be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.
286
287\membersection{wxGrid::GetLabelTextColour}\label{wxgridgetlabeltextcolour}
288
c0ed460c 289\constfunc{wxColour\&}{GetLabelTextColour}{\void}
a660d684
KB
290
291Gets a row and column label text colour.
292
293\membersection{wxGrid::GetLabelTextFont}\label{wxgridgetlabeltextfont}
294
c0ed460c 295\constfunc{wxFont\&}{GetLabelTextFont}{\void}
a660d684
KB
296
297Gets the font to be used for the row and column labels.
298
299\membersection{wxGrid::GetLabelValue}\label{wxgridgetlabelvalue}
300
c0ed460c 301\constfunc{wxString\&}{GetLabelValue}{\param{int}{ orientation}, \param{int}{ pos}}
a660d684
KB
302
303Gets a row or column label value. {\it orientation} should
304be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.\rtfsp
305{\it pos} is the label position.
306
307\membersection{wxGrid::GetRowHeight}\label{wxgridgetrowheight}
308
c0ed460c 309\constfunc{int}{GetRowHeight}{\param{int}{ row}}
a660d684
KB
310
311Gets the height in pixels for row {\it row}.
312
313\membersection{wxGrid::GetRows}\label{wxgridgetrows}
314
c0ed460c 315\constfunc{int}{GetRows}{\void}
a660d684
KB
316
317Returns the number of rows in the grid.
318
319\membersection{wxGrid::GetScrollPosX}\label{wxgridgetscrollposx}
320
c0ed460c 321\constfunc{int}{GetScrollPosX}{\void}
a660d684
KB
322
323Returns the column scroll position.
324
325\membersection{wxGrid::GetScrollPosY}\label{wxgridgetscrollposy}
326
c0ed460c 327\constfunc{int}{GetScrollPosY}{\void}
a660d684
KB
328
329Returns the row scroll position.
330
331\membersection{wxGrid::GetTextItem}\label{wxgridgettextitem}
332
c0ed460c 333\constfunc{wxText *}{GetTextItem}{\void}
a660d684
KB
334
335Returns a pointer to the text item used for entering text into a cell.
336
337\membersection{wxGrid::GetVertScrollBar}\label{wxgridgetvertscrollbar}
338
c0ed460c 339\constfunc{wxScrollBar *}{GetVertScrollBar}{\void}
a660d684
KB
340
341Returns a pointer to the vertical scrollbar.
342
343\membersection{wxGrid::InsertCols}\label{wxgridinsertcols}
344
345\func{bool}{InsertCols}{\param{int}{ pos=0}, \param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
346
347Inserts {\it n} number of columns before position {\it pos}. If {\it updateLabels} is TRUE,
348the function OnChangeLabels is called to give the application the opportunity to relabel.
349
350\membersection{wxGrid::InsertRows}\label{wxgridinsertrows}
351
352\func{bool}{InsertRows}{\param{int}{ pos=0}, \param{int}{ n=1}, \param{bool}{ updateLabels=TRUE}}
353
354Inserts {\it n} number of rows before position {\it pos}. If {\it updateLabels} is TRUE,
355the function OnChangeLabels is called to give the application the opportunity to relabel.
356
357\membersection{wxGrid::OnActivate}\label{wxgridonactivate}
358
359\func{void}{OnActivate}{\param{bool}{ active}}
360
361Sets the text item to have the focus. Call this function when the wxGrid window should have the
362focus, for example from wxFrame::OnActivate.
363
364\membersection{wxGrid::OnChangeLabels}\label{wxgridonchangelabels}
365
366\func{void}{OnChangeLabels}{\void}
367
368Called when rows and columns are created or deleted, to allow the application an
369opportunity to update the labels. By default, columns are labelled alphabetically,
370and rows numerically.
371
372\membersection{wxGrid::OnChangeSelectionLabel}\label{wxgridonchangeselectionlabel}
373
374\func{void}{OnChangeSelectionLabel}{\void}
375
376Called when a cell is selected, to allow the application an
377opportunity to update the selection label (the label of the wxText item
378used for entering cell text). By default, the cell column letter and row
379number are concatenated to form the selection label.
380
381\membersection{wxGrid::OnCreateCell}\label{wxgridoncreatecell}
382
383\func{wxGridCell *}{OnCreateCell}{\void}
384
385Override this virtual function if you want to replace the normal wxGridCell with a derived
386class.
387
388\membersection{wxGrid::OnCellLeftClick}\label{wxgridoncellleftclick}
389
390\func{void}{OnLeftClick}{\param{int}{ row}, \param{int}{ col}, \param{int}{ x}, \param{int}{ y}, \param{bool}{ control}, \param{bool}{ shift}}
391
392Virtual function called when the left button is depressed within a cell, just after OnSelectCell is called.
393
394\membersection{wxGrid::OnCellRightClick}\label{wxgridoncellrightclick}
395
396\func{void}{OnRightClick}{\param{int}{ row}, \param{int}{ col}, \param{int}{ x}, \param{int}{ y}, \param{bool}{ control}, \param{bool}{ shift}}
397
398Virtual function called when the right button is depressed within a cell, just after OnSelectCell is called.
399
400\membersection{wxGrid::OnLabelLeftClick}\label{wxgridonlabelleftclick}
401
402\func{void}{OnLeftClick}{\param{int}{ row}, \param{int}{ col}, \param{int}{ x}, \param{int}{ y}, \param{bool}{ control}, \param{bool}{ shift}}
403
404Virtual function called when the left button is depressed within a
21f280f4 405label.
a660d684
KB
406
407{\it row} will be {\it -1} if the click is in the top labels.
408
409{\it col} will be {\it -1} if the click is in the left labels.
410
411{\it row} and {\it col} will be {\it -1} if the click is in the upper
412left corner.
413
414\membersection{wxGrid::OnLabelRightClick}\label{wxgridonlabelrightclick}
415
416\func{void}{OnRightClick}{\param{int}{ row}, \param{int}{ col}, \param{int}{ x}, \param{int}{ y}, \param{bool}{ control}, \param{bool}{ shift}}
417
418Virtual function called when the right button is depressed within a label.
419
420{\it row} will be {\it -1} if the click is in the top labels.
421
422{\it col} will be {\it -1} if the click is in the left labels.
423
424{\it row} and {\it col} will be {\it -1} if the click is in the upper
425left corner.
426
427\membersection{wxGrid::OnSelectCell}\label{wxgridonselectcell}
428
429\func{void}{OnSelectCell}{\param{int}{ row}, \param{int}{ col}}
430
431Virtual function called when the user left-clicks on a cell.
432
433\membersection{wxGrid::OnSelectCellImplementation}\label{wxgridonselectcellimplementation}
434
435\func{void}{OnSelectCellImplementation}{\param{wxDC *}{dc}, \param{int}{ row}, \param{int}{ col}}
436
437Virtual function called when the user left-clicks on a cell. If you override this function,
438call wxGrid::OnSelectCell to apply the default behaviour.
439
440\membersection{wxGrid::SetCellAlignment}\label{wxgridsetcellalignment}
441
442\func{void}{SetCellAlignment}{\param{int}{ alignment}, \param{int}{ row}, \param{int}{ col}}
443
444\func{void}{SetCellAlignment}{\param{int}{ alignment}}
445
446Sets the text alignment for the cell at the given position, or for the whole grid. {\it alignment} may be wxLEFT, wxRIGHT or wxCENTRE.
447
21f280f4
RD
448\pythonnote{In place of a single overloaded method name, wxPython
449implements the following methods:\par
450\indented{2cm}{\begin{twocollist}
451\twocolitem{\bf{SetCellAlignment(alignment, row, col)}}{}
452\twocolitem{\bf{SetDefCellAlignment(alignment)}}{}
453\end{twocollist}}
454}
455
a660d684
KB
456\membersection{wxGrid::SetCellBackgroundColour}\label{wxgridsetcellbackgroundcolour}
457
458\func{void}{SetCellBackgroundColour}{\param{const wxColour\&}{ colour}, \param{int}{ row}, \param{int}{ col}}
459
460\func{void}{SetCellBackgroundColour}{\param{const wxColour\&}{ colour}}
461
462Sets the background colour for the cell at the given position, or for the whole grid.
463
21f280f4
RD
464\pythonnote{In place of a single overloaded method name, wxPython
465implements the following methods:\par
466\indented{2cm}{\begin{twocollist}
467\twocolitem{\bf{SetCellBackgroundColour(colour, row, col)}}{}
468\twocolitem{\bf{SetDefCellBackgroundColour(colour)}}{}
469\end{twocollist}}
470}
471
a660d684
KB
472\membersection{wxGrid::SetCellTextColour}\label{wxgridsetcelltextcolour}
473
474\func{void}{SetCellTextColour}{\param{const wxColour\&}{ colour}, \param{int}{ row}, \param{int}{ col}}
475
476\func{void}{SetCellTextColour}{\param{const wxColour\&}{ colour}}
477
478Sets the text colour for the cell at the given position, or for the whole grid.
479
21f280f4
RD
480\pythonnote{In place of a single overloaded method name, wxPython
481implements the following methods:\par
482\indented{2cm}{\begin{twocollist}
483\twocolitem{\bf{SetCellTextColour(colour, row, col)}}{}
484\twocolitem{\bf{SetDefCellTextColour(colour)}}{}
485\end{twocollist}}
486}
487
a660d684
KB
488\membersection{wxGrid::SetCellTextFont}\label{wxgridsetcelltextfont}
489
c0ed460c 490\func{void}{SetCellTextFont}{\param{const wxFont\&}{ font}, \param{int}{ row}, \param{int}{ col}}
a660d684 491
c0ed460c 492\func{void}{SetCellTextFont}{\param{const wxFont\&}{ font}}
a660d684
KB
493
494Sets the text font for the cell at the given position, or for the whole grid.
495
21f280f4
RD
496\pythonnote{In place of a single overloaded method name, wxPython
497implements the following methods:\par
498\indented{2cm}{\begin{twocollist}
499\twocolitem{\bf{SetCellTextFont(font, row, col)}}{}
500\twocolitem{\bf{SetDefCellTextFont(font)}}{}
501\end{twocollist}}
502}
503
a660d684
KB
504\membersection{wxGrid::SetCellValue}\label{wxgridsetcellvalue}
505
506\func{void}{SetCellValue}{\param{const wxString\&}{ val}, \param{int}{ row}, \param{int}{ col}}
507
508Sets the cell value at the given position.
509
510\membersection{wxGrid::SetColumnWidth}\label{wxgridsetcolumnwidth}
511
512\func{void}{SetColumnWidth}{\param{int}{ col}, \param{int}{ width}}
513
514Sets the width in pixels for column {\it col}.
515
516\membersection{wxGrid::SetDividerPen}\label{wxgridsetdividerpen}
517
c0ed460c 518\func{void}{SetDividerPen}{\param{const wxPen\&}{ pen}}
a660d684
KB
519
520Specifies the pen to be used for drawing the divisions between cells. The default
521is a light grey. If NULL is specified, the divisions will not be drawn.
522
523\membersection{wxGrid::SetEditable}\label{wxgridseteditable}
524
525\func{void}{SetEditable}{\param{bool}{ editable}}
526
527If {\it editable} is TRUE (the default), the grid cells will be editable by means of the
528text edit control. If FALSE, the text edit control will be hidden and the user will not
529be able to edit the cell contents.
530
531\membersection{wxGrid::SetGridCursor}\label{wxgridsetgridcursor}
532
533\func{void}{SetGridCursor}{\param{int }{row}, \param{int}{ col}}
534
535Sets the position of the selected cell.
536
537\membersection{wxGrid::SetLabelAlignment}\label{wxgridsetlabelalignment}
538
539\func{void}{SetLabelAlignment}{\param{int}{ orientation}, \param{int}{ alignment}}
540
541Sets the row or column label alignment. {\it orientation} should
542be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.\rtfsp
543{\it alignment} should be wxCENTRE, wxLEFT or wxRIGHT.
544
545\membersection{wxGrid::SetLabelBackgroundColour}\label{wxgridsetlabelbackgroundcolour}
546
547\func{void}{SetLabelBackgroundColour}{\param{const wxColour\&}{ value}}
548
549Sets a row or column label background colour.
550
551\membersection{wxGrid::SetLabelSize}\label{wxgridsetlabelsize}
552
553\func{void}{SetLabelSize}{\param{int}{ orientation}, \param{int}{ size}}
554
555Sets the row label height, or column label width, in pixels. {\it orientation} should
556be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.
557
558If a dimension of zero is specified, the row or column labels will not be
559shown.
560
561\membersection{wxGrid::SetLabelTextColour}\label{wxgridsetlabeltextcolour}
562
563\func{void}{SetLabelTextColour}{\param{const wxColour\&}{ value}}
564
565Sets a row and column label text colour.
566
567\membersection{wxGrid::SetLabelTextFont}\label{wxgridsetlabeltextfont}
568
c0ed460c 569\func{void}{SetLabelTextFont}{\param{const wxFont\&}{ font}}
a660d684
KB
570
571Sets the font to be used for the row and column labels.
572
573\membersection{wxGrid::SetLabelValue}\label{wxgridsetlabelvalue}
574
575\func{void}{SetLabelValue}{\param{int}{ orientation}, \param{const wxString\&}{ value}, \param{int}{ pos}}
576
577Sets a row or column label value. {\it orientation} should
578be wxHORIZONTAL to specify column label, wxVERTICAL to specify row label.\rtfsp
579{\it pos} is the label position.
580
581\membersection{wxGrid::SetRowHeight}\label{wxgridsetrowheight}
582
583\func{void}{SetRowHeight}{\param{int}{ row}, \param{int}{ height}}
584
585Sets the height in pixels for row {\it row}.
586
587\membersection{wxGrid::UpdateDimensions}\label{wxgridupdatedimensions}
588
589\func{void}{UpdateDimensions}{\void}
590
591Call this function whenever a change has been made via the API that
592might alter size characteristics. You may also need to follow it with
593a call to AdjustScrollbars.
594
595