Another copy of my dotfiles. Because I don't completely trust GitHub.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
354 B

  1. void
  2. setcfact(const Arg *arg)
  3. {
  4. float f;
  5. Client *c;
  6. c = selmon->sel;
  7. if (!arg || !c || !selmon->lt[selmon->sellt]->arrange)
  8. return;
  9. if (!arg->f)
  10. f = 1.0;
  11. else if (arg->f > 4.0) // set fact absolutely
  12. f = arg->f - 4.0;
  13. else
  14. f = arg->f + c->cfact;
  15. if (f < 0.25)
  16. f = 0.25;
  17. else if (f > 4.0)
  18. f = 4.0;
  19. c->cfact = f;
  20. arrange(selmon);
  21. }