| Index: sky/sdk/lib/framework/rendering/paragraph.dart
|
| diff --git a/sky/sdk/lib/framework/rendering/paragraph.dart b/sky/sdk/lib/framework/rendering/paragraph.dart
|
| index c4b9a88727e67b25385a43a4841e2550a8e7f7bb..16caee3a9d99b5ef995d21a043bd51961bdbe8e1 100644
|
| --- a/sky/sdk/lib/framework/rendering/paragraph.dart
|
| +++ b/sky/sdk/lib/framework/rendering/paragraph.dart
|
| @@ -67,6 +67,21 @@ class TextStyle {
|
| value = 37 * value + textAlign.hashCode;
|
| return value;
|
| }
|
| +
|
| + String toString([String prefix = '']) {
|
| + List<String> result = [];
|
| + if (color != null)
|
| + result.add('${prefix}color: $color');
|
| + if (fontSize != null)
|
| + result.add('${prefix}fontSize: $fontSize');
|
| + if (fontWeight != null)
|
| + result.add('${prefix}fontWeight: fontWeight');
|
| + if (textAlign != null)
|
| + result.add('${prefix}textAlign: textAlign');
|
| + if (result.isEmpty)
|
| + return '${prefix}<no style specified>';
|
| + return result.join('\n');
|
| + }
|
| }
|
|
|
| // Unfortunately, using full precision floating point here causes bad layouts
|
| @@ -196,5 +211,5 @@ class RenderParagraph extends RenderBox {
|
|
|
| // we should probably expose a way to do precise (inter-glpyh) hit testing
|
|
|
| - String debugDescribeSettings(String prefix) => '${super.debugDescribeSettings(prefix)}${prefix}color: ${color}\n${prefix}text: ${text}\n';
|
| + String debugDescribeSettings(String prefix) => '${super.debugDescribeSettings(prefix)}${prefix}style:\n${style.toString("$prefix ")}\n${prefix}text: ${text}\n';
|
| }
|
|
|