mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-15 08:16:13 +03:00
config: reorder increase font size so it works on macOS menu
Fixes #1826
This commit is contained in:
@ -1199,18 +1199,21 @@ pub fn default(alloc_gpa: Allocator) Allocator.Error!Config {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Fonts
|
|
||||||
try result.keybind.set.put(
|
|
||||||
alloc,
|
|
||||||
.{ .key = .{ .translated = .equal }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
|
||||||
.{ .increase_font_size = 1 },
|
|
||||||
);
|
|
||||||
// Increase font size mapping for keyboards with dedicated plus keys (like german)
|
// Increase font size mapping for keyboards with dedicated plus keys (like german)
|
||||||
|
// Note: this order matters below because the C API will only return
|
||||||
|
// the last keybinding for a given action. The macOS app uses this to
|
||||||
|
// set the expected keybind for the menu.
|
||||||
try result.keybind.set.put(
|
try result.keybind.set.put(
|
||||||
alloc,
|
alloc,
|
||||||
.{ .key = .{ .translated = .plus }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
.{ .key = .{ .translated = .plus }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
||||||
.{ .increase_font_size = 1 },
|
.{ .increase_font_size = 1 },
|
||||||
);
|
);
|
||||||
|
try result.keybind.set.put(
|
||||||
|
alloc,
|
||||||
|
.{ .key = .{ .translated = .equal }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
||||||
|
.{ .increase_font_size = 1 },
|
||||||
|
);
|
||||||
|
|
||||||
try result.keybind.set.put(
|
try result.keybind.set.put(
|
||||||
alloc,
|
alloc,
|
||||||
.{ .key = .{ .translated = .minus }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
.{ .key = .{ .translated = .minus }, .mods = inputpkg.ctrlOrSuper(.{}) },
|
||||||
|
Reference in New Issue
Block a user