From b411c1109dc4305a231689405e214f2e307c3cde Mon Sep 17 00:00:00 2001 From: Fumitoshi UKAI Date: Wed, 24 Sep 2003 18:48:58 +0000 Subject: fix indent --- anchor.c | 11 +-- display.c | 25 ++++--- entity.c | 6 +- etc.c | 8 +-- file.c | 238 +++++++++++++++++++++++++++++++------------------------------- fm.h | 8 +-- func.c | 13 ++-- hash.h | 4 +- html.c | 5 +- linein.c | 6 +- main.c | 21 +++--- map.c | 8 +-- menu.c | 20 +++--- rc.c | 34 ++++----- regex.c | 6 +- table.c | 20 +++--- 16 files changed, 226 insertions(+), 207 deletions(-) diff --git a/anchor.c b/anchor.c index d78163d..4244d47 100644 --- a/anchor.c +++ b/anchor.c @@ -1,4 +1,4 @@ -/* $Id: anchor.c,v 1.28 2003/09/22 21:02:16 ukai Exp $ */ +/* $Id: anchor.c,v 1.29 2003/09/24 18:48:58 ukai Exp $ */ #include "fm.h" #include "myctype.h" #include "regex.h" @@ -811,7 +811,8 @@ link_list_panel(Buffer *buf) if (a->title && *a->title) t = html_quote(a->title); else if (DecodeURL) - t = html_quote(url_unquote_conv(a->url, buf->document_charset)); + t = html_quote(url_unquote_conv + (a->url, buf->document_charset)); else t = html_quote(a->url); Strcat_m_charp(tmp, "
  • ", t, "
    ", p, @@ -838,14 +839,16 @@ link_list_panel(Buffer *buf) u = html_quote(p); if (DecodeURL) p = html_quote(url_unquote_conv(p, - buf->document_charset)); + buf-> + document_charset)); else p = u; if (m->alt && *m->alt) t = html_quote(m->alt); else if (DecodeURL) t = html_quote(url_unquote_conv(m->url, - buf->document_charset)); + buf-> + document_charset)); else t = html_quote(m->url); Strcat_m_charp(tmp, "
  • ", t, diff --git a/display.c b/display.c index a2785ba..457ebc6 100644 --- a/display.c +++ b/display.c @@ -1,10 +1,11 @@ -/* $Id: display.c,v 1.66 2003/09/22 21:02:17 ukai Exp $ */ +/* $Id: display.c,v 1.67 2003/09/24 18:48:59 ukai Exp $ */ #include #include "fm.h" #define MAX(a, b) ((a) > (b) ? (a) : (b)) #define MIN(a, b) ((a) < (b) ? (a) : (b)) +/* *INDENT-OFF* */ #ifdef USE_COLOR #define EFFECT_ANCHOR_START effect_anchor_start() @@ -20,8 +21,17 @@ #define EFFECT_MARK_START effect_mark_start() #define EFFECT_MARK_END effect_mark_end() -/* color: * 0 black * 1 red * 2 green * 3 yellow - * * 4 blue * 5 magenta * 6 cyan * 7 white */ +/*- + * color: + * 0 black + * 1 red + * 2 green + * 3 yellow + * 4 blue + * 5 magenta + * 6 cyan + * 7 white + */ #define EFFECT_ANCHOR_START_C setfcolor(anchor_color) #define EFFECT_IMAGE_START_C setfcolor(image_color) @@ -62,6 +72,7 @@ #define define_effect(name_start,name_end,color_start,color_end,mono_start,mono_end) \ static void name_start { if (useColor) { color_start; } else { mono_start; }}\ static void name_end { if (useColor) { color_end; } else { mono_end; }} + define_effect(EFFECT_ANCHOR_START, EFFECT_ANCHOR_END, EFFECT_ANCHOR_START_C, EFFECT_ANCHOR_END_C, EFFECT_ANCHOR_START_M, EFFECT_ANCHOR_END_M) define_effect(EFFECT_IMAGE_START, EFFECT_IMAGE_END, EFFECT_IMAGE_START_C, @@ -72,7 +83,6 @@ define_effect(EFFECT_MARK_START, EFFECT_MARK_END, EFFECT_MARK_START_C, EFFECT_MARK_END_C, EFFECT_MARK_START_M, EFFECT_MARK_END_M) /*****************/ -/* *INDENT-OFF* */ static void EFFECT_ACTIVE_START { @@ -131,7 +141,7 @@ EFFECT_VISITED_END } } } -/* *INDENT-ON* */ + #else /* not USE_COLOR */ #define EFFECT_ANCHOR_START underline() @@ -147,9 +157,8 @@ EFFECT_VISITED_END #define EFFECT_MARK_START standout() #define EFFECT_MARK_END standend() #endif /* not USE_COLOR */ -/* - * Terminate routine. - */ +/* *INDENT-ON* */ + void fmTerm(void) { diff --git a/entity.c b/entity.c index c4a43c2..fdd8f64 100644 --- a/entity.c +++ b/entity.c @@ -1,10 +1,10 @@ -/* $Id: entity.c,v 1.6 2003/09/22 21:27:42 ukai Exp $ */ +/* $Id: entity.c,v 1.7 2003/09/24 18:48:59 ukai Exp $ */ #ifdef DUMMY #include "Str.h" #define NBSP " " #define UseAltEntity 1 #undef USE_M17N -#else /* DUMMY */ +#else /* DUMMY */ #include "fm.h" #ifdef USE_M17N #ifdef USE_UNICODE @@ -12,7 +12,7 @@ #include "utf8.h" #endif #endif -#endif /* DUMMY */ +#endif /* DUMMY */ /* *INDENT-OFF* */ static char *alt_latin1[ 96 ] = { diff --git a/etc.c b/etc.c index ec26aa9..7b56ffa 100644 --- a/etc.c +++ b/etc.c @@ -1,4 +1,4 @@ -/* $Id: etc.c,v 1.72 2003/09/22 21:02:18 ukai Exp $ */ +/* $Id: etc.c,v 1.73 2003/09/24 18:48:59 ukai Exp $ */ #include "fm.h" #include #include "myctype.h" @@ -481,7 +481,7 @@ nextColumn(int n, char *p, Lineprop *pr) #ifdef USE_M17N if (*pr & PC_UNKNOWN) return n + 4; - return n + wtf_width((wc_uchar *)p); + return n + wtf_width((wc_uchar *) p); #else return n + 1; #endif @@ -537,7 +537,7 @@ columnLen(Line *line, int column) { int i, j; - for (i = 0, j = 0; i < line->len; ) { + for (i = 0, j = 0; i < line->len;) { j = nextColumn(j, &line->lineBuf[i], &line->propBuf[i]); if (j > column) return i; @@ -816,7 +816,7 @@ read_token(Str buf, char **instr, int *status, int pre, int append) Strclear(buf); if (pre) Strcat_char(buf, *p); - p++; + p++; goto proc_end; } Strcat_char(buf, (!pre && IS_SPACE(*p)) ? ' ' : *p); diff --git a/file.c b/file.c index 5144b24..eccd616 100644 --- a/file.c +++ b/file.c @@ -1,4 +1,4 @@ -/* $Id: file.c,v 1.227 2003/09/22 21:02:18 ukai Exp $ */ +/* $Id: file.c,v 1.228 2003/09/24 18:48:59 ukai Exp $ */ #include "fm.h" #include #include "myctype.h" @@ -641,7 +641,7 @@ readHeader(URLFile *uf, Buffer *newBuf, int thru, ParsedURL *pu) lineBuf2 = convertLine(NULL, lineBuf2, RAW_MODE, mime_charset ? &mime_charset : &charset, mime_charset ? mime_charset - : DocumentCharset); + : DocumentCharset); /* separated with line and stored */ tmp = Strnew_size(lineBuf2->length); for (p = lineBuf2->ptr; *p; p = q) { @@ -4430,7 +4430,7 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) case HTML_PRE_PLAIN: CLOSE_A; if (!(obuf->flag & RB_IGNORE_P)) { - flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); + flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); do_blankline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); } @@ -4439,7 +4439,7 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) case HTML_N_PRE_PLAIN: CLOSE_A; if (!(obuf->flag & RB_IGNORE_P)) { - flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); + flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); do_blankline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); obuf->flag |= RB_IGNORE_P; @@ -4451,7 +4451,7 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) case HTML_PLAINTEXT: CLOSE_A; if (!(obuf->flag & RB_IGNORE_P)) { - flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); + flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); do_blankline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); } @@ -4472,7 +4472,7 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) case HTML_N_XMP: CLOSE_A; if (!(obuf->flag & RB_IGNORE_P)) { - flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); + flushline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); do_blankline(h_env, obuf, envs[h_env->envc].indent, 0, h_env->limit); obuf->flag |= RB_IGNORE_P; @@ -4776,13 +4776,13 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) return 0; case HTML_DEL: if (displayInsDel) - HTMLlineproc1("[DEL:", h_env); + HTMLlineproc1("[DEL:", h_env); else obuf->flag |= RB_DEL; return 1; case HTML_N_DEL: if (displayInsDel) - HTMLlineproc1(":DEL]", h_env); + HTMLlineproc1(":DEL]", h_env); else obuf->flag &= ~RB_DEL; return 1; @@ -4800,11 +4800,11 @@ HTMLtagproc1(struct parsed_tag *tag, struct html_feed_environ *h_env) return 1; case HTML_INS: if (displayInsDel) - HTMLlineproc1("[INS:", h_env); + HTMLlineproc1("[INS:", h_env); return 1; case HTML_N_INS: if (displayInsDel) - HTMLlineproc1(":INS]", h_env); + HTMLlineproc1(":INS]", h_env); return 1; case HTML_SUP: if (!(obuf->flag & (RB_DEL | RB_S))) @@ -5717,32 +5717,32 @@ HTMLlineproc0(char *line, struct html_feed_environ *h_env, int internal) * Tag processing */ if (obuf->status == R_ST_EOL) - obuf->status = R_ST_NORMAL; + obuf->status = R_ST_NORMAL; else { read_token(h_env->tagbuf, &line, &obuf->status, pre_mode & RB_PREMODE, obuf->status != R_ST_NORMAL); if (obuf->status != R_ST_NORMAL) - return; + return; } if (h_env->tagbuf->length == 0) continue; str = h_env->tagbuf->ptr; if (*str == '<') { if (str[1] && REALLY_THE_BEGINNING_OF_A_TAG(str)) - is_tag = TRUE; + is_tag = TRUE; else if (!(pre_mode & (RB_PLAIN | RB_INTXTA | RB_INSELECT | RB_SCRIPT | RB_STYLE | RB_TITLE))) { line = Strnew_m_charp(str + 1, line, NULL)->ptr; str = "<"; } - } } - else { + } + else { read_token(tokbuf, &line, &obuf->status, pre_mode & RB_PREMODE, 0); if (obuf->status != R_ST_NORMAL) /* R_ST_AMP ? */ obuf->status = R_ST_NORMAL; str = tokbuf->ptr; - } + } if (pre_mode & (RB_PLAIN | RB_INTXTA | RB_INSELECT | RB_SCRIPT | RB_STYLE | RB_TITLE)) { @@ -5775,7 +5775,7 @@ HTMLlineproc0(char *line, struct html_feed_environ *h_env, int internal) line = Strnew_m_charp(p, line, NULL)->ptr; } is_tag = FALSE; - } + } if (obuf->table_level >= 0) goto proc_normal; /* textarea */ @@ -5788,7 +5788,7 @@ HTMLlineproc0(char *line, struct html_feed_environ *h_env, int internal) continue; /* style */ if (pre_mode & RB_STYLE) - continue; + continue; } proc_normal: @@ -5872,133 +5872,133 @@ HTMLlineproc0(char *line, struct html_feed_environ *h_env, int internal) if (obuf->flag & (RB_DEL | RB_S)) continue; while (*str) { - mode = get_mctype(str); - delta = get_mcwidth(str); - if (obuf->flag & (RB_SPECIAL & ~RB_NOBR)) { - char ch = *str; + mode = get_mctype(str); + delta = get_mcwidth(str); + if (obuf->flag & (RB_SPECIAL & ~RB_NOBR)) { + char ch = *str; if (!(obuf->flag & RB_PLAIN) && (*str == '&')) { - char *p = str; - int ech = getescapechar(&p); - if (ech == '\n' || ech == '\r') { - ch = '\n'; - str = p - 1; - } - else if (ech == '\t') { - ch = '\t'; - str = p - 1; + char *p = str; + int ech = getescapechar(&p); + if (ech == '\n' || ech == '\r') { + ch = '\n'; + str = p - 1; + } + else if (ech == '\t') { + ch = '\t'; + str = p - 1; + } } - } - if (ch != '\n') - obuf->flag &= ~RB_IGNORE_P; - if (ch == '\n') { - str++; - if (obuf->flag & RB_IGNORE_P) { + if (ch != '\n') obuf->flag &= ~RB_IGNORE_P; - continue; - } - if (obuf->flag & RB_PRE_INT) - PUSH(' '); - else + if (ch == '\n') { + str++; + if (obuf->flag & RB_IGNORE_P) { + obuf->flag &= ~RB_IGNORE_P; + continue; + } + if (obuf->flag & RB_PRE_INT) + PUSH(' '); + else flushline(h_env, obuf, h_env->envs[h_env->envc].indent, 1, h_env->limit); - } - else if (ch == '\t') { - do { - PUSH(' '); - } while ((h_env->envs[h_env->envc].indent + obuf->pos) - % Tabstop != 0); - str++; - } - else if (obuf->flag & RB_PLAIN) { - char *p = html_quote_char(*str); - if (p) { - push_charp(obuf, 1, p, PC_ASCII); + } + else if (ch == '\t') { + do { + PUSH(' '); + } while ((h_env->envs[h_env->envc].indent + obuf->pos) + % Tabstop != 0); str++; } + else if (obuf->flag & RB_PLAIN) { + char *p = html_quote_char(*str); + if (p) { + push_charp(obuf, 1, p, PC_ASCII); + str++; + } + else { + proc_mchar(obuf, 1, delta, &str, mode); + } + } else { - proc_mchar(obuf, 1, delta, &str, mode); + if (*str == '&') + proc_escape(obuf, &str); + else + proc_mchar(obuf, 1, delta, &str, mode); } + if (obuf->flag & (RB_SPECIAL & ~RB_PRE_INT)) + continue; } else { - if (*str == '&') - proc_escape(obuf, &str); - else - proc_mchar(obuf, 1, delta, &str, mode); - } - if (obuf->flag & (RB_SPECIAL & ~RB_PRE_INT)) - continue; - } - else { - if (!IS_SPACE(*str)) - obuf->flag &= ~RB_IGNORE_P; - if ((mode == PC_ASCII || mode == PC_CTRL) && IS_SPACE(*str)) { - if (*obuf->prevchar->ptr != ' ') { - PUSH(' '); + if (!IS_SPACE(*str)) + obuf->flag &= ~RB_IGNORE_P; + if ((mode == PC_ASCII || mode == PC_CTRL) && IS_SPACE(*str)) { + if (*obuf->prevchar->ptr != ' ') { + PUSH(' '); + } + str++; } - str++; - } - else { + else { #ifdef USE_M17N - if (mode == PC_KANJI1) - is_hangul = wtf_is_hangul((wc_uchar *) str); - else - is_hangul = 0; - if (mode == PC_KANJI1 && - !is_hangul && !prev_is_hangul && - obuf->pos > h_env->envs[h_env->envc].indent && - Strlastchar(obuf->line) == ' ') { - while (obuf->line->length >= 2 && + if (mode == PC_KANJI1) + is_hangul = wtf_is_hangul((wc_uchar *) str); + else + is_hangul = 0; + if (mode == PC_KANJI1 && + !is_hangul && !prev_is_hangul && + obuf->pos > h_env->envs[h_env->envc].indent && + Strlastchar(obuf->line) == ' ') { + while (obuf->line->length >= 2 && !strncmp(obuf->line->ptr + obuf->line->length - 2, " ", 2) - && obuf->pos >= h_env->envs[h_env->envc].indent) { - Strshrink(obuf->line, 1); - obuf->pos--; - } - if (obuf->line->length >= 3 && - obuf->prev_ctype == PC_KANJI1 && - Strlastchar(obuf->line) == ' ' && - obuf->pos >= h_env->envs[h_env->envc].indent) { - Strshrink(obuf->line, 1); - obuf->pos--; + && obuf->pos >= h_env->envs[h_env->envc].indent) { + Strshrink(obuf->line, 1); + obuf->pos--; + } + if (obuf->line->length >= 3 && + obuf->prev_ctype == PC_KANJI1 && + Strlastchar(obuf->line) == ' ' && + obuf->pos >= h_env->envs[h_env->envc].indent) { + Strshrink(obuf->line, 1); + obuf->pos--; + } } - } - prev_is_hangul = is_hangul; + prev_is_hangul = is_hangul; #endif - if (*str == '&') - proc_escape(obuf, &str); - else - proc_mchar(obuf, obuf->flag & RB_SPECIAL, delta, &str, - mode); + if (*str == '&') + proc_escape(obuf, &str); + else + proc_mchar(obuf, obuf->flag & RB_SPECIAL, delta, &str, + mode); + } } - } - if (need_flushline(h_env, obuf, mode)) { - char *bp = obuf->line->ptr + obuf->bp.len; - char *tp = bp - obuf->bp.tlen; - int i = 0; + if (need_flushline(h_env, obuf, mode)) { + char *bp = obuf->line->ptr + obuf->bp.len; + char *tp = bp - obuf->bp.tlen; + int i = 0; - if (tp > obuf->line->ptr && tp[-1] == ' ') - i = 1; + if (tp > obuf->line->ptr && tp[-1] == ' ') + i = 1; - indent = h_env->envs[h_env->envc].indent; - if (obuf->bp.pos - i > indent) { - Str line; - append_tags(obuf); - line = Strnew_charp(bp); - Strshrink(obuf->line, obuf->line->length - obuf->bp.len); + indent = h_env->envs[h_env->envc].indent; + if (obuf->bp.pos - i > indent) { + Str line; + append_tags(obuf); + line = Strnew_charp(bp); + Strshrink(obuf->line, obuf->line->length - obuf->bp.len); #ifdef FORMAT_NICE - if (obuf->pos - i > h_env->limit) - obuf->flag |= RB_FILL; + if (obuf->pos - i > h_env->limit) + obuf->flag |= RB_FILL; #endif /* FORMAT_NICE */ - back_to_breakpoint(obuf); - flushline(h_env, obuf, indent, 0, h_env->limit); + back_to_breakpoint(obuf); + flushline(h_env, obuf, indent, 0, h_env->limit); #ifdef FORMAT_NICE - obuf->flag &= ~RB_FILL; + obuf->flag &= ~RB_FILL; #endif /* FORMAT_NICE */ - HTMLlineproc1(line->ptr, h_env); + HTMLlineproc1(line->ptr, h_env); + } } } } - } if (!(obuf->flag & (RB_SPECIAL | RB_INTXTA | RB_INSELECT))) { char *tp; int i = 0; @@ -6664,7 +6664,7 @@ loadHTMLString(Str page) * loadGopherDir: get gopher directory */ Str -loadGopherDir(URLFile *uf, ParsedURL *pu, wc_ces *charset) +loadGopherDir(URLFile *uf, ParsedURL *pu, wc_ces * charset) { Str volatile tmp; Str lbuf, name, file, host, port; diff --git a/fm.h b/fm.h index c48481d..3699529 100644 --- a/fm.h +++ b/fm.h @@ -1,4 +1,4 @@ -/* $Id: fm.h,v 1.121 2003/09/23 18:42:25 ukai Exp $ */ +/* $Id: fm.h,v 1.122 2003/09/24 18:48:59 ukai Exp $ */ /* * w3m: WWW wo Miru utility * @@ -51,7 +51,7 @@ #include #endif #if !HAVE_SETLOCALE -#define setlocale(category, locale) /* empty */ +#define setlocale(category, locale) /* empty */ #endif #if ENABLE_NLS @@ -60,9 +60,9 @@ #define N_(String) (String) #else # undef bindtextdomain -# define bindtextdomain(Domain, Directory) /* empty */ +# define bindtextdomain(Domain, Directory) /* empty */ # undef textdomain -# define textdomain(Domain) /* empty */ +# define textdomain(Domain) /* empty */ # define _(Text) Text # define N_(Text) Text # define gettext(Text) Text diff --git a/func.c b/func.c index 70de309..9e948bd 100644 --- a/func.c +++ b/func.c @@ -1,4 +1,4 @@ -/* $Id: func.c,v 1.25 2003/09/22 21:02:18 ukai Exp $ */ +/* $Id: func.c,v 1.26 2003/09/24 18:48:59 ukai Exp $ */ /* * w3m func.c */ @@ -79,13 +79,13 @@ setKeymap(char *p, int lineno, int verbose) if (keyData == NULL) keyData = newHash_iv(KEYDATA_HASH_SIZE); putHash_iv(keyData, m, (void *)mmap); - if (c & K_ESCD) + if (c & K_ESCD) map = mmap[3]; - else if (c & K_ESCB) + else if (c & K_ESCB) map = mmap[2]; - else if (c & K_ESC) + else if (c & K_ESC) map = mmap[1]; - else + else map = mmap[0]; } else { @@ -610,7 +610,8 @@ initMouseAction(void) #else char **symbol = get_symbol(); #endif - mouse_action.lastline_str = Strnew_charp(symbol[N_GRAPH_SYMBOL + 13])->ptr; + mouse_action.lastline_str = + Strnew_charp(symbol[N_GRAPH_SYMBOL + 13])->ptr; } if ((mf = fopen(confFile(MOUSE_FILE), "rt")) != NULL) { diff --git a/hash.h b/hash.h index c835902..8756eaa 100644 --- a/hash.h +++ b/hash.h @@ -1,4 +1,4 @@ -/* $Id: hash.h,v 1.5 2003/07/22 17:33:16 ukai Exp $ */ +/* $Id: hash.h,v 1.6 2003/09/24 18:48:59 ukai Exp $ */ #ifndef HASH_H #define HASH_H @@ -19,7 +19,7 @@ extern void putHash_##sym(Hash_##sym *t, keytype key, type value); \ extern type getHash_##sym(Hash_##sym *t, keytype key, type failval); defhash(char *, int, si) - defhash(char *, char *, ss) +defhash(char *, char *, ss) defhash(char *, void *, sv) defhash(int, void *, iv) #define defhashfunc(keytype,type,sym) \ diff --git a/html.c b/html.c index d6e0f9b..2bbd8ac 100644 --- a/html.c +++ b/html.c @@ -1,4 +1,4 @@ -/* $Id: html.c,v 1.26 2003/09/22 21:02:18 ukai Exp $ */ +/* $Id: html.c,v 1.27 2003/09/24 18:48:59 ukai Exp $ */ #include "html.h" /* Define HTML Tag Infomation Table */ @@ -6,7 +6,8 @@ #define ATTR_CORE ATTR_ID #define MAXA_CORE 1 unsigned char ALST_A[] = { - ATTR_NAME, ATTR_HREF, ATTR_REL, ATTR_CHARSET, ATTR_TARGET, ATTR_HSEQ, ATTR_REFERER, + ATTR_NAME, ATTR_HREF, ATTR_REL, ATTR_CHARSET, ATTR_TARGET, ATTR_HSEQ, + ATTR_REFERER, ATTR_FRAMENAME, ATTR_TITLE, ATTR_ACCESSKEY, ATTR_CORE }; #define MAXA_A MAXA_CORE + 10 diff --git a/linein.c b/linein.c index 40ae7df..013325c 100644 --- a/linein.c +++ b/linein.c @@ -1,4 +1,4 @@ -/* $Id: linein.c,v 1.32 2003/09/22 21:02:19 ukai Exp $ */ +/* $Id: linein.c,v 1.33 2003/09/24 18:48:59 ukai Exp $ */ #include "fm.h" #include "local.h" #include "myctype.h" @@ -184,8 +184,8 @@ inputLineHistSearch(char *prompt, char *def_str, int flag, Hist *hist, cm_clear = TRUE; cm_disp_clear = TRUE; if (!i_quote && - (((cm_mode & CPL_ALWAYS) && (c == CTRL_I || c == ' ')) || - ((cm_mode & CPL_ON) && (c == CTRL_I)))) { + (((cm_mode & CPL_ALWAYS) && (c == CTRL_I || c == ' ')) || + ((cm_mode & CPL_ON) && (c == CTRL_I)))) { if (emacs_like_lineedit && cm_next) { _dcompl(); need_redraw = TRUE; diff --git a/main.c b/main.c index 7867e7d..a926d38 100644 --- a/main.c +++ b/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.232 2003/09/23 18:42:25 ukai Exp $ */ +/* $Id: main.c,v 1.233 2003/09/24 18:48:59 ukai Exp $ */ #define MAINPROGRAM #include "fm.h" #include @@ -1606,8 +1606,8 @@ srchcore(char *volatile str, int (*func) (Buffer *, char *)) #ifdef USE_M17N if (SearchConv && !WcOption.pre_conv && - Currentbuf->document_charset != DisplayCharset) - str = wtf_conv_fit(str, Currentbuf->document_charset); + Currentbuf->document_charset != DisplayCharset) + str = wtf_conv_fit(str, Currentbuf->document_charset); else #endif str = SearchString; @@ -4159,10 +4159,12 @@ adBmark(void) * WC_CES_SHIFT_JIS, shouldn't it? - ukai */ (Str_form_quote(wc_conv_strict(Currentbuf->buffername, - InnerCharset, WC_CES_EUC_JP)))->ptr); + InnerCharset, + WC_CES_EUC_JP)))->ptr); #else (Str_form_quote(wc_conv_strict(Currentbuf->buffername, - InnerCharset, SystemCharset)))->ptr); + InnerCharset, + SystemCharset)))->ptr); #endif #else (Str_form_quote(Strnew_charp(Currentbuf->buffername)))->ptr); @@ -4509,7 +4511,8 @@ _peekURL(int only_img) s = parsedURL2Str(&pu); } if (DecodeURL) - s = Strnew_charp(url_unquote_conv(s->ptr, Currentbuf->document_charset)); + s = Strnew_charp(url_unquote_conv + (s->ptr, Currentbuf->document_charset)); #ifdef USE_M17N s = checkType(s, &pp, NULL); p = NewAtom_N(Lineprop, s->length); @@ -4618,7 +4621,7 @@ vwSrc(void) old_charset = DisplayCharset; old_fix_width_conv = WcOption.fix_width_conv; DisplayCharset = (Currentbuf->document_charset != WC_CES_US_ASCII) - ? Currentbuf->document_charset : 0; + ? Currentbuf->document_charset : 0; WcOption.fix_width_conv = WC_FALSE; #endif saveBufferBody(Currentbuf, f, TRUE); @@ -5223,7 +5226,7 @@ do_mouse_action(int btn, int x, int y) #ifdef USE_M17N || (WcOption.use_wide && Currentbuf->currentLine != NULL && (CharType(Currentbuf->currentLine-> - propBuf[Currentbuf->pos]) == PC_KANJI1) + propBuf[Currentbuf->pos]) == PC_KANJI1) && x == Currentbuf->cursorX + Currentbuf->rootX + 1) #endif ) && @@ -5285,7 +5288,7 @@ process_mouse(int btn, int x, int y) || (WcOption.use_wide && Currentbuf->currentLine != NULL && (CharType(Currentbuf->currentLine-> - propBuf[Currentbuf->pos]) == PC_KANJI1) + propBuf[Currentbuf->pos]) == PC_KANJI1) && Currentbuf->cursorX == press_x - Currentbuf->rootX - 1) #endif diff --git a/map.c b/map.c index ee915be..90aa35a 100644 --- a/map.c +++ b/map.c @@ -1,4 +1,4 @@ -/* $Id: map.c,v 1.29 2003/09/22 21:02:20 ukai Exp $ */ +/* $Id: map.c,v 1.30 2003/09/24 18:49:00 ukai Exp $ */ /* * client-side image maps */ @@ -561,8 +561,7 @@ page_info_panel(Buffer *buf) "Document Type", buf->real_type ? html_quote(buf->real_type) : "unknown", "Last Modified", - html_quote(last_modified(buf)), - NULL); + html_quote(last_modified(buf)), NULL); #ifdef USE_M17N if (buf->document_charset != InnerCharset) { list = wc_get_ces_list(); @@ -572,8 +571,7 @@ page_info_panel(Buffer *buf) sprintf(charset, "%d", (unsigned int)list->id); Strcat_m_charp(tmp, "