{"id":13641920,"url":"https://github.com/Andy671/PianoChartView","last_synced_at":"2025-04-20T12:30:58.405Z","repository":{"id":202248703,"uuid":"80018331","full_name":"Andy671/PianoChartView","owner":"Andy671","description":"Elementary and clean Android PianoView for displaying piano chord/scale charts in music theory apps for pianists.","archived":false,"fork":false,"pushed_at":"2017-12-28T20:57:14.000Z","size":122,"stargazers_count":55,"open_issues_count":0,"forks_count":12,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-04-13T02:42:43.166Z","etag":null,"topics":["android","android-library","java","music-theory-apps","piano-chords","piano-keyboard","pianoview","scale-charts","view","xml"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Andy671.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}},"created_at":"2017-01-25T13:46:13.000Z","updated_at":"2024-07-19T16:54:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"479eed91-5685-4392-a9f9-07dbf518ade2","html_url":"https://github.com/Andy671/PianoChartView","commit_stats":null,"previous_names":["andy671/pianochartview"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FPianoChartView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FPianoChartView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FPianoChartView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Andy671%2FPianoChartView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Andy671","download_url":"https://codeload.github.com/Andy671/PianoChartView/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249893360,"owners_count":21341435,"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":["android","android-library","java","music-theory-apps","piano-chords","piano-keyboard","pianoview","scale-charts","view","xml"],"created_at":"2024-08-02T01:01:25.713Z","updated_at":"2025-04-20T12:30:58.388Z","avatar_url":"https://github.com/Andy671.png","language":"Java","readme":"# Piano Chart View\n[![](https://jitpack.io/v/Andy671/PianoChartView.svg)](https://jitpack.io/#Andy671/PianoChartView)\n[![](https://img.shields.io/badge/minSDK-15-brightgreen.svg)](https://developer.android.com/training/basics/supporting-devices/platforms.html)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n\n## Introduction\nElementary and clean Android View for displaying piano chord and scale charts in music theory apps for pianists.\n\n## Sample\n![](http://i.giphy.com/vuaHfrpkTbwOc.gif)\n\n## Installation\n\n### Step 1\nAdd the JitPack repository to your build file\n```gradle\n\tallprojects {\n\t\trepositories {\n\t\t\t...\n\t\t\tmaven { url 'https://jitpack.io' }\n\t\t}\n\t}\n```\n\n### Step 2\nAdd the dependency\n```gradle\n\tdependencies {\n\t\tcompile 'com.github.Andy671:PianoChartView:v0.6.6'\n\t}\n```\n\n# Usage\n### Creating from xml:\n\nIn your \u003cb\u003elayout.xml\u003c/b\u003e\n```xml\nxmlns:custom=\"http://schemas.android.com/apk/res-auto\"\n```\n\n```xml\n\u003c!-- Custom arguments are optional - if you don't override them it uses default values --\u003e\n \u003ccom.kekstudio.pianochartview.PianoChartView\n        android:id=\"@+id/piano_chart_view\"\n        android:layout_width=\"wrap_content\"\n        android:layout_height=\"wrap_content\"\n\n       \tcustom:checkedKeysColor=\"@android:color/white\"\n       \tcustom:lightKeysColor=\"@color/colorCustomLight\"\n        custom:darkKeysColor=\"@color/colorCustomDark\"\n        custom:size=\"Small\"\n        custom:checkedKeys=\"@array/some_integer_array\"/\u003e\n```\nIn your \u003cb\u003earrays.xml\u003c/b\u003e\n```xml\n\u003c!-- Numbers = keys on keyboard --\u003e\n    \u003cinteger-array name=\"some_integer_array\"\u003e\n        \u003citem\u003e5\u003c/item\u003e\n        \u003citem\u003e7\u003c/item\u003e\n        \u003citem\u003e11\u003c/item\u003e\n        \u003citem\u003e1\u003c/item\u003e\n    \u003c/integer-array\u003e\n```\n\nIn your \u003cb\u003ecolors.xml\u003c/b\u003e\n```xml\n    \u003ccolor name=\"colorCustomLight\"\u003e#C8E6C9\u003c/color\u003e\n    \u003ccolor name=\"colorCustomDark\"\u003e#1B5E20\u003c/color\u003e\n```\n\n### Editing from code:\n```java\n \tPianoChartView pianoChartView = (PianoChartView) findViewById(R.id.piano_chart_view_small);\n\tpianoChartView.setCheckedKeys(new int[]{2, 5, 3, 8, 11, 12});\n\tpianoChartView.setSize(PianoChartView.Size.Small);\n\tpianoChartView.setLightKeysColor(Color.parseColor(\"#CFD8DC\"));\n\tpianoChartView.setDarkKeysColor(Color.parseColor(\"#607D8B\"));\n\tpianoChartView.setCheckedKeysColor(Color.parseColor(\"#B2EBF2\"));\n```\n\nSee sample for more info\n\n## XML Attributes\n| Attribute        | Type                | Default      |\n| -----------------|:-------------------:| :------------|\n| lightKeysColor   | color               | Color.WHITE  |\n| darkKeysColor    | color               | Color.DKGRAY |\n| checkedKeysColor | color               | #03A9F4      |\n| additionalCheckedKeysColor | color     | #03A9F4      |\n| checkedKeys      | reference (int[])   | { }          |\n| additionalCheckedKeys      | reference (int[])   | { }          |\n| namesOfKeys      | reference (String[])   | { }          |\n| size             | enum [Large, Small] | Large        |\n\n\n## Public methods\n| Type          | Method                          |\n|--------------------- |--------------------------------|\n| void          | setCheckedKeys(int[] numbers)   |\n| void          | setAdditionalCheckedKeys(int[] numbers)   |\n| void          | setNamesOfKeys(String... keyLetters)  |\n| void          | setSize(Size size)              |\n| void          | setLightKeysColor(int color)    |\n| void          | setDarkKeysColor(int color)     |\n| void          | setCheckedKeysColor(int color)  |\n| void          | setAdditionalCheckedKeysColor(int color)  |\n| int[]         | getCheckedKeys()                |\n| int[]         | getAdditionalCheckedKeys()                |\n| Size          | getSize()                       |\n| int           | getLightKeysColor()             |\n| int           | getDarkKeysColor()              |\n| int           | getCheckedKeysColor()           |\n| int           | getAdditionalCheckedKeysColor()           |\n\n\n## Contribution\n- Feel free to fork the repo, make pull requests or fix existing bug\n- Feel free to open issues if you find some bug or unexpected behaviour\n","funding_links":[],"categories":["图表(Chart)"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAndy671%2FPianoChartView","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FAndy671%2FPianoChartView","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAndy671%2FPianoChartView/lists"}