Difference between revisions of "Save + export specification"

From GIMP GUI Redesign
Jump to: navigation, search
(export options)
(intro)
(25 intermediate revisions by the same user not shown)
Line 7: Line 7:
 
# simplify and clarify the user model: what you see on the canvas is always GIMP content;
 
# simplify and clarify the user model: what you see on the canvas is always GIMP content;
 
# enforce that what is on the canvas is only '''safe''' when saved as an xcf file—or its compressed variants;
 
# enforce that what is on the canvas is only '''safe''' when saved as an xcf file—or its compressed variants;
# give primary support for a high-end workflow where the work is saved in xcf, and when it is time for ‘delivery’, it is exported to the required format;
+
# give primary support for a high-end workflow where the work is saved in xcf, and for ‘delivery’, it is (repeatedly) exported to the required format;
# give secondary support to workflows where the input and output are the same non-xcf file; the reason for this is not the often touted ‘prosumer photo jpeg–to–jpeg’ workflow, because of GIMP product vision there is no need for optimising this. A much better reason for optimising are situations where high-end GIMP users have to do some quick touch-ups on graphic files for mates or clients, and send them back.
+
# give secondary support to workflows where the input and output are the same non-xcf file; the reason for this is not the often touted ‘prosumer photo jpeg–to–jpeg’ workflow, because for complying with the GIMP product vision there is no need for optimising this. A much better reason for optimising are situations where high-end GIMP users have to do some quick touch-ups on graphic files for mates or clients, and send them back.
  
The basic strategy that follows from the points above is: ''GIMP opens and saves GIMP files and imports/exports the rest.'' We make however one optimisation: fold Import back into Open, so everything stays (almost) the same there. Furthermore for the secondary workflow a ‘Export to’ menu item is added.
+
The basic strategy that follows from the points above is: ''GIMP opens and saves GIMP files and imports/exports the rest.'' We make however one optimisation: fold Import back into Open, so everything stays (almost) the same there. Furthermore for the secondary workflow an ‘Overwrite’ menu item is added.
  
 
==file menu changes==
 
==file menu changes==
Line 20: Line 20:
 
* Save
 
* Save
 
* Save as…
 
* Save as…
* Save a copy…
+
* Save a Copy…
 
* Revert…
 
* Revert…
 
* <menu separator>
 
* <menu separator>
 
* Export…
 
* Export…
 
* Export to
 
* Export to
* Create template…
+
* Create Template…
  
 
The sensitivity of the Export command shall track that of the Save command. The ‘Export to’ command shall be insensitive by default.
 
The sensitivity of the Export command shall track that of the Save command. The ‘Export to’ command shall be insensitive by default.
Line 31: Line 31:
 
===keyboard shortcuts===
 
===keyboard shortcuts===
  
The existing shortcuts in the FIle menu stay as-is. Finding them for the 2 new items is tricky, because the obvious candidates are taken. <ctrl>(-<shift>)-E would have been perfect for Export, ‘Export to’.
+
The existing shortcuts in the FIle menu stay as-is. <ctrl>-E shall be used for ‘Export to’, <ctrl>-<shift>-E for Export.
  
 
==(no) changes in actions==
 
==(no) changes in actions==
Line 37: Line 37:
 
===opening files===
 
===opening files===
  
It is not the goal of this spec to overhaul the file Open dialog, it and other means of opening files shall remain unchanged. What matters is what happens after a file is opened.
+
It is not the goal of this spec to overhaul the file Open dialog, it and other means of opening files (including via drag and drop) shall remain unchanged. What matters is what happens after a file is opened.
  
 
====opening a GIMP-type file====
 
====opening a GIMP-type file====
Line 45: Line 45:
 
====opening a non-GIMP-type file====
 
====opening a non-GIMP-type file====
  
After any other type of image file, it is officially imported, and the following shall be different:
+
After opening any other type of image file, it is officially imported, and the following shall be different:
  
* the title of the image window shall be set to “Untitled (imported from <filename>)-X.Y etc, etc.” where the <filename> is the name of the imported file; further opening of other files into this document (even GIMP files) shall not change the title or its status;
+
* if the import triggers a new document creation (so not an import as layer, for instance):
* the ‘Export to’ menu item shall have its label set to “Export to <filename>” and shall be made sensitive;
+
** the title of the image window shall be set to “Untitled (imported from <filename>)-X.Y etc, etc.” where the <filename> is the name (+ extension) of the imported file;
* the document shall be treated as a new, untitled file;
+
** the document shall be a new, untitled file;
 +
** the ‘Export to’ menu item shall have its label set to “Export to <filename>” and shall be made sensitive;
 +
* for every imported file, the layer name shall be set to the name (+ extension) of the imported file;
 +
** if the file imports into several layers, it shall be name (+ extension) of the imported file plus the layer number; however,
 +
** if the file imports into several layers '''and''' each of them is labelled in the file, then these labels shall be used for the layer names.
  
 
===saving files===
 
===saving files===
Line 55: Line 59:
 
Save, ‘Save as’ and ‘Save a copy’ shall only save to (compressed) GIMP formats, which shall be the only available format choices in the Save dialog. Only Save and ‘Save as’ shall change the saved-status of the document and replace the document–to–file association.
 
Save, ‘Save as’ and ‘Save a copy’ shall only save to (compressed) GIMP formats, which shall be the only available format choices in the Save dialog. Only Save and ‘Save as’ shall change the saved-status of the document and replace the document–to–file association.
  
In the save dialog, the default path and filename shall be, in order of precedence (highest at the top):
+
for Save, ‘Save as’, in the save dialog, the default path shall be, in order of precedence (highest at the top):
  
# path and filename of the last file where—within this session—this document was saved-to as GIMP file;
+
# path last filled in in a save dialog when this document was saved as GIMP file;
# path and filename of the opened GIMP file that started this session with this document;
+
# path of the opened file that started this session with this document;
# path and filename of the opened non-GIMP file that started this session with this document;
+
# path last filled in in a save dialog when any document was saved as GIMP file;
# path: user’s ‘documents’ folder on the operating system, name: “Untitled”.
+
# user’s ‘documents’ folder of the desktop environment.
  
The type of the file shall be always xcf.
+
for Save, ‘Save as’, the default filename shall be, in order of precedence (highest at the top):
 +
 
 +
# filename last filled in in a save dialog when this document was saved as GIMP file;
 +
# filename of the opened file that started this session with this document;
 +
# “Untitled”.
 +
 
 +
for ‘Save a copy’, in the save dialog, the default path shall be, in order of precedence (highest at the top):
 +
 
 +
# path last filled in in a save dialog when this document was ‘saved as a copy’ as GIMP file;
 +
# path last filled in in a save dialog when this document was saved as GIMP file;
 +
# path of the opened file that started this session with this document;
 +
# path last filled in in a save dialog when any document was saved as GIMP file;
 +
# user’s ‘documents’ folder of the desktop environment.
 +
 
 +
for ‘Save a copy’, the default filename shall be, in order of precedence (highest at the top):
 +
 
 +
# filename last filled in in a save dialog when this document was ‘saved as a copy’ as GIMP file;
 +
# filename last filled in in a save dialog when this document was saved as GIMP file;
 +
# filename of the opened file that started this session with this document;
 +
# “Untitled”.
 +
 
 +
The type of the file shall be always (compressed) xcf. If users try to ‘save’ to another file format they shall be shown a reminder saying “You can use this dialog to save to the GIMP XCF format. Use File→Export to export to other file formats.”
 +
 
 +
====drag and drop====
 +
 
 +
Dragging the document out of the main window and dropping it on the desktop environment shall attempt to save the document (being a GIMP file, as a GIMP file) at the location it was dropped.
 +
 
 +
The filename shall be, in order of precedence (highest at the top):
 +
 
 +
# filename last filled in in a save dialog when this document was saved as GIMP file;
 +
# filename of the opened file that started this session with this document;
 +
# “Untitled”.
  
 
===revert===
 
===revert===
  
The revert dialog box shall remain as-is. For reverting back to the state of [[#opening a non-GIMP-type file | opening non-GIMP files]], the top string shall be “Revert 'Untitled' to '/<path>/<filename>'?”.
+
The revert dialog box shall remain as-is. For reverting back to the state of [[#opening a non-GIMP-type file | opening non-GIMP files]], the top string shall be “Revert 'Untitled' to '/<path>/<filename>'?”, path and filename being that of the opened non-GIMP file.
  
 
To be clear, here is the list of what revert should revert to, in order of precedence (highest at the top):
 
To be clear, here is the list of what revert should revert to, in order of precedence (highest at the top):
  
# the last file where—within this session—this document was saved-to as GIMP file;
+
# the last file where this document was saved-to as GIMP file;
 
# the opened GIMP file that started this session with this document;
 
# the opened GIMP file that started this session with this document;
 
# the opened non-GIMP file that started this session with this document.
 
# the opened non-GIMP file that started this session with this document.
Line 82: Line 117:
 
* an export shall not change the saved-status of the document, or replace the document–to–file association;
 
* an export shall not change the saved-status of the document, or replace the document–to–file association;
  
In the export dialog, the default path and filename shall be, in order of precedence (highest at the top):
+
In the export dialog, the default path shall be, in order of precedence (highest at the top):
 +
 
 +
# path last filled in in an export dialog when this document was exported;
 +
# path last filled in in an export dialog when any document was exported;
 +
# path of the opened file that started this session with this document;
 +
# path last filled in in a save dialog when this document was saved as GIMP file;
 +
# path last filled in in a save dialog when any document was saved as GIMP file;
 +
# user’s ‘documents’ folder of the desktop environment.
  
# path and filename of the last file where—within this session—this document was saved-to as GIMP file;
+
The default filename shall be, in order of precedence (highest at the top):
# path and filename of the opened GIMP file that started this session with this document;
+
 
# path and filename of the opened non-GIMP file that started this session with this document;
+
# filename last filled in in an export dialog when this document was exported;
# path: user’s ‘documents’ folder on the operating system, name: “Untitled”.
+
# filename of the opened file that started this session with this document;
 +
# filename last filled in in a save dialog when this document was saved as GIMP file;
 +
# “Untitled”.
  
 
The type of the file shall be, in order of precedence (highest at the top):
 
The type of the file shall be, in order of precedence (highest at the top):
  
# the last type this document was exported to, this session;
+
# the type last chosen in an export dialog when this document was exported;
# the type of the opened non-GIMP file that started this session with this document;
+
# the type last chosen in an export dialog when any document was exported;
# the last type any document was exported to;
 
 
# the zero-day default: png (I’ll take any other reasonable suggestion of a free and open image format).
 
# the zero-day default: png (I’ll take any other reasonable suggestion of a free and open image format).
 +
 +
After a successful export, the ‘Export to’ menu item shall have its label set to “Export to <filename>” and shall be made sensitive.
  
 
===export to original===
 
===export to original===
Line 100: Line 145:
 
From the moment it is made sensitive the ‘Export to’ menu item shall remain sensitive until the document is closed.
 
From the moment it is made sensitive the ‘Export to’ menu item shall remain sensitive until the document is closed.
  
* ‘Export to’ shall export the current document back to the opened non-GIMP file that started this session;
+
* ‘Export to’ shall export the current document to the non-GIMP file that is mentioned in the menu item;
* if for some reason this file can not be written (e.g. file server gone, no permissions), Export shall be invoked;
+
* if for some reason this file can not be written (e.g. file server gone, no permissions), then the standard handling as used for saving files shall be used, where any mention of saving in the title shall be replaced by exporting;
 
* ‘Export to’ shall not change the saved-status of the document, or replace the document–to–file association.
 
* ‘Export to’ shall not change the saved-status of the document, or replace the document–to–file association.
  
Line 113: Line 158:
 
** the whole string “Your image should be exported before it can be saved as <file type> for the following reasons:” shall be omitted.
 
** the whole string “Your image should be exported before it can be saved as <file type> for the following reasons:” shall be omitted.
 
* if there are no export user choices then there shall be no options dialog;
 
* if there are no export user choices then there shall be no options dialog;
* if there is an export options dialog it shall not be shown when:
+
* if there is an export options dialog it shall not be shown when the document is being [[#export to original | exported to original]] '''and''' the file format is not [[#lossy file formats | lossy]] '''and''' all the export options can be determined from the original file.
** the document has already been exported—within this session—to exactly the same path + filename + type;
 
** the document is being [[#export to original | exported to original]] '''and''' the file format is not [[#lossy file formats | lossy]] '''and''' all the export options can be determined from the original file.
 
  
 
The export options shall default to, in order of precedence (highest at the top):
 
The export options shall default to, in order of precedence (highest at the top):

Revision as of 14:40, 29 June 2009

intro

This specification defines a clear separation between saving and export, based on version 2.6.

This change tries to achieve some specific goals:

  1. simplify and clarify the user model: what you see on the canvas is always GIMP content;
  2. enforce that what is on the canvas is only safe when saved as an xcf file—or its compressed variants;
  3. give primary support for a high-end workflow where the work is saved in xcf, and for ‘delivery’, it is (repeatedly) exported to the required format;
  4. give secondary support to workflows where the input and output are the same non-xcf file; the reason for this is not the often touted ‘prosumer photo jpeg–to–jpeg’ workflow, because for complying with the GIMP product vision there is no need for optimising this. A much better reason for optimising are situations where high-end GIMP users have to do some quick touch-ups on graphic files for mates or clients, and send them back.

The basic strategy that follows from the points above is: GIMP opens and saves GIMP files and imports/exports the rest. We make however one optimisation: fold Import back into Open, so everything stays (almost) the same there. Furthermore for the secondary workflow an ‘Overwrite’ menu item is added.

file menu changes

Currently (v2.6) the Save section of the file menu looks like this:
Save menu.png

Two new menu items shall be introduced: Export and ‘Export to’. To avoid too long (== too slow to scan) menu sections, this section shall be split in two:

  • Save
  • Save as…
  • Save a Copy…
  • Revert…
  • <menu separator>
  • Export…
  • Export to
  • Create Template…

The sensitivity of the Export command shall track that of the Save command. The ‘Export to’ command shall be insensitive by default.

keyboard shortcuts

The existing shortcuts in the FIle menu stay as-is. <ctrl>-E shall be used for ‘Export to’, <ctrl>-<shift>-E for Export.

(no) changes in actions

opening files

It is not the goal of this spec to overhaul the file Open dialog, it and other means of opening files (including via drag and drop) shall remain unchanged. What matters is what happens after a file is opened.

opening a GIMP-type file

After opening a (compressed) xcf file everything works as it does in v2.6.

opening a non-GIMP-type file

After opening any other type of image file, it is officially imported, and the following shall be different:

  • if the import triggers a new document creation (so not an import as layer, for instance):
    • the title of the image window shall be set to “Untitled (imported from <filename>)-X.Y etc, etc.” where the <filename> is the name (+ extension) of the imported file;
    • the document shall be a new, untitled file;
    • the ‘Export to’ menu item shall have its label set to “Export to <filename>” and shall be made sensitive;
  • for every imported file, the layer name shall be set to the name (+ extension) of the imported file;
    • if the file imports into several layers, it shall be name (+ extension) of the imported file plus the layer number; however,
    • if the file imports into several layers and each of them is labelled in the file, then these labels shall be used for the layer names.

saving files

Save, ‘Save as’ and ‘Save a copy’ shall only save to (compressed) GIMP formats, which shall be the only available format choices in the Save dialog. Only Save and ‘Save as’ shall change the saved-status of the document and replace the document–to–file association.

for Save, ‘Save as’, in the save dialog, the default path shall be, in order of precedence (highest at the top):

  1. path last filled in in a save dialog when this document was saved as GIMP file;
  2. path of the opened file that started this session with this document;
  3. path last filled in in a save dialog when any document was saved as GIMP file;
  4. user’s ‘documents’ folder of the desktop environment.

for Save, ‘Save as’, the default filename shall be, in order of precedence (highest at the top):

  1. filename last filled in in a save dialog when this document was saved as GIMP file;
  2. filename of the opened file that started this session with this document;
  3. “Untitled”.

for ‘Save a copy’, in the save dialog, the default path shall be, in order of precedence (highest at the top):

  1. path last filled in in a save dialog when this document was ‘saved as a copy’ as GIMP file;
  2. path last filled in in a save dialog when this document was saved as GIMP file;
  3. path of the opened file that started this session with this document;
  4. path last filled in in a save dialog when any document was saved as GIMP file;
  5. user’s ‘documents’ folder of the desktop environment.

for ‘Save a copy’, the default filename shall be, in order of precedence (highest at the top):

  1. filename last filled in in a save dialog when this document was ‘saved as a copy’ as GIMP file;
  2. filename last filled in in a save dialog when this document was saved as GIMP file;
  3. filename of the opened file that started this session with this document;
  4. “Untitled”.

The type of the file shall be always (compressed) xcf. If users try to ‘save’ to another file format they shall be shown a reminder saying “You can use this dialog to save to the GIMP XCF format. Use File→Export to export to other file formats.”

drag and drop

Dragging the document out of the main window and dropping it on the desktop environment shall attempt to save the document (being a GIMP file, as a GIMP file) at the location it was dropped.

The filename shall be, in order of precedence (highest at the top):

  1. filename last filled in in a save dialog when this document was saved as GIMP file;
  2. filename of the opened file that started this session with this document;
  3. “Untitled”.

revert

The revert dialog box shall remain as-is. For reverting back to the state of opening non-GIMP files, the top string shall be “Revert 'Untitled' to '/<path>/<filename>'?”, path and filename being that of the opened non-GIMP file.

To be clear, here is the list of what revert should revert to, in order of precedence (highest at the top):

  1. the last file where this document was saved-to as GIMP file;
  2. the opened GIMP file that started this session with this document;
  3. the opened non-GIMP file that started this session with this document.

exporting files

All non-GIMP file types can be exported via the Export menu item:

  • no (compressed) GIMP formats shall be available as format choices in the Export dialog;
  • the ‘Save as’ dialog shall be recycled for the Export dialog; the dialog title shall be “Export Image”;
  • an export shall not change the saved-status of the document, or replace the document–to–file association;

In the export dialog, the default path shall be, in order of precedence (highest at the top):

  1. path last filled in in an export dialog when this document was exported;
  2. path last filled in in an export dialog when any document was exported;
  3. path of the opened file that started this session with this document;
  4. path last filled in in a save dialog when this document was saved as GIMP file;
  5. path last filled in in a save dialog when any document was saved as GIMP file;
  6. user’s ‘documents’ folder of the desktop environment.

The default filename shall be, in order of precedence (highest at the top):

  1. filename last filled in in an export dialog when this document was exported;
  2. filename of the opened file that started this session with this document;
  3. filename last filled in in a save dialog when this document was saved as GIMP file;
  4. “Untitled”.

The type of the file shall be, in order of precedence (highest at the top):

  1. the type last chosen in an export dialog when this document was exported;
  2. the type last chosen in an export dialog when any document was exported;
  3. the zero-day default: png (I’ll take any other reasonable suggestion of a free and open image format).

After a successful export, the ‘Export to’ menu item shall have its label set to “Export to <filename>” and shall be made sensitive.

export to original

From the moment it is made sensitive the ‘Export to’ menu item shall remain sensitive until the document is closed.

  • ‘Export to’ shall export the current document to the non-GIMP file that is mentioned in the menu item;
  • if for some reason this file can not be written (e.g. file server gone, no permissions), then the standard handling as used for saving files shall be used, where any mention of saving in the title shall be replaced by exporting;
  • ‘Export to’ shall not change the saved-status of the document, or replace the document–to–file association.

export options

Nobody likes clicking their way through export options dialogs. So we will put the brakes on them:

  • there shall be one export options dialog:
    • export conversion information that needs no user choices shall be omitted;
    • the generic export choices and the file-type specific export choices shall be integrated into one dialog;
    • the whole string “Your image should be exported before it can be saved as <file type> for the following reasons:” shall be omitted.
  • if there are no export user choices then there shall be no options dialog;
  • if there is an export options dialog it shall not be shown when the document is being exported to original and the file format is not lossy and all the export options can be determined from the original file.

The export options shall default to, in order of precedence (highest at the top):

  1. the export options used last time when this document was exported to the same file type;
  2. the export options used last time when any document was exported to the same file type;
  3. the export options used in v2.6.

lossy file formats

Lossy graphics file formats are defined as those who cannot be read into memory and written back unmodified to file without loss of fidelity.