pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/x11/xosd xosd: place text correctly when using offset ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/19b22f364ea2
branches:  trunk
changeset: 331282:19b22f364ea2
user:      bsiegert <bsiegert%pkgsrc.org@localhost>
date:      Sat Mar 16 08:50:47 2019 +0000

description:
xosd: place text correctly when using offset monitors.

>From Aran Clauson in PR pkg/53994. Upstream seems dead.

diffstat:

 x11/xosd/Makefile                           |   3 +-
 x11/xosd/distinfo                           |   4 ++-
 x11/xosd/patches/patch-src_libxosd_intern.h |  14 ++++++++++
 x11/xosd/patches/patch-src_libxosd_xosd.c   |  38 +++++++++++++++++++++++++++++
 4 files changed, 57 insertions(+), 2 deletions(-)

diffs (89 lines):

diff -r 113cea124710 -r 19b22f364ea2 x11/xosd/Makefile
--- a/x11/xosd/Makefile Sat Mar 16 08:36:49 2019 +0000
+++ b/x11/xosd/Makefile Sat Mar 16 08:50:47 2019 +0000
@@ -1,8 +1,9 @@
-# $NetBSD: Makefile,v 1.13 2018/12/09 21:05:37 adam Exp $
+# $NetBSD: Makefile,v 1.14 2019/03/16 08:50:47 bsiegert Exp $
 
 .include "Makefile.common"
 
 COMMENT=               Library to display shaped text on your X display
+PKGREVISION=   1
 
 CONFIGURE_ENV+=                XOSD_XMMS_PLUGIN=NO
 CONFIGURE_ARGS+=       --disable-gdk_pixbuftest
diff -r 113cea124710 -r 19b22f364ea2 x11/xosd/distinfo
--- a/x11/xosd/distinfo Sat Mar 16 08:36:49 2019 +0000
+++ b/x11/xosd/distinfo Sat Mar 16 08:50:47 2019 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.14 2015/11/04 03:29:10 agc Exp $
+$NetBSD: distinfo,v 1.15 2019/03/16 08:50:47 bsiegert Exp $
 
 SHA1 (xosd-2.2.14.tar.gz) = 1d459a62239c9fe842d835bb7f60eb2edd7c979f
 RMD160 (xosd-2.2.14.tar.gz) = 8a39756c5a46f2897be9bbd47dd86770f42ed648
@@ -7,3 +7,5 @@
 SHA1 (patch-aa) = b555bbb0777dcf0d2475496ae8725b1b2c202fb5
 SHA1 (patch-ab) = 5502dc0f546a5afe199e746995efd90b0056a34b
 SHA1 (patch-ac) = 3c42659ff34b26710fd1ad3329a1f203710155f5
+SHA1 (patch-src_libxosd_intern.h) = 56f45d50d5c79913b6972bb1d603432dbf56f869
+SHA1 (patch-src_libxosd_xosd.c) = 5343cc73338eb12ccdb56ce3e907ddf36252db4b
diff -r 113cea124710 -r 19b22f364ea2 x11/xosd/patches/patch-src_libxosd_intern.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/x11/xosd/patches/patch-src_libxosd_intern.h       Sat Mar 16 08:50:47 2019 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-src_libxosd_intern.h,v 1.1 2019/03/16 08:50:48 bsiegert Exp $
+
+Support for y-offset monitors, http://gnats.netbsd.org/53994
+
+--- src/libxosd/intern.h.orig  2004-11-04 19:50:45.000000000 +0000
++++ src/libxosd/intern.h
+@@ -107,6 +107,7 @@ struct xosd
+   int screen_width;             /* CONST x11 */
+   int screen_height;            /* CONST x11 */
+   int screen_xpos;              /* CONST x11 */
++  int screen_ypos;              /* CONST x11 */
+   int height;                   /* CACHE (font) */
+   int line_height;              /* CACHE (font) */
+   xosd_pos pos;                 /* CONF */
diff -r 113cea124710 -r 19b22f364ea2 x11/xosd/patches/patch-src_libxosd_xosd.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/x11/xosd/patches/patch-src_libxosd_xosd.c Sat Mar 16 08:50:47 2019 +0000
@@ -0,0 +1,38 @@
+$NetBSD: patch-src_libxosd_xosd.c,v 1.1 2019/03/16 08:50:48 bsiegert Exp $
+
+Support for y-offset monitors, http://gnats.netbsd.org/53994
+
+--- src/libxosd/xosd.c.orig    2004-11-17 19:27:11.000000000 +0000
++++ src/libxosd/xosd.c
+@@ -326,13 +326,13 @@ event_loop(void *osdv)
+       }
+       switch (osd->pos) {
+       case XOSD_bottom:
+-        y = osd->screen_height - osd->height - osd->voffset;
++        y = osd->screen_height + osd->screen_ypos - osd->height - osd->voffset;
+         break;
+       case XOSD_middle:
+-        y = (osd->screen_height - osd->height) / 2 - osd->voffset;
++        y = (osd->screen_height  + osd->screen_ypos - osd->height) / 2 - osd->voffset;
+         break;
+       case XOSD_top:
+-        y = osd->voffset;
++        y = osd->screen_ypos + osd->voffset;
+       }
+       XMoveWindow(osd->display, osd->window, x, y);
+     }
+@@ -746,12 +746,14 @@ xosd_create(int number_lines)
+     osd->screen_width = screeninfo[0].width;
+     osd->screen_height = screeninfo[0].height;
+     osd->screen_xpos = screeninfo[0].x_org;
++    osd->screen_ypos = screeninfo[0].y_org;
+   } else
+ #endif
+   {
+     osd->screen_width = XDisplayWidth(osd->display, osd->screen);
+     osd->screen_height = XDisplayHeight(osd->display, osd->screen);
+     osd->screen_xpos = 0;
++    osd->screen_ypos = 0;
+   }
+ #ifdef HAVE_XINERAMA
+   if (screeninfo)



Home | Main Index | Thread Index | Old Index