Skip to content

Commit 545bd21

Browse files
committed
Use setFont: directly
1 parent 92dd6ba commit 545bd21

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

src/MacVim/MMCoreTextView.m

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -147,18 +147,13 @@ - (id)initWithFrame:(NSRect)frame
147147
}
148148
cgLayerLock = [NSLock new];
149149

150-
// NOTE! It does not matter which font is set here, Vim will set its
151-
// own font on startup anyway. Just set some bogus values.
152-
font = [[NSFont userFixedPitchFontOfSize:0] retain];
153-
fontDescent = ceil(CTFontGetDescent((CTFontRef)font));
154-
cellSize.width = cellSize.height = 1;
155-
156150
// NOTE: If the default changes to 'NO' then the intialization of
157151
// p_antialias in option.c must change as well.
158152
antialias = YES;
159153

160154
drawData = [[NSMutableArray alloc] init];
161155
fontCache = [[NSMutableArray alloc] init];
156+
[self setFont:[NSFont userFixedPitchFontOfSize:0]];
162157

163158
helper = [[MMTextViewHelper alloc] init];
164159
[helper setTextView:self];

0 commit comments

Comments
 (0)