The quickest way of ending a war is to lose it.
-- George Orwell
Introduction
I guess I made the last post a little bit of a holy crusade and while I guess that is just fine for a blog like this I did just throw it out there that I hate the non windows look and feel of the p4v application without any motivations, so I decided to just download the thing and rediscover how crappy it still is and write it down this time.
Find file and history
I'm a big fan of keyboard navigation, even though it's a graphical interface, you should be able to navigate it with ease. Since the p4win application is a standard MFC application, with the bells and whistles that brings, it's most of the time easy to navigate the UI with the keyboard only. For example, say you want to find out what the differences between revision 2 and 3 of the file Exception3.cpp are. In p4win you press CTRL-F for the find dialog. Type "exception". You can now navigate with the arrow keys to the right file (if there are multiple hits, if there is only one hit it will take you there). CTRL-H brings up the history where you immediately can shift select the two revisions and then press ALT-d to bring up the diff. All with standard windows controls.
So back to p4v. We can press CTRL-F for find, but the focus is not in the edit dialog for some reason so I have to press TAB to highlight it. Twice. Of course the default search pattern is not the client view, which makes the p4win one immensely useful, but rather whatever directory you had selected in the folder view. So I have to edit the default search view. Then enter the partial search pattern. I can now scroll down with the arrow keys to highlight my file and press CTRL-T to bring up the history. This now brings up the most unhelpful dialog ever (incidentally it's the same dialog that the visual studio integration brings up). I can see the different revisions, but I can not select two of them for diffs! I must instead press CTRL-SHIFT-D to bring up yet another diff dialog where I again have to specify the revisions I want to diff! Navigating here with the TAB key is a lot of keypresses. And we're suddenly not presented with any visual information anymore, but rather a text interface. What's the last revision? How do they differ when I've branched? All that is of course hidden in the previous dialog.
The history dialogs
I also noticed that the p4win history dialog shows the integration history, a vital piece of information. I could not find where to show that in the p4v history dialog at all. Just an oversight? I'm thinking more and more that the p4v program has not been used as extensively as the p4win application and the features has not gone into it as much. Sure, at some point it will probably catch up since the feature requests for p4win is probably at a bare trickle, but again, why would I change to this new application?
The integrate dialog
The integrate dialog is arguably much nicer than the p4win one, but only if you need to set any of the options, which you in 99% of the time don't. Most of the time I use the integrate dialog it will by default do the right thing in p4win. In very special cases it does the wrong thing and you have to go in and manually set some options in the hidden dialogs, but it's rare. Usually you're trying to do something tricky in this case. The p4v dialog is nicer since it has all the options right there, but I must say that the preview behaviour of the p4win application is much better (it shows the preview in the log) than the p4v behaviour of popping up yet another window that I have to dismiss.
Submitting a file
So I realize that the whole F6-F12 behaviour of switching tabs in p4win is arguably weird, but I really like it. Perhaps since I spend so much time in Maya that has the same kind of philosophy while switching menu sets. In p4v it's CTRL-1 instead of F6 to switch to pending changelists, not a big deal. But again the focus problem. In p4win the keyboard focus is at the correct location immediately, you can start arrow your way through the changelists you want to submit and then press CTRL-s to bring up the submit dialog.
In p4v I have to start pressing a number of TABs before the arrow keys finally do their thing. After that I can press CTRL-s to submit the file, but come on! Keyboard focus is important. P4win is building on a long time client that has the benefit of MFC as well with the keyboard focus thing. It's not perfect, but it's honed through long years. The situation between p4win and p4v reminds me of how Netscape too the number one browser and decided to throw it all out and start from scratch[1]
Navigating panes
In p4win you have to major panes, the left explorer like folder view and to the right any list pane that you've currently selected (pending changelists, submitted changelists, users etc). Switching between them is as easy as pressing CTRL-TAB. In p4v of course this is multiple TAB presses. How many each I can't determine since it's very unclear where the focus is in the p4v application.
Speaking of the left tree view, in p4win you can still see the little icons that indicate checked out status, locked status etc for highlighted items since the highlight doesn't include the icon itself. Of course in p4v the highlight includes the icons and makes it completely unreadable what the icon status is.
In closing
It seems that it has been very one sided this article, I did try to search in the help for p4v about the keyboard shortcuts. A search for the word "keyboard" brought up exactly 0 hits. Surprise surprise if the help application was a non standard windows one as well... I finally found it under "p4v shortcuts", after scrolling past the description on how you could drag and drop the files in the interface to do all sorts of fancy things. I just think the developers focused on the wrong things here...
I realize that first time users of perforce might like p4v for what it is, a mouse click fest. It's platform agnostic look and feel can be a compelling argument if you're working on multiple platforms, this might very well be the best choice for you. But for myself how pretends by daytime to make games for a living, in a windows only shop to boot, p4win makes too much sense to overlook or to switch from. You will pry the p4win client from my cold hands...
Resources
- Practical Perforce, a pragmatic take on how to manage and do common operations in perforce the way it was intended. Go with the flow and read it!
Footnotes
- [1] It was of course Netscape's downfall. Arguably it was before that when they tried to cram things into the browser too fast and too much, but then throwing out all code didn't help either.