StarryStars is iOS GUI library for displaying and editing ratings
StarryStars' RatingView
is both IBDesignable
and IBInspectable
You can change any of the following properties right in the interface builder:
And see the result right away:
To add RatingView to your Storyboard/.xib file just drag a generic UIView from palette, then in "Custom Class" section of identity inspector set class to RatingView
cd
to your project foldertouch Cartfile
(if you don't have one yet)nano Cartfile
github "peterprokop/StarryStars" == 2.0.0
into Cartfilectrl-x, y, enter
carthage update
Carthage/Build/iOS
to your projectimport StarryStars
on top of your view controller's codeJust clone and add StarryStars
directory to your project.
pod --version
sudo gem install cocoapods
pod init
in you project root dirnano Podfile
, add:pod 'StarryStars', '~> 2.0.0'
use_frameworks!
ctrl-x
, y
, enter
pod update
.xcworkspace
import StarryStars
!swift-2.2
branch)Swift:
let rvRightToLeft = RatingView()
rvRightToLeft.frame = view.bounds
view.addSubview(rvRightToLeft)
rvRightToLeft.editable = true
rvRightToLeft.delegate = self
// RatingView will respect setting this property
rvRightToLeft.semanticContentAttribute = .forceRightToLeft
Objective C:
RatingView* rvRightToLeft = [[RatingView alloc] init];
rvRightToLeft.frame = self.view.bounds;
[self.view addSubview:rvRightToLeft];
rvRightToLeft.editable = YES;
rvRightToLeft.delegate = self;
// RatingView will respect setting this property
rvRightToLeft.semanticContentAttribute = UISemanticContentAttributeForceRightToLeft;
SwiftOverlays - Swift GUI library for displaying various popups and notifications.