diff --git a/src/dispatch/bind_define.h b/src/dispatch/bind_define.h index d42e772..93de6d7 100644 --- a/src/dispatch/bind_define.h +++ b/src/dispatch/bind_define.h @@ -295,6 +295,7 @@ int increase_proportion(const Arg *arg) { int setmfact(const Arg *arg) { float f; + Client *c = NULL; if (!arg || !selmon || !selmon->pertag->ltidxs[selmon->pertag->curtag]->arrange) @@ -303,8 +304,13 @@ int setmfact(const Arg *arg) { : arg->f - 1.0; if (f < 0.1 || f > 0.9) return 0; - // selmon->mfact = f; + selmon->pertag->mfacts[selmon->pertag->curtag] = f; + wl_list_for_each(c, &clients, link) { + if (VISIBLEON(c, selmon) && ISTILED(c)) { + c->master_mfact_per = f; + } + } arrange(selmon, false); return 0; } diff --git a/src/layout/arrange.h b/src/layout/arrange.h index 0a4eca2..18d6b15 100644 --- a/src/layout/arrange.h +++ b/src/layout/arrange.h @@ -12,7 +12,7 @@ void set_size_per(Monitor *m, Client *c) { } if (!found) { - c->master_mfact_per = default_mfact; + c->master_mfact_per = m->pertag->mfacts[m->pertag->curtag]; c->master_inner_per = 1.0f; c->stack_innder_per = 1.0f; }