AAAh cool didnt now about Spanned extends CharSequence... Cool! On Aug 4, 4:03 pm, Mark Murphy <mmur...@commonsware.com> wrote: > On Wed, Aug 4, 2010 at 9:58 AM, TjerkW <tje...@gmail.com> wrote: > > I basically want a widget which has a simlar layout as the twitter > > widget like this > > > [AUTHOR] [TWEET text bla bla > > bla balb albalbalbal bla bla] > > > As you can see the tweet text nicely wraps around the AUTHOR element. > > This can be done with one TextView using the following method: > >http://developer.android.com/guide/appendix/faq/commontasks.html#sele... > > > The problem is that its a widget and i only have access to the ui > > elements using the RemoteViews: > >http://developer.android.com/reference/android/widget/RemoteViews.html > > > I was thinking of using a layout manager for this, but its impossible > > because textviews are always rectangular. > > > So how do i do this? > > Step #1: Use string concatenation to put the author and tweet in a > single String (or SpannedString created from Html.fromHtml(), or > whatever). > > Step #2: Call setTextViewText() on your RemoteViews > > -- > Mark Murphy (a Commons > Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy > > _The Busy Coder's Guide to Android Development_ Version 3.1 Available!
-- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en