# WheelPicker
**Repository Path**: HarmonyOS-tpc/WheelPicker
## Basic Information
- **Project Name**: WheelPicker
- **Description**: WheelPicker: Simple and fantastic wheel view in realistic effect for openharmony.
- **Primary Language**: Unknown
- **License**: Apache-2.0
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 8
- **Forks**: 0
- **Created**: 2021-04-15
- **Last Updated**: 2025-05-18
## Categories & Tags
**Categories**: harmony
**Tags**: None
## README
# WheelPicker
WheelPicker: Simple and fantastic wheel view in realistic effect for openharmony.
WheelPicker includes :
* Cyclically displaying data items
* Setting the number of visible data items.
* Obtaining the selected data item
* Monitoring status of the scroll, obtains the selected items and scrolling parameters after the scrolling stops.
* Dynamically updating data sources
* Setting the current selected text color and the non-selected text color.
* Setting item space
* Displaying indicator and set the indicator's size and color
* Display curtain and set the curtain's color
* Enabling atmospheric effect
* Adding item align
* Adding custom font
# Usage Instructions
WheelPicker can be used by instantiating the layout elements programmatically as shown below :
```
WheelPicker wheelpicker = new WheelPicker(this);
wheelpicker.setCurved(true);
wheelpicker.setCyclic(true);
wheelpicker.setAtmospheric(true);
wheelpicker.setSelectedItemTextColor(Color.BLACK.getValue());
```
This can also be done via xml as shown below :
```
```
Adding WheelDatePicker using xml :
```
```
Adding WheelAreaPicker using xml :
```
```
# Installation Instructions
1.For using WheelPicker module in sample app, include the source code and add the below dependencies in entry/build.gradle to generate hap/wheelpicker.har.
```
dependencies {
implementation project(':wheelpicker')
implementation fileTree(dir: 'libs', include: ['*.jar', '*.har'])
testCompile 'junit:junit:4.12'
}
```
2.For using WheelPicker in separate application using har file, add the har file in the entry/libs folder and add the dependencies in entry/build.gradle file.
```
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar', '*.har'])
testCompile 'junit:junit:4.12'
}
```
3. For using WheelPicker from a remote repository in separate application, add the below dependencies in entry/build.gradle file.
```
dependencies {
implementation fileTree(dir: 'libs', include: ['*.har'])
implementation 'io.openharmony.tpc.thirdlib:WheelPicker:1.0.1'
testCompile 'junit:junit:4.12'
}
```
# License
```
Copyright 2015-2017 AigeStudio
Licensed under the Apache License, Version 2.0 (the "License");you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
```