Your message dated Tue, 11 Aug 2009 16:41:13 -0400
with message-id <[email protected]>
has caused the   report #307158,
regarding [vim-gtk] "Edit --> Select Font..." defaults to (non-monospaced) 
"Sans" font
to be marked as having been forwarded to the upstream software
author(s) Bram Moolenaar <[email protected]>

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
307158: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=307158
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Bram,

As described below, if the user hasn't yet set 'guifont' the font
selection dialog will not have the default font selected which leads to
confusing behavior.

The attached patch addresses the first problem Andreas describes, but I
don't see a way to address the second problem.  The GTK developers
“helpfully” removed the ability to set a filter on the fonts that can be
selected when they changed from GTK1 to GTK2.

On Sun, May 01, 2005 at 11:28:06AM +0200, Andreas Metzler wrote:
> The selection dialogue that pops up on "Edit --> Select Font..." is
> set on
> --------
> Family Sans
> Style Regular
> Size 12
> --------
> 
> There are two problems with that:
> * This is not the font that is used by default, i.e.
> Edit --> Select Font...
> followed by <Enter> or the [Ok] button will change the font.
> * This font is not monospaced and therefore not usable in vim.

-- 
James
GPG Key: 1024D/61326D40 2003-09-02 James Vega <[email protected]>
diff --git a/src/gui_gtk_x11.c b/src/gui_gtk_x11.c
index 29ab9a7..798e256 100644
--- a/src/gui_gtk_x11.c
+++ b/src/gui_gtk_x11.c
@@ -4729,6 +4729,9 @@ gui_mch_font_dialog(char_u *oldval)
     if (oldval != NULL && *oldval != NUL)
 	gtk_font_selection_dialog_set_font_name(
 		GTK_FONT_SELECTION_DIALOG(gui.fontdlg), (char *)oldval);
+    else
+	gtk_font_selection_dialog_set_font_name(
+		GTK_FONT_SELECTION_DIALOG(gui.fontdlg), DEFAULT_FONT);
 
     if (gui.fontname)
     {
@@ -4816,6 +4819,9 @@ gui_mch_font_dialog(char_u *oldval)
 	if (oldname != oldval)
 	    vim_free(oldname);
     }
+    else
+	gtk_font_selection_dialog_set_font_name(
+		GTK_FONT_SELECTION_DIALOG(dialog), DEFAULT_FONT);
 
     response = gtk_dialog_run(GTK_DIALOG(dialog));
 

Attachment: signature.asc
Description: Digital signature


--- End Message ---

Reply via email to