Go forward in time to August 2011.
Has anyone read Jane Jacobs's "Systems of Survival" (of which there are many summaries)? Something tells me that it would provide a good framework for thinking about things like Contributor License Agreements — these try to combine the principles of free software with the principles of commerce, and thus lead to what Jacobs calls monstrous moral hybrids.
(I haven't gotten the book yet, unfortunately, but it's next on my to-buy list...)
In LibreOffice, it is very annoying that when you are using a drawing tool, you draw your shape and then the program switches you back to the Selection tool. For example, suppose you draw the basic shapes in a diagram, and then you want to draw arrows that connect those shapes. You have to click the arrow tool, draw an arrow, click the arrow tool again, draw an arrow, click the arrow tool again...
This is totally unlike Inkscape, which has a simpler model: the tool you select stays active, until you switch tools or single-click on an existing object (which selects it).
LibreOffice's Help even says, "To draw multiple objects of the same type, double-click the icon [in the toolbar]". Yeah, right.
I have started a patch to fix this; testing is appreciated!
(This is some procrastination from writing a presentation that actually requires a good number of drawings...)
Now it needs a second coat of paint. My poor neck.
This is the decoration for the little vault in progress:
It's really tiring to paint on the ceiling!
Recent folders in the file chooser
The other day I wrote about one of the patterns for Document-Centric Gnome, "Help the user choose a place to put a new file". After the final mockups, we now have an implementation.
If you run this branch (anchored on the gtk-3-0 stable one), your Save file chooser will look like this:
When you type a filename, and click on a suggested folder, the pathbar will change to show that folder. This is nice; it means that the "Save in folder" label actually indicates a meaningful place now.
And it avoids the problem of people forgetting to choose a folder and hitting "Save" too soon; it ensures that you make a choice first.
Since you actually get useful suggestions about where to save, this kind of warning will not feel onerous. You can navigate to other folders as usual, with the shortcuts pane or by double-clicking on one of those recent folders.
The file chooser thus lost its expanded/collapsed states. There is no more "useless, small version of the file chooser", vs. "cluttered, big version". Now, when it starts up, it actually gives you useful choices in the form of recently-used folders or files. I've also updated the documentation to tell application writers how to ensure that this works as intended.
Guidelines for application writers and Save dialogs
Don't call gtk_file_chooser_set_current_folder().
If you are writing a File/Save or File/Save As command, use the file chooser like this:
GtkWidget *dialog;
dialog = gtk_file_chooser_dialog_new ("Save File",
parent_window,
GTK_FILE_CHOOSER_ACTION_SAVE,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_SAVE, GTK_RESPONSE_ACCEPT,
NULL);
gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (dialog), TRUE);
if (user_edited_a_new_document)
gtk_file_chooser_set_current_name (GTK_FILE_CHOOSER (dialog), "Untitled document");
else
gtk_file_chooser_set_filename (GTK_FILE_CHOOSER (dialog), filename_for_existing_document);
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT)
{
char *filename;
filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (dialog));
save_to_file (filename);
g_free (filename);
}
gtk_widget_destroy (dialog);
That is, use gtk_file_chooser_set_current_name() when you don't have an existing file, and use gtk_file_chooser_set_filename() when you already have an existing file.
If you use set_filename(), the file chooser will not show the recently-used folders list. Instead it will show the file listing for the file's folder, as usual, as in "File/Save As" you usually just want to give the file a different name.
Okay, I want this
I have to forward-port this code to the master development branch. In the meantime, you can peruse the branch based on gtk-3-0. I'll also backport this to GTK+ 2.x, so that apps that haven't been ported to GTK+ 3 can still get the benefits.
If you'd like to discuss this, please go to the wiki page and post at the bottom!
Go backward in time to June 2011.
Federico Mena-Quintero <federico@gnome.org> Fri 2011/Jul/01 18:05:29 CDT