From 12f4fdd4872dac294b89bcf984492bc88dca0b5e Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Tue, 28 Jul 2015 18:38:55 +0000 Subject: Remove the hack of scrolling forward and backward with +G1G that many (jmc@, millert@, espie@, deraadt@) considered revolting. Instead, when using a pager, since we are using a temporary file for tags anyway, use another temporary file for the formatted page(s), as suggested by millert@ and similar to what the traditional BSD man(1) did, except that we use only one single temporary output file rather than one for each formatted manual page, such that searching (both with / and :t) works across all the displayed files. --- tag.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'tag.h') diff --git a/tag.h b/tag.h index 34a7eee2..0cf5c90b 100644 --- a/tag.h +++ b/tag.h @@ -1,4 +1,4 @@ -/* $Id: tag.h,v 1.4 2015/07/25 14:28:59 schwarze Exp $ */ +/* $Id: tag.h,v 1.5 2015/07/28 18:38:55 schwarze Exp $ */ /* * Copyright (c) 2015 Ingo Schwarze * @@ -15,9 +15,16 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +struct tag_files { + char ofn[20]; + char tfn[20]; + int ofd; + int tfd; +}; + __BEGIN_DECLS -char *tag_init(void); +struct tag_files *tag_init(void); void tag_put(const char *, int, size_t); void tag_write(void); void tag_unlink(void); -- cgit v1.2.3-56-ge451