-
Notifications
You must be signed in to change notification settings - Fork 30
Open
Description
The idea is inspired by the way slstatus is configured. Roughly, i think about the following structure:
typedef struct {
char *(*status)();
void (*action)(const Arg arg);
} Barconfig;
Here status is the function which gets text to display, action is the function called if this text is pressed (if needed).
In config.h it could be used as follows:
const Barconfig leftaligned[] = {
{ tags_list, NULL },
};
const Barconfig centeraligned[] = {
{ client_name, NULL },
}
const Barconfig rightaligned[] = {
{ status, NULL },
}
Afterwards three cycles over these configs are performed to draw in left, center and right parts of the bar.
This way, i think, it will be a lot easier to add any objects to the bar. The colorscheme and data for status text should be available from global variables.
I'll try to implement it myself but maybe someone could be quicker than me.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels