diff --git a/Easydict/objc/Service/Model/EZError.m b/Easydict/objc/Service/Model/EZError.m index 51d3daa95..da7318ad8 100644 --- a/Easydict/objc/Service/Model/EZError.m +++ b/Easydict/objc/Service/Model/EZError.m @@ -85,6 +85,13 @@ + (instancetype)errorWithType:(EZErrorType)type } NSString *queryFailedString = NSLocalizedString(@"query_failed", nil); + /** + FIXME: If the first character of the text is an emoji, like "💥 失败", NSTextView will render spaces incorrectly. + I don't know how to fix it, so I'm inserting an invisible special character at the beginning. + */ + NSString *zeroWidthSpace = @"\u200B"; + queryFailedString = [zeroWidthSpace stringByAppendingString:queryFailedString]; + if (errorString.length) { errorString = [NSString stringWithFormat:@"%@, %@", queryFailedString, errorString]; }