diff --git a/NextcloudTalk/NCChatTitleView.m b/NextcloudTalk/NCChatTitleView.m index 9beea241e..b31dff4a8 100644 --- a/NextcloudTalk/NCChatTitleView.m +++ b/NextcloudTalk/NCChatTitleView.m @@ -153,8 +153,9 @@ - (void)setTitle:(NSString *)title withSubtitle:(NSString *)subtitle [attributedTitle addAttribute:NSParagraphStyleAttributeName value:paragraphStyle range:rangeTitle]; if (self.showSubtitle && subtitle != nil) { - NSMutableAttributedString *attributedSubtitle = [[NSMutableAttributedString alloc] initWithString:subtitle]; - NSRange rangeSubtitle = NSMakeRange(0, [subtitle length]); + NSAttributedString *attributedString = [[NSAttributedString alloc] initWithString:subtitle]; + NSMutableAttributedString *attributedSubtitle = [SwiftMarkdownObjCBridge parseMarkdownWithMarkdownString:attributedString]; + NSRange rangeSubtitle = NSMakeRange(0, [attributedSubtitle length]); [attributedSubtitle addAttribute:NSFontAttributeName value:self.subtitleFont range:rangeSubtitle]; [attributedSubtitle addAttribute:NSForegroundColorAttributeName value:self.titleTextColor range:rangeSubtitle]; [attributedSubtitle addAttribute:NSParagraphStyleAttributeName value:paragraphStyle range:rangeSubtitle]; diff --git a/NextcloudTalk/RoomInfoTableViewController.m b/NextcloudTalk/RoomInfoTableViewController.m index 410d2e3ab..891551c3e 100644 --- a/NextcloudTalk/RoomInfoTableViewController.m +++ b/NextcloudTalk/RoomInfoTableViewController.m @@ -1911,8 +1911,13 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N if (!cell) { cell = [[TextViewTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:TextViewTableViewCell.identifier]; } - - cell.textView.text = _room.roomDescription; + + NSMutableAttributedString *attributedDescription = [[NSMutableAttributedString alloc] initWithString:_room.roomDescription]; + NSRange range = NSMakeRange(0, [attributedDescription length]); + [attributedDescription addAttribute:NSFontAttributeName value:[UIFont preferredFontForTextStyle:UIFontTextStyleBody] range:range]; + [attributedDescription addAttribute:NSForegroundColorAttributeName value:[UIColor labelColor] range:range]; + + cell.textView.attributedText = [SwiftMarkdownObjCBridge parseMarkdownWithMarkdownString:attributedDescription]; cell.selectionStyle = UITableViewCellSelectionStyleDefault; return cell; }