summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-07-18 23:40:25 +0100
committerCarl Hetherington <cth@carlh.net>2018-07-19 23:36:56 +0100
commitc1f98c84cdf3829b31929453b8a89fdcbdcd0c42 (patch)
tree12ee5a9950fd333c7f298b5b6b82f2821788141f /src
parent65cc06076b46cbd27ccfcf7387894358e2c8ab1e (diff)
More renaming; text -> plain.
sed -i "s/TextTextContent/PlainText/g" src/lib/*.cc src/lib/*.h src/wx/*.cc src/wx/*.h src/tools/*.cc test/*.cc sed -i "s/text_text/plain_text/g" src/lib/*.cc src/lib/*.h src/wx/*.cc src/wx/*.h src/tools/*.cc test/*.cc src/lib/wscript mv src/lib/text_text_content.cc src/lib/plain_text_content.cc mv src/lib/text_text_content.h src/lib/plain_text_content.h mv src/lib/text_text_decoder.cc src/lib/plain_text_decoder.cc mv src/lib/text_text_decoder.h src/lib/plain_text_decoder.h
Diffstat (limited to 'src')
-rw-r--r--src/lib/content_factory.cc6
-rw-r--r--src/lib/decoder_factory.cc6
-rw-r--r--src/lib/plain_text_content.cc (renamed from src/lib/text_text_content.cc)16
-rw-r--r--src/lib/plain_text_content.h (renamed from src/lib/text_text_content.h)12
-rw-r--r--src/lib/plain_text_decoder.cc (renamed from src/lib/text_text_decoder.cc)6
-rw-r--r--src/lib/plain_text_decoder.h (renamed from src/lib/text_text_decoder.h)4
-rw-r--r--src/lib/text_file.h2
-rw-r--r--src/lib/text_subtitle.cc4
-rw-r--r--src/lib/text_subtitle.h6
-rw-r--r--src/lib/wscript4
-rw-r--r--src/wx/content_panel.cc6
-rw-r--r--src/wx/subtitle_appearance_dialog.cc2
-rw-r--r--src/wx/subtitle_panel.cc6
-rw-r--r--src/wx/subtitle_view.cc4
-rw-r--r--src/wx/timing_panel.cc2
15 files changed, 43 insertions, 43 deletions
diff --git a/src/lib/content_factory.cc b/src/lib/content_factory.cc
index 14ca579e9..24ad95578 100644
--- a/src/lib/content_factory.cc
+++ b/src/lib/content_factory.cc
@@ -26,7 +26,7 @@
#include "audio_content.h"
#include "image_content.h"
#include "atmos_mxf_content.h"
-#include "text_text_content.h"
+#include "plain_text_content.h"
#include "dcp_content.h"
#include "dcp_text_content.h"
#include "util.h"
@@ -88,7 +88,7 @@ content_factory (shared_ptr<const Film> film, cxml::NodePtr node, int version, l
);
} else if (type == "SubRip" || type == "TextSubtitle") {
- content.reset (new TextTextContent (film, node, version));
+ content.reset (new PlainText (film, node, version));
} else if (type == "DCP") {
content.reset (new DCPContent (film, node, version));
} else if (type == "DCPSubtitle") {
@@ -210,7 +210,7 @@ content_factory (shared_ptr<const Film> film, boost::filesystem::path path)
if (valid_image_file (path)) {
single.reset (new ImageContent (film, path));
} else if (ext == ".srt" || ext == ".ssa" || ext == ".ass") {
- single.reset (new TextTextContent (film, path));
+ single.reset (new PlainText (film, path));
} else if (ext == ".xml") {
cxml::Document doc;
doc.read_file (path);
diff --git a/src/lib/decoder_factory.cc b/src/lib/decoder_factory.cc
index 1a0af1b2c..4301edd17 100644
--- a/src/lib/decoder_factory.cc
+++ b/src/lib/decoder_factory.cc
@@ -24,8 +24,8 @@
#include "dcp_decoder.h"
#include "image_content.h"
#include "image_decoder.h"
-#include "text_text_content.h"
-#include "text_text_decoder.h"
+#include "plain_text_content.h"
+#include "plain_text_decoder.h"
#include "dcp_text_content.h"
#include "dcp_text_decoder.h"
#include "video_mxf_content.h"
@@ -54,7 +54,7 @@ decoder_factory (shared_ptr<const Content> content, shared_ptr<Log> log, bool fa
return shared_ptr<Decoder> (new ImageDecoder (ic, log));
}
- shared_ptr<const TextTextContent> rc = dynamic_pointer_cast<const TextTextContent> (content);
+ shared_ptr<const PlainText> rc = dynamic_pointer_cast<const PlainText> (content);
if (rc) {
return shared_ptr<Decoder> (new TextTextDecoder (rc, log));
}
diff --git a/src/lib/text_text_content.cc b/src/lib/plain_text_content.cc
index 1ff66c490..6ca783c16 100644
--- a/src/lib/text_text_content.cc
+++ b/src/lib/plain_text_content.cc
@@ -18,7 +18,7 @@
*/
-#include "text_text_content.h"
+#include "plain_text_content.h"
#include "util.h"
#include "text_subtitle.h"
#include "film.h"
@@ -35,13 +35,13 @@ using std::cout;
using boost::shared_ptr;
using dcp::raw_convert;
-TextTextContent::TextTextContent (shared_ptr<const Film> film, boost::filesystem::path path)
+PlainText::PlainText (shared_ptr<const Film> film, boost::filesystem::path path)
: Content (film, path)
{
subtitle.reset (new TextContent (this));
}
-TextTextContent::TextTextContent (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
+PlainText::PlainText (shared_ptr<const Film> film, cxml::ConstNodePtr node, int version)
: Content (film, node)
, _length (node->number_child<ContentTime::Type> ("Length"))
{
@@ -49,7 +49,7 @@ TextTextContent::TextTextContent (shared_ptr<const Film> film, cxml::ConstNodePt
}
void
-TextTextContent::examine (boost::shared_ptr<Job> job)
+PlainText::examine (boost::shared_ptr<Job> job)
{
Content::examine (job);
TextSubtitle s (shared_from_this ());
@@ -63,19 +63,19 @@ TextTextContent::examine (boost::shared_ptr<Job> job)
}
string
-TextTextContent::summary () const
+PlainText::summary () const
{
return path_summary() + " " + _("[subtitles]");
}
string
-TextTextContent::technical_summary () const
+PlainText::technical_summary () const
{
return Content::technical_summary() + " - " + _("Text subtitles");
}
void
-TextTextContent::as_xml (xmlpp::Node* node, bool with_paths) const
+PlainText::as_xml (xmlpp::Node* node, bool with_paths) const
{
node->add_child("Type")->add_child_text ("TextSubtitle");
Content::as_xml (node, with_paths);
@@ -88,7 +88,7 @@ TextTextContent::as_xml (xmlpp::Node* node, bool with_paths) const
}
DCPTime
-TextTextContent::full_length () const
+PlainText::full_length () const
{
FrameRateChange const frc (active_video_frame_rate(), film()->video_frame_rate ());
return DCPTime (_length, frc);
diff --git a/src/lib/text_text_content.h b/src/lib/plain_text_content.h
index ccc86fbbf..7a7ef66ea 100644
--- a/src/lib/text_text_content.h
+++ b/src/lib/plain_text_content.h
@@ -22,17 +22,17 @@
class Job;
-/** @class TextTextContent
+/** @class PlainText
* @brief SubRip or SSA subtitles.
*/
-class TextTextContent : public Content
+class PlainText : public Content
{
public:
- TextTextContent (boost::shared_ptr<const Film>, boost::filesystem::path);
- TextTextContent (boost::shared_ptr<const Film>, cxml::ConstNodePtr, int);
+ PlainText (boost::shared_ptr<const Film>, boost::filesystem::path);
+ PlainText (boost::shared_ptr<const Film>, cxml::ConstNodePtr, int);
- boost::shared_ptr<TextTextContent> shared_from_this () {
- return boost::dynamic_pointer_cast<TextTextContent> (Content::shared_from_this ());
+ boost::shared_ptr<PlainText> shared_from_this () {
+ return boost::dynamic_pointer_cast<PlainText> (Content::shared_from_this ());
}
void examine (boost::shared_ptr<Job>);
diff --git a/src/lib/text_text_decoder.cc b/src/lib/plain_text_decoder.cc
index 2ae5cd38e..71f7bed42 100644
--- a/src/lib/text_text_decoder.cc
+++ b/src/lib/plain_text_decoder.cc
@@ -18,8 +18,8 @@
*/
-#include "text_text_decoder.h"
-#include "text_text_content.h"
+#include "plain_text_decoder.h"
+#include "plain_text_content.h"
#include "text_content.h"
#include <dcp/subtitle_string.h>
#include <boost/foreach.hpp>
@@ -34,7 +34,7 @@ using boost::shared_ptr;
using boost::optional;
using boost::dynamic_pointer_cast;
-TextTextDecoder::TextTextDecoder (shared_ptr<const TextTextContent> content, shared_ptr<Log> log)
+TextTextDecoder::TextTextDecoder (shared_ptr<const PlainText> content, shared_ptr<Log> log)
: TextSubtitle (content)
, _next (0)
{
diff --git a/src/lib/text_text_decoder.h b/src/lib/plain_text_decoder.h
index daaf2fcfe..4bdedf58d 100644
--- a/src/lib/text_text_decoder.h
+++ b/src/lib/plain_text_decoder.h
@@ -24,12 +24,12 @@
#include "text_decoder.h"
#include "text_subtitle.h"
-class TextTextContent;
+class PlainText;
class TextTextDecoder : public Decoder, public TextSubtitle
{
public:
- TextTextDecoder (boost::shared_ptr<const TextTextContent>, boost::shared_ptr<Log> log);
+ TextTextDecoder (boost::shared_ptr<const PlainText>, boost::shared_ptr<Log> log);
void seek (ContentTime time, bool accurate);
bool pass ();
diff --git a/src/lib/text_file.h b/src/lib/text_file.h
index 346571fc1..8cf0d3eae 100644
--- a/src/lib/text_file.h
+++ b/src/lib/text_file.h
@@ -29,7 +29,7 @@
class TextFileContent;
class text_file_time_test;
class text_file_coordinate_test;
-class text_text_content_test;
+class plain_text_content_test;
class text_file_parse_test;
class TextFile
diff --git a/src/lib/text_subtitle.cc b/src/lib/text_subtitle.cc
index 35acb9022..35801e160 100644
--- a/src/lib/text_subtitle.cc
+++ b/src/lib/text_subtitle.cc
@@ -21,7 +21,7 @@
#include "text_subtitle.h"
#include "cross.h"
#include "exceptions.h"
-#include "text_text_content.h"
+#include "plain_text_content.h"
#include <sub/subrip_reader.h>
#include <sub/ssa_reader.h>
#include <sub/collect.h>
@@ -39,7 +39,7 @@ using boost::scoped_array;
using boost::optional;
using dcp::Data;
-TextSubtitle::TextSubtitle (shared_ptr<const TextTextContent> content)
+TextSubtitle::TextSubtitle (shared_ptr<const PlainText> content)
{
Data in (content->path (0));
diff --git a/src/lib/text_subtitle.h b/src/lib/text_subtitle.h
index 0cd33c9fb..60571a439 100644
--- a/src/lib/text_subtitle.h
+++ b/src/lib/text_subtitle.h
@@ -26,16 +26,16 @@
#include <boost/shared_ptr.hpp>
#include <vector>
-class TextTextContent;
+class PlainText;
class text_subtitle_time_test;
class text_subtitle_coordinate_test;
-class text_text_content_test;
+class plain_text_content_test;
class text_subtitle_parse_test;
class TextSubtitle
{
public:
- explicit TextSubtitle (boost::shared_ptr<const TextTextContent>);
+ explicit TextSubtitle (boost::shared_ptr<const PlainText>);
boost::optional<ContentTime> first () const;
ContentTime length () const;
diff --git a/src/lib/wscript b/src/lib/wscript
index 4a7132e48..b3e04e28b 100644
--- a/src/lib/wscript
+++ b/src/lib/wscript
@@ -135,8 +135,8 @@ sources = """
text_content.cc
text_decoder.cc
text_subtitle.cc
- text_text_content.cc
- text_text_decoder.cc
+ plain_text_content.cc
+ plain_text_decoder.cc
timer.cc
transcode_job.cc
types.cc
diff --git a/src/wx/content_panel.cc b/src/wx/content_panel.cc
index 2c0f35f6c..225ac5d6b 100644
--- a/src/wx/content_panel.cc
+++ b/src/wx/content_panel.cc
@@ -39,7 +39,7 @@
#include "lib/config.h"
#include "lib/log.h"
#include "lib/compose.hpp"
-#include "lib/text_text_content.h"
+#include "lib/plain_text_content.h"
#include "lib/text_subtitle.h"
#include <wx/wx.h>
#include <wx/notebook.h>
@@ -258,11 +258,11 @@ ContentPanel::selection_changed ()
BOOST_FOREACH (shared_ptr<Content> i, selected ()) {
DCPTime p;
p = i->position();
- if (dynamic_pointer_cast<TextTextContent>(i) && i->paths_valid()) {
+ if (dynamic_pointer_cast<PlainText>(i) && i->paths_valid()) {
/* Rather special case; if we select a text subtitle file jump to its
first subtitle.
*/
- TextSubtitle ts (dynamic_pointer_cast<TextTextContent>(i));
+ TextSubtitle ts (dynamic_pointer_cast<PlainText>(i));
if (ts.first()) {
p += DCPTime(ts.first().get(), _film->active_frame_rate_change(i->position()));
}
diff --git a/src/wx/subtitle_appearance_dialog.cc b/src/wx/subtitle_appearance_dialog.cc
index f78ed9ab5..eb13a8f27 100644
--- a/src/wx/subtitle_appearance_dialog.cc
+++ b/src/wx/subtitle_appearance_dialog.cc
@@ -20,7 +20,7 @@
#include "subtitle_appearance_dialog.h"
#include "rgba_colour_picker.h"
-#include "lib/text_text_content.h"
+#include "lib/plain_text_content.h"
#include "lib/text_content.h"
#include "lib/ffmpeg_subtitle_stream.h"
#include "lib/ffmpeg_content.h"
diff --git a/src/wx/subtitle_panel.cc b/src/wx/subtitle_panel.cc
index da7891ca8..3308f40e9 100644
--- a/src/wx/subtitle_panel.cc
+++ b/src/wx/subtitle_panel.cc
@@ -26,10 +26,10 @@
#include "fonts_dialog.h"
#include "subtitle_appearance_dialog.h"
#include "lib/ffmpeg_content.h"
-#include "lib/text_text_content.h"
+#include "lib/plain_text_content.h"
#include "lib/ffmpeg_subtitle_stream.h"
#include "lib/dcp_text_content.h"
-#include "lib/text_text_decoder.h"
+#include "lib/plain_text_decoder.h"
#include "lib/dcp_text_decoder.h"
#include "lib/dcp_content.h"
#include "lib/text_content.h"
@@ -265,7 +265,7 @@ SubtitlePanel::setup_sensitivity ()
BOOST_FOREACH (shared_ptr<Content> i, sel) {
/* These are the content types that could include subtitles */
shared_ptr<const FFmpegContent> fc = boost::dynamic_pointer_cast<const FFmpegContent> (i);
- shared_ptr<const TextTextContent> sc = boost::dynamic_pointer_cast<const TextTextContent> (i);
+ shared_ptr<const PlainText> sc = boost::dynamic_pointer_cast<const PlainText> (i);
shared_ptr<const DCPContent> dc = boost::dynamic_pointer_cast<const DCPContent> (i);
shared_ptr<const DCPTextContent> dsc = boost::dynamic_pointer_cast<const DCPTextContent> (i);
if (fc) {
diff --git a/src/wx/subtitle_view.cc b/src/wx/subtitle_view.cc
index 7efe10d0c..eb63ca443 100644
--- a/src/wx/subtitle_view.cc
+++ b/src/wx/subtitle_view.cc
@@ -18,13 +18,13 @@
*/
-#include "lib/text_text_decoder.h"
+#include "lib/plain_text_decoder.h"
#include "lib/content_subtitle.h"
#include "lib/video_decoder.h"
#include "lib/audio_decoder.h"
#include "lib/film.h"
#include "lib/config.h"
-#include "lib/text_text_content.h"
+#include "lib/plain_text_content.h"
#include "subtitle_view.h"
#include "film_viewer.h"
#include "wx_util.h"
diff --git a/src/wx/timing_panel.cc b/src/wx/timing_panel.cc
index 315ead524..67a659685 100644
--- a/src/wx/timing_panel.cc
+++ b/src/wx/timing_panel.cc
@@ -29,7 +29,7 @@
#include "lib/text_content.h"
#include "lib/dcp_text_content.h"
#include "lib/audio_content.h"
-#include "lib/text_text_content.h"
+#include "lib/plain_text_content.h"
#include "lib/video_content.h"
#include <dcp/locale_convert.h>
#include <boost/foreach.hpp>