Permalink
Browse files

patch 8.0.0466: still macros that should be all-caps

Problem:    There are still a few macros that should be all-caps.
Solution:   Make a few more macros all-caps.
  • Loading branch information...
brammool committed Mar 16, 2017
1 parent 40ebc0a commit 8820b48654b62472821d9b155fe03ab7ac13a05c
Showing with 259 additions and 264 deletions.
  1. +1 −1 src/buffer.c
  2. +6 −6 src/edit.c
  3. +3 −3 src/ex_cmds.c
  4. +2 −2 src/ex_cmds2.c
  5. +2 −2 src/ex_docmd.c
  6. +5 −5 src/ex_getln.c
  7. +2 −2 src/farsi.c
  8. +7 −7 src/fileio.c
  9. +3 −3 src/getchar.c
  10. +1 −1 src/gui_beval.c
  11. +1 −1 src/hardcopy.c
  12. +10 −10 src/if_cscope.c
  13. +1 −1 src/if_xcmdsrv.c
  14. +3 −3 src/mark.c
  15. +1 −1 src/memline.c
  16. +2 −2 src/menu.c
  17. +20 −20 src/message.c
  18. +5 −5 src/misc1.c
  19. +1 −1 src/normal.c
  20. +1 −1 src/ops.c
  21. +2 −2 src/option.c
  22. +2 −2 src/quickfix.c
  23. +75 −75 src/screen.c
  24. +4 −4 src/search.c
  25. +8 −8 src/syntax.c
  26. +7 −7 src/tag.c
  27. +5 −5 src/term.c
  28. +69 −69 src/term.h
  29. +2 −2 src/ui.c
  30. +1 −1 src/undo.c
  31. +1 −1 src/userfunc.c
  32. +3 −1 src/version.c
  33. +3 −10 src/vim.h
View
@@ -6021,7 +6021,7 @@ sign_list_placed(buf_T *rbuf)
if (buf->b_signlist != NULL)
{
vim_snprintf(lbuf, BUFSIZ, _("Signs for %s:"), buf->b_fname);
- MSG_PUTS_ATTR(lbuf, hl_attr(HLF_D));
+ MSG_PUTS_ATTR(lbuf, HL_ATTR(HLF_D));
msg_putchar('\n');
}
for (p = buf->b_signlist; p != NULL && !got_int; p = p->next)
View
@@ -1771,7 +1771,7 @@ edit_putchar(int c, int highlight)
update_topline(); /* just in case w_topline isn't valid */
validate_cursor();
if (highlight)
- attr = hl_attr(HLF_8);
+ attr = HL_ATTR(HLF_8);
else
attr = 0;
pc_row = W_WINROW(curwin) + curwin->w_wrow;
@@ -2256,7 +2256,7 @@ has_compl_option(int dict_opt)
edit_submode = NULL;
msg_attr(dict_opt ? (char_u *)_("'dictionary' option is empty")
: (char_u *)_("'thesaurus' option is empty"),
- hl_attr(HLF_E));
+ HL_ATTR(HLF_E));
if (emsg_silent == 0)
{
vim_beep(BO_COMPL);
@@ -3252,7 +3252,7 @@ ins_compl_files(
{
vim_snprintf((char *)IObuff, IOSIZE,
_("Scanning dictionary: %s"), (char *)files[i]);
- (void)msg_trunc_attr(IObuff, TRUE, hl_attr(HLF_R));
+ (void)msg_trunc_attr(IObuff, TRUE, HL_ATTR(HLF_R));
}
if (fp != NULL)
@@ -4344,7 +4344,7 @@ ins_compl_get_exp(pos_T *ini)
: ins_buf->b_sfname == NULL
? ins_buf->b_fname
: ins_buf->b_sfname);
- (void)msg_trunc_attr(IObuff, TRUE, hl_attr(HLF_R));
+ (void)msg_trunc_attr(IObuff, TRUE, HL_ATTR(HLF_R));
}
else if (*e_cpt == NUL)
break;
@@ -4374,7 +4374,7 @@ ins_compl_get_exp(pos_T *ini)
{
type = CTRL_X_TAGS;
vim_snprintf((char *)IObuff, IOSIZE, _("Scanning tags."));
- (void)msg_trunc_attr(IObuff, TRUE, hl_attr(HLF_R));
+ (void)msg_trunc_attr(IObuff, TRUE, HL_ATTR(HLF_R));
}
else
type = -1;
@@ -5693,7 +5693,7 @@ ins_complete(int c, int enable_pum)
if (!p_smd)
msg_attr(edit_submode_extra,
edit_submode_highl < HLF_COUNT
- ? hl_attr(edit_submode_highl) : 0);
+ ? HL_ATTR(edit_submode_highl) : 0);
}
else
msg_clr_cmdline(); /* necessary for "noshowmode" */
View
@@ -2889,7 +2889,7 @@ print_line_no_prefix(
{
vim_snprintf((char *)numbuf, sizeof(numbuf),
"%*ld ", number_width(curwin), (long)lnum);
- msg_puts_attr(numbuf, hl_attr(HLF_N)); /* Highlight line nrs */
+ msg_puts_attr(numbuf, HL_ATTR(HLF_N)); /* Highlight line nrs */
}
msg_prt_line(ml_get(lnum), list);
}
@@ -5379,7 +5379,7 @@ do_sub(exarg_T *eap)
msg_no_more = TRUE;
/* write message same highlighting as for
* wait_return */
- smsg_attr(hl_attr(HLF_R),
+ smsg_attr(HL_ATTR(HLF_R),
(char_u *)_("replace with %s (y/n/a/q/l/^E/^Y)?"), sub);
msg_no_more = FALSE;
msg_scroll = i;
@@ -8284,7 +8284,7 @@ ex_smile(exarg_T *eap UNUSED)
else
for (n = *p++; n > 0; --n)
if (*p == 'o' || *p == '$')
- msg_putchar_attr(*p, hl_attr(HLF_L));
+ msg_putchar_attr(*p, HL_ATTR(HLF_L));
else
msg_putchar(*p);
msg_clr_eos();
View
@@ -2230,7 +2230,7 @@ buf_write_all(buf_T *buf, int forceit)
#ifdef FEAT_AUTOCMD
if (curbuf != old_curbuf)
{
- msg_source(hl_attr(HLF_W));
+ msg_source(HL_ATTR(HLF_W));
MSG(_("Warning: Entered other buffer unexpectedly (check autocommands)"));
}
#endif
@@ -4733,7 +4733,7 @@ get_one_sourceline(struct source_cookie *sp)
{
if (!sp->error)
{
- msg_source(hl_attr(HLF_W));
+ msg_source(HL_ATTR(HLF_W));
EMSG(_("W15: Warning: Wrong line separator, ^M may be missing"));
}
sp->error = TRUE;
View
@@ -6032,7 +6032,7 @@ uc_list(char_u *name, size_t name_len)
msg_putchar(gap != &ucmds ? 'b' : ' ');
msg_putchar(' ');
- msg_outtrans_attr(cmd->uc_name, hl_attr(HLF_D));
+ msg_outtrans_attr(cmd->uc_name, HL_ATTR(HLF_D));
len = (int)STRLEN(cmd->uc_name) + 4;
do {
@@ -8480,7 +8480,7 @@ ex_tabs(exarg_T *eap UNUSED)
{
msg_putchar('\n');
vim_snprintf((char *)IObuff, IOSIZE, _("Tab page %d"), tabcount++);
- msg_outtrans_attr(IObuff, hl_attr(HLF_T));
+ msg_outtrans_attr(IObuff, HL_ATTR(HLF_T));
out_flush(); /* output one line at a time */
ui_breakcheck();
View
@@ -4178,14 +4178,14 @@ showmatches(expand_T *xp, int wildmenu UNUSED)
lines = (num_files + columns - 1) / columns;
}
- attr = hl_attr(HLF_D); /* find out highlighting for directories */
+ attr = HL_ATTR(HLF_D); /* find out highlighting for directories */
if (xp->xp_context == EXPAND_TAGS_LISTFILES)
{
- MSG_PUTS_ATTR(_("tagname"), hl_attr(HLF_T));
+ MSG_PUTS_ATTR(_("tagname"), HL_ATTR(HLF_T));
msg_clr_eos();
msg_advance(maxlen - 3);
- MSG_PUTS_ATTR(_(" kind file\n"), hl_attr(HLF_T));
+ MSG_PUTS_ATTR(_(" kind file\n"), HL_ATTR(HLF_T));
}
/* list the files line by line */
@@ -4196,12 +4196,12 @@ showmatches(expand_T *xp, int wildmenu UNUSED)
{
if (xp->xp_context == EXPAND_TAGS_LISTFILES)
{
- msg_outtrans_attr(files_found[k], hl_attr(HLF_D));
+ msg_outtrans_attr(files_found[k], HL_ATTR(HLF_D));
p = files_found[k] + STRLEN(files_found[k]) + 1;
msg_advance(maxlen + 1);
msg_puts(p);
msg_advance(maxlen + 3);
- msg_puts_long_attr(p + 2, hl_attr(HLF_D));
+ msg_puts_long_attr(p + 2, HL_ATTR(HLF_D));
break;
}
for (j = maxlen - lastlen; --j >= 0; )
View
@@ -1719,7 +1719,7 @@ conv_to_pvim(void)
/* Assume the screen has been messed up: clear it and redraw. */
redraw_later(CLEAR);
- MSG_ATTR(farsi_text_1, hl_attr(HLF_S));
+ MSG_ATTR(farsi_text_1, HL_ATTR(HLF_S));
}
/*
@@ -1747,7 +1747,7 @@ conv_to_pstd(void)
/* Assume the screen has been messed up: clear it and redraw. */
redraw_later(CLEAR);
- MSG_ATTR(farsi_text_2, hl_attr(HLF_S));
+ MSG_ATTR(farsi_text_2, HL_ATTR(HLF_S));
}
/*
View
@@ -5044,7 +5044,7 @@ buf_write(
{
int numlen = errnum != NULL ? (int)STRLEN(errnum) : 0;
- attr = hl_attr(HLF_E); /* set highlight for error messages */
+ attr = HL_ATTR(HLF_E); /* set highlight for error messages */
msg_add_fname(buf,
#ifndef UNIX
sfname
@@ -5300,7 +5300,7 @@ check_mtime(buf_T *buf, stat_T *st)
msg_silent = 0; /* must give this prompt */
/* don't use emsg() here, don't want to flush the buffers */
MSG_ATTR(_("WARNING: The file has been changed since reading it!!!"),
- hl_attr(HLF_E));
+ HL_ATTR(HLF_E));
if (ask_yesno((char_u *)_("Do you really want to write to it"),
TRUE) == 'n')
return FAIL;
@@ -7011,10 +7011,10 @@ buf_check_timestamp(
# endif
{
msg_start();
- msg_puts_attr(tbuf, hl_attr(HLF_E) + MSG_HIST);
+ msg_puts_attr(tbuf, HL_ATTR(HLF_E) + MSG_HIST);
if (*mesg2 != NUL)
msg_puts_attr((char_u *)mesg2,
- hl_attr(HLF_W) + MSG_HIST);
+ HL_ATTR(HLF_W) + MSG_HIST);
msg_clr_eos();
(void)msg_end();
if (emsg_silent == 0)
@@ -7840,12 +7840,12 @@ show_autocmd(AutoPat *ap, event_T event)
if (ap->group != AUGROUP_DEFAULT)
{
if (AUGROUP_NAME(ap->group) == NULL)
- msg_puts_attr(get_deleted_augroup(), hl_attr(HLF_E));
+ msg_puts_attr(get_deleted_augroup(), HL_ATTR(HLF_E));
else
- msg_puts_attr(AUGROUP_NAME(ap->group), hl_attr(HLF_T));
+ msg_puts_attr(AUGROUP_NAME(ap->group), HL_ATTR(HLF_T));
msg_puts((char_u *)" ");
}
- msg_puts_attr(event_nr2name(event), hl_attr(HLF_T));
+ msg_puts_attr(event_nr2name(event), HL_ATTR(HLF_T));
last_event = event;
last_group = ap->group;
msg_putchar('\n');
View
@@ -4022,9 +4022,9 @@ showmap(
} while (len < 12);
if (mp->m_noremap == REMAP_NONE)
- msg_puts_attr((char_u *)"*", hl_attr(HLF_8));
+ msg_puts_attr((char_u *)"*", HL_ATTR(HLF_8));
else if (mp->m_noremap == REMAP_SCRIPT)
- msg_puts_attr((char_u *)"&", hl_attr(HLF_8));
+ msg_puts_attr((char_u *)"&", HL_ATTR(HLF_8));
else
msg_putchar(' ');
@@ -4036,7 +4036,7 @@ showmap(
/* Use FALSE below if we only want things like <Up> to show up as such on
* the rhs, and not M-x etc, TRUE gets both -- webb */
if (*mp->m_str == NUL)
- msg_puts_attr((char_u *)"<Nop>", hl_attr(HLF_8));
+ msg_puts_attr((char_u *)"<Nop>", HL_ATTR(HLF_8));
else
{
/* Remove escaping of CSI, because "m_str" is in a format to be used
View
@@ -1054,7 +1054,7 @@ set_printable_label_text(GtkLabel *label, char_u *text)
#endif
/* Look up the RGB values of the SpecialKey foreground color. */
- aep = syn_gui_attr2entry(hl_attr(HLF_8));
+ aep = syn_gui_attr2entry(HL_ATTR(HLF_8));
pixel = (aep != NULL) ? aep->ae_u.gui.fg_color : INVALCOLOR;
if (pixel != INVALCOLOR)
# if GTK_CHECK_VERSION(3,0,0)
View
@@ -569,7 +569,7 @@ prt_header(
prt_message(char_u *s)
{
screen_fill((int)Rows - 1, (int)Rows, 0, (int)Columns, ' ', ' ', 0);
- screen_puts(s, (int)Rows - 1, 0, hl_attr(HLF_R));
+ screen_puts(s, (int)Rows - 1, 0, HL_ATTR(HLF_R));
out_flush();
}
View
@@ -615,7 +615,7 @@ cs_add_common(
if (p_csverbose)
{
msg_clr_eos();
- (void)smsg_attr(hl_attr(HLF_R),
+ (void)smsg_attr(HL_ATTR(HLF_R),
(char_u *)_("Added cscope database %s"),
csinfo[i].fname);
}
@@ -1612,7 +1612,7 @@ cs_kill_execute(
if (p_csverbose)
{
msg_clr_eos();
- (void)smsg_attr(hl_attr(HLF_R) | MSG_HIST,
+ (void)smsg_attr(HL_ATTR(HLF_R) | MSG_HIST,
(char_u *)_("cscope connection %s closed"), cname);
}
cs_release_csp(i, TRUE);
@@ -2020,14 +2020,14 @@ cs_print_tags_priv(char **matches, char **cntxts, int num_matches)
{
bufsize = newsize;
(void)sprintf(buf, cstag_msg, ptag);
- MSG_PUTS_ATTR(buf, hl_attr(HLF_T));
+ MSG_PUTS_ATTR(buf, HL_ATTR(HLF_T));
}
vim_free(tbuf);
- MSG_PUTS_ATTR(_("\n # line"), hl_attr(HLF_T)); /* strlen is 7 */
+ MSG_PUTS_ATTR(_("\n # line"), HL_ATTR(HLF_T)); /* strlen is 7 */
msg_advance(msg_col + 2);
- MSG_PUTS_ATTR(_("filename / context / line\n"), hl_attr(HLF_T));
+ MSG_PUTS_ATTR(_("filename / context / line\n"), HL_ATTR(HLF_T));
num = 1;
for (i = 0; i < num_matches; i++)
@@ -2071,9 +2071,9 @@ cs_print_tags_priv(char **matches, char **cntxts, int num_matches)
{
/* csfmt_str = "%4d %6s "; */
(void)sprintf(buf, csfmt_str, num, lno);
- MSG_PUTS_ATTR(buf, hl_attr(HLF_CM));
+ MSG_PUTS_ATTR(buf, HL_ATTR(HLF_CM));
}
- MSG_PUTS_LONG_ATTR(cs_pathcomponents(fname), hl_attr(HLF_CM));
+ MSG_PUTS_LONG_ATTR(cs_pathcomponents(fname), HL_ATTR(HLF_CM));
/* compute the required space for the context */
if (cntxts[idx] != NULL)
@@ -2399,7 +2399,7 @@ cs_reset(exarg_T *eap UNUSED)
* "Added cscope database..."
*/
sprintf(buf, " (#%d)", i);
- MSG_PUTS_ATTR(buf, hl_attr(HLF_R));
+ MSG_PUTS_ATTR(buf, HL_ATTR(HLF_R));
}
}
vim_free(dblist[i]);
@@ -2411,7 +2411,7 @@ cs_reset(exarg_T *eap UNUSED)
vim_free(fllist);
if (p_csverbose)
- MSG_ATTR(_("All cscope databases reset"), hl_attr(HLF_R) | MSG_HIST);
+ MSG_ATTR(_("All cscope databases reset"), HL_ATTR(HLF_R) | MSG_HIST);
return CSCOPE_SUCCESS;
} /* cs_reset */
@@ -2497,7 +2497,7 @@ cs_show(exarg_T *eap UNUSED)
{
MSG_PUTS_ATTR(
_(" # pid database name prepend path\n"),
- hl_attr(HLF_T));
+ HL_ATTR(HLF_T));
for (i = 0; i < csinfo_size; i++)
{
if (csinfo[i].fname == NULL)
View
@@ -231,7 +231,7 @@ serverRegisterName(
if (res < -1 || i >= 1000)
{
MSG_ATTR(_("Unable to register a command server name"),
- hl_attr(HLF_W));
+ HL_ATTR(HLF_W));
return FAIL;
}
if (p == NULL)
View
@@ -794,7 +794,7 @@ show_one_mark(
}
if (name != NULL)
{
- msg_outtrans_attr(name, current ? hl_attr(HLF_D) : 0);
+ msg_outtrans_attr(name, current ? HL_ATTR(HLF_D) : 0);
if (mustfree)
vim_free(name);
}
@@ -926,7 +926,7 @@ ex_jumps(exarg_T *eap UNUSED)
msg_outtrans(IObuff);
msg_outtrans_attr(name,
curwin->w_jumplist[i].fmark.fnum == curbuf->b_fnum
- ? hl_attr(HLF_D) : 0);
+ ? HL_ATTR(HLF_D) : 0);
vim_free(name);
ui_breakcheck();
}
@@ -973,7 +973,7 @@ ex_changes(exarg_T *eap UNUSED)
name = mark_line(&curbuf->b_changelist[i], 17);
if (name == NULL)
break;
- msg_outtrans_attr(name, hl_attr(HLF_D));
+ msg_outtrans_attr(name, HL_ATTR(HLF_D));
vim_free(name);
ui_breakcheck();
}
View
@@ -1136,7 +1136,7 @@ ml_recover(void)
recoverymode = TRUE;
called_from_main = (curbuf->b_ml.ml_mfp == NULL);
- attr = hl_attr(HLF_E);
+ attr = HL_ATTR(HLF_E);
/*
* If the file name ends in ".s[uvw][a-z]" we assume this is the swap file.
Oops, something went wrong.

0 comments on commit 8820b48

Please sign in to comment.