mirror of
https://github.com/tmate-io/tmate.git
synced 2025-08-16 08:38:12 +02:00
Better format for printf format attributes.
This commit is contained in:
@ -25,13 +25,13 @@
|
||||
|
||||
void screen_write_initctx(struct screen_write_ctx *, struct tty_ctx *, int);
|
||||
void screen_write_overwrite(struct screen_write_ctx *, u_int);
|
||||
int screen_write_combine(
|
||||
struct screen_write_ctx *, const struct utf8_data *);
|
||||
int screen_write_combine(struct screen_write_ctx *,
|
||||
const struct utf8_data *);
|
||||
|
||||
/* Initialise writing with a window. */
|
||||
void
|
||||
screen_write_start(
|
||||
struct screen_write_ctx *ctx, struct window_pane *wp, struct screen *s)
|
||||
screen_write_start(struct screen_write_ctx *ctx, struct window_pane *wp,
|
||||
struct screen *s)
|
||||
{
|
||||
ctx->wp = wp;
|
||||
if (wp != NULL && s == NULL)
|
||||
@ -73,7 +73,7 @@ screen_write_putc(struct screen_write_ctx *ctx, struct grid_cell *gc,
|
||||
}
|
||||
|
||||
/* Calculate string length, with embedded formatting. */
|
||||
size_t printflike2
|
||||
size_t
|
||||
screen_write_cstrlen(int utf8flag, const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
@ -108,7 +108,7 @@ screen_write_cstrlen(int utf8flag, const char *fmt, ...)
|
||||
}
|
||||
|
||||
/* Calculate string length. */
|
||||
size_t printflike2
|
||||
size_t
|
||||
screen_write_strlen(int utf8flag, const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
@ -145,9 +145,9 @@ screen_write_strlen(int utf8flag, const char *fmt, ...)
|
||||
}
|
||||
|
||||
/* Write simple string (no UTF-8 or maximum length). */
|
||||
void printflike3
|
||||
screen_write_puts(
|
||||
struct screen_write_ctx *ctx, struct grid_cell *gc, const char *fmt, ...)
|
||||
void
|
||||
screen_write_puts(struct screen_write_ctx *ctx, struct grid_cell *gc,
|
||||
const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
@ -157,9 +157,9 @@ screen_write_puts(
|
||||
}
|
||||
|
||||
/* Write string with length limit (-1 for unlimited). */
|
||||
void printflike5
|
||||
screen_write_nputs(struct screen_write_ctx *ctx,
|
||||
ssize_t maxlen, struct grid_cell *gc, int utf8flag, const char *fmt, ...)
|
||||
void
|
||||
screen_write_nputs(struct screen_write_ctx *ctx, ssize_t maxlen,
|
||||
struct grid_cell *gc, int utf8flag, const char *fmt, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
||||
@ -221,7 +221,7 @@ screen_write_vnputs(struct screen_write_ctx *ctx, ssize_t maxlen,
|
||||
}
|
||||
|
||||
/* Write string, similar to nputs, but with embedded formatting (#[]). */
|
||||
void printflike5
|
||||
void
|
||||
screen_write_cnputs(struct screen_write_ctx *ctx,
|
||||
ssize_t maxlen, struct grid_cell *gc, int utf8flag, const char *fmt, ...)
|
||||
{
|
||||
|
Reference in New Issue
Block a user