Feature suggestions (wishlist)

Bug #1207927 reported by Eduardo rocha
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Haguichi
Fix Released
Wishlist
Stephen Brandt

Bug Description

Here are some features that may be useful if you use Haguichi on a daily basis, and have lots of networks and clients:

  1 - Auto-refresh the clients of a network, when you go online/offline in that network.
  2 - Have a quick filter textbox in main screen to narrow results in the Network/Client treeview.
  3 - Have an option to toggle all networks online/offline with just one click.
  4 - Have an option to collapse/expand all networks in the treeview with just one click.
  5 - Toggle Haguichi main screen visibility with a double-click on the systray icon.

Revision history for this message
Stephen Brandt (ztefn) wrote :

Hi Eduardo,

Thanks for your suggestions!

1. Refreshing only the clients of a network would be rather complex, but refreshing the whole list instead should be no problem (this is also done after creating/joining/leaving/deleting a network). I will add that in one of the next versions.

2. Yes, I have thought about that too. The default "type-and-jump" search of Gtk.TreeView is not very elegant. Something more useful would be nice indeed.

3. I don't see the use case for this one (apart from reversing the default behavior on setup). Maybe you can elaborate why you would like this option?

4. Same as point 3.

5. The Gtk.StatusIcon in Haguichi implements single left click to toggle main window visibility and right click to show the menu. On Ubuntu though, status icons are ignored and applications have to provide "indicators". In the name of consistency these indicators can only provide a left click menu...

Changed in haguichi:
importance: Undecided → Wishlist
status: New → Incomplete
Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

Hi Stephen!

All of those suggestions are truly useful if you have lots of networks, and keep all of then offline, and bring online only when needed.

1. Refreshing clients after bringing network online would be useful, because I would click in 'SSH Command' without need to wait for a whole update (and hitting F5 is not THAT bothering...).

2. A real filter that matches the middle of strings, and displays only matching results would be great with long clients list (I used to do a LOT of 'hamachi list | grep - i name' to find my desired machines in the past).

3 and 4. This would help to bring offline all networks at once when leaving Haguichi, and keep expanded only used ones (This I must say that is useful just in my case, so I completely understand why you didn't find a use for it) .

5. Well, tested with Gentoo and KDE, and it toggles visibility with just one left-click, but in Linux Mint with Cinnamon it keeps showing the popup menu (didn't know that Cinnamon's Panel had the same behavior as Ubuntu's panel). In this case, a "Hide to Systray on Close" option would be great too! =)

In the end, I think only topics 2 and 5 would be useful features to everyone, but the others make sense only for my way of working.

Revision history for this message
Stephen Brandt (ztefn) wrote :

5. Linux Mint is based on Ubuntu so that might explain the same behavior. You could try removing haguichi-appindicator, relaunch Haguichi and see if the status icon shows up in Cinnamon instead.
Hide to systray on close should already be the current behavior (assuming "Show Haguichi in the notification area" is checked in preferences).

Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

5. Renaming "Haguichi-AppIndicator.exe" did the trick! Now the left click on systray icon toggles visibility, and the right click shows the popup menu in Cinnamon. =)

Revision history for this message
Stephen Brandt (ztefn) wrote :

3. To bring the client offline in all networks when leaving Haguichi is simply a matter of clicking Client -> Disconnect or check "Disconnect on quit" in Preferences -> General, because that will send a "hamachi logout" command. Extra plus is that the state is being remembered (by hamachi itself), so when you connect ("hamachi login") again using Client -> Connect, you will automatically go online in all the networks that you where online in during the previous session.

4. I've added keyboard shortcuts to expand (ctrl+[) and collapse (ctrl+]) all networks: http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/360

Changed in haguichi:
assignee: nobody → Stephen Brandt (ztefn)
status: Incomplete → In Progress
Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

3. Ok. It's not very annoying to bring offline manually every network after using then with a double click.

4. Tried you revision 360, and the new shortcuts didn't work. =(

Revision history for this message
Stephen Brandt (ztefn) wrote :

4. Try revision 361 :o)

Revision history for this message
Stephen Brandt (ztefn) wrote :

1. Refreshing the network list is now also done for the go online/offline commands and will be available in version 1.0.24: http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/389

Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

Great news!
I tried downloading the tarball for revision 389, but could not build it, as there is no "configure" script anymore.
Guess I'll have to wait for version 1.0.24 to try it out!

But thanks again, Stephen! =)

Revision history for this message
Stephen Brandt (ztefn) wrote :

Hi Eduardo,

2. Treeview filtering has been implemented in revisions 407 and 408:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/407
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/408

It would be really great of you could give it a test spin. I'd like to know if the filtering works like you expected (or better...) and if the behavior is logical and all. To trigger the filtering you can use "Edit" -> "Find" (Ctrl+F) from the menubar or just start typing in the main window. Things to keep in mind about the current filter behavior:
- If only a member is matched, the parent network is shown too (a child node cannot be shown if the parent node is not visible).
- If only a network is matched, all it's children will be show too (showing just a network without it's children seemed a bit pointless).
- If "Show Offline Members" is deselected, offline members won't show up when filtering either.
- Collapsed networks stay collapsed when filtering too; to see matched members inside a collapsed network you'll have to expand it.

For convenience I've build Debian and source packages you can install:
http://www.haguichi.net/build/haguichi_1.0.25rev408-clr4.0_all.deb
http://www.haguichi.net/build/haguichi-1.0.25rev408-clr4.0.tar.gz

I look forward to your findings! =)

Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

Hi Stephen!

I've tested the new filtering feature, and it's working pretty well (and fast) so far, and current behavior seems sane enough too (in fact, I agree with all of your behavior choices).

There is just some minor tweaks that I would recommend:
  - The NumPad keys should trigger the filtering too.
  - When ESC is pressed, the filter bar should be hidden and the filter should be cleared too (to me at least, pressing ESC to clear something is pretty intuitive).
  - When the filter is changed, the current focused/selected TreeItem should be kept focused/selected (if possible).

I think the way it is now is already a great improvement for people that have too many networks/hosts like me!

Just let me know if you need some huge Hamachi networks to try it out!

Revision history for this message
Stephen Brandt (ztefn) wrote :

Thanks for your feedback!

Just came to mind that I totally forgot to mention that the filter searches by name, ID and IP address. Although that might have been obvious...

Support for NumPad keys 0-9 to trigger the filtering has been added:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/409

The searchbar is know cleared and hidden when hitting ESC:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/410

Which treeitem is selected when searching still gets controlled by the treeview. Apparently the first item which name starts with the entered text. If nothing matches that rule nothing is selected. I'll try to see if this behavior can be overridden somehow.

Then, the actual focus is on the entry field. This means that currently you cannot activate the default action for the selected network or member by pressing the enter key. I think that would actually be nice though. I will try to redirect enter key presses in the entry to the treeview.

PS: I did already use the large network list you sent me earlier for an other bug report to test the filtering... why else do you think I added the --list switch to Haguichi =D

Revision history for this message
Stephen Brandt (ztefn) wrote :

In revisions 411 and 412 selected row activation by pressing the return key has been implemented:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/411
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/412

I have researched if the treeview selection behavior itself can be modified somehow. But so far I haven't found any indication this would be possible...

Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

Just tried your changes, and the revisions 409 and 410 are working pretty well, but 411 and 412 seemed to change nothing at all.
The Return key just doesn't trigger anything when the focus is in the Filter bar (but it works fine if click the desired treeitem and press Return).

If the idea is to use the keyboard, it would be cool to allow the user to navigate through the filtered treeitems using the keyboard arrows too.

Revision history for this message
Stephen Brandt (ztefn) wrote :

Did you use the KeyPad Enter key? I didn't add support for that one yet, but will do. Apart from that, return key trigger only works if there's actually a row being selected while filtering. With the current treeview selection behavior this means only if the name of an item in the tree starts with the entered text a selection will be set automatically and the return key will trigger the default action for that row.

Great news in this regard is that I finally found out how to override the selection behavior. Turns out you can actually define your own function [1]. I've played around with it for a bit and it looks very promising. This means networks and members can eventually be selected based on the same rules as the filtering itself (matching any string part within name, ID and IP-address).

So stay tuned for some nice updates coming days! :)

[1] https://developer.gnome.org/gtk2/stable/GtkTreeView.html#GtkTreeViewSearchEqualFunc

Revision history for this message
Stephen Brandt (ztefn) wrote :

Implemented SearchEqualFunc, using the arrow keys you can indeed navigate trough all matching items:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/413

Accepting any known Return or Enter key, so row activation should now always work:
http://bazaar.launchpad.net/~ztefn/haguichi/trunk/revision/414

Revision history for this message
Stephen Brandt (ztefn) wrote :
Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

I've just tested revisions 413-416:

413: Works most of the time, but there is a little weird behaviour: if you have all networks collapsed, and just one expanded, and the filter criteria matches one of the members inside that network and members from other networks as well, the arrow keys navigation seem to cycle through random elements (well I'm not sure if it's random, because I could not figure out the pattern yet)

414: All Return/Enter keys are now working properly.

415: I'm not sure what this change is supposed to do, but when I filter something that only matches the network name, the network node is selected.

416: the accelerators do work =P

PS: sorry for the long delay to reply, but I only have Linux running at my work to try the changes.

Revision history for this message
Stephen Brandt (ztefn) wrote :

Regarding revisions 413 and 415, the idea is that the filter selection (and thereby also the arrow key navigation) only highlights the visible items that actually match. This means for example that if only the member of a network matches, only that member will get selected when cycling through the results, and not the network itself (although as parent it is still being shown). On the other hand if only the network matches the filter, then only the network will receive selection and not it's members (even though they are all still being shown). If both the network and some of it's members match the filter, the selection will cycle through these exact matches, skipping all members that do not match. If a network is collapsed, obviously matching members cannot be selected.

With this in mind I hope that the selection pattern makes any sense now. =)

Revision history for this message
Stephen Brandt (ztefn) wrote :

5. To the AppIndicator I've added an scroll event handler to show (scroll up) and hide (scroll down) the Haguichi window: http://bazaar.launchpad.net/~ztefn/haguichi-appindicator/trunk/revision/11

I thinks this last change completes the wishlist for as much as possible and I will therefore finally close this bug after the next AppIndicator version has been released. You are off course welcome to open any new bug. I think some really usefull additions have been realised based on your suggestions. So thanks again for all your input!

Changed in haguichi:
status: In Progress → Fix Committed
Revision history for this message
Eduardo rocha (joao-eduardo-rocha) wrote :

Thanks again Stephen! I also think that Haguichi got so much more usable after all those changes!

Let me know if I can help with something else, specially testing features using my huge client list!

Stephen Brandt (ztefn)
Changed in haguichi:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.