dots are converted into underscores. (_ is already used for
lowercasing the result of an expando.)
** (_) sign. For example, if you want to display the local hostname in
** lowercase, you would use:
** %_h
+ ** .pp
+ ** If you prefix the sequence character with a colon (:) character, mutt
+ ** will replace any dots in the expansion by underscores. This might be helpful
+ ** with IMAP folders that don't like dots in folder names.
*/
{ "status_on_top", DT_BOOL, R_BOTH, OPTSTATUSONTOP, 0 },
/*
else
{
short tolower = 0;
+ short nodots = 0;
- if (ch == '_')
+ while (ch == '_' || ch == ':')
{
+ if (ch == '_')
+ tolower = 1;
+ else if (ch == ':')
+ nodots = 1;
+
ch = *src++;
- tolower = 1;
}
/* use callback function to handle this case */
if (tolower)
mutt_strlower (buf);
+ if (nodots)
+ {
+ char *p = buf;
+ for (; *p; p++)
+ if (*p == '.')
+ *p = '_';
+ }
if ((len = mutt_strlen (buf)) + wlen > destlen)
len = (destlen - wlen > 0) ? (destlen - wlen) : 0;