sites

public wiki contents of suckless.org
git clone git://git.suckless.org/sites
Log | Files | Refs

commit dc7a58d5cb4663a675b1f094d3aeb1eb8dae6afa
parent f2441f20a80fcf193173db374efc00065efd35dc
Author: NRK <nrk@disroot.org>
Date:   Wed, 27 Oct 2021 07:56:38 +0600

[dmenu][patch] remove toggle-position

taking Laslo's suggestion, I'll be adding a patch with separate flag instead.

Diffstat:
Dtools.suckless.org/dmenu/patches/toggle-position/dmenu-toggle-position-20210904-d78ff08.patch | 44--------------------------------------------
Dtools.suckless.org/dmenu/patches/toggle-position/index.md | 16----------------
2 files changed, 0 insertions(+), 60 deletions(-)

diff --git a/tools.suckless.org/dmenu/patches/toggle-position/dmenu-toggle-position-20210904-d78ff08.patch b/tools.suckless.org/dmenu/patches/toggle-position/dmenu-toggle-position-20210904-d78ff08.patch @@ -1,44 +0,0 @@ -From 0bd1e230fbae8b2f18bb88fc4f7056645baa9d23 Mon Sep 17 00:00:00 2001 -From: NRK <nrk@disroot.org> -Date: Sun, 15 Aug 2021 22:46:40 +0600 -Subject: [PATCH] turn -b into a toggle - -currently config.h allows users to set the value of topbar to 0. -however if one does that, there's no way for him to get a topbar again. -it makes more sense to have -b as a toggle instead. ---- - dmenu.1 | 2 +- - dmenu.c | 4 ++-- - 2 files changed, 3 insertions(+), 3 deletions(-) - -diff --git a/dmenu.1 b/dmenu.1 -index 323f93c..5c9c488 100644 ---- a/dmenu.1 -+++ b/dmenu.1 -@@ -38,7 +38,7 @@ which lists programs in the user's $PATH and runs the result in their $SHELL. - .SH OPTIONS - .TP - .B \-b --dmenu appears at the bottom of the screen. -+toggle top/bottom position. - .TP - .B \-f - dmenu grabs the keyboard before reading stdin if not reading from a tty. This -diff --git a/dmenu.c b/dmenu.c -index 98507d9..c76b2a0 100644 ---- a/dmenu.c -+++ b/dmenu.c -@@ -716,8 +716,8 @@ main(int argc, char *argv[]) - if (!strcmp(argv[i], "-v")) { /* prints version information */ - puts("dmenu-"VERSION); - exit(0); -- } else if (!strcmp(argv[i], "-b")) /* appears at the bottom of the screen */ -- topbar = 0; -+ } else if (!strcmp(argv[i], "-b")) /* toggle top/bottom position */ -+ topbar = !(topbar); - else if (!strcmp(argv[i], "-f")) /* grabs keyboard before reading stdin */ - fast = 1; - else if (!strcmp(argv[i], "-i")) { /* case-insensitive item matching */ --- -2.33.0 - diff --git a/tools.suckless.org/dmenu/patches/toggle-position/index.md b/tools.suckless.org/dmenu/patches/toggle-position/index.md @@ -1,16 +0,0 @@ -toggle-position -=============== - -Currently config.h allows users to have a default bottom bar by setting the -value of `topbar` to 0. However if one does that, there's no way to get a topbar -again at runtime. - -This patch turns `-b` into a top/bottom toggle, which may be considered more useful. - -Download --------- -* [dmenu-toggle-position-20210904-d78ff08.patch](dmenu-toggle-position-20210904-d78ff08.patch) - -Author ------- -* NRK <nrk@disroot.org>