36 |
: QTable(pParent, pszName) |
: QTable(pParent, pszName) |
37 |
{ |
{ |
38 |
m_pClient = NULL; |
m_pClient = NULL; |
39 |
|
|
40 |
|
// Set fixed number of columns. |
41 |
|
QTable::setNumCols(5); |
42 |
|
QTable::setShowGrid(false); |
43 |
|
QTable::setSorting(false); |
44 |
|
QTable::setFocusStyle(QTable::FollowStyle); |
45 |
|
QTable::setSelectionMode(QTable::NoSelection); |
46 |
|
// No vertical header. |
47 |
|
QTable::verticalHeader()->hide(); |
48 |
|
QTable::setLeftMargin(0); |
49 |
|
// Initialize the fixed table column headings. |
50 |
|
QHeader *pHeader = QTable::horizontalHeader(); |
51 |
|
pHeader->setLabel(0, tr("Name")); |
52 |
|
pHeader->setLabel(1, tr("Description")); |
53 |
|
pHeader->setLabel(2, tr("Type")); |
54 |
|
pHeader->setLabel(3, tr("Value")); |
55 |
|
pHeader->setLabel(4, tr("Default")); |
56 |
|
// Set read-onlyness of each column |
57 |
|
QTable::setColumnReadOnly(0, true); |
58 |
|
QTable::setColumnReadOnly(1, true); |
59 |
|
QTable::setColumnReadOnly(2, true); |
60 |
|
/* QTable::setColumnReadOnly(2, true); -- of course not. */ |
61 |
|
QTable::setColumnReadOnly(4, true); |
62 |
} |
} |
63 |
|
|
64 |
// Default destructor. |
// Default destructor. |