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 "support/docstring.h"
27 namespace support { class FileFilterList; }
31 class GuiBibtexAddDialog : public QDialog, public Ui::BibtexAddUi
34 GuiBibtexAddDialog(QWidget * parent) : QDialog(parent)
36 Ui::BibtexAddUi::setupUi(this);
37 QDialog::setModal(true);
42 class GuiBibtex : public GuiCommand, public Ui::BibtexUi
47 GuiBibtex(LyXView & lv);
50 void change_adaptor();
52 void browseBibPressed();
56 void databaseChanged();
57 void availableChanged();
61 void closeEvent(QCloseEvent * e);
69 void updateContents();
71 /// Browse for a .bib file
72 docstring const browseBib(docstring const & in_name) const;
74 /// Browse for a .bst file
75 docstring const browseBst(docstring const & in_name) const;
77 /// get the list of bst files
78 void getBibStyles(std::vector<std::string> & data) const;
79 /// get the list of bib files
80 void getBibFiles(std::vector<std::string> & data) const;
81 /// build filelists of all availabe bib/bst/cls/sty-files. done through
82 /// kpsewhich and an external script, saved in *Files.lst
83 void rescanBibStyles() const;
84 /// do we use bibtopic (for sectioned bibliography)?
85 bool usingBibtopic() const;
86 /// should we put the bibliography to the TOC?
87 bool bibtotoc() const;
88 /// which stylefile do we use?
89 std::string const getStylefile() const;
92 GuiBibtexAddDialog * add_;
94 ButtonController add_bc_;
97 } // namespace frontend
100 #endif // GUIBIBTEX_H