X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FCiteEnginesList.h;h=ad703325c61161a431f999c1d8d2080f599b0a74;hb=62af7ee772f16f154225d2d0b65d77f4376b6001;hp=17cfbb80897bf1cfd944edb007083118701827c0;hpb=59a4f263a44ca3a1f5a37a652c8df154788f72d1;p=lyx.git diff --git a/src/CiteEnginesList.h b/src/CiteEnginesList.h index 17cfbb8089..ad703325c6 100644 --- a/src/CiteEnginesList.h +++ b/src/CiteEnginesList.h @@ -22,8 +22,7 @@ namespace lyx { /** * This class represents a particular LyX "cite engine", which defines the features - * of a particular citation backend such as natbib or biblatex. In that sense, it is more like - * a LaTeX package, where a layout file corresponds to a LaTeX class. + * of a particular citation backend such as natbib or biblatex. * * In general, a given cite engine can be used with any document class. That said, * one cite engine may `require' another, or it may `exclude' some other cite engine. @@ -51,10 +50,10 @@ public: /// LyXCiteEngine(std::string const & name, std::string const & id, std::vector const & enginetypes, + std::string const & cfm, + std::vector const & defaultbiblios, std::string const & description, - std::vector const & packagelist, - std::vector const & requires, - std::vector const & excludes); + std::vector const & packagelist); /// whether the required packages are available bool isAvailable() const; /// the missing prerequisites, if any @@ -66,27 +65,22 @@ public: /// std::string const & getFilename() const { return filename_; } /// + std::string const & getCiteFramework() const { return cite_framework_; } + /// std::vector const & getEngineType() const { return engine_types_; } /// bool hasEngineType(CiteEngineType const &) const; /// + std::string getDefaultBiblio(CiteEngineType const &) const; + /// + bool isDefaultBiblio(std::string const &) const; + /// std::string const & getDescription() const { return description_; } /// std::vector const & getPackageList() const { return package_list_; } /// - std::vector const & getRequiredEngines() const - { return required_engines_; } - /// Engines this one excludes: the list should be treated disjunctively - std::vector const & getExcludedEngines() const - { return excluded_engines_; } - /// \return true if the engine is compatible with this one, i.e., - /// it does not exclude us and we do not exclude it. - /// this will also return true if cename is unknown and we do not - /// exclude it, since in that case we cannot check its exclusions. - bool isCompatible(std::string const & cename) const; - /// - static bool areCompatible(std::string const & eng1, std::string const & eng2); + bool required(std::string const p) const; private: /// what appears in the ui std::string name_; @@ -97,16 +91,16 @@ private: std::string filename_; /// the engine type(s) std::vector engine_types_; + /// cite framework (bibtex, biblatex) + std::string cite_framework_; + /// default bibliography styles + std::vector default_biblios_; /// a short description for use in the ui std::string description_; /// the LaTeX packages on which this depends, if any std::vector package_list_; - /// Engines this one requires: at least one - std::vector required_engines_; - /// Engines this one excludes: none of these - std::vector excluded_engines_; // these are mutable because they are used to cache the results - // or an otherwise const operation. + // of an otherwise const operation. /// mutable bool checked_; /// @@ -153,12 +147,13 @@ public: void operator=(CiteEnginesList const &); /// add an engine to the list void addCiteEngine(std::string const &, std::string const &, - std::vector const &, std::string const &, std::vector const &, - std::vector const &, std::vector const &); + std::vector const &, std::string const &, + std::vector const &, std::string const &, + std::vector const &); /// std::vector englist_; }; extern CiteEnginesList theCiteEnginesList; -} +} // namespace lyx #endif