diff options
author | Dai Sato <satodai@dog.intcul.tohoku.ac.jp> | 2002-07-01 10:50:53 +0000 |
---|---|---|
committer | Dai Sato <satodai@dog.intcul.tohoku.ac.jp> | 2002-07-01 10:50:53 +0000 |
commit | 589cabdbdcbb714edb87ddf85713800c8d9114c3 (patch) | |
tree | c9a92afcea93edabde2006610c3c9ab3feccdf59 /main.c | |
parent | [w3m-dev 03233] "obuf->flag |= RB_IGNORE_P" after <body> tag (diff) | |
download | w3m-589cabdbdcbb714edb87ddf85713800c8d9114c3.tar.gz w3m-589cabdbdcbb714edb87ddf85713800c8d9114c3.zip |
add prec_num to topA/lastA
Diffstat (limited to '')
-rw-r--r-- | main.c | 16 |
1 files changed, 11 insertions, 5 deletions
@@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.107 2002/06/09 16:09:25 ukai Exp $ */ +/* $Id: main.c,v 1.108 2002/07/01 10:51:58 inu Exp $ */ #define MAINPROGRAM #include "fm.h" #include <signal.h> @@ -3273,14 +3273,17 @@ topA(void) HmarkerList *hl = Currentbuf->hmarklist; BufferPoint *po; Anchor *an; - int hseq; + int hseq = 0; if (Currentbuf->firstLine == NULL) return; if (!hl || hl->nmark == 0) return; - hseq = 0; + if (prec_num > hl->nmark) + hseq = hl->nmark - 1; + else if (prec_num > 0) + hseq = prec_num - 1; do { if (hseq >= hl->nmark) return; @@ -3304,14 +3307,17 @@ lastA(void) HmarkerList *hl = Currentbuf->hmarklist; BufferPoint *po; Anchor *an; - int hseq; + int hseq = hl->nmark - 1; if (Currentbuf->firstLine == NULL) return; if (!hl || hl->nmark == 0) return; - hseq = hl->nmark - 1; + if( prec_num >= hl->nmark ) + hseq = 0; + else if( prec_num > 0 ) + hseq = hl->nmark - prec_num; do { if (hseq < 0) return; |