{"id":16683398,"url":"https://github.com/ac-alpha/numberpickerview","last_synced_at":"2026-04-27T19:03:15.427Z","repository":{"id":69335007,"uuid":"129299218","full_name":"ac-alpha/NumberPickerView","owner":"ac-alpha","description":"Simple number picker (increment/decrement)","archived":false,"fork":false,"pushed_at":"2018-04-13T15:12:18.000Z","size":138,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-12-27T04:48:59.042Z","etag":null,"topics":["android-ui","customview"],"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/ac-alpha.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2018-04-12T19:06:34.000Z","updated_at":"2018-04-14T14:36:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"d903124c-0b40-4c0f-86a0-2ac26b626753","html_url":"https://github.com/ac-alpha/NumberPickerView","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ac-alpha/NumberPickerView","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ac-alpha%2FNumberPickerView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ac-alpha%2FNumberPickerView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ac-alpha%2FNumberPickerView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ac-alpha%2FNumberPickerView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ac-alpha","download_url":"https://codeload.github.com/ac-alpha/NumberPickerView/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ac-alpha%2FNumberPickerView/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32350245,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T17:12:42.749Z","status":"ssl_error","status_checked_at":"2026-04-27T17:12:41.658Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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-ui","customview"],"created_at":"2024-10-12T14:24:23.844Z","updated_at":"2026-04-27T19:03:15.412Z","avatar_url":"https://github.com/ac-alpha.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NumberIncDecView\nThis app demonstrates creation of a simple custom view for picking numbers by incrementing or decrementing. The NumberPickerView also demonstrates how to add custom attributes to your custom view.\n\n## Usage\nTo use this library, include the following code in your app's build.gradle file\n```\nallprojects {\n\t\trepositories {\n\t\t\t...\n\t\t\tmaven { url 'https://jitpack.io' }\n\t\t}\n\t}\n```\nand\n```\ndependencies {\n\t        compile 'com.github.ac-alpha:NumberPickerView:1.0'\n\t}\n```\n\n## Understanding the code\nThe NumberIncDecView.java class inherits from the LinearLayout class. The data items value and onlyPositive specify the current value of displayed number and whether it is positive only or may take negative values.\n\nThe init() function takes TypedArray as parameter which is used to extract the attribute values from the xml file.\n\n\n```\nprivate void init(@Nullable AttributeSet attrs) {\n\n        plusButton = (Button) findViewById(R.id.btn_plus);\n        plusButton.setOnClickListener(new OnClickListener() {\n            @Override\n            public void onClick(View view) {\n                upDateUI(1);\n            }\n        });\n        minusButton = (Button)findViewById(R.id.btn_minus);\n        minusButton.setOnClickListener(new OnClickListener() {\n            @Override\n            public void onClick(View view) {\n                upDateUI(2);\n            }\n        });\n        valueText=(EditText)findViewById(R.id.edit_text);\n        valueText.setText(Integer.toString(value));\n\n        TypedArray ta = getContext().obtainStyledAttributes(attrs, R.styleable.NumberPickerView);\n\n        onlyPositive=ta.getBoolean(R.styleable.NumberPickerView_onlyPositive,true);\n        ta.recycle();\n\n    }\n```\n\nNew attributes are added to the NumberIncDecView class by adding a attrs.xml resource file in the values directory\n\n```xml\n\u003cresources\u003e\n    \u003cdeclare-styleable name=\"NumberIncDecView\"\u003e\n        \u003cattr name=\"onlyPositive\" format=\"boolean\"/\u003e\n    \u003c/declare-styleable\u003e\n\u003c/resources\u003e\n```\n\n## Licence\nThis project is licensed under the Apache 2.0 License - see the [LICENSE.md](LICENSE.md) file for details\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fac-alpha%2Fnumberpickerview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fac-alpha%2Fnumberpickerview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fac-alpha%2Fnumberpickerview/lists"}