Merge branch 'master' of ssh://git.carlh.net/home/carl/git/dcpomatic
[dcpomatic.git] / src / lib / font.h
index bbf88b34ad0247d1bf9468bb826e11710e4128ab..b2ae86daff328d208a1e5c59d4f6b2ae83fe4b2f 100644 (file)
@@ -21,7 +21,6 @@
 #ifndef DCPOMATIC_FONT_H
 #define DCPOMATIC_FONT_H
 
-#include "font_files.h"
 #include <libcxml/cxml.h>
 #include <boost/optional.hpp>
 #include <boost/signals2.hpp>
 class Font
 {
 public:
-       Font (std::string id)
+       explicit Font (std::string id)
                : _id (id) {}
 
-       Font (cxml::NodePtr node);
+       explicit Font (cxml::NodePtr node);
 
        void as_xml (xmlpp::Node* node);
 
@@ -42,21 +41,12 @@ public:
                return _id;
        }
 
-       boost::optional<boost::filesystem::path> file (FontFiles::Variant variant) const {
-               return _files.get (variant);
+       boost::optional<boost::filesystem::path> file () const {
+               return _file;
        }
 
-       void set_file (FontFiles::Variant variant, boost::filesystem::path file) {
-               _files.set (variant, file);
-               Changed ();
-       }
-
-       FontFiles files () const {
-               return _files;
-       }
-
-       void set_files (FontFiles files) {
-               _files = files;
+       void set_file (boost::filesystem::path file) {
+               _file = file;
                Changed ();
        }
 
@@ -65,7 +55,7 @@ public:
 private:
        /** Font ID, used to describe it in the subtitle content */
        std::string _id;
-       FontFiles _files;
+       boost::optional<boost::filesystem::path> _file;
 };
 
 bool operator!= (Font const & a, Font const & b);