diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/command/cmd_defs.c | 2 | ||||
-rw-r--r-- | src/command/cmd_funcs.c | 2 | ||||
-rw-r--r-- | src/xmpp/avatar.c | 5 |
3 files changed, 5 insertions, 4 deletions
diff --git a/src/command/cmd_defs.c b/src/command/cmd_defs.c index ffc4ec83..599262c1 100644 --- a/src/command/cmd_defs.c +++ b/src/command/cmd_defs.c @@ -2452,7 +2452,7 @@ static struct cmd_t command_defs[] = { "If nothing happens after using this command the user either doesn't have an avatar set at all " "or doesn't use XEP-0084 to publish it.") CMD_ARGS( - { "set <path>", "Set avatar to the img at <path>." }, + { "set <path>", "Set avatar to the image at <path>." }, { "get <barejid>", "Download the avatar. barejid is the JID to download avatar from." }, { "open <barejid>", "Download avatar and open it with command." }) CMD_EXAMPLES( diff --git a/src/command/cmd_funcs.c b/src/command/cmd_funcs.c index dfe96971..2a8331d1 100644 --- a/src/command/cmd_funcs.c +++ b/src/command/cmd_funcs.c @@ -9201,7 +9201,7 @@ cmd_avatar(ProfWin* window, const char* const command, gchar** args) cons_show("Avatar updated successfully"); } #else - cons_show("This version of Profanity has not been built with GDK Pixbuf support enabled"); + cons_show("Profanity has not been built with GDK Pixbuf support enabled which is needed to scale the avatar when uploading."); #endif } else if (g_strcmp0(args[0], "get") == 0) { avatar_get_by_nick(args[1], false); diff --git a/src/xmpp/avatar.c b/src/xmpp/avatar.c index 15ec7f1a..9345ba3a 100644 --- a/src/xmpp/avatar.c +++ b/src/xmpp/avatar.c @@ -36,12 +36,13 @@ #include "config.h" #include <glib.h> +#ifdef HAVE_PIXBUF #include <gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf.h> +#endif #include <string.h> #include <stdio.h> #include <stdlib.h> #include <errno.h> -#include <assert.h> #include <sys/stat.h> #include "log.h" @@ -61,7 +62,7 @@ typedef struct avatar_metadata static GHashTable* looking_for = NULL; // contains nicks/barejids from who we want to get the avatar static GHashTable* shall_open = NULL; // contains a list of nicks that shall not just downloaded but also opened -const int MAX_PIXEL = 192; +const int MAX_PIXEL = 192; // max pixel width/height for an avatar static void _avatar_request_item_by_id(const char* jid, avatar_metadata* data); static int _avatar_metadata_handler(xmpp_stanza_t* const stanza, void* const userdata); |