Broken build.
Should the Paint fields be made public or should the SpanStringBuilder
method be hidden ???
Change-Id: I8ecea19104357ea53ad53b23d02a707ec422161d
These were added in 99657 by using a misconfigured eclipse
save action that adds @Overirde to interfaces (Java 1.6 only).
Change-Id: I766bbde917b0bb063cb6d588ee276787e2f7db66
* commit 'b732b7b5e8192501360edc15fb8c6399d11fb97d':
GpsLocationProvider: Clean up HAL initialization/cleanup sequence
Fixed GSM encoded network initiated position request
Ensuring thread-safe usage of DateFormat.
Fixing infinite loop for zero duration.
Fix for an infinite loop while scrolling lists.
WAPPushManager, WAP Push over SMS message handler
Add --non-constant-id to aapt.
* commit 'ce57a7f35344e76689d30f45964d1e37b78280cb':
GpsLocationProvider: Clean up HAL initialization/cleanup sequence
Fixed GSM encoded network initiated position request
Ensuring thread-safe usage of DateFormat.
Fixing infinite loop for zero duration.
Fix for an infinite loop while scrolling lists.
WAPPushManager, WAP Push over SMS message handler
Add --non-constant-id to aapt.
DateFormat is inherently unsafe for multithreaded use. This patch adds
proper synchronization. The 'sLock' is re-used. To avoid two consecutive
lockings, locked version of initFormatStrings() method is created and
used where appropriate, i.e. in original method AND in added synchronized
block.
Change-Id: Id3c34613623e743e703aadb2342aa788679dda8a
Bug 3422121
With ellipsize, lines starting with a very long word that does not
fit inside the width were simply ignored. Cut the long word instead.
start - widthStart index offset shift in BiDi.
The original ellipsize-end patch that added '...' after the last
word on end-ellipsized lines has been punted in favor of a true
ellipsize support in I.
I believe the StaticLayout calculateEllipsise is a no-op since textwidth <= avail
by construction: fitWidth and okwidth are < outerWidth. The only exception is the
paraEnd != here case in generate (when not a single character fits in width).
This case is exercised by StaticLayoutTest in cts (width of 8 pixels) and revealed
an offset error in widstart.
All in all, it looks like this code was probably never really tested. I tried some
typical text configuration to make sure these changes improved the situation.
Change-Id: Ibee410bd7db453abf93e10e8beb844eae998922c
- remove unused local variables
- add char constants
- some variables renaming to be more understandable
Change-Id: Id54dd671b1449cca6463bf77160dc72c8bf0c805
Bug 3261766
If defined, the drawable is used instead of directly drawing a 1 pixel
line. This makes the cursor more fancy and more visible.
The drawable is currently clipped by the TextView's limits, which is
currently visible on the left when the cursor is at the first position.
To solve this issue properly, we would need to propagate a do-not-clip
up in the hierarchy.
Change-Id: I99f6001048eed14104994acf6bab942dda8eb38e
Bug 3295544
Only the last line of text includes the bottomPadding (extra line
spacing below the characters' descent. When The text is clipped using
maxLines, the desired height correctly added this value, but getLineTop
and getLineDescent are also used when the layout is drawn.
The fix is to make the layout aware of its clipping so that these
values are correctly updated.
Change-Id: I703656cf45022d34a90f55f0ed8fc5e4b30f80b1
Bug 3400770
TextUtils#commaEllipsize creates a MeasuredText "mt" object with the
text to be ellipsized. It calls setPara which initializes mt's mPos
member to be 0. It then calls addStyleRun which moves mPos to the end
of the string. The loop back in commaEllipsize then calls mt addStyleRun
again and this causes IndexOutOfBoundsException, because the paint
object is trying to measure text past the text's length.
It seems this was a typo and that the tempMt variable should be used,
because the code is trying to measure the format string...not the
the string to be ellipsized. This makes the saner parts of CTS test
for this method pass now.
Change-Id: Ib6aa6e4bbd6afff4c95ad4c4d51a384cc1389875
Bug 3381368
The 250 characters limit is passed for long URLs. There are only 3
TextLine objects, so their total size is not an issue. Recycle long
lines as well to make sure we fill the cache and avoid object creation.
Change-Id: I843bf623594312a0fcf0edbb13b7cd64cce0ddd1
Bug:3085564
Bug:3196224
Bug:3321608
Remove Touch.getMaxScrollX(), which is incorrect for my
purpose, and is not used anywhere else. Instead use the
layout to determine the maximum horizontal scroll of a
textfield.
Now that textareas use layers, scroll the layer's picture
in the UI thread for vertical movement. When passing a
click to webcore, also pass a message to scroll the actual
textarea so the click will be in the correct place.
Lastly, do not override bringPointIntoView, which allows
moving the insertion handler beyond the edge of a field to
scroll it. Instead, override requestRectangleOnScreen to
do nothing, since my actual goal is to prevent the TextView
from changing the scroll of the WebView, which is done by
webkit.
Requires a change to external/webkit.
Change-Id: Ib91907599b792287c373d3678cb04e0cb5e34471
In the LengthFilter make sure that we do not cut the
string so a last emoji character gets broken and replaced
by some garbage character.
We need to check if the last char is the high surrogate and
if so drop the high surrogate also.
Change-Id: I210e7e41aa0761ecbb2b32e3ebf680a04382c287
Anyone calling this method is probably storing IP addresses
in an int, which doesn't make sense anymore.
Change-Id: Iba535b66f6cff47ce07b5ecc6427e3b2fd846998
Bug 3322607
Re-applying the revert that fixed the ANR (https://android-git.corp.google.com/g/#change,87129),
whith an updated here value that seems to fix the problem.
This layout code is pretty involved, with destabilizing variable names and
uses. Althought I tested it, this fix is not 100% garanteed.
Change-Id: I1f4b09b329fb8a328ae8ab26ae472e343453beda
- Tweak Fragment docs to match new sample code.
- Make some new attributes public.
- Hide all of the XmlAdapter stuff, since it is not actually being used.
Change-Id: Iae2062f91d1ca0c6b1d656ae948417d3d048482f
This reverts commit 32ea4ffdca.
This change introduces an ANR in AutoComplete text view. There is
an infinite loop when the suggestion TextView is measured.
Reverted to fix the ANR, opening a new bug for the ellipsize.
Bug 3315813, 3320375, 3318059
Change-Id: I1872116ca1f39324ed4500d338bafac7e0d195ec