summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ScriptGroup.java
diff options
context:
space:
mode:
authorMady Mellor <madym@google.com>2015-06-22 16:46:29 -0700
committerMady Mellor <madym@google.com>2015-06-22 16:46:29 -0700
commite264ac392a886788ebfd1069e1d366e2b1edef72 (patch)
treec8bf4a58cb14e1abb41e41e8b6616fc9fb73cd1a /rs/java/android/renderscript/ScriptGroup.java
parentc54bcade1b7ec7e044aca7fe9c60357ad957a8c2 (diff)
Text selection: Fix word boundaries for languages without spaces
WordIterator's getEnd/getBeginning methods does not support the needs for word boundary detection in text selection. Consider the words AABB (where AA and BB are each words). If getEnd is given the offset on the boundary between AA and BB, it would return that offset since it is the end of AA. For text selection we always want the "next end" if available. This CL adds two methods to word iterator that return the next end and previous beginning. This CL also alters the code in Start/EndHandle to use the x value and current / prev line positions to determine if the user is expanding or contracting the selection. Bug: 21305292 Change-Id: I6e7a83e53e245d71e43d78f1957f844f2ed1cdfb
Diffstat (limited to 'rs/java/android/renderscript/ScriptGroup.java')
0 files changed, 0 insertions, 0 deletions