diff options
author | Ailin Nemui <ailin@esf51.localdomain> | 2014-11-04 12:08:27 +0100 |
---|---|---|
committer | Ailin Nemui <ailin@esf51.localdomain> | 2014-11-10 10:53:14 +0100 |
commit | b03805eeb916712815971ac6bcfffe10cc16711f (patch) | |
tree | d0fcb3658c7309fcaf7cac3f82b9b7e969ab67f1 /src/fe-common | |
parent | 688fc817dd9958f66e3be603dd0ee8ecc97d649d (diff) | |
download | irssi-b03805eeb916712815971ac6bcfffe10cc16711f.zip |
reimplement format and length logic for the entry prompt
Diffstat (limited to 'src/fe-common')
-rw-r--r-- | src/fe-common/core/printtext.c | 12 | ||||
-rw-r--r-- | src/fe-common/core/printtext.h | 1 |
2 files changed, 13 insertions, 0 deletions
diff --git a/src/fe-common/core/printtext.c b/src/fe-common/core/printtext.c index 466a2825..ba6f3242 100644 --- a/src/fe-common/core/printtext.c +++ b/src/fe-common/core/printtext.c @@ -413,6 +413,18 @@ void printtext_gui(const char *text) g_free(str); } +/* Like printtext_gui(), but don't expand % codes. */ +void printtext_gui_internal(const char *str) +{ + TEXT_DEST_REC dest; + + g_return_if_fail(str != NULL); + + memset(&dest, 0, sizeof(dest)); + + format_send_to_gui(&dest, str); +} + static void msg_beep_check(TEXT_DEST_REC *dest) { if (dest->level != 0 && (dest->level & MSGLEVEL_NO_ACT) == 0 && diff --git a/src/fe-common/core/printtext.h b/src/fe-common/core/printtext.h index 66ba28f4..ab8dfac1 100644 --- a/src/fe-common/core/printtext.h +++ b/src/fe-common/core/printtext.h @@ -23,6 +23,7 @@ void printtext_dest(TEXT_DEST_REC *dest, const char *text, ...); /* only GUI should call these - used for printing text to somewhere else than windows */ void printtext_gui(const char *text); +void printtext_gui_internal(const char *str); void printformat_module_gui(const char *module, int formatnum, ...); void printformat_module_gui_args(const char *module, int formatnum, va_list va); |