Take a Shot! - yet another screenshot utility...

Paint programs, vector editors, 3d modelers, animation editors, etc.
Message
Author
musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#81 Post by musher0 »

greengeek wrote:
MochiMoppel wrote:2) Let a femal voice do the count down. It's now "Five...Four...Three...Two...One...Katchan!!".
Keen to hear how you set that up. Could be handy.
This is Puppy. He should use barks, not a human (even female) voice.
(Where's that tongue-in-cheek icon?!) :D

@Mochi: Here's your explanation:

Code: Select all

aplay 18.wav 
aplay: test_wavefile:898: can't play WAVE-file format 0x0007 which is not PCM or FLOAT encoded
I simply loaded it in mhWaveEdit, and have it play once. Then I re-saved it as file
"18a.wav", and it played fine. Here's my proof: :)

Code: Select all

aplay 18a.wav 
Playing WAVE '18a.wav' : Float 32 bit Little Endian, Rate 8000 Hz, Mono
The new file will be 4.5 times bigger than the initial one. (Gnahahahaha!) :twisted:

I hope this helps. BFN.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

step
Posts: 1349
Joined: Fri 04 May 2012, 11:20

#82 Post by step »

musher0 wrote: "Toggle" is a difficult verb to translate in French. We don't have the exact equivalent.
We have to use two verbs side by side, something like:
Révéler/masquer plus d'options
or
Afficher/cacher plus d'options
I'm just curious, could the single verb commuer be used instead?
[url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Fatdog64-810[/url]|[url=http://goo.gl/hqZtiB]+Packages[/url]|[url=http://goo.gl/6dbEzT]Kodi[/url]|[url=http://goo.gl/JQC4Vz]gtkmenuplus[/url]

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#83 Post by MochiMoppel »

musher0 wrote:I simply loaded it in mhWaveEdit, and have it play once. Then I re-saved it as file
Did you say "simply"? :lol: But thanks anyway, this would be one way to solve the problem, though somewhat brutal.
I now use ffmpeg. Lighter than mplayer and already part of the TAS tool list. It bothers me a bit that I don't know why it works (ffmpeg -i /path/to/sound.wav -f alsa ""), but at least it does.

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#84 Post by SFR »

MochiMoppel wrote:I don't know why it works (ffmpeg -i /path/to/sound.wav -f alsa ""), but at least it does.
Nice trick! Sadly, doesn't work with avconv, so I used avplay/ffplay instead (see the changelog).
___________

Version 1.11:

- disabled beep for Quickshot (it's taken immediately, so there's no point to have it)
- added checkbox "Beep on Shot" (thanks to MochiMoppel)
- can use avplay/ffplay (they support more formats than aplay) as a player for BEEPFILE - aplay as a fallback
- standard beep command as a fallback, if /usr/share/audio/beep_high.wav doesn't exist (thanks to MochiMoppel)
- the default BEEPFILE as well as DEFAULTIMAGEVIEWER and DEFAULTIMAGEEDITOR can be specified in ~/.take_a_shot.rc config file (no need to edit the code anymore)
- added checkbox "Show timer" - it displays a timer in the center of the screen if DELAY > 0

First post updated!

Greetings!
Attachments
Screenshot.png
(18.34 KiB) Downloaded 344 times
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#85 Post by MochiMoppel »

Looks good! I like the new animated timer. And interesting use (or misuse?) of a notebook widget. :lol:
SFR wrote:- disabled beep for Quickshot (it's taken immediately, so there's no point to have it)
Oh, there is a point: Quickshots happen in the background. A keyboard shortcut which appears to do nothing can be irritating. But a beep could be even more irritating. I hate beeps which let me guess what happened. Maybe I'm spoiled: Japanese appliances speak. My oven speaks and so does my rice cooker and my boiler ("Water temperature is now set to 60 C. Be careful. Water will be hot!"). None of them beeps. So instead of a beep I prefer a short splash to let me know where the shot has been saved. Don't take this as a request. It's only an idea for my own tweaks.

For the time being I'll stay with v1.10. I added a Delete button. This was really easy since it fits into the program flow: After hitting View I can examine the shot. After closing the viewer I'm back at the dialog and if I didn't like what I saw I can hit Delete and your next dialog tells me that "Screenshot.png no longer exists!" and I'm back at the main dialog. Perfect for me.

Thanks again!

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#86 Post by musher0 »

step wrote:
musher0 wrote: "Toggle" is a difficult verb to translate in French. We don't have the exact equivalent.
We have to use two verbs side by side, something like:
Révéler/masquer plus d'options
or
Afficher/cacher plus d'options
I'm just curious, could the single verb commuer be used instead?
Hi step.

Please read the index card again? The current context and meaning is legal.
It was used in the sense of "transform" by 19th Century writers, but not since.

"Commuter" is tempting, but of rather specialized use in the field of electricity.
And again, in the legal field.

Maybe "Afficher +/- d'options" ? But it looks and sounds weird...

Thanks for trying to help, though. BFN.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#87 Post by musher0 »

MochiMoppel wrote:
musher0 wrote:I simply loaded it in mhWaveEdit, and have it play once. Then I re-saved it as file
Did you say "simply"? :lol: But thanks anyway, this would be one way to solve the problem, though somewhat brutal.
I now use ffmpeg. Lighter than mplayer and already part of the TAS tool list. It bothers me a bit that I don't know why it works (ffmpeg -i /path/to/sound.wav -f alsa ""), but at least it does.
Did you say "brutal"? :lol:
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
peebee
Posts: 4370
Joined: Sun 21 Sep 2008, 12:31
Location: Worcestershire, UK
Contact:

#88 Post by peebee »

The advent of bash-4.4 exposes 2 lines in TAS that need amendment....
01micko wrote:'read' should not assign vars on the newline.. the default delim is $IFS (default IFS is usually a space char) so the original in TAS is wrong
In tas-1.11 these lines should be changed:

49: read -d "\n" MAXX MAXY <<< `xwininfo -root | awk 'NR>=8&&NR<=9 {print $2}'`

486: read -d "\n" XPOS YPOS WIDTH HEIGHT <<< `xwininfo -frame | awk 'NR>=8&&NR<=9 {print $4} NR>=12&&NR<=13 {print $2}'`

Cheers
peebee
ImageLxPup = Puppy + LXDE
Main version used daily: LxPupSc; Assembler of UPups, ScPup & ScPup64, LxPup, LxPupSc & LxPupSc64

User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#89 Post by 01micko »

Nah, default IFS is
<space><tab><newline>
.. so why does it fail in bash 4.4?

The -d ='\n' doesn't look right to me (although it probably is ok) but maybe using printf in the awk routine would be better.

like so:

Code: Select all

read XPOS YPOS WIDTH HEIGHT <<< `xwininfo -frame | awk 'NR>=8&&NR<=9 {printf "%s ", $4} NR>=12&&NR<=13 {printf "%s ", $2}'`
and

Code: Select all

read MAXX MAXY <<< `xwininfo -root | awk 'NR>=8&&NR<=9 {printf "%s ", $2}'`
(not tested on bash-4.4)

:?:
Puppy Linux Blog - contact me for access

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#90 Post by SFR »

Hmm, that's strange indeed. The behaviour was consistent since at least bash-3.0 and suddenly changed...
Maybe it wasn't intentional..?
Anyway, I'll fix it in next release, but I want to change a couple of other things, too, and am little short on time these days, so it may take a while.

Thanks for the heads up &
Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#91 Post by SFR »

Version 1.12:

- fix for different treatment of newline by 'read' cmd in Bash-4.4 (thanks to peebee & 01micko)
- fix for newer ffmpeg that does not recognize '+nomouse' option anymore
- can make use of xrectsel, if available
- ditched xmessage; everything's done in Gtkdialog now
- minor corrections/fixes

First post updated!

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#92 Post by SFR »

Version 1.13:

- removed 'Add datestamp' and 'Add timestamp' checkboxes; instead a user can freely insert date's % parameters into filename, e.g. Screenshot_%Y-%m-%d will become Screenshot_2016-10-19
- fix: some ancient versions of ffmpeg may not support '-draw_mouse' option
- minor corrections

First post updated!

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#93 Post by musher0 »

Oh well. I did like the date-stamp checkboxes...
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#94 Post by SFR »

musher0 wrote:Oh well. I did like the date-stamp checkboxes...
Hey Musher0

Well, I liked them, too, but they weren't flexible enough.
Now you can freely move the date/time around the core filename, date format is no longer hardcoded to YYYY-MM-DD, some users also may prefer 12h time format with AM/PM, and so on...
Oh, and the GUI is now less cluttered and looks clearer IMHO.

To regain practically the entire functionality of date/timestamp checkboxes it's merely a matter of appending %F (for date) and/or %T (for time).
Using the 'Info' button next to the filename you can preview how the actual, output filename's gonna look like.

Anyway, hope this change is not a deal-breaker for you. ;)

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#95 Post by musher0 »

Hello SFR.

No, of course it's not a deal-breaker: your TAS is still the most versatile
screenshot utility around! Just my basic laziness I guess... ;)

BFN.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

moi_classic2007
Posts: 23
Joined: Sun 20 Mar 2016, 23:40

#96 Post by moi_classic2007 »

It's really cool! Thank you so much!

User avatar
vovchik
Posts: 1507
Joined: Tue 24 Oct 2006, 00:02
Location: Ukraine

#97 Post by vovchik »

Dear SFR,

Thanks. TAS works very nicely and is coded very economically. What a joy.:)

With kind regards,
vovchik

User avatar
greengeek
Posts: 5789
Joined: Tue 20 Jul 2010, 09:34
Location: Republic of Novo Zelande

#98 Post by greengeek »

Just had a discussion with my wife about the "clipping tool" (EDIT : actually "snipping tool") that she uses on her school Windows PC - it gives her a method to select a part of the screen so she can attach it to an email (to her students or their parents) but she says she has to start it from the menu (which initially seemed much more longwinded than using the PRTSC button as I do to start TAS) but what she likes is that she can select a non-rectangular portion of the screen (she can clip a circular region).

Hmmm, I can do something similar by hitting PRTSC, then "edit", then selecting a rectangle, then "shift, ctrl, x" ing it to save the bit I want, then I can draw a couloured circle around the most important bit - but then I thought maybe TAS could also offer a different option other than "view, edit, continue, exit" - maybe there is a way to offer "select region" or "clip image" or something similar?? (without having to go into mtpaint).

Does anyone have any thoughts?

I would quite like to have a way for my wife (when using puppy) to highlight a region and put a coloured circle around it (simply - without having to understand mtpaint functionality).

I use an older version of mtpaint but I know the newer version is rumoured to have more cli functionality - maybe there is an easy way to offer such an option (or even using a non-mtpaint method?)
Last edited by greengeek on Thu 16 Feb 2017, 06:05, edited 1 time in total.

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#99 Post by musher0 »

Hi greengeek.

What I do when I need a portion of the screen is that I do a full screenshot
with TAS and then I edit it / crop it in mtpaint with the cursor by dragging
the dotted rectangle to focus on the part of the screen that I want.

Then I go to the Image sub-menu and click Crop. Voilà, it's done !

IHTH.
Attachments
cropping(1).JPG
This will crop the section to the top right with the clock and the 3 icons.
(63.46 KiB) Downloaded 476 times
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
greengeek
Posts: 5789
Joined: Tue 20 Jul 2010, 09:34
Location: Republic of Novo Zelande

#100 Post by greengeek »

musher0 wrote:Hi greengeek.

What I do when I need a portion of the screen is that I do a full screenshot
with TAS and then I edit it / crop it in mtpaint with the cursor by dragging
the dotted rectangle to focus on the part of the screen that I want.

Then I go to the Image sub-menu and click Crop. Voilà, it's done !

IHTH.
Yes - BUT - this is simple for those of us who know how to use mtpaint. The question is could TAS be expanded with a button that bypasses the mtpaint programme and lets the user select a rectangle (or circle) straight off the desktop (like "clipping tool" in Windows)?

Post Reply