about summary refs log tree commit diff stats
path: root/src/command/cmd_defs.c
diff options
context:
space:
mode:
authorArtjom Vejsel <akawolf0@gmail.com>2022-03-29 20:34:34 +0300
committerArtjom Vejsel <akawolf0@gmail.com>2022-04-02 00:23:08 +0300
commit2c003dd2e1a1fb956de6ed58c073e5b9d1cc5f3c (patch)
tree4ea53ea97f0e0a011b84001225008bbdb2f91c66 /src/command/cmd_defs.c
parentabfab2aff7561aee98957e805b637b83abc3bdd7 (diff)
downloadprofani-tty-2c003dd2e1a1fb956de6ed58c073e5b9d1cc5f3c.tar.gz
add /stamp command
command allow override standard stamps of incoming and outgoing messages
Diffstat (limited to 'src/command/cmd_defs.c')
-rw-r--r--src/command/cmd_defs.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/command/cmd_defs.c b/src/command/cmd_defs.c
index 24d4a737..db42be1c 100644
--- a/src/command/cmd_defs.c
+++ b/src/command/cmd_defs.c
@@ -2411,6 +2411,30 @@ static struct cmd_t command_defs[] = {
               "/color own off")
     },
 
+    { "/stamp",
+      parse_args, 0, 2, NULL,
+      CMD_NOSUBFUNCS
+      CMD_MAINFUNC(cmd_stamp)
+      CMD_TAGS(
+              CMD_TAG_UI)
+      CMD_SYN(
+              "/stamp outgoing <string>",
+              "/stamp incoming <string>",
+              "/stamp unset outgoing|incoming")
+      CMD_DESC(
+              "Set chat window stamp values. "
+              "Current format of single log-line in the chat window next: \"<timestamp> <encryption sign> <stamp> <message>\" "
+              "where <stamp> is \"me:\" for incoming messages or \"username@server/resource\" for outcoming messages. "
+              "This command allows to change <stamp> value.")
+      CMD_ARGS(
+              { "outgoing", "Set outgoing messages stamp" },
+              { "incoming", "Set incoming stamp"},
+              { "unset outgoing|incoming", "unset stamp"})
+      CMD_EXAMPLES(
+              "/stamp outgoing -->",
+              "/stamp incoming <--")
+    },
+
     { "/avatar",
       parse_args, 2, 2, NULL,
       CMD_NOSUBFUNCS