XnView Software

0.84: 'Del' key on categories deletes files

0.84: 'Del' key on categories deletes files

Posted: Fri Mar 04, 2016 2:12 pm

by jonha4711

I am not sure the following classifies as a bug but it definitely seems not right.

Say I have selected one (or more) images in the browser window. I then click the "Categories" pane and click on any of the defined categories.I can now use the up/down keys to move around in the defined categories. IOW, the keyboard focus is now clearly in the "Categories" pane. If now I press the delete key in an attempt to delete the currently selected category, XnViewMP (.78, Win7) instead deletes the selected images in the browser window which does, at that point, not have the focus!

This is rather dangerous and not at all what I would expect.

The only way I've found to delete a category is to right-click it and then click on Delete in the context menu. It seems impossible to delete categories via the keyboard.

Re: Deleting categories

Posted: Wed Mar 09, 2016 1:58 pm

by xnview

not really a bug, but you're right it can be dangerous...

when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

Re: Deleting categories

Posted: Wed Mar 09, 2016 2:12 pm

by oops66

xnview wrote:not really a bug, but you're right it can be dangerous...when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

+ 1000

Re: Deleting categories

Posted: Wed Mar 09, 2016 3:11 pm

by cday

xnview wrote:not really a bug, but you're right it can be dangerous...

when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

Perhaps a warning prompt would be desirable?

Re: Deleting categories

Posted: Thu Mar 10, 2016 10:33 am

by jonha4711

xnview wrote:when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

That's what I would expect. Whether there should be a confirmation box is debatable... I am not a great fan of those. Clicking OK or pressing the return key (I tend to be a keyboard guy) wouldn't be much of a problem though.

So as far as I'm concerned... a definite YES.

Re: Deleting categories

Posted: Thu Mar 10, 2016 11:36 am

by cday

jonha4711 wrote:Whether there should be a confirmation box is debatable... I am not a great fan of those. Clicking OK or pressing the return key (I tend to be a keyboard guy) wouldn't be much of a problem though.

A warning prompt could have a 'Do not show again' option...

If there is a significant risk of losing valuable data due to a misunderstanding or carelessness, a prompt seems justified...

Re: Deleting categories

Posted: Mon Mar 28, 2016 5:14 am

by CameronD

xnview wrote:
when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

Certainly.

Other issues:
The prompt for deleting an image says "Are you sure to delete these 1 item(s)?" - using "item" rather than "image" or even "file" means the user was not even aware that he/she is currently confirming an image deletion rather than a category.

Even deleting a category might not be what the user actually wants, and simply deleting the category from the DB might be counterproductive.

For example: I might actually want to remove a category from image files, but I have options enabled to import and export categories as iptc:keywords and xmp-dc:subject. Currently the "delete category" process will only delete the entry in the database, and if the program revisits the images at a later date then it should re-import the categories and I would be heading back to where I started. (It does not, so I will report that as a separate bug). To best achieve my original aim, I would want to not delete the category, but use the categories filter to find all occurrences and remove them manually, before then deleting the category.
As a different example, I might want to modify a category name. Using "rename category" in xnviewMP does not rewrite values stored in image metadata, so I would need to carefully follow several steps through with xnviewMP or else use use exiftool and hope I could reimport the renamed category.

No single operation will be suitable in all cases, so the prompt should at least include a warning that metadata in files will not be changed.

Re: Deleting categories

Posted: Thu Jul 14, 2016 1:38 pm

by jonha4711

For 0.82 can you please consider either ignoring the Del key if the Categories tab has the focus or (in my view better) make it delete the current category? The current way to delete all selected images is not at all intuitive.

Deleting metadata shows same problem

Posted: Sun Jul 17, 2016 12:05 pm

by CameronD

The same problem happens when the Info pane window is showing metadata such as IPTC or XMP.

I saw an image with junk inserted by Microsoft Photo. I thought it would be nice to remove that so I selected it, ensuring focus was in the Info pane, and hit delete.
This gave the same ambiguous warning "Are you sure to delete these 1 item(s)" and when I said yes then the jpeg file was deleted.

Now, in this case, I expect that removing the offending metadata is not as simple as deleting categories, so in this case either

Re: Deleting categories

Posted: Tue Jan 03, 2017 10:21 am

by jadO

This is what happened to me today as I made some major reorginasations within the categories.
I deleted one category and got a prompt.
I deleted another one, saw the prompt, hit yes and did not realise that I had deleted a file.

This is what I did: Created a category with subcategory at a wrong place. Clicked on subcategory->Right click->Popup asking to delete category. Selected parent category->Hit del key
I did not read the popup properly as it was exactly what I expected however this time it was the popup asking me if I wanted to delete this item. I hit yes, because everything was focused on category and gone was a file.

This is not good. As 2 completely different items are highlighted, it is ambigous what the user really wants to do. So the popup should force me to select if I want to delete the category or if I want to delete the file.

Re: Deleting categories

Posted: Sat Feb 11, 2017 10:09 pm

by helmut

xnview wrote:not really a bug, but you're right it can be dangerous...

when focus in on category pane, del must delete the category and not the file, everyone is ok with that?

+1 And: Due to the potential loss of image files I consider this as a must fix.

Re: 0.84: 'Del' key on categories deletes files

Posted: Sat Jun 17, 2017 4:58 pm

by xnview

O.k., thank you, I can also reproduce the problem. Issue 845 is fixed in next version.

Re: 0.84: 'Del' key on categories deletes files

Posted: Sat Jul 08, 2017 12:57 pm

by xnview

This problem is supposed to be fixed in XnView MP 0.87. Please check and confirm the bug fix here.

Re: 0.84: 'Del' key on categories deletes files

Posted: Tue Aug 22, 2017 10:05 am

by HanVroon

Tested with 0.87 beta 3, fixed.

First reproduced with version 0.86, selecting two files, then selecting a category, pressing Del asked if I wanted to delete the two files. After confirming the two files where deleted, not the category.

Tested with 0.87 beta 3, did the same thing, now the message "Are you shure to delete this category" came and after confirming the category was deleted.