{"id":13640507,"url":"https://github.com/lingochamp/MagicProgressWidget","last_synced_at":"2025-04-20T02:33:57.089Z","repository":{"id":57726244,"uuid":"47830059","full_name":"lingochamp/MagicProgressWidget","owner":"lingochamp","description":"MagicProgressCircle \u0026 MagicProgressBar","archived":false,"fork":false,"pushed_at":"2018-08-08T12:08:57.000Z","size":1014,"stargazers_count":727,"open_issues_count":7,"forks_count":145,"subscribers_count":23,"default_branch":"master","last_synced_at":"2024-04-29T01:03:39.371Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://blog.dreamtobe.cn/2015/12/13/magic_progress_widget/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lingochamp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-12-11T14:08:10.000Z","updated_at":"2024-04-18T09:51:28.000Z","dependencies_parsed_at":"2022-09-26T16:40:16.099Z","dependency_job_id":null,"html_url":"https://github.com/lingochamp/MagicProgressWidget","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lingochamp%2FMagicProgressWidget","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lingochamp%2FMagicProgressWidget/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lingochamp%2FMagicProgressWidget/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lingochamp%2FMagicProgressWidget/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lingochamp","download_url":"https://codeload.github.com/lingochamp/MagicProgressWidget/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223816628,"owners_count":17207890,"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:11.844Z","updated_at":"2024-11-09T10:31:19.434Z","avatar_url":"https://github.com/lingochamp.png","language":"Java","readme":"# MagicProgressWidget\n\n[![Download][bintray_svg]][bintray_link]\n[![Build Status][build_status_svg]][build_status_link]\n\n\u003e 渐变的圆形进度条与轻量横向进度条\n\n## I. 最终效果\n\n![demo gif][demo_gif]\n\n## II. 如何使用\n\n`build.gradle`中配置:\n\n```\nimplementation 'com.liulishuo.magicprogresswidget:library:1.1.1'\n```\n\n\u003e 建议参考github中的demo\n\n```\n\u003ccom.liulishuo.magicprogresswidget.MagicProgressCircle\n    android:id=\"@+id/demo_mpc\"\n    android:layout_width=\"@dimen/mpc_size\"\n    android:layout_height=\"@dimen/mpc_size\"\n    app:mpc_percent=\"0.8\"\n    app:mpc_start_color=\"@color/mpc_start_color\"\n    app:mpc_end_color=\"@color/mpc_end_color\"\n    app:mpc_stroke_width=\"@dimen/mpc_stroke_width\"\n    app:mpc_default_color=\"@color/mpc_default_color\"/\u003e\n\n\u003ccom.liulishuo.magicprogresswidget.MagicProgressBar\n    android:id=\"@+id/demo_2_mpb\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"@dimen/mpb_height\"\n    app:mpb_fill_color=\"@color/mpb_color\"\n    app:mpb_background_color=\"@color/mpb_default_color\"\n    app:mpb_flat=\"true\"/\u003e\n```\n\n#### 1. Magic Progress Circle\n\n- 支持平滑过渡: `setSmoothPercent(percent:float):void`\n- 支持指定时间的平滑过渡: `setSmoothPercent(percent:float, durationMillis:long):void`\n\n| 参数 | 含义 | 默认值 |\n| :--- | :--- | :--- |\n| mpc_percent | 填充的百分比[0, 1] | 0 |\n| mpc_stroke_width | 描边宽度 | 18dp |\n| mpc_start_color | 渐变颜色起点颜色(percent=0) | \u003cfont color=\"#FF00FFED\"\u003e#FF00FFED\u003c/font\u003e |\n| mpc_end_color | 渐变颜色终点颜色(percent=1) | \u003cfont color=\"#FFED00FF\"\u003e#FFED00FF\u003c/font\u003e |\n| mpc_default_color | 未填充部分的描边的颜色 | \u003cfont color=\"#1AFFFFFF\"\u003e#1AFFFFFF\u003c/font\u003e |\n| mpc_foot_over_head | 结尾的圆弧是否覆盖开始的圆弧 | false |\n\n#### 2. Magic Progress Bar\n\n\u003e 相比系统的ProgressBar更加轻量，如果你的ProgressBar要求不是很复杂，推荐使用\n\n- 支持平滑过渡: `setSmoothPercent(percent:float):void`\n- 支持指定时间的平滑过渡: `setSmoothPercent(percent:float, durationMillis:long):void`\n\n| 参数 | 含义 | 默认值 |\n| :--- | :--- | :--- |\n| mpb_percent | 填充的百分比[0, 1] | 0 |\n| mpb_fill_color | 填充进度的颜色 | 0 |\n| mpb_background_color | 进度背景的颜色 | 0 |\n| mpb_flat | 填充的进度条右侧是否是平面(不是平面就是圆弧) | false |\n\n## III. LICENSE\n\n```\nCopyright (c) 2015 LingoChamp Inc.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n   http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n\n[demo_gif]: https://github.com/lingochamp/MagicProgressWidget/raw/master/art/demo.gif\n[bintray_svg]: https://api.bintray.com/packages/jacksgong/maven/MagicProgressWidget/images/download.svg\n[bintray_link]: https://bintray.com/jacksgong/maven/MagicProgressWidget/_latestVersion\n[build_status_svg]: https://travis-ci.org/lingochamp/MagicProgressWidget.svg?branch=master\n[build_status_link]: https://travis-ci.org/lingochamp/MagicProgressWidget\n","funding_links":[],"categories":["进度条"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flingochamp%2FMagicProgressWidget","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flingochamp%2FMagicProgressWidget","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flingochamp%2FMagicProgressWidget/lists"}