From 9d4b26e1e491e2a0e8348f0b1d4fc2e288db851f Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Wed, 16 Jan 2002 16:49:53 +0000 Subject: [w3m-dev 02859] * config.h.dist (DEF_MIGEMO_COMMAND): added * configure (DEF_MIGEMO_COMMAND): added * fm.h (migemo_command): initial value is DEF_MIGEMO_COMMAND * main.c (migemostr): remove here, move search.c * main.c (srchcore): dont migemostr() here * proto.h (init_migemo): added * rc.c (sync_with_option): init_migemo() * search.c (init_migemo): added * search.c (open_migemo): added * search.c (migemostr): communicate background migemo * search.c (forwardSearch): if regexCompile for migemostr failed, try original str * search.c (backwardSearch): ditto From: Fumitoshi UKAI --- main.c | 26 ++------------------------ 1 file changed, 2 insertions(+), 24 deletions(-) (limited to 'main.c') diff --git a/main.c b/main.c index afc3184..c660faa 100644 --- a/main.c +++ b/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.61 2002/01/16 16:11:38 ukai Exp $ */ +/* $Id: main.c,v 1.62 2002/01/16 16:49:54 ukai Exp $ */ #define MAINPROGRAM #include "fm.h" #include @@ -1333,24 +1333,6 @@ rdrwSc(void) displayBuffer(Currentbuf, B_FORCE_REDRAW); } -#ifdef USE_MIGEMO -/* Migemo: romaji --> kana+kanji in regexp */ -static char * -migemostr(char *str) -{ - FILE *f; - Str tmp; - - tmp = Strnew_m_charp(migemo_command, " ", shell_quote(str), NULL); - if (!(f = popen(tmp->ptr, "r"))) - return str; - tmp = Strfgets(f); - Strchop(tmp); - pclose(f); - return tmp->ptr; -} -#endif /* USE_MIGEMO */ - static void clear_mark(Line *l) { @@ -1369,11 +1351,7 @@ srchcore(char *str, int (*func) (Buffer *, char *)) volatile int i, result = SR_NOTFOUND; if (str != NULL && str != SearchString) - SearchString = -#ifdef USE_MIGEMO - use_migemo ? migemostr(str) : -#endif /* USE_MIGEMO */ - str; + SearchString = str; if (SearchString == NULL || *SearchString == '\0') return SR_NOTFOUND; -- cgit v1.2.3