mirror of
https://github.com/mintycube/dwm.git
synced 2024-10-22 12:05:45 +00:00
status2d: rawstext may not exist if neither statuscmd nor the extrabar patch is used
This commit is contained in:
parent
6eb24902f2
commit
2cf37aa492
@ -1,28 +1,44 @@
|
||||
int
|
||||
width_status2d(Bar *bar, BarWidthArg *a)
|
||||
{
|
||||
#if BAR_EXTRASTATUS_PATCH || BAR_STATUSCMD_PATCH
|
||||
return status2dtextlength(rawstext) + lrpad;
|
||||
#else
|
||||
return status2dtextlength(stext) + lrpad;
|
||||
#endif // #if BAR_EXTRASTATUS_PATCH | BAR_STATUSCMD_PATCH
|
||||
}
|
||||
|
||||
#if BAR_EXTRASTATUS_PATCH
|
||||
int
|
||||
width_status2d_es(Bar *bar, BarWidthArg *a)
|
||||
{
|
||||
return status2dtextlength(rawestext);
|
||||
#if BAR_EXTRASTATUS_PATCH || BAR_STATUSCMD_PATCH
|
||||
return status2dtextlength(rawestext) + lrpad;
|
||||
#else
|
||||
return status2dtextlength(estext) + lrpad;
|
||||
#endif // #if BAR_EXTRASTATUS_PATCH | BAR_STATUSCMD_PATCH
|
||||
}
|
||||
#endif // BAR_EXTRASTATUS_PATCH
|
||||
|
||||
int
|
||||
draw_status2d(Bar *bar, BarDrawArg *a)
|
||||
{
|
||||
#if BAR_EXTRASTATUS_PATCH || BAR_STATUSCMD_PATCH
|
||||
return drawstatusbar(a->x, rawstext);
|
||||
#else
|
||||
return drawstatusbar(a->x, stext);
|
||||
#endif // #if BAR_EXTRASTATUS_PATCH | BAR_STATUSCMD_PATCH
|
||||
}
|
||||
|
||||
#if BAR_EXTRASTATUS_PATCH
|
||||
int
|
||||
draw_status2d_es(Bar *bar, BarDrawArg *a)
|
||||
{
|
||||
#if BAR_EXTRASTATUS_PATCH || BAR_STATUSCMD_PATCH
|
||||
return drawstatusbar(a->x, rawestext);
|
||||
#else
|
||||
return drawstatusbar(a->x, estext);
|
||||
#endif // #if BAR_EXTRASTATUS_PATCH | BAR_STATUSCMD_PATCH
|
||||
}
|
||||
#endif // BAR_EXTRASTATUS_PATCH
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user