forked from daiweilai/DDRichText
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWFTextView.h
More file actions
executable file
·48 lines (35 loc) · 1.19 KB
/
WFTextView.h
File metadata and controls
executable file
·48 lines (35 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
//
// WFTextView.h
// WFCoretext
//
// Created by 阿虎 on 14/10/31.
// Copyright (c) 2014年 tigerwf. All rights reserved.
//
/**
* CTLine 去画
*
*/
#import <UIKit/UIKit.h>
@protocol WFCoretextDelegate <NSObject>
- (void)clickWFCoretext:(NSString *)clickString;
- (void)clickWFCoretext:(NSString *)clickString replyIndex:(NSInteger)index;
@end
@interface WFTextView : UIView
typedef NS_ENUM(NSUInteger, TextType) { //弄一个枚举类型用来更改主题
TextTypeContent = 0,
TextTypeReply
};
@property (nonatomic,strong) NSAttributedString *attrEmotionString;
@property (nonatomic,strong) NSArray *emotionNames;
@property (nonatomic,assign) BOOL isDraw;
@property (nonatomic,assign) BOOL isFold;//是否折叠
@property (nonatomic,strong) NSMutableArray *attributedData;
@property (nonatomic,assign) int textLine;
@property (nonatomic,assign) id<WFCoretextDelegate>delegate;
@property (nonatomic,assign) CFIndex limitCharIndex;//限制行的最后一个char的index
@property (nonatomic,assign) TextType type;
@property (nonatomic,assign) NSInteger replyIndex;
- (void)setOldString:(NSString *)oldString andNewString:(NSString *)newString;
- (int)getTextLines;
- (float)getTextHeight;
@end