Files
yuyin_ios/SweetParty/主类/Others/NewTools/UILabel+ChangeSpace.h

45 lines
999 B
C
Raw Normal View History

2025-08-08 11:05:33 +08:00
//
// UILabel+ChangeSpace.h
// romantic
//
// Created by bj_szd on 2022/4/9.
// Copyright © 2022 romantic. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface UILabel (ChangeSpace)
- (void)topAlignment;
- (void)bottomAlignment;
/**
*
*/
+ (void)changeLineSpaceForLabel:(UILabel *)label WithSpace:(float)space;
/**
*
*/
+ (void)changeWordSpaceForLabel:(UILabel *)label WithSpace:(float)space;
/**
*
*/
+ (void)changeSpaceForLabel:(UILabel *)label withLineSpace:(float)lineSpace WordSpace:(float)wordSpace;
/**
label文字中某段文字的颜色
label label
oneW
size
*/
- (void)LabelAttributedString:(UILabel*)label firstW:(NSString *)oneW size:(CGFloat)size;
+ (CGFloat)textHeight:(NSString *)text font:(UIFont *)font width:(CGFloat)width lineSpace:(CGFloat)lineSpace;
@end
NS_ASSUME_NONNULL_END