Suppress horizontal scrolling with trailing blanks
The existing behavior of EditText is that trailing blanks can cause a line to exceed the layout width, causing the cursor to extend past the line, which in turn causes horizontal scrolling. This patch clamps the cursor to the layout width in the non-scrolling case, which makes the spaces effectively invisible when they're at the end of the line, but at least suppresses the scrolling. The clamping only works reliably in left-to-right alignments, so this patch checks for than and only enables the clamping in those cases. Fix for bug 7699295. Change-Id: I22bc4e6c9ded3d7716edfcf10dd2b5c31a5da9de
Loading
Please register or sign in to comment