我正在尝试创建一个聊天气泡,就像 viber、whatsapp 和 facebook 聊天一样。请看这个截图:
最后一个气泡没有箭头。我想知道这些气泡是 9 补丁图像还是以编程方式制作的东西。我在谷歌上搜索了一段时间,但我无法准确找到这张图片,尽管它在许多应用程序(viber、whatsapp)中都是一样的。
我的第二个问题是,如何在气泡中创建显示消息是否已送达的底线。它是一个内部带有 Html.fromHtml() 的 ImageButton(底线)吗?它是带有两个 TextView 的 LinearLayout 吗?
我也在搜索这些 ✓✓。 Viber和WhatsApp有一样的,不过好像不是utf。也许是图片?
谢谢。
最佳答案
I am wondering if those bubbles are a 9-patch images or something which is made programmatically
气泡(带箭头和不带箭头)是 9-patch 。
My second question is, how do I create that bottom line in the bubbles which shows if the message has been delivered.
此气泡底部的消息状态是一个 ImageView
,它从没有 ✓ 变为带有一个 ✓ 的图像,然后当消息到达接收者时显示两个 ✓✓ 图像。
关于android - 像 whatsapp、viber、facebook 聊天这样的气泡,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21460657/