From 0c35d513f852d40d8c6c382e2750373b57afe0cd Mon Sep 17 00:00:00 2001
From: Vitaly Takmazov
Date: Mon, 12 Nov 2018 15:06:33 +0300
Subject: Fix quote line breaks
---
Juick/Supporting Files/Juick-Info.plist | 2 +-
Juick/Views/MessageCell.m | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
(limited to 'Juick')
diff --git a/Juick/Supporting Files/Juick-Info.plist b/Juick/Supporting Files/Juick-Info.plist
index 75e1360..a7b5d3c 100644
--- a/Juick/Supporting Files/Juick-Info.plist
+++ b/Juick/Supporting Files/Juick-Info.plist
@@ -21,7 +21,7 @@
CFBundleSignature
????
CFBundleVersion
- 81
+ 82
ITSAppUsesNonExemptEncryption
LSApplicationCategoryType
diff --git a/Juick/Views/MessageCell.m b/Juick/Views/MessageCell.m
index 99fb296..f9c9746 100644
--- a/Juick/Views/MessageCell.m
+++ b/Juick/Views/MessageCell.m
@@ -73,7 +73,10 @@
}
self.text.attributedText = nil;
if (msg.text) {
- NSMutableAttributedString *txt = [[NSMutableAttributedString alloc] initWithString:[msg.text stringByDecodingHTMLEntities] attributes:@{NSFontAttributeName:[UIFont preferredFontForTextStyle:UIFontTextStyleBody]}];
+ NSMutableAttributedString *txt = [[NSMutableAttributedString alloc]
+ initWithString:
+ [[msg.text stringByDecodingHTMLEntities] stringByReplacingOccurrencesOfString:@"\n" withString:@"\r\n"]
+ attributes:@{NSFontAttributeName:[UIFont preferredFontForTextStyle:UIFontTextStyleBody]}];
[txt beginEditing];
for (NSDictionary *entity in msg.entities) {
NSUInteger start = [[entity objectForKey:@"start"] unsignedIntegerValue];
--
cgit v1.2.3