Compare commits
No commits in common. "146d90c9ccf7134277ab65032c2090be0de5d4dd" and "3e790f67f45c8d9a6f627ae7fe0ffe2e8023d71b" have entirely different histories.
146d90c9cc
...
3e790f67f4
73
dwm-flexipatch/'
Normal file
73
dwm-flexipatch/'
Normal file
|
@ -0,0 +1,73 @@
|
|||
# dwm version
|
||||
VERSION = 6.4
|
||||
|
||||
# Customize below to fit your system
|
||||
|
||||
# paths
|
||||
PREFIX = /usr/local
|
||||
MANPREFIX = ${PREFIX}/share/man
|
||||
|
||||
X11INC = /usr/X11R6/include
|
||||
X11LIB = /usr/X11R6/lib
|
||||
|
||||
# FreeBSD (uncomment)
|
||||
#X11INC = /usr/local/include
|
||||
#X11LIB = /usr/local/lib
|
||||
|
||||
# Xinerama, comment if you don't want it
|
||||
XINERAMALIBS = -lXinerama
|
||||
XINERAMAFLAGS = -DXINERAMA
|
||||
|
||||
# freetype
|
||||
FREETYPELIBS = -lfontconfig -lXft
|
||||
FREETYPEINC = /usr/include/freetype2
|
||||
# FreeBSD (uncomment)
|
||||
#FREETYPEINC = /usr/local/include/freetype2
|
||||
# OpenBSD (uncomment)
|
||||
#FREETYPEINC = ${X11INC}/freetype2
|
||||
# OpenBSD - Uncomment this for the swallow patch / SWALLOW_PATCH
|
||||
#KVMLIB = -lkvm
|
||||
|
||||
# Uncomment this for the alpha patch and the winicon patch (BAR_ALPHA_PATCH, BAR_WINICON_PATCH)
|
||||
XRENDER = -lXrender
|
||||
|
||||
# Uncomment this for the mdpcontrol patch / MDPCONTROL_PATCH
|
||||
MPDCLIENT = -lmpdclient
|
||||
|
||||
# Uncomment for the pango patch / BAR_PANGO_PATCH
|
||||
#PANGOINC = `pkg-config --cflags xft pango pangoxft`
|
||||
#PANGOLIB = `pkg-config --libs xft pango pangoxft`
|
||||
|
||||
# Uncomment for the ipc patch / IPC_PATCH
|
||||
YAJLLIBS = -lyajl
|
||||
YAJLINC = -I/usr/include/yajl
|
||||
|
||||
# Uncomment this for the rounded corners patch / ROUNDED_CORNERS_PATCH
|
||||
XEXTLIB = -lXext
|
||||
|
||||
# Uncomment this for the swallow patch / SWALLOW_PATCH
|
||||
XCBLIBS = -lX11-xcb -lxcb -lxcb-res
|
||||
|
||||
# This is needed for the winicon and tagpreview patches / BAR_WINICON_PATCH / BAR_TAGPREVIEW_PATCH
|
||||
IMLIB2LIBS = -lImlib2
|
||||
|
||||
# Uncomment for the bidi patch
|
||||
#BDINC = `pkg-config --cflags fribidi`
|
||||
#BDLIBS = `pkg-config --libs fribidi`
|
||||
|
||||
# includes and libs
|
||||
INCS = -I${X11INC} -I${FREETYPEINC} ${YAJLINC} ${PANGOINC} ${BDINC}
|
||||
LIBS = -L${X11LIB} -lX11 ${XINERAMALIBS} ${FREETYPELIBS} ${XRENDER} ${MPDCLIENT} ${XEXTLIB} ${XCBLIBS} ${KVMLIB} ${PANGOLIB} ${YAJLLIBS} ${IMLIB2LIBS} $(BDLIBS)
|
||||
|
||||
# flags
|
||||
CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700L -DVERSION=\"${VERSION}\" ${XINERAMAFLAGS}
|
||||
#CFLAGS = -g -std=c99 -pedantic -Wall -O0 ${INCS} ${CPPFLAGS}
|
||||
CFLAGS = -std=c99 -pedantic -Wall -Wno-unused-function -Wno-deprecated-declarations -Os ${INCS} ${CPPFLAGS}
|
||||
LDFLAGS = ${LIBS}
|
||||
|
||||
# Solaris
|
||||
#CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
|
||||
#LDFLAGS = ${LIBS}
|
||||
|
||||
# compiler and linker
|
||||
CC = cc
|
|
@ -554,10 +554,9 @@ static const BarRule barrules[] = {
|
|||
/* monitor bar alignment widthfunc drawfunc clickfunc hoverfunc name */
|
||||
#if BAR_STATUSBUTTON_PATCH
|
||||
{ -1, 0, BAR_ALIGN_LEFT, width_stbutton, draw_stbutton, click_stbutton, NULL, "statusbutton" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton2, draw_stbutton2, click_stbutton2, NULL, "statusbutton2" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton3, draw_stbutton3, click_stbutton3, NULL, "statusbutton3" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton4, draw_stbutton4, click_stbutton4, NULL, "statusbutton4" },
|
||||
{ -1, 1, BAR_ALIGN_RIGHT, width_stbutton5, draw_stbutton5, click_stbutton5, NULL, "statusbutton5" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton2, draw_stbutton2, click_stbutton2, NULL, "statusbutton2" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton3, draw_stbutton3, click_stbutton3, NULL, "statusbutton3" },
|
||||
{ -1, 1, BAR_ALIGN_LEFT, width_stbutton4, draw_stbutton4, click_stbutton4, NULL, "statusbutton4" },
|
||||
#endif // BAR_STATUSBUTTON_PATCH
|
||||
#if BAR_POWERLINE_TAGS_PATCH
|
||||
{ 0, 0, BAR_ALIGN_LEFT, width_pwrl_tags, draw_pwrl_tags, click_pwrl_tags, NULL, "powerline_tags" },
|
||||
|
@ -566,7 +565,7 @@ static const BarRule barrules[] = {
|
|||
{ -1, 0, BAR_ALIGN_LEFT, width_tags, draw_tags, click_tags, hover_tags, "tags" },
|
||||
#endif // BAR_TAGS_PATCH
|
||||
#if BAR_TAGLABELS_PATCH
|
||||
{ -1, 0, BAR_ALIGN_LEFT, width_taglabels, draw_taglabels, click_taglabels, hover_taglabels, "taglabels" },
|
||||
{ -1, 0, BAR_ALIGN_LEFT, width_taglabels, draw_taglabels, click_taglabels, NULL, "taglabels" },
|
||||
#endif // BAR_TAGLABELS_PATCH
|
||||
#if BAR_TAGGRID_PATCH
|
||||
{ -1, 0, BAR_ALIGN_LEFT, width_taggrid, draw_taggrid, click_taggrid, NULL, "taggrid" },
|
||||
|
@ -574,6 +573,9 @@ static const BarRule barrules[] = {
|
|||
#if BAR_SYSTRAY_PATCH
|
||||
{ 0, 0, BAR_ALIGN_RIGHT, width_systray, draw_systray, click_systray, NULL, "systray" },
|
||||
#endif // BAR_SYSTRAY_PATCH
|
||||
#if BAR_STATUSBUTTON_PATCH
|
||||
{ -1, 1, BAR_ALIGN_RIGHT, width_stbutton5, draw_stbutton5, click_stbutton5, NULL, "statusbutton5" },
|
||||
#endif // BAR_STATUSBUTTON_PATCH
|
||||
#if BAR_LTSYMBOL_PATCH
|
||||
{ -1, 0, BAR_ALIGN_LEFT, width_ltsymbol, draw_ltsymbol, click_ltsymbol, NULL, "layout" },
|
||||
#endif // BAR_LTSYMBOL_PATCH
|
||||
|
|
|
@ -62,7 +62,7 @@ LIBS = -L${X11LIB} -lX11 ${XINERAMALIBS} ${FREETYPELIBS} ${XRENDER} ${MPDCLIENT
|
|||
# flags
|
||||
CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700L -DVERSION=\"${VERSION}\" ${XINERAMAFLAGS}
|
||||
#CFLAGS = -g -std=c99 -pedantic -Wall -O0 ${INCS} ${CPPFLAGS}
|
||||
CFLAGS = -std=c99 -pedantic -Wall -Wno-unused-function -Wno-deprecated-declarations -O3 -march=native ${INCS} ${CPPFLAGS}
|
||||
CFLAGS = -std=c99 -pedantic -Wall -Wno-unused-function -Wno-deprecated-declarations -Os ${INCS} ${CPPFLAGS}
|
||||
LDFLAGS = ${LIBS}
|
||||
|
||||
# Solaris
|
||||
|
|
|
@ -89,57 +89,3 @@ click_taglabels(Bar *bar, Arg *arg, BarArg *a)
|
|||
}
|
||||
return ClkTagBar;
|
||||
}
|
||||
|
||||
int
|
||||
hover_taglabels(Bar *bar, BarArg *a, XMotionEvent *ev)
|
||||
{
|
||||
#if BAR_TAGPREVIEW_PATCH
|
||||
int i = 0, x = lrpad / 2;
|
||||
int px, py;
|
||||
Monitor *m = bar->mon;
|
||||
#if VANITYGAPS_PATCH
|
||||
int ov = gappov;
|
||||
int oh = gappoh;
|
||||
#else
|
||||
int ov = 0;
|
||||
int oh = 0;
|
||||
#endif // VANITYGAPS_PATCH
|
||||
|
||||
#if BAR_HIDEVACANTTAGS_PATCH
|
||||
Client *c;
|
||||
unsigned int occ = 0;
|
||||
for (c = bar->mon->clients; c; c = c->next)
|
||||
occ |= c->tags == 255 ? 0 : c->tags;
|
||||
#endif // BAR_HIDEVACANTTAGS_PATCH
|
||||
|
||||
do {
|
||||
#if BAR_HIDEVACANTTAGS_PATCH
|
||||
if (!(occ & 1 << i || bar->mon->tagset[bar->mon->seltags] & 1 << i))
|
||||
continue;
|
||||
#endif // BAR_HIDEVACANTTAGS_PATCH
|
||||
x += TEXTW(m->taglabel[i]);
|
||||
} while (a->x >= x && ++i < NUMTAGS);
|
||||
|
||||
if (i < NUMTAGS) {
|
||||
if ((i + 1) != selmon->previewshow && !(selmon->tagset[selmon->seltags] & 1 << i)) {
|
||||
if (bar->by > m->my + m->mh / 2) // bottom bar
|
||||
py = bar->by - m->mh / scalepreview - oh;
|
||||
else // top bar
|
||||
py = bar->by + bar->bh + oh;
|
||||
px = bar->bx + ev->x - m->mw / scalepreview / 2;
|
||||
if (px + m->mw / scalepreview > m->mx + m->mw)
|
||||
px = m->wx + m->ww - m->mw / scalepreview - ov;
|
||||
else if (px < bar->bx)
|
||||
px = m->wx + ov;
|
||||
selmon->previewshow = i + 1;
|
||||
showtagpreview(i, px, py);
|
||||
} else if (selmon->tagset[selmon->seltags] & 1 << i) {
|
||||
hidetagpreview(selmon);
|
||||
}
|
||||
} else if (selmon->previewshow != 0) {
|
||||
hidetagpreview(selmon);
|
||||
}
|
||||
#endif // BAR_TAGPREVIEW_PATCH
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
|
|
@ -2,5 +2,4 @@
|
|||
|
||||
static int width_taglabels(Bar *bar, BarArg *a);
|
||||
static int draw_taglabels(Bar *bar, BarArg *a);
|
||||
static int click_taglabels(Bar *bar, Arg *arg, BarArg *a);
|
||||
static int hover_taglabels(Bar *bar, BarArg *a, XMotionEvent *ev);
|
||||
static int click_taglabels(Bar *bar, Arg *arg, BarArg *a);
|
|
@ -65,7 +65,7 @@
|
|||
* taps into the many layout options that flextile-deluxe offers to produce a window
|
||||
* title section in the bar that is representative of what is shown on screen.
|
||||
*/
|
||||
#define BAR_FLEXWINTITLE_PATCH 0
|
||||
#define BAR_FLEXWINTITLE_PATCH 0
|
||||
|
||||
/* This patch adds a context menu for layout switching.
|
||||
* - xmenu needs to be installed.
|
||||
|
@ -74,7 +74,7 @@
|
|||
* - The text of the menu items is for display only. Name them however you want.
|
||||
* https://dwm.suckless.org/patches/layoutmenu/
|
||||
*/
|
||||
#define BAR_LAYOUTMENU_PATCH 0
|
||||
#define BAR_LAYOUTMENU_PATCH 0
|
||||
|
||||
/* Show layout symbol in bar */
|
||||
#define BAR_LTSYMBOL_PATCH 1
|
||||
|
@ -170,7 +170,7 @@
|
|||
#define BAR_SYSTRAY_PATCH 1
|
||||
|
||||
/* Show tag symbols in the bar. */
|
||||
#define BAR_TAGS_PATCH 0
|
||||
#define BAR_TAGS_PATCH 0
|
||||
|
||||
/* Show tag symbols + class of master window in the bar.
|
||||
* https://dwm.suckless.org/patches/taglabels/
|
||||
|
@ -290,7 +290,7 @@
|
|||
* modules.
|
||||
* https://dwm.suckless.org/patches/centeredwindowname/
|
||||
*/
|
||||
#define BAR_CENTEREDWINDOWNAME_PATCH 0
|
||||
#define BAR_CENTEREDWINDOWNAME_PATCH 0
|
||||
|
||||
/* Draws a dot indicator overlayed on each tag icon for each client. The selected client
|
||||
* is drawn as a larger horizontal line.
|
||||
|
@ -660,7 +660,7 @@
|
|||
/* Switch focus only by mouse click and not sloppy (focus follows mouse pointer).
|
||||
* https://dwm.suckless.org/patches/focusonclick/
|
||||
*/
|
||||
#define FOCUSONCLICK_PATCH 0
|
||||
#define FOCUSONCLICK_PATCH 1
|
||||
|
||||
/* Selects the next window having the urgent flag regardless of the tag it is on.
|
||||
* The urgent flag can be artificially set with the following xdotool command on any window:
|
||||
|
@ -948,7 +948,7 @@
|
|||
* Additionally dwm can quit cleanly by using kill -TERM dwmpid.
|
||||
* https://dwm.suckless.org/patches/restartsig/
|
||||
*/
|
||||
#define RESTARTSIG_PATCH 1
|
||||
#define RESTARTSIG_PATCH 1
|
||||
|
||||
/* Adds rio-like drawing to resize the selected client.
|
||||
* This depends on an external tool slop being installed.
|
||||
|
|
Loading…
Reference in a new issue