separate alphas array for powerline alpha
This commit is contained in:
parent
3b9490285d
commit
fbbd505855
46
colors.h
46
colors.h
|
@ -34,24 +34,38 @@ static char *powerlinecolors[][2] = {
|
||||||
[SchemeStatus] = { col_powerline7_text, col_powerline7 },
|
[SchemeStatus] = { col_powerline7_text, col_powerline7 },
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* Alpha to use for the powerlines */
|
||||||
|
static unsigned int powerlinealphas[][3] = {
|
||||||
|
/* fg bg unused */
|
||||||
|
[SchemeBar] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeTagsNorm] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeTagsSel] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeTagsUrg] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeStatus] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeBorderNorm] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeBorderSel] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeBorderUrg] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
[SchemeStatus] = { opaque, powerlineopacity, powerlineopacity },
|
||||||
|
};
|
||||||
|
|
||||||
/* Colors for the status bar (.Xresources) */
|
/* Colors for the status bar (.Xresources) */
|
||||||
static char *colstatus[] = {
|
static char *colstatus[] = {
|
||||||
col_status0,
|
col_status0,
|
||||||
col_status1,
|
col_status1,
|
||||||
col_status2,
|
col_status2,
|
||||||
col_status3,
|
col_status3,
|
||||||
col_status4,
|
col_status4,
|
||||||
col_status5,
|
col_status5,
|
||||||
col_status6,
|
col_status6,
|
||||||
col_status7,
|
col_status7,
|
||||||
col_status8,
|
col_status8,
|
||||||
col_status9,
|
col_status9,
|
||||||
col_status10,
|
col_status10,
|
||||||
col_status11,
|
col_status11,
|
||||||
col_status12,
|
col_status12,
|
||||||
col_status13,
|
col_status13,
|
||||||
col_status14,
|
col_status14,
|
||||||
col_status15,
|
col_status15,
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Alpha to use for opacity */
|
/* Alpha to use for opacity */
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/* speedwm
|
/* speedwm
|
||||||
*
|
*
|
||||||
* Below is a configuration file which is technically C source code.
|
* Below is a configuration file which is technically C source code.
|
||||||
* See the man page (speedie.1) or README.md for help.
|
* See the man page (speedie.1), README.md, readme.php or https://speedie.gq/projects/speedwm.php (they're all identical) for help.
|
||||||
* See the LICENSE file for license details.
|
* See the LICENSE file for license details.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -303,6 +303,7 @@ static char text_layout15[] = "(L15)"; /* Text for layout 15 *
|
||||||
#define normborderopacity opaque /* Opacity for the all window borders except selected */
|
#define normborderopacity opaque /* Opacity for the all window borders except selected */
|
||||||
#define selborderopacity opaque /* Opacity for the selected window border */
|
#define selborderopacity opaque /* Opacity for the selected window border */
|
||||||
#define hiddenopacity transparent /* Opacity for hidden/minimized windows */
|
#define hiddenopacity transparent /* Opacity for hidden/minimized windows */
|
||||||
|
#define powerlineopacity 160 /* Opacity for the speedwm powerline in the status bar */
|
||||||
#define statusopacity 160 /* Opacity for speedwm status bar */
|
#define statusopacity 160 /* Opacity for speedwm status bar */
|
||||||
#define systrayopacity 160 /* Opacity for the speedwm built in systray */
|
#define systrayopacity 160 /* Opacity for the speedwm built in systray */
|
||||||
|
|
||||||
|
|
|
@ -252,7 +252,7 @@ struct Client {
|
||||||
Client *next;
|
Client *next;
|
||||||
Client *snext;
|
Client *snext;
|
||||||
Client *swallowing;
|
Client *swallowing;
|
||||||
Client *ishidden;
|
int ishidden;
|
||||||
Monitor *mon;
|
Monitor *mon;
|
||||||
Window win;
|
Window win;
|
||||||
#if USEIPC
|
#if USEIPC
|
||||||
|
@ -2659,6 +2659,8 @@ hidewin(Client *c) {
|
||||||
if (!c || HIDDEN(c))
|
if (!c || HIDDEN(c))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
c->ishidden = 1; /* is hidden */
|
||||||
|
|
||||||
Window w = c->win;
|
Window w = c->win;
|
||||||
static XWindowAttributes ra, ca;
|
static XWindowAttributes ra, ca;
|
||||||
|
|
||||||
|
@ -2672,8 +2674,6 @@ hidewin(Client *c) {
|
||||||
XSelectInput(dpy, root, ra.your_event_mask);
|
XSelectInput(dpy, root, ra.your_event_mask);
|
||||||
XSelectInput(dpy, w, ca.your_event_mask);
|
XSelectInput(dpy, w, ca.your_event_mask);
|
||||||
XUngrabServer(dpy);
|
XUngrabServer(dpy);
|
||||||
|
|
||||||
c->ishidden = 1; /* is hidden */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#if USEIPC
|
#if USEIPC
|
||||||
|
@ -5158,7 +5158,7 @@ setup(void)
|
||||||
tagscheme[i] = drw_scm_create(drw, tagsel[i], tagalpha, 2);
|
tagscheme[i] = drw_scm_create(drw, tagsel[i], tagalpha, 2);
|
||||||
powerlinescheme = ecalloc(LENGTH(powerlinecolors), sizeof(Clr *));
|
powerlinescheme = ecalloc(LENGTH(powerlinecolors), sizeof(Clr *));
|
||||||
for (i = 0; i < LENGTH(powerlinecolors); i++)
|
for (i = 0; i < LENGTH(powerlinecolors); i++)
|
||||||
powerlinescheme[i] = drw_scm_create(drw, powerlinecolors[i], alphas[i], 2);
|
powerlinescheme[i] = drw_scm_create(drw, powerlinecolors[i], powerlinealphas[i], 2);
|
||||||
/* init bars */
|
/* init bars */
|
||||||
updatebars();
|
updatebars();
|
||||||
updatestatus();
|
updatestatus();
|
||||||
|
|
Loading…
Reference in a new issue