*
* \author Angus Leeming
* \author Kalle Dalheimer
+ * \author Abdelrazak Younes
*
* Full author contact details are available in file CREDITS.
*/
#ifndef QCITATION_H
#define QCITATION_H
-#include "ControlCitation.h"
+#include "frontends/controllers/ControlCitation.h"
+#include <QStringList>
#include <QStringListModel>
namespace lyx {
public:
///
QCitation(Dialog &);
+ virtual ~QCitation() {}
+ virtual bool initialiseParams(std::string const & data);
+
+ ///
+ void init();
+
/// Available keys
- QStringListModel * available() { return &available_keys_; }
+ QStringListModel * available() { return &available_model_; }
/// Selected keys
- QStringListModel * selected() { return &selected_keys_; }
-
- /// Found keys
- QStringListModel * found() { return &found_keys_; }
+ QStringListModel * selected() { return &selected_model_; }
/// Text before cite
QString textBefore();
/// Clear selected keys
void clearSelection();
- /// Find keys containing the string (not case-sens)
- void findKey(QString const &);
+ /// Find keys containing a string.
+ void findKey(
+ QString const & str, //< string expression
+ bool only_keys, //< set to true if only keys shall be searched.
+ bool case_sensitive, //< set to true for case sensitive search.
+ bool reg_exp //< set to true if \c str is a regular expression.
+ );
/// Add key to selected keys
void addKey(QModelIndex const &);
virtual void apply(int const choice, bool const full, bool const force,
QString before, QString after);
- /// Update dialog before/whilst showing it.
- virtual void updateModel();
+private:
+ /// available keys.
+ QStringListModel available_model_;
-private:
- /// available keys
- QStringListModel available_keys_;
+ /// selected keys.
+ QStringListModel selected_model_;
- /// selected keys
- QStringListModel selected_keys_;
+ /// All keys.
+ QStringList all_keys_;
- /// found keys
- QStringListModel found_keys_;
+ /// Cited keys.
+ QStringList cited_keys_;
};