mirror of
https://codeberg.org/fairyglade/ly.git
synced 2026-08-19 03:54:20 +02:00
config: address review feedback for show_tty
- Move show_tty field to correct alphabetical position in Config.zig (after show_password_key, before shutdown_cmd) - Add blank line before tty_label_width for readability
This commit is contained in:
parent
84b4f6d097
commit
62464b19c8
2 changed files with 2 additions and 1 deletions
|
|
@ -84,6 +84,7 @@ service_name: [:0]const u8 = "ly",
|
|||
session_log: ?[]const u8 = "ly-session.log",
|
||||
setup_cmd: []const u8 = build_options.config_directory ++ "/ly/setup.sh",
|
||||
show_password_key: []const u8 = "F7",
|
||||
show_tty: bool = false,
|
||||
shutdown_cmd: []const u8 = "/sbin/shutdown -a now",
|
||||
shutdown_key: []const u8 = "F1",
|
||||
sleep_cmd: ?[]const u8 = null,
|
||||
|
|
@ -92,7 +93,6 @@ start_cmd: ?[]const u8 = null,
|
|||
text_in_center: bool = false,
|
||||
vi_default_mode: ViMode = .normal,
|
||||
vi_mode: bool = false,
|
||||
show_tty: bool = false,
|
||||
waylandsessions: ?[]const u8 = build_options.prefix_directory ++ "/share/wayland-sessions",
|
||||
x_cmd: []const u8 = build_options.prefix_directory ++ "/bin/X",
|
||||
x_vt: ?u8 = null,
|
||||
|
|
|
|||
|
|
@ -1941,6 +1941,7 @@ fn positionWidgets(ptr: *anyopaque) !void {
|
|||
.add(TerminalBuffer.START_POSITION)
|
||||
.addYFromIf(state.brightness_up_label.childrenPosition(), !state.config.hide_key_hints)
|
||||
.removeYFromIf(state.edge_margin, !state.config.hide_key_hints));
|
||||
|
||||
const tty_label_width = if (state.config.show_tty) TerminalBuffer.strWidth(state.tty_label.text) else 0;
|
||||
const tty_label_gap = if (state.config.show_tty and state.config.clock != null) @as(usize, 1) else 0;
|
||||
state.tty_label.positionXY(state.edge_margin
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue