{"id":21823485,"url":"https://github.com/limedroid/tagedittext","last_synced_at":"2025-10-06T17:03:04.846Z","repository":{"id":217102628,"uuid":"71860850","full_name":"limedroid/TagEditText","owner":"limedroid","description":"Text control for displaying tags.","archived":false,"fork":false,"pushed_at":"2016-12-19T11:06:09.000Z","size":82,"stargazers_count":153,"open_issues_count":1,"forks_count":18,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-27T18:21:21.904Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/limedroid.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-10-25T04:55:14.000Z","updated_at":"2025-03-23T08:41:46.000Z","dependencies_parsed_at":null,"dependency_job_id":"cf376ccd-9d6b-42ee-9b93-145964641b0d","html_url":"https://github.com/limedroid/TagEditText","commit_stats":null,"previous_names":["limedroid/tagedittext"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/limedroid%2FTagEditText","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/limedroid%2FTagEditText/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/limedroid%2FTagEditText/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/limedroid%2FTagEditText/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/limedroid","download_url":"https://codeload.github.com/limedroid/TagEditText/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248820102,"owners_count":21166600,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-27T17:32:22.205Z","updated_at":"2025-10-06T17:02:59.803Z","avatar_url":"https://github.com/limedroid.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TagEditText，类似微博标签的文本控件\n\n[TagEditText](https://github.com/limedroid/TagEditText)实现了显示类似微博中的活动标签， 其特点是将一段文字中用'#'包裹的部分以特殊的颜色显示，并能进行点击交互。\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/art/tagedittext.png\" alt=\"TagEditText\" /\u003e\n\u003c/p\u003e\n\n## 主要功能\n\n* 自定义包裹符号，如# ... # 或者 * ... *，或者 # ... * ，具体什么符号可以自定义，默认是 # ... #\n* 自定义匹配的标签字体颜色\n* 自定义标签点击事件\n\n## 使用\n\n* Gradle ： **compile 'cn.droidlover:TagEditText:1.0.0''**\n* Github ： [TagEditText](https://github.com/limedroid/TagEditText)\n\n## 说明\n库中主要包括两个控件:\n* TagEditText ：主要用于用户评论的编辑，用户可输入类似#...#的内容。\n* TagTextView ：主要用于显示内容。\n\n## 主要用法\n\n#### TagTextView\n\n```xml\n \u003ccn.droidlover.tagedittext.TagTextView\n        android:id=\"@+id/tagTextView\"\n        android:layout_width=\"match_parent\"\n        android:layout_height=\"wrap_content\"\n        android:padding=\"16dp\"\n        android:textSize=\"14sp\" /\u003e\n```\n在java中\n```java\ntagTextView\n           .tagColor(Color.RED)        //设置标签颜色\n           .tag(\"#\", \"#\");             //设置前后匹配符\n\ntagTextView.setCallback(new TagSpan.Callback\u003cString\u003e() {     //设置标签点击事件\n    @Override\n    public void onClick(String data) {\n        toast(data);\n    }\n})\n\ntagTextView.text(str);                      //设置内容\n```\n\n#### TagEditText\n\n```xml\n\u003ccn.droidlover.tagedittext.TagEditText\n        android:id=\"@+id/tagEditText\"\n        android:layout_width=\"match_parent\"\n        android:hint=\"TagEditText\"\n        android:layout_height=\"wrap_content\"\n        android:layout_marginTop=\"50dp\"\n        android:background=\"@android:color/transparent\"\n        android:padding=\"16dp\"\n        android:textSize=\"14sp\" /\u003e\n```\n\n在java中\n\n```java\ntagEditText\n        .tag(\"#\", \"#\")              //设置前后匹配符\n        .tagColor(Color.BLUE);      //设置标签颜色\ntagEditText.appendText(\"\");              //追加文本\ntagEditText.getTagList();                //获取标签集合\ntagEditText.removeText(\"\");              //删除指定\n```\n\n\n\n\n\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flimedroid%2Ftagedittext","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flimedroid%2Ftagedittext","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flimedroid%2Ftagedittext/lists"}