Qubes Screenshot Tool with imgurl auto upload available. [beta]

337 views
Skip to first unread message

Eva Star

unread,
Jul 2, 2016, 4:57:07 PM7/2/16
to qubes-users
Okey. I released tool that can automatically capture fullscreen/windows/regions and upload it to AppVM and imgurl automaticaly.

Now it is in beta state and tested only with Qubes 3.2rc1, but I think it will work with other Qubes starting from R3.0 or R3.1 (where qvm-run is available)

Full description and download you can find here: 

 
Test it and I hope you will be happy with it as I am :) Because screenshots is one weak side of Qubes (before this tool done ;) 

Plans: 
* add editor for images at AppVM to blur some arias on image... (suggest are welcome)
* multiple selections -> one screenshots -> upload it
* delayed screenshots
* maybe uploading any existed image from dom0 to imgurl after selecting it on dialog

Enjoy but remember that is only beta

Eva Star

unread,
Jul 2, 2016, 4:58:52 PM7/2/16
to qubes-users
If you are not sure, maybe wait until somebody will review it and confirm.

Eva Star

unread,
Jul 2, 2016, 6:43:10 PM7/2/16
to qubes-users
Other notes: 

* It is ready for GNOME and it's developed and tested under XFCE

Andrew David Wong

unread,
Jul 3, 2016, 2:29:22 AM7/3/16
to Eva Star, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Thank you for doing this!

I've added your message and a link to this thread to the issue we have
for this:

https://github.com/QubesOS/qubes-issues/issues/953#issuecomment-
230137991

And added you as the developer for this on the feature tracker:

https://www.qubes-os.org/qubes-issues/

- --
Andrew David Wong (Axon)
Community Manager, Qubes OS
https://www.qubes-os.org
-----BEGIN PGP SIGNATURE-----

iQIcBAEBCgAGBQJXeLC2AAoJENtN07w5UDAwUzUP/02Fy40HUHiijmhUYfT1KHO9
XcUxfLnDBr2E77n5X2dujcs/2JfgvQO4W/Av8Ol1E0cLmUAj8D07OUpuZBqwcFHo
58A+XIxH88WhwpWKsn6sIxdcW85XSJBOzvEStDkV5t9pcY2ojE9O70whzSAkz93T
8usTioou3AbKYpKPiHnNwmSZ3Dal+BbM2P1296S68XN/MRkmb0BY4z/itN/La0Qn
8jhsDpgTn4JanxzkO1XvYLjB8zJMoNNKYFMS6qa0spchjO/NKRZSq/tgsYJIK+Gc
CwFR38P067Ak56UXSAMH8hMzRFswu5dCxJ/UKczly54sBcu7yDNUUOcV98HQokog
/C3NmlvUDpAtsooZ1X2iTJ/mxJoaRmioHJlzbQJ+2JoA/y/QehnmReGeLjFz8VBy
tFw1W6jjra7drQNkZJT7yqB51DG9EmnhjOTbu/En/zAtLpI9W51oPfpSTcWQ/gzZ
BAXCN2gPWOSKkKHj6sAnETY7XUA+sbLTR/I7UPgq4rllR1dtnm1gB2MNB282pnoN
Q+Eo6ipa09c7X4ECxMffiZcfUuelGh+3vmwLTpGfjsBsy+18/RjORj14HhEMNBhr
K68r36aU6BhzanI0JrAmss/aXodzX/Zjb5783Zt6ST+UxraXqut9Jgj+pY48rF6B
DyoyTv+R6bUYtcouBDor
=tSE4
-----END PGP SIGNATURE-----

Eva Star

unread,
Jul 3, 2016, 8:00:47 AM7/3/16
to qubes-users
I done some research and found that we can send screenshot to gthumb (Gnome Thumbs) and add the ability into it to upload screenshots to imgurl like tool already do. But it does not solve anything. 

We need some lightweight image editing software at AppVM to edit image for:
1) annotate
2) blur some area
3) crop.

Gthumb can only crop. Maybe GIMP? But it's too heavy.
Also there is Shutter at Fedora Fusion repository. But it have a lot of dependencies ( 2 Mb Shutter + 100 mb dependencies) 

Eva Star

unread,
Jul 4, 2016, 12:41:13 PM7/4/16
to qubes-users
new version with editor available :) now it's possibile to edit scrrenshots before move them to appvm or upload to imgurl

Eva Star

unread,
Jul 4, 2016, 12:44:39 PM7/4/16
to qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Great improvement!

Now the qvm-screenshot-tool support editing of screenshots before
uploading them to AppVM or Imgurl !

You can draw lines, annotate text, additionally crop images, add
filters, hide some unwanted areas, composite images, draw lines and much
more!

Please, read documentation how to use editor tool, before use it.

As you do not like to read. I can say that before exiting from the
editor you must save your screenshot to predefined slot at
0000-SAVE-EDITED-SHOT-HERE-TO-PROCESS.png
And if you do so, then new edited image will be uploaded.

https://github.com/evadogstar/qvm-screenshot-tool/

Enjoy!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJXepJpAAoJEGSin3PC/C0ACWUQAMQ3W7xXywrhG+Izx+6qagE2
h089CSOfj1M2UXHz6QSwEDfP5ylFOuifhQAjOAhX6sMfu5H0jFI2sh8dBPNZKknS
I7YUKlvPDyr9rutiHCg2rKixAboDdHq14OFUQzJOyTVjMxXwysiUlzkjDFvFzlRo
rMHCffxQv9OmBj34DBzMuuMACHq/vOSG4DJ/nD6D80lZeaEb1rKuPgTqnQBMKmQy
l+kw+ie0gNwvulCdnqrejcspluvrvI39bdkVKuTnGW0zXN2j8ZK/nM7JH9YA4EK3
Z+rsDpGvqn3lTHRs74Bvm8+iCmy4Uy0u7j8712RO/6tU/QvEO1Blwx8S6maVm/n9
LU81hRey4FsMcCTbct9uJmjzbF8AFUnmBZd67U2kIy7daX2KdoTPcIRmFAo51mcE
tivlfNlR8fIwpExZbjdOgPbILn2mWq6CxI0lnTh+HpI893+MMvvBCYmfh/LfwkXx
PRMzOdlNZSKkPKUOSaZP8JvoYo7ZVcoY18RwkQOTo3+VoNIeg72YxmQCIE6+RSiQ
rGq/H+2jRPrxRdZNjBLz+Xtqq2Lrodcoe6Xp82qqi/9FXJ5YufaYHuMhbOrqzJJx
2Z3Qk9Ar/4a2bcw1N3VqS9VV1JeoXntky212Nr8ibXHNviqnQiD9cKNk2euooY9o
lnnAmWS4l8RBCRwBPXYM
=n/xj
-----END PGP SIGNATURE-----

Adrian Rocha

unread,
Jul 4, 2016, 5:37:53 PM7/4/16
to qubes-users, eva...@openmailbox.org
Many thanks Eva,

I'm testing it. First at all, its a great idea and, I appreciate very much your work.

I have two minor issues with the script:

1)
[user@dom0 Imágenes]$ ./qvm-screenshot-tool.sh 
[FATAL] no "zenity" tool at dom0 installeted use: \n\nsudo qubed-dom0-update zenity command to add it first

(Instead of "qubed-dom0-update is "qubes-dom0-update")
As I understand, in some versions of bash, the "\n" don't works as expected. So, I propose to change "echo" by "printf". You just have to add a "\n" at the end.

2) I have dom0 in spanish. So, my Pictures folder is /home/user/Imágenes/ instead of /home/user/Pictures/. But when I run the script, it is saving the pictures in "/home/user/Pictures/" instead of ".../Imágenes"
To obtain the correct directory to save the file you can use this command:
xdg-user-dir PICTURES
/home/user/Imágenes

Best Regards!

Eva Star

unread,
Jul 5, 2016, 7:39:13 AM7/5/16
to qubes-users, eva...@openmailbox.org


> (Instead of "qubed-dom0-update is "qubes-dom0-update")

thank you

> As I understand, in some versions of bash, the "\n" don't works as expected. So, I propose to change "echo" by "printf". You just have to add a "\n" at the end.

thanks. I will fix it.

> 2) I have dom0 in spanish. So, my Pictures folder is /home/user/Imágenes/ instead of /home/user/Pictures/. But when I run the script, it is saving the pictures in "/home/user/Pictures/" instead of ".../Imágenes"
> To obtain the correct directory to save the file you can use this command:
> xdg-user-dir PICTURES
> /home/user/Imágenes
>

is it portable way to get PICTURES directory on other unix based systems?

Eva Star

unread,
Jul 5, 2016, 12:48:03 PM7/5/16
to qubes...@googlegroups.com
https://github.com/evadogstar/qvm-screenshot-tool/
new version available, fixed issue with different "pictures" directory
name on some languages/systems.
Now Qubes Screenshot Tool will check dom0 "pictures"directory name and
destination VM pictures directory name, before uploading image into it.

Adrian Rocha

unread,
Jul 5, 2016, 12:51:41 PM7/5/16
to qubes-users, eva...@openmailbox.org
xdg-user-dir is a freedesktop.org tool. As I know, it works on Linux, Solaris and BSD. In the case of dom0, is a Fedora Linux, so we haven't any problem here. The issue can be with the VMs that doesn't have this command. There have to think in another way for this cases.

Eva Star

unread,
Jul 5, 2016, 12:55:44 PM7/5/16
to Adrian Rocha, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 07/05/2016 07:51 PM, Adrian Rocha wrote:

>> is it portable way to get PICTURES directory on other unix based
>> systems?
>
> xdg-user-dir is a freedesktop.org tool. As I know, it works on
> Linux, Solaris and BSD. In the case of dom0, is a Fedora Linux, so
> we haven't any problem here. The issue can be with the VMs that
> doesn't have this command. There have to think in another way for
> this cases.
>

It's the question to Qubes Team. Will xdg-user-dir available at dom0
or not.
But do not worry, I'm already fix this. If there will no tool
available we will continue with default ~/Pictures directory.


- --
Regards
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJXe+aIAAoJEGSin3PC/C0AonsP/iUeRT5pyGd6B3HOnTh4rCT5
Yy93W269QfO9I6IeDlrLs4C4+G4/gwriJlVXltb8ctfQj0+26Uub6rtgpdGklrNi
FpD7JXq6LQPdgCO4rekSUJ5masN96Ijn0KNLdasV1jiolhhuk+OKhWQSYK5GkONJ
AQoi1g0px0/SwOwImfR7mi1icHj6gKZ5/YuE5ASAI/dTZWvnCtR91cY74UD3D1kx
GMyaP7Ao/aV+0luM5LhYwt4xvn2PTYYM9AD1XuqNgSw80fvf2DaeHoB0IlUy4jcN
ryMGjcgVKcFsaIEocKTL6znw1vlpPYBIezpKPohYJ3t6tPq3W9Mg9Gzda5GqHKWO
w649trfIBw3HwY6Pq3BDappSIRsDoBK9Z9e8/ip2xftD6dIPW6rG3qS11Nm2ZW5+
aScOBXiITyEw2e42HcV/GXLiJCVNq8e0yFM2yw1CUpOxBgbZapyiFxj35g196bIv
rTO7cJmUgjx50HlmrHVc9tFmL6OJAxWhf1R8T2IlBh0Uof9mfBXvC6SmhIfWMqAi
6zZtCz1w9oXRGRH7xH3PTn1ZqMXnTmDVr2bd+dyKA+LqxuaKm59Q7voKAOyd58+U
IyXy7GO+uSWlG9Uloef+974053wGgoWcDEW/I3fdVJudYwOvnUDMsSf8+0L+Veml
lbkXt4neu55WVeOzP1cL
=27eM
-----END PGP SIGNATURE-----

Marek Marczykowski-Górecki

unread,
Jul 5, 2016, 1:57:40 PM7/5/16
to Eva Star, Adrian Rocha, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Tue, Jul 05, 2016 at 07:55:36PM +0300, Eva Star wrote:
> On 07/05/2016 07:51 PM, Adrian Rocha wrote:
>
> >> is it portable way to get PICTURES directory on other unix based
> >> systems?
> >
> > xdg-user-dir is a freedesktop.org tool. As I know, it works on
> > Linux, Solaris and BSD. In the case of dom0, is a Fedora Linux, so
> > we haven't any problem here. The issue can be with the VMs that
> > doesn't have this command. There have to think in another way for
> > this cases.
> >
>
> It's the question to Qubes Team. Will xdg-user-dir available at dom0
> or not.
> But do not worry, I'm already fix this. If there will no tool
> available we will continue with default ~/Pictures directory.

Yes, it is and will be available.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXe/ULAAoJENuP0xzK19csngwH/1Db3ubEw6jWbR0Oj3uyobnE
PD85+ccxqI5yAUsKMbxuA/Zx0bKig9HqFviHf4gtids6/Z18pdLv/k4Mt5IP1S4F
mYw/nks8yLKYkSVzFSoHYhqetq/EZJxMXqDXDEkNbml8Xprlmvrtwpk7QdHymp4G
UgDW7RsGJr5VrT9mJpwQxnIz72nr60NACpoXYI/2iwa4hU4GyZol5sJZO28M7Tby
EH4xAS/bE9dKbWYaW/qeyAtti8KUhy0Nq/J4WH1mgL38ZERE1JC0pNKnnOv7T/iq
iXsYc8CwLPv/zyJjmERnWaF1uvHwltl0XCM0oqgrLCdvG3/wL2bsr7T2ChReEAU=
=ErHX
-----END PGP SIGNATURE-----

Marek Marczykowski-Górecki

unread,
Jul 5, 2016, 2:06:14 PM7/5/16
to Eva Star, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Mon, Jul 04, 2016 at 07:44:25PM +0300, Eva Star wrote:
> Great improvement!
>
> Now the qvm-screenshot-tool support editing of screenshots before
> uploading them to AppVM or Imgurl !
>
> You can draw lines, annotate text, additionally crop images, add
> filters, hide some unwanted areas, composite images, draw lines and much
> more!

Nice!

> Please, read documentation how to use editor tool, before use it.
>
> As you do not like to read. I can say that before exiting from the
> editor you must save your screenshot to predefined slot at
> 0000-SAVE-EDITED-SHOT-HERE-TO-PROCESS.png
> And if you do so, then new edited image will be uploaded.

Why using separate filename? I think you can operate on original image -
if you do made some modifications - that's ok, but if don't the file
will be unchanged.

> https://github.com/evadogstar/qvm-screenshot-tool/
>
> Enjoy!
>

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXe/cKAAoJENuP0xzK19csfWoH/0LgK/hhHElYiQvwZInyPHkX
Ff5FR9idVDeGbuyfM6CHcNckHfwCasXJz907J0WETLWZc5HldtEV6njmH3Cg4FVK
83u0fHv5SwPZ5AEic8NO7cLqXMH5sHvyIBNn/b0I4S7PZQlHbNF2+7l5SHlf37pF
C2WpO5bmNmTTmMuHheqsnNad/3rqPW9VAsqdEqrlAX4YlraZOQ7Xy3oLUlkIacsg
dAOozDU8py4ReOBoNF1qu0baFyGi3eove7SD9Rhu69to4qtHorlHcq47NThKhhwL
Db21Zybok9Y93RsNsrpvjWyQpGwCuoSC74mIHubRPcjgBMGXYKzqxtiHW07/RU4=
=uB0o
-----END PGP SIGNATURE-----

Eva Star

unread,
Jul 5, 2016, 2:19:34 PM7/5/16
to Marek Marczykowski-Górecki, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256


> Why using separate filename? I think you can operate on original
> image - if you do made some modifications - that's ok, but if don't
> the file will be unchanged.
Unfortunately, because of IM display tool GUI interface is very ugly
and it want to get direction from the user on "Save" command.
Save is work like "Save As", but it also does not show the name of
already opened file. User must choose the name from full list or type
the name. This solution show the name of the temp file at the top of
all others, because the file start with "0000-" and it's very simple
to click on it and confirm overwrite. Then Quit from GUI to continue.

- --
Regards
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJXe/owAAoJEGSin3PC/C0Auy4QALqW0Hcp1Lu2KFxrqVS0gzXd
VrVS6K8cfVfVLUdcNg2O/10aLsbgpPlibLVszFfca0sxMKtAvfhe9C0li+OSh9Kc
ghv+MZVAfYry/zsZ2qfMBmVqDdcMnJFGazxFPyZYiFfZrs3/P5KKCu1S5b0SWxut
5LIVipJG9lDhZgzjbMBszesxBVbxYKz3357OSMzn4g1SiCbnEMS9ossf5kPQ7s7b
4p+eS1PRiVAZHJHSjdSShmI8/d8nltDA4VSjvwbUIMhYU0m/GYo283EUIJ0fJ/fZ
JjNFV44yDLKlhrnyItnydyNolsKCIBbIBgK5zY3pTf0YVhzh7ovMl1hVTKU2teXF
DXtymcBrtLe0x8WWxTMPBBUQ3sg/Yc1M7RrZpVU5cxvvG0Xg3wLTYKyoQnK17Lub
hKjPUDcuavoCcYmCTuY9nQ+iBgl1++4Q739dp1/k62wLp9Wr4NXefal++TuHxz6R
/6b68L3hXqD30wKE8zpjQ1sYJXuai7h9DctoMFw8+j9pPPYMCtbatixnGiImK9nh
5n6GpysnzFKmo5jE/snjh5xZlzP/3pvT7fp37kmAIBN4sVzdE0vAgLAWB74UvOAY
GX+irDENOtPnoKsty08NSHmrIjK+y6CZtzefVH+zJAEmLf6RNkJjRCajz/EtZu1J
ybN5fWmFaPSCXK4GNfbt
=v80z
-----END PGP SIGNATURE-----

Eva Star

unread,
Jul 5, 2016, 2:24:12 PM7/5/16
to qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

https://i.imgur.com/VkgnMc0.png
Save dialog
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJXe/tGAAoJEGSin3PC/C0AaZIP/3Mj5ntzDqOdRboVR6H51cAw
rZdp+qrT9jLPBZI9HiWJ3/m/Ibbgjy5IHQ6cNa4mmEdEnMaMHUuztw/5YYrdXgDz
D5q/Tgga5ckx3q0fOSFlq2KOqLB8d1iqb0C6YltHWCEbSbb55qzIb9yy5D02iegb
yRNMv6HTg0HPkutxTP+6HtVwcf0aRc5BxFxSkuXphtyZLG/qcGRC24hxtOjHeRMA
hN+jZ84gOBAjc8R48OH0kAZTYiikmcULn5Pz0kShZkVUq80PbfrsPl3kkNSJF7kd
MbGRjbSLVCCwZ0UMu7gyPtcCScTKtaSr4Rf/nirnVfPMEygc4fVw9+gWHT6aiMWz
+VQcTwqmrEivBxtFAaA9kGcLdGnfPu/1PsSZmPm+/nc2Es+aNb4ALPHh+EuRlzGq
CEMQdRDbL2Yf0bAnq+YPqVzWCfrGdBrKvVcXr2Sp6wgFttNGZ9Hpa/WIS1m8yK0v
n5OKkvvdOn7R/Vcfi4nD1WXaC7k7myd9kQpJP4pxXjdYz9O+QhL7gPLL09IRIcYr
Acnt+gVPegyclCRUMo6g4+ZPvIsEVCUk2zj4UF0migldHFp8fEu9B/ua/vj7k/Vk
h9mtQ/ugW4xOGD2mMSiu8BfY+lR3iZdyllXvSGNoxbnnCXX/Aa+2bo0IPUgU9mmO
SQI5vT/6pbizVLY9HecT
=PKC7
-----END PGP SIGNATURE-----

Marek Marczykowski-Górecki

unread,
Jul 5, 2016, 2:24:48 PM7/5/16
to Eva Star, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Tue, Jul 05, 2016 at 09:19:28PM +0300, Eva Star wrote:
>
> > Why using separate filename? I think you can operate on original
> > image - if you do made some modifications - that's ok, but if don't
> > the file will be unchanged.
> Unfortunately, because of IM display tool GUI interface is very ugly
> and it want to get direction from the user on "Save" command.
> Save is work like "Save As", but it also does not show the name of
> already opened file. User must choose the name from full list or type
> the name. This solution show the name of the temp file at the top of
> all others, because the file start with "0000-" and it's very simple
> to click on it and confirm overwrite. Then Quit from GUI to continue.

Ah, I see.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXe/tmAAoJENuP0xzK19csC5AH/1JFPvIC0odwv0XxHVqMixL7
C56x6BHl3kLxfCOqJbzj/7QqYAApWzvAnjyqj2cZrbmFXiXYF0r3vMsSs1k3G5E+
V1UkEJcxnWY4Ky5kVen6nydlN3vuVwD7zLZi7+Yd6FMsYBC/8lIzyS28Ld1O1n5g
0YmG8Q5zTBeXxq7h9Y+vpi9l553uL1JivsBH6q/PfktC+sphg/A6h9ZU7VkEMoXS
xrqzjAPanTEk52f4yegPatAZZdQReDuFAMx1bJy+N/niS2yWRRW6otSkWDmRQE4n
TDVcyukgpWOycOwjM07qTMP0Xy9YvJpkOv5T6njXa90yLO8lzXTJ2RQW+hyssj8=
=L0wK
-----END PGP SIGNATURE-----

JPL

unread,
Jul 7, 2016, 2:07:13 PM7/7/16
to qubes-users
Works really well. Thanks. Another job made a hell of a lot easier.

Eva Star

unread,
Jul 7, 2016, 5:13:34 PM7/7/16
to qubes...@googlegroups.com
Thanks for your feedback! :)
Reply all
Reply to author
Forward
0 new messages