Added explanatory comment

This commit is contained in:
Tom Bogle 2018-05-31 16:40:30 -04:00
parent cabff25ae1
commit 186c1b2f65

View file

@ -44,6 +44,10 @@ NSRange _previousSelRange;
// This is the public initializer.
- (instancetype)initWithClient:(NSString *)clientAppId {
// Note: Pages and Keynote (and possibly lots of other undiscovered apps that are otherwise compliant
// with Apple's IM faramework) need to be treated as "legacy" because if the user selects a different
// font (or other formatting) and then types a sequence that causes characters to be added to the document
// and then subsequently replaced, the replacement causes the formatting decision to be forgotten.
BOOL legacy = ([clientAppId isEqual: @"com.apple.iWork.Pages"] ||
[clientAppId isEqual: @"com.apple.iWork.Keynote"] ||
[clientAppId isEqual: @"com.github.atom"] ||