GQRatingView
五星评分RatingView,支持拖拽点击评分,可自定义五角星样式,支持链式调用。
Install / Use
/learn @g763007297/GQRatingViewREADME
GQRatingView
五星评分RatingView,支持拖拽点击评分,过渡动画平滑,可自定义五角星样式和颜色,支持链式调用。
Overview

CocoaPods
1.在 Podfile 中添加 pod 'GQRatingView'。
2.执行 pod install 或 pod update。
3.导入 GQRatingView.h。
Basic usage
1.下载 GQRatingView 文件夹内的所有.h和.m文件。
2.将 GQRatingView 内的源文件添加(拖放)到你的工程。
3.在需要用到的地方引用头文件 GQRatingView.h。
4.添加代码:
//链式调用
[GQRatingView init]
.frameChain(CGPointMake(50, 100),50)
.canTouchChain(YES)
.needIntValueChain(YES)
.scoreNumChain(@5)
.scroreBlockChain(^(NSNumber *scoreNumber){
NSLog(@"%@",scoreNumber);
}).superViewChain(self.view);
//普通用法
GQRatingView *fiveStar = [GQRatingView initWithPoint:CGPointMake(50, 100) withSize:50];
fiveStar.canTouch = YES;//设置可以触摸
fiveStar.needIntValue = NO;//设置不需要整数分数
fiveStar.scoreNum = [NSNumber numberWithInt:5];//设置初始化分数
fiveStar.scoreBlock = ^(float number){//返回的分数
NSLog(@"%.1f",number);
};
[self.view addSubview:fiveStar];
##Support
欢迎指出bug或者需要改善的地方,欢迎提出issues、加Q群交流iOS经验:578841619 , 我会及时的做出回应,觉得好用的话不妨给个star吧,你的每个star是我持续维护的强大动力。
Related Skills
node-connect
351.8kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
110.9kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
351.8kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
351.8kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
