Permalink
Browse files

Item13369: Item13371: Item13372L: encoding fixes. Note that there are…

… certain strings involving entities that cannot be expected to ROUNDTRIP, as the entities get converted unconditionally back to codepoints. While this *could* be changed, it would require significant engineering effort.
  • Loading branch information...
cdot committed Apr 20, 2015
1 parent 390ac7f commit 7f5796f0567395181c8dc58ab050fce118b0af53
@@ -1371,9 +1371,13 @@ sub _checkAfterEmphasis {
sub _verbatim {
my ( $this, $tag, $options ) = @_;
$options |= WC::PROTECTED | WC::BR2NL | WC::KEEP_WS;
# KEEP_ENTITIES for literal and pre
$options |= WC::PROTECTED | WC::KEEP_ENTITIES | WC::BR2NL | WC::KEEP_WS;
my ( $flags, $text ) = $this->_flatten($options);
# Don't do this for literal or sticky
WC::decodeRepresentableEntities($text);
my $p = _htmlParams( $this->{attrs}, $options );
return ( $flags, "<$tag$p>$text</$tag>" );
@@ -2947,12 +2947,16 @@ HTML
TML
},
{
exec => ROUNDTRIP,
exec => TML2HTML,
name => 'entityNamedInsideMacro_Item13369',
tml => <<'TML',
Outside macro &copy; dash &mdash; done
%MAKETEXT{"Copyright &&copy; mdash &&mdash;"}%
TML
html => <<'HTML',
<p> Outside macro &copy; dash &mdash; done <span class='WYSIWYG_PROTECTED'><br />%MAKETEXT{&#34;Copyright&nbsp;&#38;&#38;copy;&nbsp;mdash&nbsp;&#38;&#38;mdash;&#34;}%</span>
</p>
HTML
},
{
exec => TML2HTML | HTML2TML | ROUNDTRIP,

0 comments on commit 7f5796f

Please sign in to comment.