Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libcurses Display default (HLINE/VLINE) characters when ...
details: https://anonhg.NetBSD.org/src/rev/b7e6e3408507
branches: trunk
changeset: 503430:b7e6e3408507
user: jdc <jdc%NetBSD.org@localhost>
date: Mon Feb 05 21:56:36 2001 +0000
description:
Display default (HLINE/VLINE) characters when character 0 is passed in.
This is not in the SUSv2 specification but is what System V curses does
(and it's consistent with box() and border()).
diffstat:
lib/libcurses/line.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (36 lines):
diff -r 234c184dcd14 -r b7e6e3408507 lib/libcurses/line.c
--- a/lib/libcurses/line.c Mon Feb 05 21:54:21 2001 +0000
+++ b/lib/libcurses/line.c Mon Feb 05 21:56:36 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: line.c,v 1.1 2000/04/24 14:09:44 blymn Exp $ */
+/* $NetBSD: line.c,v 1.2 2001/02/05 21:56:36 jdc Exp $ */
/*-
* Copyright (c) 1998-1999 Brett Lymn
@@ -31,7 +31,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: line.c,v 1.1 2000/04/24 14:09:44 blymn Exp $");
+__RCSID("$NetBSD: line.c,v 1.2 2001/02/05 21:56:36 jdc Exp $");
#endif /* not lint */
#include "curses.h"
@@ -86,6 +86,8 @@
n = min(count, win->maxx - win->curx);
ocurx = win->curx;
+ if (!(ch & __CHARTEXT))
+ ch |= ACS_HLINE;
for (i = 0; i < n; i++)
mvwaddch(win, win->cury, ocurx + i, ch);
@@ -142,6 +144,8 @@
ocury = win->cury;
ocurx = win->curx;
+ if (!(ch & __CHARTEXT))
+ ch |= ACS_VLINE;
for (i = 0; i < n; i++)
mvwaddch(win, ocury + i, ocurx, ch);
Home |
Main Index |
Thread Index |
Old Index