summaryrefslogtreecommitdiff
path: root/graphics/xv/files/patch-af
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/xv/files/patch-af')
-rw-r--r--graphics/xv/files/patch-af58
1 files changed, 58 insertions, 0 deletions
diff --git a/graphics/xv/files/patch-af b/graphics/xv/files/patch-af
new file mode 100644
index 000000000000..eb55dc32ef5c
--- /dev/null
+++ b/graphics/xv/files/patch-af
@@ -0,0 +1,58 @@
+--- xv.c.orig Sat Mar 8 16:29:05 1997
++++ xv.c Sat Mar 8 16:38:48 1997
+@@ -3197,9 +3197,17 @@
+ hints.flags = 0;
+ if ((i&XValue || i&YValue)) hints.flags = USPosition;
+
+- if (i&XValue && i&XNegative) x = vrWIDE - eWIDE - abs(x);
+- if (i&YValue && i&YNegative) y = vrHIGH - eHIGH - abs(y);
+-
++ hints.win_gravity = NorthWestGravity;
++ if (i&XValue && i&XNegative) {
++ hints.win_gravity = NorthEastGravity;
++ x = vrWIDE - (eWIDE + 2 * bwidth) - abs(x);
++ }
++ if (i&YValue && i&YNegative) {
++ hints.win_gravity = (hints.win_gravity == NorthWestGravity) ?
++ SouthWestGravity : SouthEastGravity;
++ y = vrHIGH - (eHIGH + 2 * bwidth) - abs(y);
++ }
++
+ if (x+eWIDE > vrWIDE) x = vrWIDE - eWIDE; /* keep on screen */
+ if (y+eHIGH > vrHIGH) y = vrHIGH - eHIGH;
+
+@@ -3218,7 +3226,7 @@
+ hints.x = x; hints.y = y;
+ hints.width = eWIDE; hints.height = eHIGH;
+ hints.max_width = maxWIDE; hints.max_height = maxHIGH;
+- hints.flags |= USSize | PMaxSize;
++ hints.flags |= USSize | PMaxSize | PWinGravity;
+
+ xswa.bit_gravity = StaticGravity;
+ xswa.background_pixel = bg;
+@@ -3267,10 +3275,6 @@
+ }
+ }
+
+-
+- XSetStandardProperties(theDisp,mainW,"","",None,NULL,0,&hints);
+- setWinIconNames(name);
+-
+ xwmh.input = True;
+ xwmh.flags = InputHint;
+
+@@ -3295,12 +3299,12 @@
+ }
+ }
+ }
+- XSetWMHints(theDisp, mainW, &xwmh);
+
+ classh.res_name = "xv";
+ classh.res_class = "XVroot";
+- XSetClassHint(theDisp, mainW, &classh);
+
++ XmbSetWMProperties(theDisp, mainW, NULL, NULL, NULL, 0, &hints, &xwmh, &classh);
++ setWinIconNames(name);
+
+ if (nodecor) { /* turn of image window decorations (in MWM) */
+ Atom mwm_wm_hints;