45 static char marker[256] = { 0 };
48 snprintf(marker,
sizeof(marker),
"\033]9;%" PRIu64
"\a",
mutt_rand64());
59 static char marker[256] = { 0 };
62 snprintf(marker,
sizeof(marker),
"\033]8;%lld\a", (
long long)
mutt_date_epoch());
102 if (!s || !s->
fp_out || !t)
110 if ((*t++ ==
'\n') && *t)
125 char mb[MB_LEN_MAX] = { 0 };
128 rc = wcrtomb(mb, wc, NULL);
131 if (fputs(mb, s->
fp_out) == EOF)
145 const wchar_t *p = ws;
147 while (p && (*p != L
'\0'))
189 rc = vfprintf(s->
fp_out, fmt, ap);
209 fwrite(buf, buflen, 1, s->
fp_out);
const char * cs_subset_string(const struct ConfigSubset *sub, const char *name)
Get a string config item by name.
Convenience wrapper for the config headers.
Convenience wrapper for the core headers.
time_t mutt_date_epoch(void)
Return the number of seconds since the Unix epoch.
Convenience wrapper for the library headers.
int state_putws(struct State *s, const wchar_t *ws)
Write a wide string to the state.
int state_printf(struct State *s, const char *fmt,...)
Write a formatted string to the State.
void state_prefix_put(struct State *s, const char *buf, size_t buflen)
Write a prefixed fixed-string to the State.
void state_prefix_putc(struct State *s, char c)
Write a prefixed character to the state.
const char * state_protected_header_marker(void)
Get a unique (per-run) ANSI string to mark protected headers in an email.
void state_mark_attach(struct State *s)
Write a unique marker around content.
const char * state_attachment_marker(void)
Get a unique (per-run) ANSI string to mark PGP messages in an email.
void state_attach_puts(struct State *s, const char *t)
Write a string to the state.
void state_mark_protected_header(struct State *s)
Write a unique marker around protected headers.
static int state_putwc(struct State *s, wchar_t wc)
Write a wide character to the state.
#define state_puts(STATE, STR)
#define state_set_prefix(state)
#define MUTT_PENDINGPREFIX
Prefix to write, but character must follow.
#define state_reset_prefix(state)
#define state_putc(STATE, STR)
#define MUTT_DISPLAY
Output is displayed to the user.
bool mutt_str_equal(const char *a, const char *b)
Compare two strings.
uint64_t mutt_rand64(void)
Create a 64-bit random number.
Container for Accounts, Notifications.
struct ConfigSubset * sub
Inherited config items.
Keep track when processing files.
StateFlags flags
Flags, e.g. MUTT_DISPLAY.
FILE * fp_out
File to write to.
char * prefix
String to add to the beginning of each output line.