{"id":13643688,"url":"https://github.com/GitLqr/LQRNineGridImageView","last_synced_at":"2025-04-21T02:31:05.794Z","repository":{"id":144672732,"uuid":"81042653","full_name":"GitLqr/LQRNineGridImageView","owner":"GitLqr","description":"仿微信群头像九宫格控件","archived":false,"fork":false,"pushed_at":"2017-04-10T13:19:11.000Z","size":370,"stargazers_count":137,"open_issues_count":3,"forks_count":29,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-02T13:22:46.591Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":false,"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/GitLqr.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}},"created_at":"2017-02-06T03:08:07.000Z","updated_at":"2024-11-16T05:00:33.000Z","dependencies_parsed_at":"2024-01-14T11:12:23.657Z","dependency_job_id":"4efbca7b-57c3-4d96-bb60-6312158324be","html_url":"https://github.com/GitLqr/LQRNineGridImageView","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitLqr%2FLQRNineGridImageView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitLqr%2FLQRNineGridImageView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitLqr%2FLQRNineGridImageView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitLqr%2FLQRNineGridImageView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GitLqr","download_url":"https://codeload.github.com/GitLqr/LQRNineGridImageView/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249986048,"owners_count":21356314,"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-08-02T01:01:51.309Z","updated_at":"2025-04-21T02:31:00.783Z","avatar_url":"https://github.com/GitLqr.png","language":"Java","funding_links":[],"categories":["ImageView"],"sub_categories":[],"readme":"# LQRNineGridImageView\n\n## ***一、简介：***\n参照[Android 仿微信群聊头像](http://blog.csdn.net/loften_93663469/article/details/51227541)文章学习开发的一个仿微信群头像九宫格控件，感谢博主Loften_93663469。\n\n效果如下:\n\n![image](screenshots/1.png)\n\n## ***二、使用：***\n### 1、在自己项目中添加本项目依赖：\n\n\tcompile 'com.lqr.ninegridimageview:library:1.0.0'\n\n### 2、布局中使用：\n\n\t\u003ccom.lqr.ninegridimageview.LQRNineGridImageView\n        android:id=\"@+id/ngiv8\"\n        android:layout_width=\"110dp\"\n        android:layout_height=\"110dp\"\n        android:layout_below=\"@id/ngiv5\"\n        android:layout_margin=\"2dp\"\n        android:layout_toRightOf=\"@id/ngiv7\"\n        android:background=\"#eeeeee\"\n        app:imgGap=\"12dp\"/\u003e\n\napp:imgGap=\"12dp\"指头像间距，默认是8px。\n\n### 3、代码中使用：\n#### 1)设置适配器：\n    LQRNineGridImageViewAdapter adapter = new LQRNineGridImageViewAdapter\u003cString\u003e() {\n        @Override\n        protected void onDisplayImage(Context context, ImageView imageView, String s) {\n            ImageLoaderManager.LoadNetImage(s, imageView);\n        }\n\n        //重写该方法自定义生成ImageView方式，用于九宫格头像中的一个个图片控件，可以设置ScaleType等属性\n        @Override\n        protected ImageView generateImageView(Context context) {\n            return super.generateImageView(context);\n        }\n    };\n\tmNgiv1.setAdapter(adapter);\n#### 2)设置数据源：\n\tList\u003cString\u003e mData1 = new ArrayList\u003c\u003e();\n\t...\n\t填充数据\n\t...\n\tmNgiv1.setImagesData(mData1);//会重画控件，使用适配器加载图片，所以要先设置适配器\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGitLqr%2FLQRNineGridImageView","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FGitLqr%2FLQRNineGridImageView","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGitLqr%2FLQRNineGridImageView/lists"}