{"id":15040848,"url":"https://github.com/ladingwu/dimens_sw","last_synced_at":"2025-10-09T06:46:11.859Z","repository":{"id":48185794,"uuid":"137244940","full_name":"ladingwu/dimens_sw","owner":"ladingwu","description":"Android UI适配方案","archived":false,"fork":false,"pushed_at":"2019-06-10T03:16:14.000Z","size":461,"stargazers_count":1756,"open_issues_count":6,"forks_count":390,"subscribers_count":26,"default_branch":"master","last_synced_at":"2025-05-23T07:06:38.559Z","etag":null,"topics":["android","android-app"],"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/ladingwu.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}},"created_at":"2018-06-13T16:51:27.000Z","updated_at":"2025-05-07T07:32:37.000Z","dependencies_parsed_at":"2022-09-12T06:50:38.975Z","dependency_job_id":null,"html_url":"https://github.com/ladingwu/dimens_sw","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ladingwu/dimens_sw","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ladingwu%2Fdimens_sw","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ladingwu%2Fdimens_sw/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ladingwu%2Fdimens_sw/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ladingwu%2Fdimens_sw/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ladingwu","download_url":"https://codeload.github.com/ladingwu/dimens_sw/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ladingwu%2Fdimens_sw/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000855,"owners_count":26082951,"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","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["android","android-app"],"created_at":"2024-09-24T20:45:09.875Z","updated_at":"2025-10-09T06:46:11.845Z","avatar_url":"https://github.com/ladingwu.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"- android ui适配，基于smallestWidth的适配方案\n\n\n\u003e Tips:大部分手机的宽度dp值集中在320-450之间，大部分1080P的手机应该都是360dp，390dp,411dp。可以在这个基础上，参考Android studio中的Virtual Device Configuration\n\n![](https://github.com/ladingwu/dimens_sw/blob/master/tips.jpg)\n\n\n## 使用说明\n- clone该项目到本地,以Android项目打开。\n- DimenTypes文件中写入你希望适配的sw尺寸，默认的这些尺寸能够覆盖几乎所有手机适配需求\n- DimenGenerator文件中填写设计稿的尺寸(DESIGN_WIDTH是设计稿宽度，DESIGN_HEIGHT是设计稿高度)\n- 执行lib module中的DimenGenerator.main()方法，当前地址下会生成相应的适配文件,把相应的文件连带文件夹拷贝到正在开发的项目中\n\n## 希望用真机测试的，可运行app项目看效果(效果如下图)\n\n![](https://github.com/ladingwu/dimens_sw/blob/master/test.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fladingwu%2Fdimens_sw","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fladingwu%2Fdimens_sw","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fladingwu%2Fdimens_sw/lists"}