You should be able to do it by subclassing ReplacementSpan:
http://developer.android.com/reference/android/text/style/ReplacementSpan.html
... which lets you do the drawing yourself, rather than modifying a
TextPaint.
-- Kostya
20.11.2011 8:24, Jay пишет:
I have actually already considered that. The StrikethruSpan class just
sets the strikethru bit on the Paint that is passed through it; there
does not seem to be a separate field for strikethru color.
Unfortunately, I cannot find any documentation of the entry points
that custom Spans have available to modify the drawing process, so I
don't know how to implement custom-colored strikethru "by hand". I
will continue to chase through the source, but would appreciate any
insight anyone can provide as to how the Span classes interact with
the text.
Jay
On Nov 19, 9:41 pm, Zsolt Vasvari<[email protected]> wrote:
Get the source code for the class that implements strikethru and
modiify it to your liking.
On Nov 20, 4:43 am, Jay<[email protected]> wrote:
Is it possible to to create a span of text in a textview in which the
strikethru line is a different color than the text. I cannot find much
documentation on the SpannableString interface.
Thanks,
Jay
--
Kostya Vasilyev
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en