[gtk+/open-with-dialog: 26/52] Simplify title and heading
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/open-with-dialog: 26/52] Simplify title and heading
- Date: Tue, 23 Nov 2010 15:57:17 +0000 (UTC)
commit d09550b2d2c517164e5365105b5d87e1d49b5320
Author: William Jon McCann <jmccann redhat com>
Date: Thu Nov 18 17:17:23 2010 -0500
Simplify title and heading
gtk/gtkopenwithdialog.c | 17 ++++++++++-------
1 files changed, 10 insertions(+), 7 deletions(-)
---
diff --git a/gtk/gtkopenwithdialog.c b/gtk/gtkopenwithdialog.c
index 633ab2e..c3b069c 100644
--- a/gtk/gtkopenwithdialog.c
+++ b/gtk/gtkopenwithdialog.c
@@ -229,28 +229,27 @@ get_extension (const char *basename)
static void
set_dialog_properties (GtkOpenWithDialog *self)
{
- char *label, *emname, *name, *extension, *description;
+ char *label, *name, *extension, *description;
+ PangoFontDescription *font_desc;
name = NULL;
extension = NULL;
label = NULL;
- emname = NULL;
description = NULL;
if (self->priv->gfile != NULL)
{
name = g_file_get_basename (self->priv->gfile);
- emname = g_strdup_printf ("<i>%s</i>", name);
extension = get_extension (name);
}
description = g_content_type_get_description (self->priv->content_type);
- gtk_window_set_title (GTK_WINDOW (self), _("Choose an Application"));
+ gtk_window_set_title (GTK_WINDOW (self), "");
- if (emname != NULL)
+ if (name != NULL)
{
/* Translators: %s is a filename */
- label = g_strdup_printf (_("Open %s with:"), emname);
+ label = g_strdup_printf (_("Select an application to open \"%s\":"), name);
}
else
{
@@ -260,13 +259,17 @@ set_dialog_properties (GtkOpenWithDialog *self)
self->priv->content_type : description);
}
+ font_desc = pango_font_description_new ();
+ pango_font_description_set_weight (font_desc, PANGO_WEIGHT_BOLD);
+ gtk_widget_modify_font (self->priv->label, font_desc);
+ pango_font_description_free (font_desc);
+
gtk_label_set_markup (GTK_LABEL (self->priv->label), label);
g_free (label);
g_free (name);
g_free (extension);
g_free (description);
- g_free (emname);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]