--- as_assist.cpp 2002/12/10 12:06:56 1.54
+++ as_assist.cpp 2002/12/10 14:23:58 1.55
@@ -30,11 +30,11 @@
//
// For username research
-#if defined(Q_WS_WIN)
+#if defined(Q_OS_WIN32)
#include <lmcons.h>
#else
#include <unistd.h>
-#endif
+#endif // #if defined(Q_OS_WIN32)
// Qt style headers
#include <qcdestyle.h>
@@ -346,15 +346,19 @@
m_pTbarspopup->setItemChecked(nMenuid, true);
m_pViewpopup->insertSeparator();
m_pViewpopup->insertItem(trUtf8("&Columns"), m_pColspopup);
+ nMenuid = m_pColspopup->insertItem(trUtf8("&Status"), this, SLOT(showStatcol()));
+ m_pColspopup->setItemEnabled(nMenuid, false);
nMenuid = m_pColspopup->insertItem(trUtf8("&Line"), this, SLOT(showLinecol()));
m_pColspopup->setItemEnabled(nMenuid, false);
+ nMenuid = m_pColspopup->insertItem(trUtf8("&User"), this, SLOT(showUsercol()));
+ m_pColspopup->setItemEnabled(nMenuid, false);
nMenuid = m_pColspopup->insertItem(trUtf8("&GUID"), this, SLOT(showGuidcol()));
m_pColspopup->setItemEnabled(nMenuid, false);
- nMenuid = m_pColspopup->insertItem(trUtf8("&Date"), this, SLOT(showDatecol()));
+ nMenuid = m_pColspopup->insertItem(trUtf8("&CRC"), this, SLOT(showCrccol()));
m_pColspopup->setItemEnabled(nMenuid, false);
- nMenuid = m_pColspopup->insertItem(trUtf8("&User"), this, SLOT(showUsercol()));
+ nMenuid = m_pColspopup->insertItem(trUtf8("&Rev"), this, SLOT(showRevcol()));
m_pColspopup->setItemEnabled(nMenuid, false);
- nMenuid = m_pColspopup->insertItem(trUtf8("&Task"), this, SLOT(showTaskcol()));
+ nMenuid = m_pColspopup->insertItem(trUtf8("&Date"), this, SLOT(showDatecol()));
m_pColspopup->setItemEnabled(nMenuid, false);
nMenuid = m_pColspopup->insertItem(trUtf8("&Start"), this, SLOT(showStartcol()));
m_pColspopup->setItemEnabled(nMenuid, false);
@@ -362,6 +366,8 @@
m_pColspopup->setItemEnabled(nMenuid, false);
nMenuid = m_pColspopup->insertItem(trUtf8("&Amount"), this, SLOT(showAmountcol()));
m_pColspopup->setItemEnabled(nMenuid, false);
+ nMenuid = m_pColspopup->insertItem(trUtf8("&Task"), this, SLOT(showTaskcol()));
+ m_pColspopup->setItemEnabled(nMenuid, false);
nMenuid = m_pColspopup->insertItem(trUtf8("&Remark"), this, SLOT(showRemarkcol()));
m_pColspopup->setItemEnabled(nMenuid, false);
@@ -486,6 +492,10 @@
// Table header row
m_pTablehead = m_pMaintable->horizontalHeader();
m_pMaintable->setHScrollBarMode(QScrollView::AlwaysOff);
+ m_pTablehead->setLabel(TITRAQ_IDXUSER, QObject::trUtf8("User"), 32);
+ m_pTablehead->setLabel(TITRAQ_IDXGUID, QObject::trUtf8("GUID"), 36);
+ m_pTablehead->setLabel(TITRAQ_IDXCRC, QObject::trUtf8("CRC"), 32);
+ m_pTablehead->setLabel(TITRAQ_IDXREV, QObject::trUtf8("Rev"), 32);
m_pTablehead->setLabel(TITRAQ_IDXDATE, QObject::trUtf8("Date"), 90);
m_pTablehead->setLabel(TITRAQ_IDXSTART, QObject::trUtf8("Begin"), 80);
m_pTablehead->setLabel(TITRAQ_IDXFINISH, QObject::trUtf8("End"), 80);
@@ -510,6 +520,78 @@
// QSpacerItem Pad(TITRAQ_SPACING / 2, 0, QSizePolicy::Fixed);
// m_pEditlayout->addWidget(&Pad); // Padd left side of control layout
+ // Make the user edit
+ m_pUseredit = new QLineEdit(m_pCenframe, "User");
+ if (m_pUseredit == NULL) // Sanity check
+ throw Genexcept("Main window user edit creation failed.");
+ m_pUseredit->setText(m_pPrefs->getString(TITRAQ_PREFUSER, TITRAQ_DEFUSER));
+ m_pUseredit->setFrameShape(QLineEdit::LineEditPanel);
+ m_pUseredit->setFrameShadow(QLineEdit::Sunken);
+ m_pUseredit->setFrame(true);
+ m_pUseredit->setReadOnly(false);
+ QToolTip::add(m_pUseredit, trUtf8("User Name"));
+ m_pEditlayout->addWidget(m_pUseredit); // Finally add the user edit
+
+ // Whatsthis info for the user edit
+ const char *kszUsertext = "Edit the <em>user name</em> by clicking "
+ "on this control and typing the user name "
+ "you want to account.";
+ QWhatsThis::add(m_pUseredit, kszUsertext);
+
+ // Make the GUID edit
+ m_pGuidedit = new QLineEdit(m_pCenframe, "Guid");
+ if (m_pGuidedit == NULL) // Sanity check
+ throw Genexcept("Main window GUID edit creation failed.");
+ m_pGuidedit->setText(trUtf8("."));
+ m_pGuidedit->setFrameShape(QLineEdit::LineEditPanel);
+ m_pGuidedit->setFrameShadow(QLineEdit::Sunken);
+ m_pGuidedit->setFrame(true);
+ m_pGuidedit->setReadOnly(false);
+ QToolTip::add(m_pGuidedit, trUtf8("GUID"));
+ m_pEditlayout->addWidget(m_pGuidedit); // Finally add the GUID edit
+
+ // Whatsthis info for the GUID edit
+ const char *kszGuidtext = "Edit the <em>GUID</em> by clicking "
+ "on this control and typing the GUID "
+ "corresponding to this account item.";
+ QWhatsThis::add(m_pGuidedit, kszGuidtext);
+
+ // Make the CRC edit
+ m_pCrcedit = new QLineEdit(m_pCenframe, "Crc");
+ if (m_pCrcedit == NULL) // Sanity check
+ throw Genexcept("Main window CRC edit creation failed.");
+ m_pCrcedit->setText(trUtf8("."));
+ m_pCrcedit->setFrameShape(QLineEdit::LineEditPanel);
+ m_pCrcedit->setFrameShadow(QLineEdit::Sunken);
+ m_pCrcedit->setFrame(true);
+ m_pCrcedit->setReadOnly(false);
+ QToolTip::add(m_pCrcedit, trUtf8("CRC"));
+ m_pEditlayout->addWidget(m_pCrcedit); // Finally add the CRC edit
+
+ // Whatsthis info for the CRC edit
+ const char *kszCrctext = "Edit the <em>CRC</em> by clicking "
+ "on this control and typing the new "
+ "value for this account item.";
+ QWhatsThis::add(m_pCrcedit, kszCrctext);
+
+ // Make the revision edit
+ m_pRevedit = new QLineEdit(m_pCenframe, "Revision");
+ if (m_pRevedit == NULL) // Sanity check
+ throw Genexcept("Main window revision edit creation failed.");
+ m_pRevedit->setText(trUtf8("."));
+ m_pRevedit->setFrameShape(QLineEdit::LineEditPanel);
+ m_pRevedit->setFrameShadow(QLineEdit::Sunken);
+ m_pRevedit->setFrame(true);
+ m_pRevedit->setReadOnly(false);
+ QToolTip::add(m_pRevedit, trUtf8("Revision"));
+ m_pEditlayout->addWidget(m_pRevedit); // Finally add the revision edit
+
+ // Whatsthis info for the revision edit
+ const char *kszRevtext = "Edit the <em>revision</em> by clicking "
+ "on this control and typing the new value "
+ "for this account type.";
+ QWhatsThis::add(m_pRevedit, kszRevtext);
+
// Make the date selector
m_pDateedit = new QDateEdit(m_pCenframe, "Date");
m_pDatezero = new QDate(m_pDateedit->date()); // Hack to store empty date
@@ -611,7 +693,7 @@
m_pTasks->listBox()->setHScrollBarMode(QScrollView::Auto);
// m_pTasks->setMinimumWidth(m_pTasks->listBox()->maxItemWidth());
- // Whatsthis info for the remark line
+ // Whatsthis info for the task editor
const char *kszTasktext = "Choose a <em>task account</em> by clicking on "
"this box, and choosing whichever item most "
"closely resembles your task.";
|