??????????????????????????????????????????л??????????????????????????????????????????????Щ??????????????????б????????????????“???[??Ц]??[????]”???????????????????????????????????????????????????????潫?????????????????????
??????????????IOS?????е???????.plist?? ???????????????TextView?????????????á?
??????????????·????????????????????????????????range?? ?????range??????????е?????????????[????]?? ???[????] ??????.plist??item?μ?chs????????????????????????????????????????????????????????????滻???ɡ???????????????????????????????
????1.????????????????????????????飬?????????????????????????????.plist????????????????????????д洢??????????????????root????????飬?????е?item????????????д??????????????????????????????????????????????????????????????

????2.??δ?.plist????л??????????????bundle???????????·????????????·?????????飬?????д洢????????????е???????????£?
????//????plist????е?????
????NSBundle *bundle = [NSBundle mainBundle];
????//????????·??
????NSString *path = [bundle pathForResource:@"emoticons" ofType:@"plist"];
????//???plist?е?????
????NSArray *face = [[NSArray alloc] initWithContentsOfFile:path];
????3.??????????????????????????????κα??飬?????滻??
????//??????????????????????·???????????????
????NSString *str = @"??[Χ??]??[????]??[????]??[????]??[????]??[??]??[?]??[???]??[?][123456]";
????4.???????str???????????????????????????????????????????TextView???????????????????????????£?
????//????????????????????
????NSMutableAttributedString *attributeString = [[NSMutableAttributedString alloc] initWithString:str];
????5.?????????????????????????????е??Χ???????????????????[/*]??????[123567]????????????????????????????
????//?????????滻????????Χ
????//???????
????NSString * pattern = @"\[[a-zA-Z0-9\u4e00-\u9fa5]+\]";
????NSError *error = nil;
????NSRegularExpression * re = [NSRegularExpression regularExpressionWithPattern:pattern options:NSRegularExpressionCaseInsensitive error:&error];
????if (!re) {
????NSLog(@"%@"?? [error localizedDescription]);
????}
????//????????????????????
????NSArray *resultArray = [re matchesInString:str options:0 range:NSMakeRange(0?? str.length)];