After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 328092 - want gtk_file_chooser_GET_current_name
want gtk_file_chooser_GET_current_name
Status: RESOLVED DUPLICATE of bug 135901
Product: gtk+
Classification: Platform
Component: Widget: GtkFileChooser
unspecified
Other Linux
: Normal enhancement
: Small API
Assigned To: gtk-bugs
Federico Mena Quintero
: 525847 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-01-21 22:13 UTC by Christian Persch
Modified: 2008-04-02 21:13 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Christian Persch 2006-01-21 22:13:13 UTC
as counterpart to _set_current_name. Here's why:
_set_current_name is used to set a name proposal. When there's a format selector (combo box for example) as extra widget, I want to change the proposed name with the extension matching the newly selected format. E.g. user typed "test.png" and changes the format to "GIF", I want to update the 'typed' filename to "test.gif".
I could do that by getting the current file/uri, finding the filename part, convert to UTF-8, change + _set_current_name (that's what gimp does, see the rather complicated gimp_file_dialog_proc_changed function in 
http://cvs.gnome.org/viewcvs/*checkout*/gimp/app/widgets/gimpfiledialog.c?rev=1.55 ) but I want a simpler way. Also _get_current_name would eliminate problems by not converting the user input first to locale encoding then back.
Comment 1 Federico Mena Quintero 2006-01-23 17:45:27 UTC
Wouldn't it be better to have robust handling of file types at the API level?  See bug #135901 about this.
Comment 2 Federico Mena Quintero 2007-01-25 17:11:41 UTC

*** This bug has been marked as a duplicate of 135901 ***
Comment 3 Christian Persch 2008-04-02 21:13:16 UTC
*** Bug 525847 has been marked as a duplicate of this bug. ***