Android布局绕过带文本的图像

时间:2010-11-29 23:37:15

标签: android layout

我想实现文本和图像的android布局,如左图所示,但是使用ImageSpan和内嵌图像到开头的文本只给出了右图中的内容。

是否有任何解决方案可以通过文本精美地绕过大图像?

|-------------| texttexttexttexttext   |-------------| 
|             | texttexttexttexttext   |             | 
|   image     | texttexttexttexttext   |   image     | 
|             | texttexttexttexttext   |             |
|-------------| texttexttexttexttext   |-------------| texttexttexttexttext
texttexttexttexttexttexttexttexttext    texttexttexttexttexttexttexttexttext
texttexttexttexttexttexttexttexttext    texttexttexttexttexttexttexttexttext
texttexttexttexttexttexttexttexttext    texttexttexttexttexttexttexttexttext
|

1 个答案:

答案 0 :(得分:2)

可以使用WebView并编写HTML代码。将HTML插入带有Html.fromHtml(String, Html.ImageGetter, Html.TagHandler)的TextView也可能是可行的。请参阅使用ImageGetter here的示例。