*/
#include "config.h"
+#include "empathy-cell-renderer-text.h"
+
+#include <tp-account-widgets/tpaw-utils.h>
#include "empathy-utils.h"
-#include "empathy-cell-renderer-text.h"
#define GET_PRIV(obj) EMPATHY_GET_PRIV (obj, EmpathyCellRendererText)
typedef struct {
gboolean selected)
{
EmpathyCellRendererTextPriv *priv;
- const PangoFontDescription *font_desc;
+ PangoFontDescription *font_desc;
PangoAttrList *attr_list;
PangoAttribute *attr_color = NULL, *attr_size;
GtkStyleContext *style;
attr_list = pango_attr_list_new ();
- font_desc = gtk_style_context_get_font (style, GTK_STATE_FLAG_NORMAL);
+ gtk_style_context_get (style, GTK_STATE_FLAG_NORMAL,
+ "font", &font_desc,
+ NULL);
font_size = pango_font_description_get_size (font_desc);
+ pango_font_description_free (font_desc);
attr_size = pango_attr_size_new (font_size / 1.2);
attr_size->start_index = strlen (priv->name) + 1;
attr_size->end_index = -1;
}
if (priv->compact) {
- if (EMP_STR_EMPTY (priv->status)) {
+ if (TPAW_STR_EMPTY (priv->status)) {
str = g_strdup (priv->name);
} else {
str = g_strdup_printf ("%s %s", priv->name, priv->status);
const gchar *status = priv->status;
gboolean on_a_phone = FALSE;
- if (EMP_STR_EMPTY (priv->status)) {
+ if (TPAW_STR_EMPTY (priv->status)) {
status = empathy_presence_get_default_message (priv->presence_type);
}