If the charset item doesn't have a class (aka "Unknown"), don't write a

2002-03-13  Jeffrey Stedfast  <fejj@ximian.com>

	* e-charset-picker.c (add_charset): If the charset item doesn't
	have a class (aka "Unknown"), don't write a class name, instead
	just give the charset name as the menu item label. Fixes bug
	#14753.

svn path=/trunk/; revision=16154
This commit is contained in:
Jeffrey Stedfast
2002-03-14 00:34:35 +00:00
committed by Jeffrey Stedfast
parent 828991183b
commit a18af91be5
2 changed files with 12 additions and 3 deletions

View File

@ -1,3 +1,10 @@
2002-03-13 Jeffrey Stedfast <fejj@ximian.com>
* e-charset-picker.c (add_charset): If the charset item doesn't
have a class (aka "Unknown"), don't write a class name, instead
just give the charset name as the menu item label. Fixes bug
#14753.
2002-03-13 Christopher James Lahey <clahey@ximian.com>
* e-multi-config-dialog.c: Added alpha blending here.

View File

@ -123,18 +123,20 @@ add_charset (GtkWidget *menu, ECharset *charset, gboolean free_name)
{
GtkWidget *item;
char *label;
if (charset->subclass) {
label = g_strdup_printf ("%s, %s (%s)",
_(classnames[charset->class]),
_(charset->subclass),
charset->name);
} else {
} else if (charset->class) {
label = g_strdup_printf ("%s (%s)",
_(classnames[charset->class]),
charset->name);
} else {
label = g_strdup (charset->name);
}
item = gtk_menu_item_new_with_label (label);
gtk_object_set_data_full (GTK_OBJECT (item), "charset",
charset->name, free_name ? g_free : NULL);