Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Sep 1999 19:14:28 +0200 (CEST)
From:      Christian Weisgerber <naddy@unix-ag.uni-kl.de>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/13762: Additional patches for editors/elvis
Message-ID:  <199909151714.TAA74394@fettuccini.unix-ag.uni-kl.de>

next in thread | raw e-mail | index | archive | help

>Number:         13762
>Category:       ports
>Synopsis:       Additional patches for editors/elvis
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 15 10:20:00 PDT 1999
>Closed-Date:
>Last-Modified:
>Originator:     Christian Weisgerber
>Release:        FreeBSD 4.0-CURRENT i386
>Organization:
Unix-AG, Uni Kaiserslautern
>Environment:

n/a

>Description:

Adds two patches to the editors/elvis port:
- guix11: add support for XK_KP_* cursor keys (keypad with Numlock off).
- ctags: main() should return int rather than void.

>How-To-Repeat:

n/a

>Fix:

diff -uNr /usr/ports/editors/elvis/patches/patch-ab elvis/patches/patch-ab
--- /usr/ports/editors/elvis/patches/patch-ab	Thu Jan  1 01:00:00 1970
+++ elvis/patches/patch-ab	Wed Sep 15 18:53:10 1999
@@ -0,0 +1,107 @@
+--- guix11/xdialog.c.orig	Tue Jul  6 20:07:34 1999
++++ guix11/xdialog.c	Wed Sep 15 17:16:51 1999
+@@ -802,7 +802,9 @@
+ 	switch (key)
+ 	{
+ 	  case XK_Left:
++	  case XK_KP_Left:
+ 	  case XK_Right:
++	  case XK_KP_Right:
+ 		/* find the current value */
+ 		val = dia->field[dia->current].value;
+ 		i = CHARlen(val);
+@@ -813,7 +815,7 @@
+ 		}
+ 
+ 		/* move left or right */
+-		if (key == XK_Left)
++		if (key == XK_Left || key == XK_KP_Left)
+ 			this--;
+ 		else
+ 			this++;
+@@ -869,11 +871,13 @@
+ 	switch (key)
+ 	{
+ 	  case XK_Left:
++	  case XK_KP_Left:
+ 		if (dia->cursor > 0)
+ 			dia->cursor--;
+ 		break;
+ 
+ 	  case XK_Right:
++	  case XK_KP_Right:
+ 		if (dia->cursor < origlen)
+ 			dia->cursor++;
+ 		break;
+@@ -898,10 +902,12 @@
+ 		break;
+ 
+ 	  case XK_Home:
++	  case XK_KP_Home:
+ 		dia->cursor = 0;
+ 		break;
+ 
+ 	  case XK_End:
++	  case XK_KP_End:
+ 		dia->cursor = CHARlen(dia->field[dia->current].value);
+ 		break;
+ 
+@@ -916,6 +922,7 @@
+ 
+ 	  case '\177':
+ 	  case XK_Delete:
++	  case XK_KP_Delete:
+ 		if (dia->cursor < origlen)
+ 			CHARcpy(&orig[dia->cursor], &orig[dia->cursor + 1]);
+ 		break;
+@@ -955,6 +962,7 @@
+ 	  case '\n':
+ 	  case XK_Linefeed:
+ 	  case XK_Return:
++	  case XK_KP_Enter:
+ 		/* store the values of all options */
+ 		eventfocus((GUIWIN *)dia->xw);
+ 		for (i = 0; i < dia->nfields; i++)
+@@ -991,10 +999,12 @@
+ 		break;
+ 
+ 	  case XK_Up:
++	  case XK_KP_Up:
+ 		makecurrent(dia, dia->current - 1);
+ 		break;
+ 
+ 	  case XK_Down:
++	  case XK_KP_Down:
+   		makecurrent(dia, dia->current + 1);
+ 		break;
+ 
+--- guix11/guix11.c.orig	Tue Jul  6 20:07:34 1999
++++ guix11/guix11.c	Wed Sep 15 17:23:32 1999
+@@ -152,16 +152,27 @@
+ } keys[] =
+ {
+ 	{ "<Up>",	XK_Up,		"k",	MAP_ALL },
++	{ "<KP_Up>",	XK_KP_Up,	"k",	MAP_ALL },
+ 	{ "<Down>",	XK_Down,	"j",	MAP_ALL },
++	{ "<KP_Down>",	XK_KP_Down,	"j",	MAP_ALL },
+ 	{ "<Left>",	XK_Left,	"h",	MAP_ALL },
++	{ "<KP_Left>",	XK_KP_Left,	"h",	MAP_ALL },
+ 	{ "<Right>",	XK_Right,	"l",	MAP_ALL },
++	{ "<KP_Right>",	XK_KP_Right,	"l",	MAP_ALL },
+ 	{ "<Prior>",	XK_Prior,	"\002",	MAP_ALL_VISUAL },
++	{ "<KP_Prior>",	XK_KP_Prior,	"\002",	MAP_ALL_VISUAL },
+ 	{ "<Next>",	XK_Next,	"\006",	MAP_ALL_VISUAL },
++	{ "<KP_Next>",	XK_KP_Next,	"\006",	MAP_ALL_VISUAL },
+ 	{ "<Home>",	XK_Home,	"^",	MAP_ALL },
++	{ "<KP_Home>",	XK_KP_Home,	"^",	MAP_ALL },
+ 	{ "<Begin>",	XK_Begin,	"^",	MAP_ALL },
++	{ "<KP_Begin>",	XK_KP_Begin,	"^",	MAP_ALL },
+ 	{ "<End>",	XK_End,		"$",	MAP_ALL },
++	{ "<KP_End>",	XK_KP_End,	"$",	MAP_ALL },
+ 	{ "<Insert>",	XK_Insert,	"i",	MAP_ALL },
++	{ "<KP_Insert>",XK_KP_Insert,	"i",	MAP_ALL },
+ 	{ "<Delete>",	XK_Delete,	"x",	MAP_ALL },
++	{ "<KP_Delete>",XK_KP_Delete,	"x",	MAP_ALL },
+ 	{ "<Undo>",	XK_Undo,	"u",	MAP_ALL_VISUAL },
+ 	{ "<Help>",	XK_Help,	":help\r",MAP_ALL_VISUAL },
+ 	{ "<Multi_key>",XK_Multi_key,	"\013",	MAP_INPUT|MAP_OPEN }
diff -uNr /usr/ports/editors/elvis/patches/patch-ac elvis/patches/patch-ac
--- /usr/ports/editors/elvis/patches/patch-ac	Thu Jan  1 01:00:00 1970
+++ elvis/patches/patch-ac	Wed Sep 15 18:53:17 1999
@@ -0,0 +1,20 @@
+--- ctags.c.orig	Tue Jul  6 20:07:31 1999
++++ ctags.c	Wed Sep 15 17:44:00 1999
+@@ -58,7 +58,7 @@
+ extern void	maketag P_((int, char *, long, long, int, char *));
+ extern void	ctags P_((char *));
+ extern void	usage P_((void));
+-extern void	main P_((int, char **));
++extern int	main P_((int, char **));
+ 
+ 
+ #if defined (GUI_WIN32)
+@@ -1022,7 +1022,7 @@
+ 
+ 
+ 
+-void main(argc, argv)
++int main(argc, argv)
+ 	int	argc;
+ 	char	**argv;
+ {

>Release-Note:
>Audit-Trail:
>Unformatted:


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199909151714.TAA74394>