Compare commits

...

2 Commits

Author SHA1 Message Date
b26a0fcd99 Added smart borders 2016-04-01 14:52:58 -04:00
2ee1a6d285 Added tiny titles 2016-04-01 14:52:49 -04:00
2 changed files with 12 additions and 4 deletions

View File

@ -1411,6 +1411,17 @@ Con *con_descend_direction(Con *con, direction_t direction) {
* *
*/ */
Rect con_border_style_rect(Con *con) { Rect con_border_style_rect(Con *con) {
Con *cur = con;
while (cur->floating < 2 && cur) {
Con *par = cur->parent;
if (con_num_children(par) == 1)
if (par->type == CT_WORKSPACE)
return (Rect){0, 0, 0, 0};
else
cur = par;
else
break;
}
adjacent_t borders_to_hide = ADJ_NONE; adjacent_t borders_to_hide = ADJ_NONE;
int border_width = con->current_border_width; int border_width = con->current_border_width;
DLOG("The border width for con is set to: %d\n", con->current_border_width); DLOG("The border width for con is set to: %d\n", con->current_border_width);

View File

@ -25,10 +25,7 @@ static void render_con_dockarea(Con *con, Con *child, render_params *p);
* Returns the height for the decorations * Returns the height for the decorations
*/ */
int render_deco_height(void) { int render_deco_height(void) {
int deco_height = config.font.height + 4; return config.font.height + 2;
if (config.font.height & 0x01)
++deco_height;
return deco_height;
} }
/* /*