简体   繁体   English

如何在 Android socialview 中的 $ 字符上添加提及适配器以及 @?

[英]How to add mention adapter on $ character in Android socialview along with @?

We want to enable tagging feature based on $ character and @ character in Android socialview, with 2 different adapter.我们想在 Android socialview 中启用基于 $ 字符和 @ 字符的标记功能,具有 2 个不同的适配器。 Any idea how can we achieve this.知道我们如何实现这一目标。 Please refer to this link for Android Socialview Android Socialview请参考此链接

https://github.com/hendraanggrian/socialview https://github.com/hendraanggrian/socialview

Take a look at here .看看这里 Line no.行号177 just changing the regex from # to $ should work but there is no direct way of setting it while using their library. 177 只是将正则表达式从 # 更改为 $ 应该可以工作,但是在使用他们的库时没有直接的方法来设置它。 You will have to include the source code directly inside your app and make the change.您必须将源代码直接包含在您的应用程序中并进行更改。

Edit:编辑:

As @Darkman suggested change the code at 183 for mentions.正如@Darkman建议的那样,更改 183 处的代码以进行提及。 @(\\w+) to [@$](\\w+) will do the work. @(\\w+)[@$](\\w+)将完成这项工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在Android中提及localhost - How to mention the localhost in android 如何在SQLITE Android中添加子查询和'IN'? - How to add sub query in SQLITE Android along with 'IN'? 如何在简单的适配器Android中添加多个单词? - How to add multiple words in simple adapter android? 如何在自动完成文本视图中动态添加建议,同时保留字符状态和图像 - How to dynamically add suggestions to autocompletetextview with preserving character status along with images 如何将带有标记的地图添加到android中的适配器项目? - How to add map with marker to adapter item in android? Android RecyclerView:如何将scrollToPosition(0)添加到适配器? - Android RecyclerView: how to add scrollToPosition(0) to Adapter? 如何在Android中将自定义适配器添加到ListView - how to add a Custom adapter to listview in android 如何在android中为An活动提及两个intent过滤器 - How to mention two intent filters for An activity in android 如何在android中的spinner数组适配器中实现添加项目 - how to implement add item in spinner array adapter in android 如何使用自定义适配器在Android列表视图中添加ImageView / TextView? - How to add ImageView/TextView in a Android List view with custom adapter?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM