| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #library('bidi_utils'); | 5 #library('bidi_utils'); |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * Bidi stands for Bi-directional text. | 8 * Bidi stands for Bi-directional text. |
| 9 * According to http://en.wikipedia.org/wiki/Bi-directional_text: | 9 * According to http://en.wikipedia.org/wiki/Bi-directional_text: |
| 10 * Bi-directional text is text containing text in both text directionalities, | 10 * Bi-directional text is text containing text in both text directionalities, |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 | 388 |
| 389 /** | 389 /** |
| 390 * Check the directionality of [str], return true if the piece of | 390 * Check the directionality of [str], return true if the piece of |
| 391 * text should be laid out in RTL direction. If [isHtml] is true, the string | 391 * text should be laid out in RTL direction. If [isHtml] is true, the string |
| 392 * is HTML or HTML-escaped. | 392 * is HTML or HTML-escaped. |
| 393 */ | 393 */ |
| 394 static bool detectRtlDirectionality(String str, [bool isHtml]) { | 394 static bool detectRtlDirectionality(String str, [bool isHtml]) { |
| 395 return estimateDirection(str, isHtml) == TextDirection.RTL; | 395 return estimateDirection(str, isHtml) == TextDirection.RTL; |
| 396 } | 396 } |
| 397 } | 397 } |
| OLD | NEW |