* add test mail

This commit is contained in:
Dirk-Jan C. Binnema
2011-05-29 13:57:27 +03:00
parent 61f462c4ad
commit 0dcc122c0f
4 changed files with 461 additions and 11 deletions

View File

@ -297,27 +297,28 @@ save_parts (const char *path, const char *filename, MuConfig *opts)
}
#define color_maybe(C,COND) ((COND)?(C):"")
static void
each_part_show (MuMsg *msg, MuMsgPart *part, gboolean color)
{
g_print (" %u %s%s%s %s%s/%s%s [%s%s%s]\n",
g_print (" %u %s%s %s%s/%s%s [%s%s%s]\n",
part->index,
/* filename */
color && part->file_name ? MU_COLOR_GREEN : "",
color_maybe (MU_COLOR_GREEN, color),
part->file_name ? part->file_name : "<none>",
color ? MU_COLOR_DEFAULT : "",
/* content type */
color ? MU_COLOR_BLUE : "",
color_maybe (MU_COLOR_BLUE, color),
part->type ? part->type : "",
part->subtype ? part->subtype : "",
color ? MU_COLOR_DEFAULT : "",
color_maybe (MU_COLOR_DEFAULT, color),
/* disposition */
color && part->disposition ? MU_COLOR_MAGENTA : "",
color_maybe (MU_COLOR_MAGENTA, color),
part->disposition ? part->disposition : "<none>",
color ? MU_COLOR_DEFAULT : ""
color_maybe (MU_COLOR_DEFAULT, color)
);
}