Script-fu SF-FILENAME don't show the default setting
On Wed, 2007-08-29 at 01:17 +0200, Pere Pujal i Carabantes wrote:
When using SF-FILENAME, if the file exist, the name of the file is
in the button, but if the file does not exist, ie. has to be created,
there is "(none)" in the button.
Is there a way to show the name on the button even if the file does
After some try/error and a look at the code, it seems not.
SF-Filename uses gtk_file_chooser_button, and acording to
gtk_file_chooser_button only supports the GtkFileChooserActions
GTK_FILE_CHOOSER_ACTION_OPEN and GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER,
not the GTK_FILE_CHOOSER_ACTION_SAVE
GTK_FILE_CHOOSER_ACTION_OPEN Indicates open mode. The file chooser will
only let the user pick an existing file.
GTK_FILE_CHOOSER_ACTION_SAVE Indicates save mode. The file chooser will
let the user pick an existing file, or type in a new filename.
So, if someone like I wants to write a nonexistent file, and this file
has to be selected by the user, the obvious solution is to use
SF-DIRNAME to get the directory and follow a SF-STRING to get the
After that, a (string-append dirname "/" filename) in the code gives the