9991f9ccc8
In the case where one want to put the cursor at the middle of the workarea, it is logic to do: x=screen.workarea.x+screen.workasrea.width/2 However, this can cause floating points. This commit move the burden back to the C-API so the Lua placement code doesn't have to add a large number of rounding methods. Given 1 type of rounding cover a vast majority of use cases for each types of coordinates, the C-API can take care of it in peace. For the other corner cases, it is still possible for the Lua code to do the rounding there, but no longer necessary. The convenstions are: 'x' and 'y': use round (move to the closest point) 'width' and 'height': use ceil (to avoid involontary truncating) |
||
---|---|---|
.. | ||
button.c | ||
button.h | ||
client.c | ||
client.h | ||
drawable.c | ||
drawable.h | ||
drawin.c | ||
drawin.h | ||
key.c | ||
key.h | ||
screen.c | ||
screen.h | ||
tag.c | ||
tag.h | ||
window.c | ||
window.h |