4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
15 #include "GuiDialog.h"
17 #include "FancyLineEdit.h"
19 #include "insets/InsetCommandParams.h"
23 class QTreeWidgetItem;
28 class GuiRef : public GuiDialog, public Ui::RefUi
34 /// Dialog inherited methods
36 void enableView(bool enable);
40 void changed_adaptor();
44 void refHighlighted(QTreeWidgetItem *);
45 void selectionChanged();
46 void refTextChanged(QString const &);
47 void refSelected(QTreeWidgetItem *);
52 void dialogRejected();
56 bool isBufferDependent() const { return true; }
57 /** disconnect from the inset when the Apply button is pressed.
58 Allows easy insertion of multiple references. */
59 bool disconnectOnApply() const { return true; }
61 void gotoRef(std::string const &);
65 void closeEvent(QCloseEvent * e);
71 void updateContents();
75 /// is name allowed for this ?
77 /// is type allowed for this ?
79 /// go to current reference
81 /// set go back button
83 /// set goto ref button
85 /// re-enter references
90 bool initialiseParams(std::string const & data);
92 void clearParams() { params_.clear(); }
94 void dispatchParams();
98 InsetCommandParams params_;
100 /// contains the search box
101 FancyLineEdit * filter_;
103 /// went to a reference ?
105 /// the last reference entered or examined
106 QString last_reference_;
107 /// store the buffer settings
108 int restored_buffer_;
109 /// store the last active buffer
112 std::vector<docstring> refs_;
115 } // namespace frontend