Quote some characters for HTML output.
This commit is contained in:
parent
8d8d8b951d
commit
81b12ac32b
@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: mbrlen.3,v 1.6 2004/01/24 16:58:54 wiz Exp $
|
||||
.\" $NetBSD: mbrlen.3,v 1.7 2006/08/08 17:31:35 wiz Exp $
|
||||
.\"
|
||||
.\" Copyright (c)2002 Citrus Project,
|
||||
.\" All rights reserved.
|
||||
@ -55,7 +55,7 @@ is equivalent to the following call (except
|
||||
.Fa ps
|
||||
is evaluated only once):
|
||||
.Bd -literal -offset indent
|
||||
mbrtowc(NULL, s, n, (ps != NULL) ? ps : &internal);
|
||||
mbrtowc(NULL, s, n, (ps != NULL) ? ps : \*[Am]internal);
|
||||
.Ed
|
||||
.Pp
|
||||
Here,
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: nl_langinfo.3,v 1.15 2005/10/03 19:20:53 wiz Exp $
|
||||
.\" $NetBSD: nl_langinfo.3,v 1.16 2006/08/08 17:31:35 wiz Exp $
|
||||
.\"
|
||||
.\" Written by J.T. Conklin <jtc@NetBSD.org>.
|
||||
.\" Public domain.
|
||||
@ -101,9 +101,9 @@ The following example uses
|
||||
to obtain the date and time format for the current locale:
|
||||
.Pp
|
||||
.Bd -literal -offset indent
|
||||
#include <time.h>
|
||||
#include <langinfo.h>
|
||||
#include <locale.h>
|
||||
#include \*[Lt]time.h\*[Gt]
|
||||
#include \*[Lt]langinfo.h\*[Gt]
|
||||
#include \*[Lt]locale.h\*[Gt]
|
||||
|
||||
int main(void)
|
||||
{
|
||||
@ -113,7 +113,7 @@ int main(void)
|
||||
char *ptr;
|
||||
|
||||
t = time(NULL);
|
||||
tm = localtime(&t);
|
||||
tm = localtime(\*[Am]t);
|
||||
(void)setlocale(LC_ALL, "");
|
||||
ptr = nl_langinfo(D_T_FMT);
|
||||
strftime(datestring, sizeof(datestring), ptr, tm);
|
||||
@ -127,8 +127,8 @@ int main(void)
|
||||
.\" to obtain the setting of the currency symbol for the current locale:
|
||||
.\" .Pp
|
||||
.\" .Bd
|
||||
.\" #include <langinfo.h>
|
||||
.\" #include <locale.h>
|
||||
.\" #include \*[Lt]langinfo.h\*[Gt]
|
||||
.\" #include \*[Lt]locale.h\*[Gt]
|
||||
.\" int main(void)
|
||||
.\" {
|
||||
.\" char *ptr;
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: wcwidth.3,v 1.1 2006/06/03 04:36:45 tnozaki Exp $
|
||||
.\" $NetBSD: wcwidth.3,v 1.2 2006/08/08 17:31:35 wiz Exp $
|
||||
.\" FreeBSD: src/lib/libc/locale/wcwidth.3,v 1.6 2004/08/17 04:56:03 trhodes Exp
|
||||
.\"
|
||||
.\" Copyright (c) 2002 Tim J. Robbins
|
||||
@ -68,14 +68,14 @@ int column, w;
|
||||
column = 0;
|
||||
while ((ch = getwchar()) != WEOF) {
|
||||
w = wcwidth(ch);
|
||||
if (w > 0 && column + w >= 20) {
|
||||
if (w \*[Gt] 0 \*[Am]\*[Am] column + w \*[Gt]= 20) {
|
||||
putwchar(L'\en');
|
||||
column = 0;
|
||||
}
|
||||
putwchar(ch);
|
||||
if (ch == L'\en')
|
||||
column = 0;
|
||||
else if (w > 0)
|
||||
else if (w \*[Gt] 0)
|
||||
column += w;
|
||||
}
|
||||
.Ed
|
||||
|
Loading…
Reference in New Issue
Block a user