@@ -28,6 +28,7 @@ - (instancetype)initWithNumberString:(NSString *)numberString letteringString:(N
2828 if (self = [super init ]) {
2929 _numberString = numberString;
3030 _letteringString = letteringString;
31+ _contentAlpha = 1 .0f ;
3132 [self setUp ];
3233 }
3334
@@ -159,21 +160,21 @@ - (UIImage *)hightlightedBackgroundImage { return self.circleView.highlightedCir
159160
160161- (void )setNumberFont : (UIFont *)numberFont
161162{
162- self.buttonLabel .numberLabel . font = numberFont;
163+ self.buttonLabel .numberLabelFont = numberFont;
163164 [self setNeedsLayout ];
164165}
165166
166- - (UIFont *)numberFont { return self.buttonLabel .numberLabel . font ; }
167+ - (UIFont *)numberFont { return self.buttonLabel .numberLabelFont ; }
167168
168169/* **********************************************************/
169170
170171- (void )setLetteringFont : (UIFont *)letteringFont
171172{
172- self.buttonLabel .letteringLabel . font = letteringFont;
173+ self.buttonLabel .letteringLabelFont = letteringFont;
173174 [self setNeedsLayout ];
174175}
175176
176- - (UIFont *)letteringFont { return self.buttonLabel .letteringLabel . font ; }
177+ - (UIFont *)letteringFont { return self.buttonLabel .letteringLabelFont ; }
177178
178179/* **********************************************************/
179180
@@ -204,4 +205,18 @@ - (void)setTextColor:(UIColor *)textColor
204205 self.buttonLabel .textColor = _textColor;
205206}
206207
208+ /* **********************************************************/
209+
210+ - (void )setContentAlpha : (CGFloat)contentAlpha
211+ {
212+ if (_contentAlpha == contentAlpha) {
213+ return ;
214+ }
215+
216+ _contentAlpha = contentAlpha;
217+
218+ self.buttonLabel .alpha = contentAlpha;
219+ self.circleView .alpha = contentAlpha;
220+ }
221+
207222@end
0 commit comments