# lrcview **Repository Path**: OpenHarmony1/lrcview ## Basic Information - **Project Name**: lrcview - **Description**: 一个音乐播放器自动滚动歌词组件 - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2022-11-02 - **Last Updated**: 2023-05-04 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # lrcview #### 项目介绍 该组件是一个可关联音乐播放器的自定义歌词组件 #### 项目演示 ![输入图片说明](./screenshot/demo_1.gif) ##### 基础用法 ```java //更多用法请参照Demo代码演示 LrcView({ url: 'https://www.lrcgeci.com/lrcdown/19565.html', curPlayTime: this.curPlayTime, offset: 3, normalTextSize: 14, selectedTextSize: 21, seekTextSize: 16, normalTextColor: '#999999', selectedTextColor: '#339900', seekTextColor: Color.Pink, onSeekPlayTimeCallback: this.onSeekPlayTimeCallback }); ``` #### 接口及属性 | **属性** | **必填** | **说明** | | ------------------------------------ | :------: | --------------------------------------------------------- | | url: String (url,filePath,lrcText只需其一) | 是 | 歌词网络资源地址 | | filePath: String | 是 | 歌词本地路径地址 | | lrcText: String | 是 | 歌词文本 | | curPlayTime: Number | 否 | 当前播放时间,默认0 | | offset: Number | 否 | 歌词最上方可显示的歌词行数,默认2 | | normalTextSize: Number | 否 | 歌词正常字体大小,默认16 | | selectedTextSize: Number | 否 | 歌词选中字体大小,默认20 | | seekTextSize: Number | 否 | 拖拽歌词时选中的歌词字体大小,默认16 | | normalTextColor: (Color,Number,String,Resource) | 否 | 正常歌词字体颜色,默认0x666666 | | selectedTextColor: (Color,Number,String,Resource)| 否 | 歌词选中的字体颜色,默认Color.Blue | | seekTextColor: (Color,Number,String,Resource) | 否 | 拖拽选中的歌词颜色,默认Color.Black | | onSeekPlayTimeCallback: Function | 否 | 拖拽歌词进度回调,(playTime: number) => void | #### 版权和许可信息 ``` 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. ```