diff options
| author | Carl Hetherington <cth@carlh.net> | 2022-06-09 21:16:31 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2022-06-10 23:12:13 +0200 |
| commit | ca5cc79f4464c5e9f34480757c288b9bbcb569ec (patch) | |
| tree | 43aabbb22b7e7ae05be1ef4ee02e5602f173d13d | |
| parent | 2f1986a814403d690aedcbe8b7057878ebae76b0 (diff) | |
Make it OK to re-examine content with subtitles.
| -rw-r--r-- | src/lib/string_text_file_content.cc | 2 | ||||
| -rw-r--r-- | src/lib/text_content.cc | 7 | ||||
| -rw-r--r-- | src/lib/text_content.h | 1 |
3 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/string_text_file_content.cc b/src/lib/string_text_file_content.cc index 934144fa4..95a282174 100644 --- a/src/lib/string_text_file_content.cc +++ b/src/lib/string_text_file_content.cc @@ -66,6 +66,8 @@ StringTextFileContent::examine (shared_ptr<const Film> film, shared_ptr<Job> job Content::examine (film, job); StringTextFile file (shared_from_this()); + only_text()->clear_fonts(); + /* Default to turning these subtitles on */ only_text()->set_use (true); diff --git a/src/lib/text_content.cc b/src/lib/text_content.cc index 9c925cbcf..e91b7bcc0 100644 --- a/src/lib/text_content.cc +++ b/src/lib/text_content.cc @@ -664,3 +664,10 @@ TextContent::get_font(string id) const return *iter; } + +void +TextContent::clear_fonts() +{ + _fonts.clear(); +} + diff --git a/src/lib/text_content.h b/src/lib/text_content.h index f46b6c6d0..7ddb20b08 100644 --- a/src/lib/text_content.h +++ b/src/lib/text_content.h @@ -76,6 +76,7 @@ public: std::string identifier () const; void take_settings_from (std::shared_ptr<const TextContent> c); + void clear_fonts (); void add_font (std::shared_ptr<dcpomatic::Font> font); std::shared_ptr<dcpomatic::Font> get_font(std::string id) const; |
