Closed GoogleCodeExporter closed 9 years ago
OG String: "%d guide"
Decoded: <b>%d</b> guide
Rebuilt then Decoded: &lt;b>%d&lt;/b> guide
Yep another problem, even though I think the guidelines say not to do this.
#391 was suppose to fix this. Will add this as another unit-test and fix.
Original comment by connor.tumbleson
on 24 Jul 2014 at 6:45
Shouldn't the unit test added as part of issue #608 already cover this?
WRT the guidelines, the "Styling with HTML markup" section at [1] basically has
the same example, saying
Store your styled text resource as an HTML-escaped string:
<string name="welcome_messages">Hello, %1$s! You have <b>%2$d new messages</b>.</string>
So using basic HTML text formatting like , <i> and <u> is fine at least in a
regular string resource, so I guess it's fine for plurals, too.
The only other difference to my example is that I've also escaped the closing
">" to ">", but while not required this should be fine also. I think it's also
fine that apktool decodes my original ">" to ">" here as escaping it is
optional in the first place.
[1] http://developer.android.com/guide/topics/resources/string-resource.html
Original comment by sschuberth
on 24 Jul 2014 at 7:40
Original comment by connor.tumbleson
on 2 Oct 2014 at 7:18
https://github.com/iBotPeaches/Apktool/commit/f9f59bff2234d8ae3a88f00e182e4949bb
96d2f9
Fixed.
Original comment by connor.tumbleson
on 3 Mar 2015 at 9:44
Original issue reported on code.google.com by
sschuberth
on 22 Jul 2014 at 3:14