summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--wiitrack.c4
-rw-r--r--wiitrack.xml.in7
2 files changed, 9 insertions, 2 deletions
diff --git a/wiitrack.c b/wiitrack.c
index de0af18..58ae195 100644
--- a/wiitrack.c
+++ b/wiitrack.c
@@ -235,8 +235,8 @@ static Bool WTPaintWindow(CompWindow *w, const WindowPaintAttrib *attrib,
if (shouldPaintStacked(w)) {
if (!(w->type == CompWindowTypeDesktopMask)) {
if (!(WIN_REAL_X(w) + WIN_REAL_W(w) <= 0.0 || WIN_REAL_X(w) >= w->screen->width))
- matrixTranslate(&wTransform, 0.0, 0.0, wtw->zDepth);
- if (wtw->zDepth != 0.0)
+ matrixTranslate(&wTransform, 0.0, 0.0, wtw->zDepth + (float)wiitrackGetStackPadding(w->screen) / 100.0f);
+ if (wtw->zDepth + (float)wiitrackGetStackPadding(w->screen) / 100.0f != 0.0)
mask |= PAINT_WINDOW_TRANSFORMED_MASK;
} else {
matrixTranslate(&wTransform, 0.0, 0.0, 0.0);
diff --git a/wiitrack.xml.in b/wiitrack.xml.in
index 388938f..cdecfab 100644
--- a/wiitrack.xml.in
+++ b/wiitrack.xml.in
@@ -95,6 +95,13 @@
<min>0</min>
<max>100</max>
</option>
+ <option type="int" name="stack_padding">
+ <_short>Stack Padding</_short>
+ <_long>Make your windows pop out this far from the screen. 100 is cube size</_long>
+ <default>0</default>
+ <min>0</min>
+ <max>1000</max>
+ </option>
<option type="bool" name="enable_tracking">
<_short>Enable Tracking</_short>
<_long>Enable tracking using JCL's algorithm. You must have wiimote enabled to use this.</_long>