From b5099e3cd36e3f5892573bf706f6ff6c698c8e3a Mon Sep 17 00:00:00 2001 From: Chris Guillott Date: Sun, 19 Nov 2017 15:25:25 -0500 Subject: [PATCH] tweak manpage; make keylayout turn the clock on --- i3lock.1 | 15 +++++++++++++++ i3lock.c | 2 ++ 2 files changed, 17 insertions(+) diff --git a/i3lock.1 b/i3lock.1 index fdfc4bf..f84a97b 100644 --- a/i3lock.1 +++ b/i3lock.1 @@ -125,6 +125,21 @@ Images may still be overlaid over the blurred screenshot. .B \-\-indicator Forces the indicator to always be visible, instead of only showing on activity. +.TP +.B \-\-keylayout mode +Displays the keylayout. Modes are as follows: +.RS +.RS + +0 - Displays the full string returned by the query, i.e. "English (US)" + +1 - Displays up until the first parenthesis, i.e. "English" + +2 - Displays just the contents of the parenthesis, i.e. "US" + +.RE +.RE + .TP .B \-\-composite Some compositors have problems with i3lock trying to render over them, so this argument is disabled by default. However, some will work properly with it, so it's been left enabled. diff --git a/i3lock.c b/i3lock.c index bd94baf..9f5b431 100644 --- a/i3lock.c +++ b/i3lock.c @@ -1271,6 +1271,8 @@ int main(int argc, char *argv[]) { // if not NULL, attempt to display stuff // need to code some sane defaults for it layout_text = get_keylayoutname(atoi(optarg)); + if (layout_text) + show_clock = true; } else if (strcmp(longopts[longoptind].name, "timestr") == 0) { //read in to timestr