diff options
author | nakai <nakai@FreeBSD.org> | 2000-01-22 19:46:45 +0800 |
---|---|---|
committer | nakai <nakai@FreeBSD.org> | 2000-01-22 19:46:45 +0800 |
commit | 8e76258260591feba8c1af15c1ca6664ed23c5c7 (patch) | |
tree | 6d1a5aa0965f5392bbc49122cf3833c044e424b0 /x11 | |
parent | fe634d0115acb9af3ad90191efcd3274f380d426 (diff) | |
download | freebsd-ports-gnome-8e76258260591feba8c1af15c1ca6664ed23c5c7.tar.gz freebsd-ports-gnome-8e76258260591feba8c1af15c1ca6664ed23c5c7.tar.zst freebsd-ports-gnome-8e76258260591feba8c1af15c1ca6664ed23c5c7.zip |
Fix and updates from KATO Tsuguru.
Submitted by: "KATO Tsuguru" <tkato@prontomail.ne.jp>
Diffstat (limited to 'x11')
-rw-r--r-- | x11/xantfarm/Makefile | 14 | ||||
-rw-r--r-- | x11/xantfarm/distinfo | 2 | ||||
-rw-r--r-- | x11/xantfarm/pkg-descr | 2 | ||||
-rw-r--r-- | x11/xmascot/Makefile | 17 | ||||
-rw-r--r-- | x11/xmascot/distinfo | 2 | ||||
-rw-r--r-- | x11/xmascot/files/patch-aa | 10 | ||||
-rw-r--r-- | x11/xmascot/pkg-descr | 3 | ||||
-rw-r--r-- | x11/xmascot/pkg-plist | 51 | ||||
-rw-r--r-- | x11/xmold/Makefile | 14 | ||||
-rw-r--r-- | x11/xmold/files/patch-aa | 13 | ||||
-rw-r--r-- | x11/xmold/pkg-descr | 2 | ||||
-rw-r--r-- | x11/xzoom/files/patch-aa | 12 | ||||
-rw-r--r-- | x11/xzoom/files/patch-ab | 105 | ||||
-rw-r--r-- | x11/xzoom/files/patch-ac | 427 | ||||
-rw-r--r-- | x11/xzoom/files/patch-ad | 21 |
15 files changed, 652 insertions, 43 deletions
diff --git a/x11/xantfarm/Makefile b/x11/xantfarm/Makefile index 094f6f0c1758..2cbdea0ac3e6 100644 --- a/x11/xantfarm/Makefile +++ b/x11/xantfarm/Makefile @@ -1,19 +1,19 @@ -# New ports collection makefile for: xantfarm -# Version required: 1.16 -# Date created: 13 February 1997 -# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> +# New ports collection makefile for: xantfarm +# Version required: 1.16 +# Date created: 13 February 1997 +# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> # # $FreeBSD$ # -DISTNAME= xantfarm +DISTNAME= xantfarm_23oct91 PKGNAME= xantfarm-1.16 CATEGORIES= x11 -MASTER_SITES= ftp://ftp.kuis.kyoto-u.ac.jp/Linux/JG/other-sources/ -DISTFILES= xantfarm23oct91.tar.gz +MASTER_SITES= http://www.acme.com/software/xantfarm/ MAINTAINER= nakai@FreeBSD.org +WRKSRC= ${WRKDIR}/xantfarm USE_IMAKE= yes MAN1= xantfarm.1 diff --git a/x11/xantfarm/distinfo b/x11/xantfarm/distinfo index 366415d7b5df..28c0d9440558 100644 --- a/x11/xantfarm/distinfo +++ b/x11/xantfarm/distinfo @@ -1 +1 @@ -MD5 (xantfarm23oct91.tar.gz) = 2820d9fa8090c269a51a544fb22200c0 +MD5 (xantfarm_23oct91.tar.gz) = d3a7a4366baad292fcb6c05df59a0ee0 diff --git a/x11/xantfarm/pkg-descr b/x11/xantfarm/pkg-descr index f906b4c3e39f..271c418b84ae 100644 --- a/x11/xantfarm/pkg-descr +++ b/x11/xantfarm/pkg-descr @@ -1 +1,3 @@ Xantfarm animates the X11 root window with a simulated ant hill. + +WWW: http://www.acme.com/software/xantfarm/ diff --git a/x11/xmascot/Makefile b/x11/xmascot/Makefile index d181fc6bedaa..856a753c1f67 100644 --- a/x11/xmascot/Makefile +++ b/x11/xmascot/Makefile @@ -1,21 +1,20 @@ -# New ports collection makefile for: xmascot -# Version required: 2.5p2 -# Date created: 20 November 1996 -# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> +# New ports collection makefile for: xmascot +# Version required: 2.6a +# Date created: 20 November 1996 +# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> # # $FreeBSD$ # -DISTNAME= xmascot2.5p2 -PKGNAME= xmascot-2.5p2 +DISTNAME= xmascot2.6a +PKGNAME= xmascot-2.6a CATEGORIES= x11 -MASTER_SITES= ftp://cclub.tutcc.tut.ac.jp/pub/xmascot/ +MASTER_SITES= ftp://cclub.tutcc.tut.ac.jp/pub/xmascot/ \ + http://cclub-flying.dsl.gr.jp/products/xmascot/ MAINTAINER= nakai@FreeBSD.org -USE_GMAKE= yes USE_IMAKE= yes MAN1= xmascot.1 -MANCOMPRESSED= yes .include <bsd.port.mk> diff --git a/x11/xmascot/distinfo b/x11/xmascot/distinfo index 60d80cef7034..22d1fadb3519 100644 --- a/x11/xmascot/distinfo +++ b/x11/xmascot/distinfo @@ -1 +1 @@ -MD5 (xmascot2.5p2.tar.gz) = 4e953fbbc347086a12a894bfe8ca440b +MD5 (xmascot2.6a.tar.gz) = 0841f9448349db6fc89a2201385c2bdc diff --git a/x11/xmascot/files/patch-aa b/x11/xmascot/files/patch-aa new file mode 100644 index 000000000000..81dd64266e5f --- /dev/null +++ b/x11/xmascot/files/patch-aa @@ -0,0 +1,10 @@ +--- config.tmpl.orig Fri Oct 24 01:41:01 1997 ++++ config.tmpl Sat Jan 15 00:00:00 2000 +@@ -97,6 +97,7 @@ + + #ifdef USE_I18N + DEFINES_I18N = -DI18N ++LANG = ja_JP.EUC + LOCALEDIR = $(LIBDIR)/$(LANG)/app-defaults + #else + DEFINES_I18N = diff --git a/x11/xmascot/pkg-descr b/x11/xmascot/pkg-descr index 948c8be1f914..c3b7acd09756 100644 --- a/x11/xmascot/pkg-descr +++ b/x11/xmascot/pkg-descr @@ -19,5 +19,4 @@ PNM *.pnm PPM, PGM, or PBM XMascot distinguishes images from their suffix and can load other image formats when {suffix}topnm, *topgm, or *topbm commands are found in your system. -WWW: http://cclub.tutcc.tut.ac.jp:1080/xmascot/ - ftp://cclub.tutcc.tut.ac.jp/pub/xmascot/ +WWW: http://cclub-flying.dsl.gr.jp/products/xmascot/ diff --git a/x11/xmascot/pkg-plist b/x11/xmascot/pkg-plist index b78ef49e07ce..58894e351453 100644 --- a/x11/xmascot/pkg-plist +++ b/x11/xmascot/pkg-plist @@ -1,24 +1,45 @@ bin/xmascot lib/X11/app-defaults/XMascot -lib/X11/xmascot/pin.mag -lib/X11/xmascot/chain.mag -lib/X11/xmascot/mail_r.mag -lib/X11/xmascot/kuma.mag -lib/X11/xmascot/inu.mag -lib/X11/xmascot/neko.mag -lib/X11/xmascot/neko2.mag -lib/X11/xmascot/teru.mag -lib/X11/xmascot/pen.mag -lib/X11/xmascot/saru.mag -lib/X11/xmascot/rabi.mag -lib/X11/xmascot/fish.mag -lib/X11/xmascot/monohosi.mag -lib/X11/xmascot/logo.mag -lib/X11/xmascot/pipipipi.au +lib/X11/ja_JP.EUC/app-defaults/XMascot +lib/X11/xmascot/aquarius.gif +lib/X11/xmascot/aries.gif +lib/X11/xmascot/canser.gif +lib/X11/xmascot/capric.gif +lib/X11/xmascot/chain.gif +lib/X11/xmascot/fish.gif +lib/X11/xmascot/gemini.gif +lib/X11/xmascot/icon.xbm +lib/X11/xmascot/inu.gif +lib/X11/xmascot/kuma.gif +lib/X11/xmascot/leo.gif +lib/X11/xmascot/libra.gif +lib/X11/xmascot/logo.gif +lib/X11/xmascot/mail_r.gif lib/X11/xmascot/mi.au lib/X11/xmascot/mi.raw lib/X11/xmascot/mi2.au lib/X11/xmascot/mi2.raw lib/X11/xmascot/mitime.au lib/X11/xmascot/mitime.raw +lib/X11/xmascot/monohosi.gif +lib/X11/xmascot/neko.gif +lib/X11/xmascot/neko2.gif +lib/X11/xmascot/osu.xbm +lib/X11/xmascot/osu.xbmmsk +lib/X11/xmascot/pen.gif +lib/X11/xmascot/pin.gif +lib/X11/xmascot/pipipipi.au +lib/X11/xmascot/pisces.gif +lib/X11/xmascot/rabi.gif +lib/X11/xmascot/sagitt.gif +lib/X11/xmascot/saru.gif +lib/X11/xmascot/scorpio.gif +lib/X11/xmascot/select.xbm +lib/X11/xmascot/taurus.gif +lib/X11/xmascot/teru.gif +lib/X11/xmascot/tumamu.xbm +lib/X11/xmascot/tumamu.xbmmsk +lib/X11/xmascot/virgo.gif +lib/X11/xmascot/yubi.xbm +lib/X11/xmascot/yubi.xbmmsk @dirrm lib/X11/xmascot diff --git a/x11/xmold/Makefile b/x11/xmold/Makefile index dcc68809dc3b..fb6b71a50467 100644 --- a/x11/xmold/Makefile +++ b/x11/xmold/Makefile @@ -1,7 +1,7 @@ -# New ports collection makefile for: xmold -# Version required: 1.0 -# Date created: 11 October 1996 -# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> +# New ports collection makefile for: xmold +# Version required: 1.0 +# Date created: 11 October 1996 +# Whom: Yukihiro Nakai <Nakai@Mlab.t.u-tokyo.ac.jp> # # $FreeBSD$ # @@ -14,11 +14,9 @@ MASTER_SITES= ftp://cclub.tutcc.tut.ac.jp/pub/xwin/ MAINTAINER= nakai@FreeBSD.org USE_IMAKE= yes +NO_INSTALL_MANPAGE= yes do-install: - @${MKDIR} ${PREFIX}/bin - @install -c -s ${WRKSRC}/xmold ${PREFIX}/bin - @${CHMOD} 755 ${PREFIX}/bin/xmold - @${CHOWN} bin.bin ${PREFIX}/bin/xmold + ${INSTALL_PROGRAM} ${WRKSRC}/xmold ${PREFIX}/bin .include <bsd.port.mk> diff --git a/x11/xmold/files/patch-aa b/x11/xmold/files/patch-aa new file mode 100644 index 000000000000..d9bd8977461e --- /dev/null +++ b/x11/xmold/files/patch-aa @@ -0,0 +1,13 @@ +--- Imakefile.orig Sat Nov 25 04:07:57 1995 ++++ Imakefile Sat Jan 15 00:00:00 2000 +@@ -1,7 +1,7 @@ +-CC = gcc +-CDEBUGFLAGS=\ ++XCOMM CC = gcc ++XCOMM CDEBUGFLAGS=\ + # -g +-CCOPTIONS=\ ++XCOMM CCOPTIONS=\ + # -O2 + + #ifndef LocalLib diff --git a/x11/xmold/pkg-descr b/x11/xmold/pkg-descr index 4ba0274736b1..b652db4423e2 100644 --- a/x11/xmold/pkg-descr +++ b/x11/xmold/pkg-descr @@ -8,3 +8,5 @@ Recover: xrefresh Yukihiro Nakai<Nakai@Mlab.t.u-tokyo.ac.jp> + +WWW: http://cclub.cc.tut.ac.jp/lib/xwin/xmold.html diff --git a/x11/xzoom/files/patch-aa b/x11/xzoom/files/patch-aa new file mode 100644 index 000000000000..de8ccd7efd1e --- /dev/null +++ b/x11/xzoom/files/patch-aa @@ -0,0 +1,12 @@ +--- Imakefile.orig Wed Apr 17 18:04:51 1996 ++++ Imakefile Sat Jan 15 00:00:00 2000 +@@ -19,7 +19,7 @@ + + NAME = xzoom + +-BINDIR = /usr/local/bin +-MANPATH = /usr/local/man ++XCOMM BINDIR = /usr/local/bin ++XCOMM MANPATH = /usr/local/man + + SimpleProgramTarget($(NAME)) diff --git a/x11/xzoom/files/patch-ab b/x11/xzoom/files/patch-ab new file mode 100644 index 000000000000..46728bbc46f1 --- /dev/null +++ b/x11/xzoom/files/patch-ab @@ -0,0 +1,105 @@ +--- scale.h.orig Sat Jan 15 14:23:58 2000 ++++ scale.h Sat Jan 15 00:00:00 2000 +@@ -0,0 +1,102 @@ ++/* scale image from SRC to DST - parameterized by type T */ ++ ++/* get pixel address of point (x,y) in image t */ ++#define getP(t,x,y) \ ++ (T *) (&ximage[t]->data[(ximage[t]->xoffset+(x))*sizeof(T) + \ ++ (y)*ximage[t]->bytes_per_line]) ++ ++{ ++ int i, j, k; ++ ++ /* copy scaled lines from SRC to DST */ ++ j = flipxy ? width[SRC] - 1 : height[SRC] - 1; ++ do { ++ T *p1; ++ T *p2; ++ int p2step; ++ T *p1_save; ++ ++ /* p1 point to begining of scanline j*magy in DST */ ++ p1 = getP(DST,0,j*magy); ++ p1_save = p1; ++ /* p2 point to begining of scanline j in SRC */ ++ /* if flipy then line height[SRC]-1-j */ ++ p2 = getP(SRC,0,flipy ? (height[SRC]-1-j) : j); ++ ++ if (flipxy) ++ { ++ p2 = getP(SRC,flipy ? j : (width[SRC]-1-j),0); ++ p2step = ximage[SRC]->bytes_per_line / sizeof(T); ++ ++ if (flipx) ++ { ++ p2 += p2step * (height[SRC]-1); ++ p2step = -p2step; ++ } ++ ++ i = height[SRC]; ++ do { ++ T c = *p2; p2 += p2step; ++ k = magx; do *p1++ = c; while (--k > 0); ++ } while (--i > 0); ++ } ++ else if (flipx) ++ { ++ p2 += width[SRC]; ++ i = width[SRC]; ++ do { ++ T c = *--p2; ++ k = magx; do *p1++ = c; while (--k > 0); ++ } while (--i > 0); ++ } ++ else ++ { ++ i = width[SRC]; ++ do { ++ T c = *p2++; ++ k = magx; do *p1++ = c; while (--k > 0); ++ } while (--i > 0); ++ } ++ ++ /* draw vertical grid */ ++ if (gridy && magx >= 2) ++ { ++ p1 = p1_save - 1; ++ i = magx; ++ k = flipxy ? height[SRC] : width[SRC]; ++ do { ++ p1 += i; ++ *p1 ^= ~((T)0); ++ } while (--k > 0); ++ } ++ ++ /* duplicate that line as needed */ ++ if (magy > 1) ++ { ++ /* p1 point to begining of scanline j*magy in DST */ ++ p1 = p1_save; ++ /* p2 points to begining of next line */ ++ p2 = p1; ++ p2step = ximage[DST]->bytes_per_line / sizeof(T); ++ ++ i = width[DST] * sizeof(T); ++ k = magy - 1; ++ do { ++ p2 += p2step; ++ memcpy(p2, p1, i); ++ } while (--k > 0); ++ ++ /* draw horizontal grid */ ++ if (gridx && magy >= 2) ++ { ++ k = width[DST]; ++ do { ++ *p2++ ^= ~((T)0); ++ } while (--k > 0); ++ } ++ } ++ } while (--j >= 0); ++} ++ ++#undef getP ++ diff --git a/x11/xzoom/files/patch-ac b/x11/xzoom/files/patch-ac new file mode 100644 index 000000000000..0a5ed453d0f3 --- /dev/null +++ b/x11/xzoom/files/patch-ac @@ -0,0 +1,427 @@ +--- xzoom.c.orig Wed May 29 18:40:51 1996 ++++ xzoom.c Sat Jan 15 00:00:00 2000 +@@ -12,13 +12,20 @@ + exact location where the source code can be obtained. + + Changelist: +-Author Description +------- ----------- +-Itai Nahshon Version 0.1, Nov. 21 1995 +-Itai Nahshon Version 0.2, Apr. 17 1996 +- include <sys/types.h> +- Use memmove() instead of memcopy() +- Optional macro to replace call to usleep(). ++Author Description ++------ ----------- ++Itai Nahshon Version 0.1, Nov. 21 1995 ++Itai Nahshon Version 0.2, Apr. 17 1996 ++ include <sys/types.h> ++ Use memmove() instead of memcopy() ++ Optional macro to replace call to usleep(). ++Markus F.X.J. Oberhumer Version 0.4, Feb. 18 1998 ++ split into 2 files (scale.h) ++ added support for 15, 16, 24 and 32 bpp displays ++ added a grid (press key 'g') ++ optimized scaling routines ++ use memcpy() instead of memmove() ;-) ++ some other minor changes/fixes + */ + + #include <stdio.h> +@@ -87,8 +94,12 @@ + int xzoom_flag = False; /* next mag change only to magx */ + int yzoom_flag = False; /* next mag change only to magy */ + ++int gridx = False; ++int gridy = False; ++ + int width[2] = { 0, WIDTH }; + int height[2] = { 0, HEIGHT }; ++unsigned depth = 0; + + #ifdef XSHM + XShmSegmentInfo shminfo[2]; /* Segment info. */ +@@ -106,6 +117,7 @@ + void + timeout_func(int signum) { + set_title = True; ++ signum = signum; /* UNUSED */ + } + + #ifdef FRAME +@@ -116,9 +128,6 @@ + void + allocate_images(void) { + int i; +-#ifndef XSHM +- char *data; +-#endif + + for(i = 0; i < 2; i++) { + +@@ -137,7 +146,7 @@ + shminfo[i].shmid = shmget(IPC_PRIVATE, + (unsigned int)(ximage[i]->bytes_per_line * ximage[i]->height), + IPC_CREAT | 0777); +- ++ + if(shminfo[i].shmid < 0) { + perror("shmget"); + exit(-1); +@@ -163,20 +172,21 @@ + + shmctl(shminfo[i].shmid, IPC_RMID, 0); + #else +- data = malloc(width[i] * height[i]); ++ char *data; ++ data = malloc(BitmapUnit(dpy) / 8 * width[i] * height[i]); + + ximage[i] = XCreateImage(dpy, + DefaultVisualOfScreen(scr), + DefaultDepthOfScreen(scr), + ZPixmap, 0, data, +- width[i], height[i], 8, width[i]); ++ width[i], height[i], 32, 0); + + if(ximage[i] == NULL) { + perror("XCreateImage"); + exit(-1); + } + +-#endif XSHM ++#endif /* XSHM */ + } + created_images = True; + } +@@ -185,6 +195,9 @@ + destroy_images(void) { + int i; + ++ if (!created_images) ++ return; ++ + for(i = 0; i < 2; i++) { + #ifdef XSHM + XShmDetach(dpy, &shminfo[i]); /* ask X11 to detach shared segment */ +@@ -195,6 +208,8 @@ + ximage[i]->data = NULL; /* remove refrence to that address */ + XDestroyImage(ximage[i]); /* and destroy image */ + } ++ ++ created_images = False; + } + + void +@@ -230,8 +245,7 @@ + void + resize(int new_width, int new_height) { + +- if(created_images) +- destroy_images(); /* we can get rid of these */ ++ destroy_images(); /* we can get rid of these */ + + /* find new dimensions for source */ + +@@ -244,9 +258,13 @@ + height[SRC] = (new_height+magy-1) / magy; + } + ++ if(width[SRC] < 1) ++ width[SRC] = 1; + if(width[SRC] > WidthOfScreen(scr)) + width[SRC] = WidthOfScreen(scr); + ++ if(height[SRC] < 1) ++ height[SRC] = 1; + if(height[SRC] > HeightOfScreen(scr)) + height[SRC] = HeightOfScreen(scr); + +@@ -270,12 +288,34 @@ + height[DST] = new_height; + } + ++ ++void scale8(void) ++{ ++#define T unsigned char ++#include "scale.h" ++#undef T ++} ++ ++ ++void scale16(void) ++{ ++#define T unsigned short ++#include "scale.h" ++#undef T ++} ++ ++ ++void scale32(void) ++{ ++#define T unsigned int ++#include "scale.h" ++#undef T ++} ++ ++ + int + main(int argc, char **argv) { + XSetWindowAttributes xswa; +- int i, j, k; +- char c; +- char *p1, *p2; + XEvent event; + int buttonpressed = False; + int unmapped = True; +@@ -286,8 +326,9 @@ + int source_geom_mask = NoValue, + dest_geom_mask = NoValue, + copy_from_src_mask; +- int xpos = 0, ypos = 0; ++ int xpos = 0, ypos = 0; + ++ atexit(destroy_images); + progname = strrchr(argv[0], '/'); + if(progname) + ++progname; +@@ -312,7 +353,7 @@ + + if(magx <= 0) + Usage(); +- ++ + + magy = argc > 1 ? atoi(argv[1]) : -1; + +@@ -340,7 +381,7 @@ + flipxy = True; + continue; + } +- ++ + if(!strcmp(argv[0], "-source")) { + ++argv; --argc; + +@@ -438,23 +479,24 @@ + + scr = DefaultScreenOfDisplay(dpy); + +- if(DefaultDepthOfScreen(scr) != 8) { +- fprintf(stderr, "%s: can work only with 8 bits/pixel\n", progname); ++ depth = DefaultDepthOfScreen(scr); ++ if (depth < 8) { ++ fprintf(stderr, "%s: need at least 8 bits/pixel\n", progname); + exit(1); + } + + if(source_geom_mask & XNegative) + xgrab += WidthOfScreen(scr); +- ++ + if(source_geom_mask & YNegative) + ygrab += HeightOfScreen(scr); + + if(dest_geom_mask & XNegative) + xpos += WidthOfScreen(scr); +- ++ + if(source_geom_mask & YNegative) + ypos += HeightOfScreen(scr); +- ++ + /* printf("=%dx%d+%d+%d\n", width[DST], height[DST], xpos, ypos); */ + + xswa.event_mask = ButtonPressMask|ButtonReleaseMask|ButtonMotionMask; +@@ -463,17 +505,17 @@ + xswa.background_pixel = BlackPixelOfScreen(scr); + + win = XCreateWindow(dpy, RootWindowOfScreen(scr), +- xpos, ypos, width[DST], height[DST], 0, ++ xpos, ypos, width[DST], height[DST], 0, + DefaultDepthOfScreen(scr), InputOutput, + DefaultVisualOfScreen(scr), + CWEventMask | CWBackPixel, &xswa); + +- XChangeProperty(dpy, win, XA_WM_ICON_NAME, XA_STRING, 8, ++ XChangeProperty(dpy, win, XA_WM_ICON_NAME, XA_STRING, 8, + PropModeReplace, + (unsigned char *)progname, strlen(progname)); + + /* +- XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, ++ XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, + PropModeReplace, + (unsigned char *)progname, strlen(progname)); + */ +@@ -512,7 +554,7 @@ + { + static char bitmap_data[] = { 0 }; + static XColor col = { 0 }; +- Pixmap curs = XCreatePixmapFromBitmapData(dpy, ++ Pixmap curs = XCreatePixmapFromBitmapData(dpy, + RootWindowOfScreen(scr), bitmap_data, 1, 1, 0, 0, 1); + + when_button = XCreatePixmapCursor(dpy, curs, curs, &col, &col, 0, 0); +@@ -567,6 +609,7 @@ + + case '+': + case '=': ++ case XK_KP_Add: + if(!yzoom_flag) ++magx; + if(!xzoom_flag) ++magy; + xzoom_flag = yzoom_flag = False; +@@ -575,6 +618,7 @@ + break; + + case '-': ++ case XK_KP_Subtract: + if(!yzoom_flag) --magx; + if(!xzoom_flag) --magy; + xzoom_flag = yzoom_flag = False; +@@ -585,6 +629,7 @@ + break; + + case XK_Left: ++ case XK_KP_Left: + if(flipxy) + if(flipx) + ygrab += scroll; +@@ -598,6 +643,7 @@ + break; + + case XK_Right: ++ case XK_KP_Right: + if(flipxy) + if(flipx) + ygrab -= scroll; +@@ -611,6 +657,7 @@ + break; + + case XK_Up: ++ case XK_KP_Up: + if(flipxy) + if(flipy) + xgrab -= scroll; +@@ -624,6 +671,7 @@ + break; + + case XK_Down: ++ case XK_KP_Down: + if(flipxy) + if(flipy) + xgrab += scroll; +@@ -666,12 +714,17 @@ + xzoom_flag = False; + break; + ++ case 'g': ++ gridx = !gridx; ++ gridy = !gridy; ++ break; ++ + case 'd': + if(++delay_index >= NDELAYS) + delay_index = 0; + delay = delays[delay_index]; + sprintf(title, "delay = %d ms", delay/1000); +- XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, ++ XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, + PropModeReplace, + (unsigned char *)title, strlen(title)); + signal(SIGALRM, timeout_func); +@@ -717,6 +770,7 @@ + #endif + } + break; ++ + } + + /* trying XShmGetImage when part of the rect is +@@ -736,6 +790,7 @@ + + if(ygrab > HeightOfScreen(scr)-height[SRC]) + ygrab = HeightOfScreen(scr)-height[SRC]; ++ + } + + #ifdef XSHM +@@ -753,63 +808,12 @@ + } + #endif + +- /* copy scaled lines from src to dst */ +- for(j = flipxy?width[SRC]:height[SRC]; --j >= 0; ) { +- /* p1 point to begining of scanline j*magy in DST */ +- p1 = &ximage[DST]->data[ximage[DST]->xoffset + +- j*magy*ximage[DST]->bytes_per_line ]; +- /* p2 point to begining of scanline j in SRC */ +- /* if flipy then line height[SRC]-1-j */ +- p2 = &ximage[SRC]->data[ximage[SRC]->xoffset + +- (flipy?(height[SRC]-1-j):j)*ximage[SRC]->bytes_per_line ]; +- +- if(flipxy) { +- int p2step = ximage[SRC]->bytes_per_line; +- p2 = &ximage[SRC]->data[ximage[SRC]->xoffset + (flipy?j:(width[SRC]-1-j))]; +- +- if(flipx) { +- p2 += p2step * (height[SRC]-1); +- p2step = -p2step; +- } +- +- for(i = height[SRC]; --i >= 0;) { +- c = *p1++ = *p2; +- p2 += p2step; +- for(k = magx; --k > 0; ) +- *p1++ = c; +- } +- } +- else if(flipx) { +- p2 += width[SRC]; +- for(i = width[SRC]; --i >= 0;) { +- c = *p1++ = *--p2; +- for(k = magx; --k > 0; ) +- *p1++ = c; +- } +- } +- else { +- for(i = width[SRC]; --i >= 0;) { +- c = *p1++ = *p2++; +- for(k = magx; --k > 0; ) +- *p1++ = c; +- } +- } +- +- /* p1 point to begining of scanline j*magy in DST */ +- p1 = &ximage[DST]->data[ximage[DST]->xoffset + +- j*magy*ximage[DST]->bytes_per_line ]; +- /* p2 points to begining of next line */ +- p2 = p1 + ximage[DST]->bytes_per_line; +- /* duplicate that line as needed */ +- for(k = magy; --k > 0; ) { +-#ifdef BCOPY +- bcopy(p1, p2, width[DST]); +-#else +- memmove(p2, p1, width[DST]); +-#endif +- p2 += ximage[DST]->bytes_per_line; +- } +- } ++ if (depth == 8) ++ scale8(); ++ else if (depth <= 8*sizeof(short)) ++ scale16(); ++ else if (depth <= 8*sizeof(int)) ++ scale32(); + + #ifdef XSHM + XShmPutImage(dpy, win, gc, ximage[DST], 0, 0, 0, 0, width[DST], height[DST], False); +@@ -825,7 +829,7 @@ + flipx?"-":"", magx, + flipxy?" <=>":";", + flipy?"-":"", magy); +- XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, ++ XChangeProperty(dpy, win, XA_WM_NAME, XA_STRING, 8, + PropModeReplace, + (unsigned char *)title, strlen(title)); + set_title = False; diff --git a/x11/xzoom/files/patch-ad b/x11/xzoom/files/patch-ad new file mode 100644 index 000000000000..e47b307f4a81 --- /dev/null +++ b/x11/xzoom/files/patch-ad @@ -0,0 +1,21 @@ +--- xzoom.man.orig Thu Apr 18 01:37:48 1996 ++++ xzoom.man Sat Jan 15 00:00:00 2000 +@@ -3,7 +3,7 @@ + .\" + .TH XZOOM 1X + .SH NAME +-xzoom \- ++xzoom \- magnify part of the screen, with fast updates + .SH SYNOPSIS + .B xzoom + [ \-display \fIdisplayname\fP ] [ \-mag \fImag\fP [ \fImag\fP ] ] +@@ -84,6 +84,9 @@ + .B d + sets the delay between frame updates. + Built-in delays are 200, 100, 50, 10 and 0 ms. ++.TP 5 ++.B g ++toggle grid on and off. + .TP 5 + .B Mouse buttons + To set the location of the magnified are click the left mouse |