On Mon, 09 Jul 2007 08:14:29 +0200, Sven Neumann <[EMAIL PROTECTED]> wrote:

> Hi,
>
> On Sun, 2007-07-08 at 19:15 -0400, guepe wrote:
>
>> In fact, my patch... does exactly that : if defaults settings are
>> already saved, jpeg is saved with the parasites one (erasing the
>> hardcoded ones). If no settings have been saved, then hardcoded are
>> used.
>
> There is another player in the game and that's the last-used values
> stored with gimp_[gs]et_data(). And that's what has bitten Guillermo. He
> has saved an image as JPEG with low quality settings. Then later, he
> saved another image, which didn't have the parasite set. And for that
> image, the low quality parameters from the last invocation of the JPEG
> plug-in have been used.

That certainly would happen and is part of the issue. Hwvr, in his case  
(confirmed by two other posters) it was a high setting being replaced by  
the default of 85, so it was not even a little bit his fault it was gimp.

> This is the expected behavior for all plug-ins.

Yes in general its good, if I chose png compression of 9 I dont want to  
have to reset that value on very invocation of the dlg.

But two cases need to be destinguished: Save and SaveAs. I would suggest  
that Save should _always_ retain the current settings of the image be it  
jpeg , png or whatever. Save should do just that, not start redefining  
things.

In the case of png this is a minor annoying defect that can be remedied  
later but the same principal applies.

> But we might want to make an exception for JPEG because of its
> potentially destructive nature.
>
>
> Sven
>

OK, so everyone agrees this is unacceptable for jpeg. I would suggest that  
all formats preserve all parameters when in non-interactive , ie Save.  
This means less exceptions and predictable results and common code path.


Where there is a need for special treatment is SaveAs. Because of the  
destructive effects the dlg should come up with the image's existing  
quality param for jpeg o/w the user will never know what it needs to be  
even if he is fully aware and wants it to remain the same.

Other formats it would be nice (usabiliy) to take last used , user's  
default being used when no value is available (that's what default means  
in fact) ie on a new image or on format change.

I think we need to let jpeg lead the dance here since it can be  
destructive and irreversible.

A good way to present all this in a common format with no potentially  
confusing ifs and buts would be to add a radio button choice to all plugin  
dlgs   [ Default | Current | Last-used ]  defaulting to last used as  
dictated by jpeg but the user is never more than one click away from a  
clear choice between the three cases.

I know you dont like more controls but this seems the only to be  
consistant and clear. Making choices that do different things behind the  
users back depending on image format can only be confusing.


Anyway, that is something of side issue. The main defect that need fixing  
directly is the non-interactive case.

I think Save should do nothing fancy and should be the same for all.  
Simple, predictable and non destructive.
It should preserve existing setting for all formats.

We should probably focus on that before discussing SaveAs.

Also minor coding effort , we just need to dig out jpeg_quality from  
somewhere.

/gg


_______________________________________________
Gimp-developer mailing list
Gimp-developer@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

Reply via email to