sites

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

commit f4c1c57acc78508fd7c547384a8dd5b45c3f9f49
parent 8d611595d4dfa6822ccea7805c1f8bc4e2d883b3
Author: Marco Fleres <mafleres@gmail.com>
Date:   Fri, 12 Mar 2021 22:53:09 -0300

[dwm][patch] Add to viewontag patch: prevent following window to "all" tag.

Modifies patch viewontag so that tagging a window on all tags does not
enable all of them. There is no need to follow a window that would still be
visible anyways.

Diffstat:
Adwm.suckless.org/patches/viewontag/dwm-viewontag-20210312-61bb8b2.diff | 39+++++++++++++++++++++++++++++++++++++++
Mdwm.suckless.org/patches/viewontag/index.md | 6+++++-
2 files changed, 44 insertions(+), 1 deletion(-)

diff --git a/dwm.suckless.org/patches/viewontag/dwm-viewontag-20210312-61bb8b2.diff b/dwm.suckless.org/patches/viewontag/dwm-viewontag-20210312-61bb8b2.diff @@ -0,0 +1,39 @@ +From 03d3c172ff736cb80e12f7bb7cab4e1f250af9dd Mon Sep 17 00:00:00 2001 +From: Marco Fleres <mafleres@gmail.com> +Date: Fri, 12 Mar 2021 22:25:53 -0300 +Subject: [PATCH] Modification on viewontag patch: windows will not be followed + to the "all" tag + +--- + config.def.h | 1 + + dwm.c | 2 ++ + 2 files changed, 3 insertions(+) + +diff --git a/config.def.h b/config.def.h +index 1c0b587..d7dfb6d 100644 +--- a/config.def.h ++++ b/config.def.h +@@ -5,6 +5,7 @@ static const unsigned int borderpx = 1; /* border pixel of windows */ + static const unsigned int snap = 32; /* snap pixel */ + static const int showbar = 1; /* 0 means no bar */ + static const int topbar = 1; /* 0 means bottom bar */ ++static const Bool viewontag = True; /* Switch view on tag switch */ + static const char *fonts[] = { "monospace:size=10" }; + static const char dmenufont[] = "monospace:size=10"; + static const char col_gray1[] = "#222222"; +diff --git a/dwm.c b/dwm.c +index 664c527..8ca2f98 100644 +--- a/dwm.c ++++ b/dwm.c +@@ -1660,6 +1660,8 @@ tag(const Arg *arg) + selmon->sel->tags = arg->ui & TAGMASK; + focus(NULL); + arrange(selmon); ++ if(viewontag && ((arg->ui & TAGMASK) != TAGMASK)) ++ view(arg); + } + } + +-- +2.30.1 + diff --git a/dwm.suckless.org/patches/viewontag/index.md b/dwm.suckless.org/patches/viewontag/index.md @@ -3,13 +3,17 @@ viewontag Description ----------- -Follow a window to the tag it is being moved to +Follow a window to the tag it is being moved to. + +Patch 20210312 prevents the window being followed if it is being moved to the "all" tag. Download -------- * [dwm-r1522-viewontag.diff](dwm-r1522-viewontag.diff) (dwm r1522) (20100725) +* [dwm-viewontag-20210312-61bb8b2.diff](dwm-viewontag-20210312-61bb8b2.diff) (window will not be followed to the "all" tag) Author ------ * Markus P. - peters\_mops at arcor . de +* Marco Fleres - mafleres at gmail.com (20210312-61bb8b2)