Some UX changes to Screenshooter

Steve Dodier-Lazaro sidnioulz at gmail.com
Wed Apr 30 01:58:48 CEST 2014


Hello everyone,

It's been a while. Yesterday I somehow ended up playing with
Screenshooter's codebase and implemented a couple of tiny things. It was a
bit of an organic thoughtless process so many of these bits do not have an
associated bug report, and I'd like to have Xfce devs' opinions on each of
the changes I made in my branch:

The branch can be found here:
https://github.com/Sidnioulz/xfce4-screenshooter

2014-04-28  Steve Dodier-Lazaro  <sidi at xfce.org>

    * lib/screenshooter-utils.c: Fixed help callback not working properly.
Fixes two open bugs.

https://github.com/Sidnioulz/xfce4-screenshooter/commit/9d9d4bb38a8bc64b4da42eb11377239f8f5d11f1

    * lib/screenshooter-capture.c, configure.ac.in, Makefile.am: Notify the
ability to cancel a
    region selection with Esc -- this is somewhat controversial as it
requires a dependency to
    libnotify -- however that lib is already used by xfce4-volumed,
xfce4-power-manager, Thunar and
    obviously xfce4-notify so it would be problematic only for a subset of
users. Of course there's
    a compile-time switch. I'd like the change to occur to improve the
learnability of the feature.

https://github.com/Sidnioulz/xfce4-screenshooter/commit/3213b49f33a418f4f905c05cab357de76ce79112

    * lib/screenshooter-(capture,dialogs).c, src/main.c: No longer waiting
a whole second for a
    screenshot, but 200ms -- increase if people report bugs. Also
controversial as in theory this
    increases the likelihood of bad screenshots being generated. However
there is no evidence that
    the current 1000ms is the right value -- it was set this way only
because the original authors
    used the seconds spinner's min value to implement the feature. If 200ms
turns out to be a bit
    short for old computers, they can either leave the delay of 1 second in
the spinner or the value
    can be increased. It makes for a much nicer experience on those modern
computers that can redraw
    a dialog in under 200ms.

https://github.com/Sidnioulz/xfce4-screenshooter/commit/fc75b69e7eb7dc827b3d185b58bd491d0b3372ac

    * lib/screenshooter-(actions,dialogs,utils,zimagez).(c,h): When an
action fails (app launch,
    clipboard, save to disk, etc), return to actions dialog rather than
quitting. The reason behind
    this change is that if you've gone through the pain of saving a
screenshot AND selecting an
    action to save it, it's pretty likely you *want* to take that
screenshot. If you've needed some
    effort to make the screenshot (anything region or timing-based) then
you don't want that effort
    wasted on Screenshooter exiting as soon as you press Esc. Now, if your
action is cancelled or
    fails (wrong credentials to zimagez, clipboard unavailable, save file
dialog was destroyed or
    the app you selected could not be launched) then Screenshooter will try
its best to detect it
    and return to the previous menu. Similarly, the Save and Upload dialogs
now have a 'Back'
    button because it fits better with the philosophy of this commit. The
commit also changes the
    error dialog util, adding some markup and giving a nicer error message
for when apps can't be
    launched. I didn't iterate through all error messages though...
probably should do that if this
    commit is considered for inclusion.

https://github.com/Sidnioulz/xfce4-screenshooter/commit/8c2dfdbd537b6896b68cdedcc62dd8e16f0c26bf

    * lib/screenshooter-zimagez.c:  Do not respawn theZimageZ dialog upon
closing it or pressing 'Esc'
    I think this is what caused me to hack in the first place!
Self-explanatory and badly needed in
    my not-so-humble opinion :)

https://github.com/Sidnioulz/xfce4-screenshooter/commit/c5128fa554c3e4c2bdba3a11bd22a895374a19fb

    * src/main.c: Removed deprecated GThread functions -- this is now
automatically done by the GLib.
    I'm not sure if people still run the old GLib that does not have
automatic GThread init. If yes,
    then a compile-time switch could be added based on the detected GLib
version. It's not a big
    deal in any way, just code cleanup.

https://github.com/Sidnioulz/xfce4-screenshooter/commit/74b6151db6e39d7fe3ed5b05389c1910424e3b02

If you know of other (quick to write) UX improvements that are badly needed
(and not in the bugzilla), please do tell me (except storing the Zimagez
password in cleartext ;) ).

Thanks,
-- 
Steve Dodier-Lazaro
PhD Student in Information Security
University College London
Free Software Developer
OpenPGP : 1B6B1670
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.xfce.org/pipermail/xfce4-dev/attachments/20140430/107f02af/attachment.html>


More information about the Xfce4-dev mailing list