3 * This file is part of LyX, the document processor.
4 * Licence details can be found in the file COPYING.
8 * Full author contact details are available in file CREDITS
14 #pragma implementation
17 #include "ControlIndex.h"
20 #include "QIndexDialog.h"
23 #include <qlineedit.h>
24 #include <qpushbutton.h>
26 typedef Qt2CB<ControlIndex, Qt2DB<QIndexDialog> > base_class;
29 : base_class(_("Index"))
34 void QIndex::build_dialog()
36 dialog_.reset(new QIndexDialog(this));
38 bc().setOK(dialog_->okPB);
39 bc().setCancel(dialog_->closePB);
40 bc().addReadOnly(dialog_->keywordED);
44 void QIndex::update_contents()
46 dialog_->keywordED->setText(controller().params().getContents().c_str());
52 controller().params().setContents(dialog_->keywordED->text().latin1());
56 bool QIndex::isValid()
58 return !string(dialog_->keywordED->text()).empty();