w3m

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/w3m.git/
Log | Files | Refs | README

commit a9582e11b2f233f6c1f46d9aed00ce95f3119130
parent 7aa7b923cfbcfb30ef29dd14044b45db4b936da8
Author: ukai <ukai>
Date:   Wed,  4 Dec 2002 17:08:26 +0000

[w3m-dev 03524] fix doc*/README.func, w3mhelp.cgi.in
* doc/README.func (REINIT): added
* doc-jp/README.func (REINIT): added
* scripts/w3mhelp.cgi.in (Page/Cursor motion):
			add moveR1 movL1 movD1 movU1 ldown1 lup1
	(File/Stream operation): add pipeBuf
	(Miscellany): add dispVer execCmd reinit
	(load_keymap): rewrite
	(norm_key): rewrite
From: Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>

Diffstat:
MChangeLog | 12++++++++++++
Mdoc-jp/README.func | 1+
Mdoc/README.func | 1+
Mscripts/w3mhelp.cgi.in | 41++++++++++++++++++++++-------------------
4 files changed, 36 insertions(+), 19 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,15 @@ +2002-12-05 Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp> + + * [w3m-dev 03524] fix doc*/README.func, w3mhelp.cgi.in + * doc/README.func (REINIT): added + * doc-jp/README.func (REINIT): added + * scripts/w3mhelp.cgi.in (Page/Cursor motion): + add moveR1 movL1 movD1 movU1 ldown1 lup1 + (File/Stream operation): add pipeBuf + (Miscellany): add dispVer execCmd reinit + (load_keymap): rewrite + (norm_key): rewrite + 2002-12-05 Fumitoshi UKAI <ukai@debian.or.jp> * NEWS: rc: display_ins_del diff --git a/doc-jp/README.func b/doc-jp/README.func @@ -94,6 +94,7 @@ QUIT w3m READ_SHELL コマンドを実行し,結果を全部読んでから表示します REDRAW 再描画します REG_MARK 正規表現で指定された文字列を全てマークします +REINIT 設定ファイルを再読込します。 RELOAD バッファを再度読み込みます RIGHT 画面全体を1文字右にずらします SAVE 文書のソースをファイルに保存します diff --git a/doc/README.func b/doc/README.func @@ -94,6 +94,7 @@ QUIT Quit w3m READ_SHELL Execute shell command and load REDRAW Redraw screen REG_MARK Set mark using regexp +REINIT Reload configuration files RELOAD Reload buffer RIGHT Shift screen one column right SAVE Save document source to file diff --git a/scripts/w3mhelp.cgi.in b/scripts/w3mhelp.cgi.in @@ -130,11 +130,12 @@ for $otherlang (@docdirs) { } &show_keymap("Page/Cursor motion", - split(" ", "pgFore pgBack movR movL movD movU ldown1 lup1 + split(" ", "pgFore pgBack movR movL movD movU + movR1 movL1 movD1 movU1 ldown1 lup1 shiftl shiftr col1L col1R linbeg linend ctrCsrH ctrCsrV goLine goLineF goLineL movRW movLW topA lastA nextA prevA - nextR nextRD nextL nextRD nextLU nextD nextU")); + nextR nextL nextD nextU nextRD nextLU")); &show_keymap("Hyperlink operation", split(" ", "followA tabA svA followI svI submitForm @@ -142,7 +143,8 @@ for $otherlang (@docdirs) { rFrame extbrz linkbrz")); &show_keymap("File/Stream operation", - split(" ", "goURL gorURL tabURL tabrURL ldfile readsh pipesh")); + split(" ", "goURL gorURL tabURL tabrURL ldfile readsh pipesh + pipeBuf")); &show_keymap("Buffer operation", split(" ", "backBf nextBf prevBf selMn selBuf vwSrc svSrc svBuf @@ -164,8 +166,9 @@ for $otherlang (@docdirs) { split(" ", "_mark nextMk prevMk reMark")); &show_keymap("Miscellany", - split(" ", "mainMn ldhelp ldOpt cooLst ldHist ldDL msgs msToggle - wrapToggle setAlarm setOpt setEnv execsh susp qquitfm quitfm defKey")); + split(" ", "mainMn ldhelp ldOpt dispVer cooLst ldHist ldDL + msgs msToggle wrapToggle execCmd setAlarm setOpt setEnv defKey + reinit execsh susp qquitfm quitfm")); &show_keymap("Buffer selection mode", split(" ", "buffer_next buffer_prev buffer_delete buffer_go")); @@ -189,13 +192,14 @@ sub load_keymap { local($func) = @_; while (<FH>) { - next if /^#/; - next if /^\s*$/; - ($keymap, $key, $fname, $data) = split; - next if $data; - next unless $keymap =~ /keymap/; + /^#/ && next; + s/^\s*keymap\s+// || next; + s/^(\"(\\\"|[^\"])+\"|\'(\\\'|[^\'])+\'|\S+)\s+(\S+)\s*// || next; + ($key, $fname) = ($1, $4); + ($data = $_) && next; $fname =~ tr/a-z/A-Z/; - next unless (defined($funcdesc{$fname})); + defined($funcdesc{$fname}) || next; + $key =~ s/^["'](.*)["']$/$1/; $key = &norm_key($key); $keyfunc{$key} = $fname; } @@ -205,19 +209,18 @@ sub norm_key { local($_) = @_; s/\\(.)/$1/g; - s/^\^(.)/C-$1/; - s/^(C-\[|M-)/ESC-/; + s/(^|\s+|-)\^(.)/${1}C-$2/g; + s/(^|\s+|-)(C-\[|M-)/${1}ESC-/g; if (/^ESC-\[/) { /^ESC-\[A$/ && return "UP"; /^ESC-\[B$/ && return "DOWN"; /^ESC-\[C$/ && return "RIGHT"; /^ESC-\[D$/ && return "LEFT"; - s/^ESC-/\^\[/; - return $_; } - s/^ESC-\^(.)/ESC-C-$1/; - s/^(ESC-)?C-[iI]/${1}TAB/; - s/^(ESC-)?C-\?/${1}DEL/; + s/(^|\s+|-)ESC-\[/$1\^\[\[/g; + s/(^|\s+|-)ESC-\^(.)/${1}ESC-C-$2/g; + s/(^|\s+|-)(ESC-)?C-[iI]/$1${2}TAB/g; + s/(^|\s+|-)(ESC-)?C-\?/$1${2}DEL/g; return $_; } @@ -242,7 +245,7 @@ PAGE $keys =~ s/[<>&]/$htmlesc{$&}/ge; $desc =~ s/[<>&]/$htmlesc{$&}/ge; print <<PAGE; -<TR><TD$attr>$keys</TD><TD>$desc</TD></TR> +<TR><TD$attr>$keys<TD>$desc PAGE $attr = ""; }