4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
8 * \author Angus Leeming
10 * Full author contact details are available in file CREDITS.
16 #include "GuiDialog.h"
17 #include "ButtonController.h"
18 #include "ui_BibtexUi.h"
19 #include "ui_BibtexAddUi.h"
21 #include "insets/InsetCommandParams.h"
27 class GuiBibtexAddDialog : public QDialog, public Ui::BibtexAddUi
30 GuiBibtexAddDialog(QWidget * parent) : QDialog(parent)
32 Ui::BibtexAddUi::setupUi(this);
33 QDialog::setModal(true);
38 class GuiBibtex : public GuiDialog, public Ui::BibtexUi
43 explicit GuiBibtex(GuiView & lv);
46 void change_adaptor();
48 void browseBibPressed();
54 void databaseChanged();
55 void availableChanged();
65 void updateContents();
67 /// Browse for a .bib file
68 QString browseBib(QString const & in_name) const;
69 /// Browse for a .bst file
70 QString browseBst(QString const & in_name) const;
71 /// get the list of bst files
72 QStringList bibStyles() const;
73 /// get the list of bib files
74 QStringList bibFiles() const;
75 /// build filelists of all availabe bib/bst/cls/sty-files. done through
76 /// kpsewhich and an external script, saved in *Files.lst
77 void rescanBibStyles() const;
78 /// do we use bibtopic (for sectioned bibliography)?
79 bool usingBibtopic() const;
80 /// should we put the bibliography to the TOC?
81 bool bibtotoc() const;
82 /// which stylefile do we use?
83 QString styleFile() const;
86 bool initialiseParams(std::string const & data);
88 void clearParams() { params_.clear(); }
90 void dispatchParams();
92 bool isBufferDependent() const { return true; }
96 InsetCommandParams params_;
98 GuiBibtexAddDialog * add_;
100 ButtonController add_bc_;
103 } // namespace frontend
106 #endif // GUIBIBTEX_H