-
Notifications
You must be signed in to change notification settings - Fork 58
Open
Labels
Description
构造如下markdown内容:
|模块|子模块|功能|状态|优先级|
|---|---|---|---|---|
|用户管理|登录|用户名密码登录|已完成|P0|
|用户管理|登录|第三方登录|进行中|P1|
|用户管理|注册|邮箱注册|已完成|P0|
|用户管理|注册|手机号注册|待开始|P1|
|消息管理|发送|文本消息|已完成|P0|
|消息管理|发送|图片消息|进行中|P1|
|消息管理|接收|Markdown渲染|已完成|P0|
|消息管理|接收|内容1<br>内容2<br>内容3|已完成|P0|
|消息管理|接收|**加粗内容**|已完成|P0|
|消息管理|接收|*斜体内容*|已完成|P0|
|消息管理|接收|`行内代码`|已完成|P0| 在
- (void)parser:(CMParser *)parser foundInlineCode:(NSString *)code
{
[self.attributeStack pushAttributes:_attributes.inlineCodeAttributes];
if(code && [code length] > 0)
{
NSString* codeStr = [NSString stringWithFormat:@"\u00A0%@\u00A0", code];
[self appendString:codeStr];
NSDictionary* spaceAttr = @{NSKernAttributeName:@(6),NSFontAttributeName:[UIFont systemFontOfSize:2.f]};
[self.buffer addAttributes:spaceAttr range:NSMakeRange(self.buffer.length - codeStr.length, 1)];
[self.buffer addAttributes:spaceAttr range:NSMakeRange(self.buffer.length - 1, 1)];
}
[self.attributeStack pop];
}中,此时buffer内容为空,会发生越界错误,导致无法正常渲染显示。
Reactions are currently unavailable