diff options
| author | Carl Hetherington <cth@carlh.net> | 2014-12-14 22:44:23 +0000 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2014-12-14 22:44:23 +0000 |
| commit | 861117816d557cd048d56b26f8903ac26a94b395 (patch) | |
| tree | 269649a3b7e3ed2f3f6dedd46e167921da388958 /src/subtitle_string.cc | |
| parent | e58cec97a15d1d5dd198dfb145e1d7daf6be9641 (diff) | |
Switch subtitle string font specs to be the font ID; split SubtitleContent into Interop and SMPTE.
Diffstat (limited to 'src/subtitle_string.cc')
| -rw-r--r-- | src/subtitle_string.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/subtitle_string.cc b/src/subtitle_string.cc index 66869fd5..a92eac92 100644 --- a/src/subtitle_string.cc +++ b/src/subtitle_string.cc @@ -22,10 +22,11 @@ using std::string; using std::ostream; +using boost::optional; using namespace dcp; SubtitleString::SubtitleString ( - string font, + optional<string> font, bool italic, Color color, int size, @@ -92,7 +93,7 @@ dcp::operator<< (ostream& s, SubtitleString const & sub) { s << "\n`" << sub.text() << "' from " << sub.in() << " to " << sub.out() << ";\n" << "fade up " << sub.fade_up_time() << ", fade down " << sub.fade_down_time() << ";\n" - << "font " << sub.font() << ", "; + << "font " << sub.font().get_value_or ("[default]") << ", "; if (sub.italic()) { s << "italic"; |
