You should have received a copy of the GNU General Public License
along with libdcp. If not, see <http://www.gnu.org/licenses/>.
+ In addition, as a special exception, the copyright holders give
+ permission to link the code of portions of this program with the
+ OpenSSL library under certain conditions as described in each
+ individual source file, and distribute linked combinations
+ including the two.
+
+ You must obey the GNU General Public License in all respects
+ for all of the code used other than OpenSSL. If you modify
+ file(s) with this exception, you may extend this exception to your
+ version of the file(s), but you are not obligated to do so. If you
+ do not wish to do so, delete this exception statement from your
+ version. If you delete this exception statement from all source
+ files in the program, then also delete it here.
*/
#include "raw_convert.h"
#include "text_node.h"
#include "subtitle_string.h"
#include "dcp_assert.h"
-#include "AS_DCP.h"
-#include "KM_util.h"
+#include <asdcp/AS_DCP.h>
+#include <asdcp/KM_util.h>
#include <libxml++/nodes/element.h>
#include <boost/algorithm/string.hpp>
#include <boost/shared_array.hpp>
#include <boost/foreach.hpp>
-#include <fstream>
using std::string;
using std::list;
-using std::ostream;
-using std::ofstream;
-using std::stringstream;
using std::cout;
using std::cerr;
using std::map;
effective_font.id,
effective_font.italic.get_value_or (false),
effective_font.bold.get_value_or (false),
+ effective_font.underline.get_value_or (false),
effective_font.colour.get_value_or (dcp::Colour (255, 255, 255)),
effective_font.size,
effective_font.aspect_adjust.get_value_or (1.0),
string const xmlns = standard == SMPTE ? "dcst" : "";
- /* XXX: script, underlined not supported */
+ /* XXX: script not supported */
optional<string> font;
bool italic = false;
bool bold = false;
+ bool underline = false;
Colour colour;
int size = 0;
float aspect_adjust = 1.0;
font != i.font() ||
italic != i.italic() ||
bold != i.bold() ||
+ underline != i.underline() ||
colour != i.colour() ||
size != i.size() ||
fabs (aspect_adjust - i.aspect_adjust()) > ASPECT_ADJUST_EPSILON ||
font = i.font ();
italic = i.italic ();
bold = i.bold ();
+ underline = i.underline ();
colour = i.colour ();
size = i.size ();
aspect_adjust = i.aspect_adjust ();
font_element->set_attribute ("EffectColor", effect_colour.to_argb_string());
font_element->set_attribute ("Script", "normal");
if (standard == SMPTE) {
- font_element->set_attribute ("Underline", "no");
+ font_element->set_attribute ("Underline", underline ? "yes" : "no");
} else {
- font_element->set_attribute ("Underlined", "no");
+ font_element->set_attribute ("Underlined", underline ? "yes" : "no");
}
font_element->set_attribute ("Weight", bold ? "bold" : "normal");
}