Version: 0.8.1 (using KDE KDE 3.5.3) Installed from: Fedora RPMs OS: Linux In the "Edit image comments and tags" dialog, the user has to click inside each checkbox for the tags. It would be much more nice to be able to click on the tag text as well. That way the user doesn't have to aim directly at the check box to choose which tags to apply to each image. Best wishes to the developers, K Robinson
Perhaps installEventListener on the TAlbumListView or on each tag's TAlbumCheckListItem for a mouse click (or a Shift-click), upon which the relevant tag will be toggled?
I like this idea. Single click could lead to mistakes, so shift clicking is a good idea. Double clicking might work too, since shift clicking is normally associated with selecting multiple items. Also, right now the space bar seems to go to the next picture in the album, yet it doesn't show up in the configure shortcuts dialog... I think it might also make sense to allow selecting multiple tags with ctrl or shift click, and toggling with the space bar. This might be easier to implement as well.
there is definitely a need for improvement => usability rules! (doubleclick would annoy me when is was to tag 1000pictures..)
Jens, sure; patches, i.e code contributions, are very welcome! ;-)
Created attachment 25847 [details] patch #1 Hi, just wrote a little patch for the described problem. But it doesn't work well yet. Clicking on the CheckListItem in general works fine, but if you click the little checkbox, it doesn't work anymore. Gilles, Arnd, Marcel... is it possible to filter where the user has clicked? Another question: is a TAlbumListView object also used in the left tags sidebar? If so, does this additional slot affect it in a negative way?
Hmm it seems to be impossible to fix this, well at least I can't find a good solution. One possibility would be to double-click on the tag, just replace the signal in the connect statement with doubleClicked(). The problem with this is that the users have to be informed about this, because normally you don't double-click on such items...
Andi, Like it's said in comment #1 you need to add an eventFilter. Look my code as exemple from adjust level plugin dialog AdjustLevelDialog::eventFilter(). More info from Qt api : http://doc.trolltech.com/3.3/qobject.html#installEventFilter http://doc.trolltech.com/3.3/qobject.html#eventFilter Gilles
Created attachment 25877 [details] patch #2 Now it works fine... Gilles, ready to commit?
Created attachment 25884 [details] patch #3 There was a problem with the second patch, you were not able to collapse the CheckListItems anymore, only by double click, which also resulted in assigning a tag, although not wanted. To fix this, I used the mouseInItemRect() function from TAlbumViewList class. The problem here: it is private. I had to change access to public to use it. Is there a problem with that? TAlbumListView seems to be no part in any lib in digiKam so changing its access rights isn't a too big problem, right? Gilles, what do you think?
Andi, No problem to change access of this method. I will test your patch soon. Gilles
Gilles, the mentioned function is also defined in FolderView, with exactly the same code as defined in TAlbumView. The only difference are the access rights, in FolderView the function is protected. It would be even better to set the method in FolderView to public and completely remove it in TAlbumView. But FolderView is a member of libdigikam. Would this change have side effects on the lib? If so, changing only TAlbumView is fine...
Oh. nice. I take a look. Gilles
Andi, About your comment #11, we must use parent class code. FolderView::mouseInItemRect() must be set as public and TAlbumViewList::mouseInItemRect() removed. Gilles
Created attachment 25895 [details] patch #4 (final?) Ok, now the function is removed completely from TAlbumView...
>patch #4 (final?) No (:=)) I can see one problem with the new behaviour. 1/ one click => tag selected. work fine (great) 2/ one double click => tag selected => no. this must collapse/uncollapse childs treeview only. this is the default behaviour without your patch and it must be preserved. Note: a similar patch must be applied to tagfilter view to be homogenous, else you will see a new bug report about in the future (:=))) Gilles
I guess this is not possible, I tried it before... A double click also is handled as a normal click... there is no way (at least for me right now) to handle such situations. Even if the very first line in the eventFilter is if (e->type() == QEvent::MouseButtonDblClick) return false; the "normal" click action will be called. Do you know a way to do this?
Andi, Yes, it's ound like impossible to separate single and double click behaviours This is my proposal : always handle single click and ignore double like this: bool ImageDescEditTab::eventFilter(QObject* obj, QEvent* e) { if (obj == d->tagsView->viewport()) { if (e->type() == QEvent::MouseButtonDblClick) return true; if (e->type() == QEvent::MouseButtonPress) { ... } Gilles
Ok, but now double-click will not collapse the tree anymore... Maybe there is another way... but right now I'm too busy to think about it, maybe later...
Yes, double click is ignored to collapse tree. To do it, use the "+" or "-" symbols from tree view branch to collapse/expand. Gilles
There is another solution to unbreak colapse/expand tree view branch with double click : using middle mouse button to perform tag selection/deselection. What do you think about ? Gilles
Hmm don't know, this is a very unusual behavior. I guess most users will not like it and we must inform users somehow that they have to select tags with middle mouse button now. I guess this will even be true for the little checkbox widget, and this is definitely a strange way to select a checkbox... I will play around with the event filter later that day... if nothing will work we have to discuss this over again.
Created attachment 25898 [details] new version using middle button to select tag Andi, This version include several mouse buttons behaviours changes: 1/ Use middle mouse button to select/uselect tag when user click on tag text (and only tag text) 2/ Single Right mouse button click expand/collapse treeview. This behaviour is ask on this report: http://bugs.kde.org/show_bug.cgi?id=126871. This way is already used in K3b to expand/collapse treeview faster. I think it's really an usability improvement. Of course, this change must be done in other treeview as Albumview, Dateview an Tagview from left sidebar. 3/ Double Right mouse click always work as default. No change here. We cannot mix single/double right mouse button click to select/unselect tag and expand/collapse treeview. Also, middle button to select/uselect tags is not too wrong. It's a special case from digiKam taht all. In my patch, i have improved the FoldeView::mouseInItemRect() to only handle text area without checkbox. User can continue to use (+) and (-) to expand/collapse and the checkbox to select/unselect tag. Gilles
This looks exactly like my patch, and it behaves the same... maybe you uploaded the wrong version?
Created attachment 25899 [details] right version patch using middle button to select tag
SVN commit 829376 by cgilles: digiKam from KDE3 branch : toggle on/of tag check box item using middle mouse button. BUGS: 130906 M +12 -5 folderview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=829376
SVN commit 829399 by cgilles: backport commit #829376 from KDE3 branch CCBUGS: 130906 M +11 -5 folderview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=829399