X-Git-Url: https://git.carlh.net/gitweb/?p=dcpomatic.git;a=blobdiff_plain;f=src%2Fwx%2Ftext_panel.cc;h=a9a3f142dd60ce3773f5f2d0f8acb7965052f415;hp=7bbead30ccb91926004e34e4cf49a1c557ae55b3;hb=6c18c9a37f3a1c8ea1d3ca7791a0f1380b23f5d1;hpb=19e47294d1de485a12dccf2c25bec0c8144049e8 diff --git a/src/wx/text_panel.cc b/src/wx/text_panel.cc index 7bbead30c..a9a3f142d 100644 --- a/src/wx/text_panel.cc +++ b/src/wx/text_panel.cc @@ -18,6 +18,7 @@ */ + #include "check_box.h" #include "content_panel.h" #include "dcp_text_track_dialog.h" @@ -44,17 +45,20 @@ #include "lib/string_text_file_decoder.h" #include "lib/subtitle_analysis.h" #include "lib/text_content.h" +#include +LIBDCP_DISABLE_WARNINGS #include +LIBDCP_ENABLE_WARNINGS -using std::vector; -using std::string; -using std::list; using std::cout; -using std::shared_ptr; -using boost::optional; using std::dynamic_pointer_cast; +using std::list; +using std::shared_ptr; +using std::string; +using std::vector; using boost::bind; +using boost::optional; /** @param t Original text type of the content, if known */ @@ -869,12 +873,12 @@ TextPanel::update_outline_subtitles_in_viewer () if (rect) { auto content = _analysis_content.lock (); DCPOMATIC_ASSERT (content); - rect->x += content->text.front()->x_offset(); - rect->y += content->text.front()->y_offset(); + rect->x += content->text.front()->x_offset() - _analysis->analysis_x_offset(); + rect->y += content->text.front()->y_offset() - _analysis->analysis_y_offset(); } fv->set_outline_subtitles (rect); } else { - fv->set_outline_subtitles (optional >()); + fv->set_outline_subtitles ({}); } }