TKGaugeScale Class Reference
Inherits from | CALayer |
Declared in | TKGaugeScale.h |
Tasks
-
owner
property -
range
property -
fill
property -
stroke
property -
ticks
property -
labels
property -
segments
property -
indicators
property -
– initWithRange:
-
– initWithMinimum:maximum:
-
– valueForPoint:
-
– locationForValue:
-
– textForValue:
-
– addSegment:
-
– removeSegment:
-
– removeSegmentAtIndex:
-
– insertSegment:atIndex:
-
– segmentAtIndex:
-
– removeAllSegments
-
– addIndicator:
-
– removeIndicator:
-
– removeIndicatorAtIndex:
-
– insertIndicator:atIndex:
-
– indicatorAtIndex:
-
– removeAllIndicators
Properties
fill
Defines the scale fill.
@property (nonatomic, strong, nullable) TKFill *fill
Declared In
TKGaugeScale.h
indicators
Contains all the indicators added to the scale.
@property (nonatomic, strong, readonly, nonnull) NSArray<__kindofTKGaugeIndicator*> *indicators
Declared In
TKGaugeScale.h
labels
Instance representing the labels of the scale.
@property (nonatomic, strong, readonly, nonnull) TKGaugeLabels *labels
Declared In
TKGaugeScale.h
owner
Represents the instance of TKGauge that owns this scale.
@property (nonatomic, weak, null_unspecified) TKGauge *owner
Declared In
TKGaugeScale.h
range
Defines the minimum and maximum value of the scale.
@property (nonatomic, strong, nonnull) TKRange *range
Declared In
TKGaugeScale.h
segments
Contains all the segments added to the scale.
@property (nonatomic, strong, readonly, nonnull) NSArray<TKGaugeSegment*> *segments
Declared In
TKGaugeScale.h
Instance Methods
addIndicator:
Adds indicator to the scale.
- (void)addIndicator:(TKGaugeIndicator *__nonnull)indicator
Parameters
- indicator
The indicator to be added.
Declared In
TKGaugeScale.h
addSegment:
Adds segment to the scale.
- (void)addSegment:(TKGaugeSegment *__nonnull)segment
Parameters
- segment
The segment to be added.
Declared In
TKGaugeScale.h
indicatorAtIndex:
Returns indicator from the scale by given index.
- (TKGaugeIndicator *__nullable)indicatorAtIndex:(int)index
Parameters
- index
The index of the indicator to be returned.
Declared In
TKGaugeScale.h
initWithMinimum:maximum:
Initializes scale with minimum and maximum value.
- (instancetype __nonnull)initWithMinimum:(id __nonnull)minimum maximum:(id __nonnull)maximum
Parameters
- minimum
The minimum value of the scale.
- maximum
The maximum value of the scale.
Declared In
TKGaugeScale.h
initWithRange:
Initializes scale with TKRange.
- (instancetype __nonnull)initWithRange:(TKRange *__nonnull)range
Parameters
- range
TKRange instance that defines the minumum and maximum value of the scale.
Declared In
TKGaugeScale.h
insertIndicator:atIndex:
Inserts indicator to the scale at given index.
- (void)insertIndicator:(TKGaugeIndicator *__nonnull)indicator atIndex:(int)index
Parameters
- indicator
The indicator to be added.
- index
The index for the indicator to be insert at.
Declared In
TKGaugeScale.h
insertSegment:atIndex:
Inserts segment to the scale at given index.
- (void)insertSegment:(TKGaugeSegment *__nonnull)segment atIndex:(int)index
Parameters
- segment
The segment to be added.
- index
The index for the segment to be insert at.
Declared In
TKGaugeScale.h
locationForValue:
Returns the screen coordinates of a given value
- (CGFloat)locationForValue:(CGFloat)value
Parameters
- value
The value.
Declared In
TKGaugeScale.h
removeAllIndicators
Removes all indicators from the scale.
- (void)removeAllIndicators
Declared In
TKGaugeScale.h
removeAllSegments
Removes all segments from the scale.
- (void)removeAllSegments
Declared In
TKGaugeScale.h
removeIndicator:
Removes indicator from the scale.
- (void)removeIndicator:(TKGaugeIndicator *__nonnull)indicator
Parameters
- indicator
The indicator to be removed.
Declared In
TKGaugeScale.h
removeIndicatorAtIndex:
Removes indicator from the scale by given index.
- (void)removeIndicatorAtIndex:(int)index
Parameters
- index
The index of the indicator to be removed.
Declared In
TKGaugeScale.h
removeSegment:
Removes segment from the scale.
- (void)removeSegment:(TKGaugeSegment *__nonnull)segment
Parameters
- segment
The segment to be removed.
Declared In
TKGaugeScale.h
removeSegmentAtIndex:
Removes segment from the scale by given index.
- (void)removeSegmentAtIndex:(int)index
Parameters
- index
The index of the segment to be removed.
Declared In
TKGaugeScale.h
segmentAtIndex:
Returns segment from the scale by given index.
- (TKGaugeSegment *__nullable)segmentAtIndex:(int)index
Parameters
- index
The index of the segment to be returned.
Declared In
TKGaugeScale.h