{"id":13396230,"url":"https://github.com/grantland/android-autofittextview","last_synced_at":"2025-05-14T14:04:38.819Z","repository":{"id":1388197,"uuid":"1364139","full_name":"grantland/android-autofittextview","owner":"grantland","description":"A TextView that automatically resizes text to fit perfectly within its bounds.","archived":false,"fork":false,"pushed_at":"2019-01-12T23:57:12.000Z","size":1190,"stargazers_count":4269,"open_issues_count":60,"forks_count":689,"subscribers_count":106,"default_branch":"master","last_synced_at":"2025-04-11T18:21:40.162Z","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":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/grantland.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2011-02-14T06:00:52.000Z","updated_at":"2025-04-11T09:20:44.000Z","dependencies_parsed_at":"2022-08-02T10:34:54.342Z","dependency_job_id":null,"html_url":"https://github.com/grantland/android-autofittextview","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantland%2Fandroid-autofittextview","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantland%2Fandroid-autofittextview/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantland%2Fandroid-autofittextview/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grantland%2Fandroid-autofittextview/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/grantland","download_url":"https://codeload.github.com/grantland/android-autofittextview/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254159169,"owners_count":22024558,"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-07-30T18:00:42.740Z","updated_at":"2025-05-14T14:04:38.772Z","avatar_url":"https://github.com/grantland.png","language":"Java","readme":"# AutoFitTextView\n\n[![Maven Central](https://maven-badges.herokuapp.com/maven-central/me.grantland/autofittextview/badge.svg?style=flat)](https://maven-badges.herokuapp.com/maven-central/me.grantland/autofittextview)\n\nA TextView that automatically resizes text to fit perfectly within its bounds.\n\n![Example Image](/website/static/autofittextview.gif?raw=true)\n\n\n## Usage\n\n```cson\ndependencies {\n    compile 'me.grantland:autofittextview:0.2.+'\n}\n```\n\nEnable any View extending TextView in code:\n\n```java\nAutofitHelper.create(textView);\n```\n\nEnable any View extending TextView in XML:\n\n```xml\n\u003cme.grantland.widget.AutofitLayout\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"wrap_content\"\n    \u003e\n    \u003cButton\n        android:layout_width=\"match_parent\"\n        android:layout_height=\"wrap_content\"\n        android:singleLine=\"true\"\n        /\u003e\n\u003c/me.grantland.widget.AutofitLayout\u003e\n```\n\nUse the built in Widget in code or XML:\n```xml\n\u003cRootElement\n    xmlns:autofit=\"http://schemas.android.com/apk/res-auto\"\n    ...\n```   \n\n```xml\n\u003cme.grantland.widget.AutofitTextView\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"wrap_content\"\n    android:singleLine=\"true\"\n    android:maxLines=\"2\"\n    android:textSize=\"40sp\"\n    autofit:minTextSize=\"16sp\"\n    /\u003e\n```\n\n\n## License\n\n    Copyright 2014 Grantland Chew\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n","funding_links":[],"categories":["Index `(light-weight pages)`","TextView","Index","Libs"],"sub_categories":["\u003cA NAME=\"Widget\"\u003e\u003c/A\u003eWidget"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrantland%2Fandroid-autofittextview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrantland%2Fandroid-autofittextview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrantland%2Fandroid-autofittextview/lists"}