Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/MacVim/MMCoreTextView.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ NS_ASSUME_NONNULL_BEGIN
// NSFontChanging methods
//
- (void)changeFont:(nullable id)sender;
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
- (NSFontPanelModeMask)validModesForFontPanel:(NSFontPanel *)fontPanel;
#endif

//
// NSMenuItemValidation
Expand Down
2 changes: 2 additions & 0 deletions src/MacVim/MMCoreTextView.m
Original file line number Diff line number Diff line change
Expand Up @@ -1355,13 +1355,15 @@ - (void)changeFont:(id)sender
}
}

#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_14
- (NSFontPanelModeMask)validModesForFontPanel:(NSFontPanel *)fontPanel
{
// Lets the user pick only the font face / size, as other properties as not
// useful. Still enable text/document colors as these affect the preview.
// Otherwise it could just be white text on white background in the preview.
return NSFontPanelModesMaskStandardModes & (~NSFontPanelModeMaskAllEffects | NSFontPanelModeMaskTextColorEffect | NSFontPanelModeMaskDocumentColorEffect);
}
#endif

/// Specifies whether the menu item should be enabled/disabled.
- (BOOL)validateMenuItem:(NSMenuItem *)item
Expand Down
12 changes: 12 additions & 0 deletions src/MacVim/MacVim.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@
#ifndef MAC_OS_X_VERSION_10_14
# define MAC_OS_X_VERSION_10_14 101400
#endif
#ifndef MAC_OS_X_VERSION_10_15
# define MAC_OS_X_VERSION_10_15 101500
#endif
#ifndef MAC_OS_VERSION_11_0
# define MAC_OS_VERSION_11_0 110000
#endif
Expand All @@ -55,13 +58,19 @@
#ifndef MAC_OS_VERSION_14_0
# define MAC_OS_VERSION_14_0 140000
#endif
#ifndef MAC_OS_VERSION_15_0
# define MAC_OS_VERSION_15_0 150000
#endif

#ifndef NSAppKitVersionNumber10_10
# define NSAppKitVersionNumber10_10 1343
#endif
#ifndef NSAppKitVersionNumber10_10_Max
# define NSAppKitVersionNumber10_10_Max 1349
#endif
#ifndef NSAppKitVersionNumber10_11
# define NSAppKitVersionNumber10_11 1404
#endif
#ifndef NSAppKitVersionNumber10_12
# define NSAppKitVersionNumber10_12 1504
#endif
Expand All @@ -74,6 +83,9 @@
#ifndef NSAppKitVersionNumber10_14
# define NSAppKitVersionNumber10_14 1671
#endif
#ifndef NSAppKitVersionNumber10_15
# define NSAppKitVersionNumber10_15 1894
#endif
#ifndef NSAppKitVersionNumber11_0
# define NSAppKitVersionNumber11_0 2022
#endif
Expand Down
Loading