Questions about Categories

Ask for help and post your question on how to use XnView MP.

Moderators: XnTriq, xnview

User avatar
xnview
Author of XnView
Posts: 32005
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Questions about Categories

Post by xnview » Mon Feb 29, 2016 3:11 pm

oops66 wrote: Image
it's perhaps better and more user friendly than having AND/OR/NOT for each line??
Pierre.

jonha4711
Posts: 55
Joined: Mon Feb 08, 2016 4:35 pm

Re: Questions about Categories

Post by jonha4711 » Mon Feb 29, 2016 4:52 pm

xnview wrote:
oops66 wrote: Image
it's perhaps better and more user friendly than having AND/OR/NOT for each line??
Well, this is probably slightly easier to understand but it's not nearly as powerful as a fully-fledged AND/OR/NOT capability. If you add a drop-down box *after* each condition linking it with the following condition (along the lines of what photoken wrote), I think the best would be to offer the following 4 choices:
1. AND
2. OR
3. AND NOT
4. OR NOT
These should be pretty self explanatory.

I for one would very much appreciate an extended search feature.

User avatar
xnview
Author of XnView
Posts: 32005
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Questions about Categories

Post by xnview » Mon Feb 29, 2016 7:18 pm

jonha4711 wrote: Well, this is probably slightly easier to understand but it's not nearly as powerful as a fully-fledged AND/OR/NOT capability. If you add a drop-down box *after* each condition linking it with the following condition (along the lines of what photoken wrote), I think the best would be to offer the following 4 choices:
1. AND
2. OR
3. AND NOT
4. OR NOT
These should be pretty self explanatory.
but it can become complicated for the user i think
For C1 AND C2 OR C3, is it ((C1 AND C2) OR C3) or (C1 AND (C2 OR C3))
Pierre.

User avatar
oops66
XnThusiast
Posts: 1999
Joined: Tue Jul 17, 2007 1:17 am
Location: France

Re: Questions about Categories

Post by oops66 » Mon Feb 29, 2016 10:07 pm

xnview wrote:
oops66 wrote: Image
it's perhaps better and more user friendly than having AND/OR/NOT for each line??
... For me both are OK ;-) ... In a first time Digikam used the "OR, AND, NOT and ()" items, but now it is more user friendly for most of the users, like this screenshot.
XnViewMP 0.82 Linux X64 - Ubuntu 16.04 LTS - X64

jonha4711
Posts: 55
Joined: Mon Feb 08, 2016 4:35 pm

Re: Questions about Categories

Post by jonha4711 » Tue Mar 01, 2016 11:16 am

xnview wrote:
jonha4711 wrote: Well, this is probably slightly easier to understand but it's not nearly as powerful as a fully-fledged AND/OR/NOT capability. If you add a drop-down box *after* each condition linking it with the following condition (along the lines of what photoken wrote), I think the best would be to offer the following 4 choices:
1. AND
2. OR
3. AND NOT
4. OR NOT
These should be pretty self explanatory.
but it can become complicated for the user i think
For C1 AND C2 OR C3, is it ((C1 AND C2) OR C3) or (C1 AND (C2 OR C3))
First of all, sure this can get quite complicated... that is the whole point of having a powerful mechanism at your fingertips! OTOH, nobody is *forced* to construct very complex queries. Similarly, nobody is ever *forced* to use regular expressions in a textual search but they add a whole new level of capability.

Second, to the real question. There are two possibilities here: one is simply to define the operator precedence in a certain way and stick with that. (For instance in C, logical AND has a higher priority than logical OR, so "C1 && C2 || C3" would read as "((C1 && C2) || C3)".)

Second, one could add a mechanism for explicitly supporting parentheses to make the meaning clear. This would be the Rolls Royce version, but I am not sure whether the effort is worth it. Perhaps it would be worthwhile to "test the waters" with the simpler precedence version and only if and when users complain about the lack of parentheses with convincing use cases, think about adding them. Sort of lazy evaluation : )

User avatar
photoken
Posts: 19
Joined: Sun Mar 29, 2015 9:34 pm

Re: Questions about Categories

Post by photoken » Tue Mar 01, 2016 6:08 pm

xnview wrote: but it can become complicated for the user i think
For C1 AND C2 OR C3, is it ((C1 AND C2) OR C3) or (C1 AND (C2 OR C3))
Yes, it can become complicated.

Since the end result is to create a SQL query against the database, I think there are two optional methods to use in the User Interface:
  • Do nothing in the UI to accommodate parentheses, and let the default behaviour of the database's interpretation happen.
  • Add small dropdown selection boxes to each line:
    • At the front of the line, the dropdown box would contain two items:
      • Nothing. (Empty)
      • Open parenthesis: (
    • At the end of the line, the dropdown box would contain two items:
      • Nothing. (Empty)
      • Close parenthesis: )
    The empty items would be the default.
This would eliminate the need for "AND NOT" and "OR NOT" items in the other selection dropdown box.
Ken
Yes, I think it can be eeeeeasily done...
Just take everything out on Highway 61.

User avatar
Sirio
Posts: 120
Joined: Tue Oct 13, 2015 3:22 pm

Re: Questions about Categories

Post by Sirio » Fri Apr 08, 2016 9:25 am

+1
The AND/OR/NOT option would be useful.
Sirio

samvise
Posts: 12
Joined: Fri Mar 11, 2016 1:50 pm

Re: Questions about Categories

Post by samvise » Mon Apr 18, 2016 1:29 pm

photoken wrote: [*]Each line of criteria would be followed by a dropdown selection box containing three items that refer to the following line of criteria:
  • AND
  • OR
  • NOT
[/list]
+1! As a first step, this would already be great, even without parenthesis.

User avatar
xnview
Author of XnView
Posts: 32005
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Questions about Categories

Post by xnview » Mon Apr 18, 2016 1:54 pm

this solution is not easiest?
Image
Pierre.

User avatar
Sirio
Posts: 120
Joined: Tue Oct 13, 2015 3:22 pm

Re: Questions about Categories

Post by Sirio » Mon Apr 18, 2016 2:26 pm

It would be more complete and precise like this:
Image
And with the possibility that the keyword in the category become visible instead of "Categories"
Attachments
AND-OR-NOT.jpg
Sirio

User avatar
photoken
Posts: 19
Joined: Sun Mar 29, 2015 9:34 pm

Re: Questions about Categories

Post by photoken » Tue Apr 19, 2016 5:41 am

Sirio wrote:And with the possibility that the keyword in the category become visible instead of "Categories"
+1,000 !
Ken
Yes, I think it can be eeeeeasily done...
Just take everything out on Highway 61.

User avatar
Sirio
Posts: 120
Joined: Tue Oct 13, 2015 3:22 pm

Re: Questions about Categories

Post by Sirio » Tue Apr 19, 2016 8:49 am

More logic if they stay before.
Attachments
AND-OR-NOT copy.jpg
Sirio

jonha4711
Posts: 55
Joined: Mon Feb 08, 2016 4:35 pm

Re: Questions about Categories

Post by jonha4711 » Wed Apr 20, 2016 3:10 pm

xnview wrote:this solution is not easiest?
Image
Easy is good, powerful is better. See my posts further up re this suggestion...

curio
Posts: 5
Joined: Thu May 26, 2016 8:26 am

Re: Questions about Categories

Post by curio » Thu May 26, 2016 12:34 pm

xnview wrote:
photoken wrote: XnViewMP is lacking one very important search feature, however -- the ability to search for images which do NOT have a specific category. In other words, you can build a search for images which have the categories "Germany" AND "Mountains", but you cannot build a search for images which have the category "Germany" and NOT "Mountains". I filed a request for this many months ago, but it has not been implemented. :(
yes, but how to do that in ui? by selecting category in the treeview, we can have AND/OR, but how to represent NOT
Very easily, e.g., the way Daminion does: In the tree, a radio box can be ticked for positive selection (turns green) and Ctrl-clicked (or was it Alt-clicked?) for negative selection (turns red). Also, once multiple entries are ticked on the same level of the hierarchy, a logical operation selector becomes availabe (inline with the next-higher tier) for selection between AND and OR. Being able to filter this way would be way less cumbersome than the pretty tedious procedure performed in the search dialog.

User avatar
Sirio
Posts: 120
Joined: Tue Oct 13, 2015 3:22 pm

Re: Questions about Categories

Post by Sirio » Thu May 26, 2016 12:46 pm

Interesting, in fact, here the link to see it:
http://daminion.net/feature-tour/damini ... any-assets
Sirio

Post Reply