3 * Copyright 2001 the LyX Team
4 * Read the file COPYING
19 #include <qpushbutton.h>
20 #include <qcombobox.h>
21 #include <qlistview.h>
26 class TocDialog : public QDialog {
29 TocDialog(FormToc * form, QWidget * parent=0, char const * name=0,
30 bool modal=false, WFlags f=0);
37 QPushButton * buttonUpdate;
38 QPushButton * buttonClose;
43 void closeEvent(QCloseEvent * e);
50 QHBoxLayout * topLayout;
52 QHBoxLayout * buttonLayout;
55 /// adaptor to FormToc::select
56 void select_adaptor(QListViewItem * item) {
57 form_->select(item->text(0));
60 /// adaptor to FormToc::set_depth
61 void depth_adaptor(int depth) {
62 form_->set_depth(depth);
65 /// adaptor to FormToc::update
66 void update_adaptor(void) {
70 // adaptors to FormToc::set_type
71 void activate_adaptor(int index) {
74 form_->set_type(Buffer::TOC_TOC);
77 form_->set_type(Buffer::TOC_LOF);
80 form_->set_type(Buffer::TOC_LOT);
83 form_->set_type(Buffer::TOC_LOA);
86 lyxerr[Debug::GUI] << "Unknown TOC combo selection." << std::endl;
91 /// adaptor to FormToc::close
92 void close_adaptor(void) {