Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sun 08 Dec 2019, 06:31
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
Now you can use the Print Screen Key
Moderators: deshlab, Flash, GuestToo, Ian, JohnMurga, Lobster
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 2 [23 Posts]   Goto page: 1, 2 Next
Author Message
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Fri 10 Apr 2009, 10:51    Post subject:  Now you can use the Print Screen Key  

The following will allow you to capture a screenshot as a jpeg in the my-documents folder just by pressing the "Print Screen" Key'.

"Alt-Print Screen" then click on a window to just capture that window.

Tested in JWM on 4.1.2 and 4.2

Hope you like it. Smile

Latest version further down in Dingo post http://www.murga-linux.com/puppy/viewtopic.php?p=293779#293779

Last edited by gposil on Fri 10 Apr 2009, 23:06; edited 2 times in total
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
Dingo


Joined: 11 Dec 2007
Posts: 1439
Location: somewhere at the end of rainbow...

PostPosted: Fri 10 Apr 2009, 11:16    Post subject:  

very good, I suggest a little addition, to be able to select windows size (choosing width and height, moving mouse around windows you can capture)

adding -s parameter, like:

Code:
scrot '-s %T.png' -e 'mv $f ~/my-documents/'; xmessage -timeout 3 -center "Screen Shot Done"


regarding the keyboard shortcut, if

Code:
!/bin/bash
#post-install script.

 sed -i -e '/<!-- Key bindings -->/ a\<Key keycode="111">exec:fullshot</Key>' /root/.jwm/jwmrc-personal
 xmessage -center You must restart X for changes to take effect.


keycode="111" is used to perform fullshot, what key do you think we can use to perform a border selected screenshot?
selectborders.zip
Description 
zip

 Download 
Filename  selectborders.zip 
Filesize  283 Bytes 
Downloaded  530 Time(s) 

Last edited by Dingo on Fri 10 Apr 2009, 11:20; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website 
Lobster
Official Crustacean


Joined: 04 May 2005
Posts: 15550
Location: Paradox Realm

PostPosted: Fri 10 Apr 2009, 11:19    Post subject:  

Seems good . . . but 237 k

Is it possible to activate the screen capture in mtpaint from the command line and activate it by assigning it the print screen key?

_________________
Puppy on Raspberry Pi Release Candidate Cool
Puppy Links Page http://www.smokey01.com/bruceb/puppy.html Very Happy
Back to top
View user's profile Send private message Visit poster's website 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Fri 10 Apr 2009, 11:23    Post subject:  

Dingo that is already in there as seperate script, just run winshot and click on window you want to capture. I'm working on assigning winshot to Alt-Print Screen.

Lobster..the pet file includes the scrot command not in Puppy and includes the LibImLib2 libraries to support it.
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
Dingo


Joined: 11 Dec 2007
Posts: 1439
Location: somewhere at the end of rainbow...

PostPosted: Fri 10 Apr 2009, 11:38    Post subject:  

thanks, I was blind. regarding keybord shortcut, what keycode do you think we can assing to winshot (to select manually screenshoot area)
_________________
replace .co.cc with .info to get access to stuff I posted in forum
dropbox 2GB free
OpenOffice for Puppy Linux
Back to top
View user's profile Send private message Visit poster's website 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Fri 10 Apr 2009, 12:32    Post subject: winshot key assignment  

Dingo
keycode 92 should do it...that Alt-Print Screen or Shift-Print Screen either will work I think...got to test it... Smile

new version with window capture uploaded.
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
Dingo


Joined: 11 Dec 2007
Posts: 1439
Location: somewhere at the end of rainbow...

PostPosted: Fri 10 Apr 2009, 15:11    Post subject:  

Alt-Print Screen key is not working (I must type in console
Code:
scrot -s
and then click on an on active window - (I'll further investigate) anyway, I have repackaged .pet with a little dependency missing (libtiff.so.4) and other libs renamed

take in mind, when create pet packages, that dir must have same name of pet package or it will not able to expand. fixed in version I have uploaded as attachment and on dokupuppy

http://puppylover.netsons.org/dokupuppy/programs:screenshot

_________________
replace .co.cc with .info to get access to stuff I posted in forum
dropbox 2GB free
OpenOffice for Puppy Linux
Back to top
View user's profile Send private message Visit poster's website 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Fri 10 Apr 2009, 23:12    Post subject:  

Thanks Dingo.. it was 3:00am and I had brain fade Sad

The Alt-PrintScreen is still bugging me i'll get onto it...

Version 0.1.2 will also cater for IceWM users...
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
richard.a


Joined: 15 Aug 2006
Posts: 510
Location: Adelaide, South Australia

PostPosted: Sat 11 Apr 2009, 06:18    Post subject:  

Lobster wrote:
Is it possible to activate the screen capture in mtpaint from the command line and activate it by assigning it the print screen key?

Actually I wrote about that in the context of JWM when I described my button-bars (command bars) last year (possibly) or even the year before.

Let me quote from the web page I wrote which you can find here :

Quote:
While nothing whatsoever to do with button bars, I thought I'd mention this customisation tip as well. I've discovered it isn't difficult to enable the Print/Screen button (like WhoDo did in 2.15ce) to initiate taking a screen capture - which is also used in several other operating systems, including Windows, but surprisingly in few Linuxes.

All it needs is a single line of code in the /root/.jwmrc file, near the bottom, in the key redefinition section...

<Key key="Print">exec:mtpaint -s</Key>

The keypress capture technique doesn't seem to work in Ver 1.09 for Windows, though. It locks the keyboard inoperable if you try it.

I don't know how WhoDo did it in 215ce, but the very simple line in the .jwmrc file works without anything extra in all the ver2's that use JWM, and from memory similarly in v3 as well. I haven't tried it in v4 at this time.

Richard in Oz-land

_________________
Have you noticed editing is always needed for the inevitable typos that weren't there when you hit the "post" button?


Back to top
View user's profile Send private message 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Sat 11 Apr 2009, 07:39    Post subject: No it doesn't  

No that simple line doesn't work in version 4+...JWM has changed and you have to use the key scan method..

The whole point of what I and now Dingo are trying to achieve is to give the screen capture over to a familiar method ...just press the Print Screen Key...without opening software...you ca go back later and review and edit what you captured...

The reason I have steered clear of mtPaint is its inability to deal with clipboard matters...
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
richard.a


Joined: 15 Aug 2006
Posts: 510
Location: Adelaide, South Australia

PostPosted: Sat 11 Apr 2009, 08:06    Post subject:  

Thanks for the info. Is that because in the design the JWM menuing has been disabled?

I could never understand why there was a need for the other way of menuing when you almost never use more than one window manager.

I might have a look in the next day or so at re-enabling the JWM menuing in 4.12 - I'm pretty sure I was able to get the .jwmrc-tray menu up and running with my extra buttons etc on it several weeks ago when I first looked at it.

Richard

Edit
If you open .jwmrctray and duplicate the button next to the start menu button, and change the command in the duplicate to exec:mtpaint -s it works in the same way as a hot key Smile

So if you don't like mtpaint (and I agree with your point) I'm sure there would be another app that could run in a capture mode that could be used.

The problem seems to be the inability to call a command from a key. Which makes one wonder if any of the other keybindings in the .jwmrc file work? Or maybe if the jwmrc menu were reinstated, they all would? Speculation for another day Very Happy

I'm off to bed. Take care Very Happy

Richard

_________________
Have you noticed editing is always needed for the inevitable typos that weren't there when you hit the "post" button?


Back to top
View user's profile Send private message 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Sat 11 Apr 2009, 09:11    Post subject:  

Richard

All you need is an entry in the key bindings section of /.jwm/jwmrc-personal, but you use the keycode="111" instead of key="Print"(which doesn't work)...

What i'm trying to do is avoid opening any software when you capture a screen, just save it directly to a file for later perusal...this part works...we are now trying to get the selective window capture working from the Alt-Print Screen key combo.
Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
wjaguar

Joined: 21 Jun 2006
Posts: 350

PostPosted: Sat 11 Apr 2009, 13:13    Post subject:  

gposil wrote:
The reason I have steered clear of mtPaint is its inability to deal with clipboard matters...

Your information is outdated. Smile As of version 3.30, mtPaint can import images from, and export to, system clipboard.
Back to top
View user's profile Send private message 
panzerpuppy

Joined: 02 Oct 2007
Posts: 632

PostPosted: Sat 11 Apr 2009, 15:48    Post subject:  

gposil wrote:
All you need is an entry in the key bindings section of /.jwm/jwmrc-personal, but you use the keycode="111" instead of key="Print"(which doesn't work)...


And what should I add to .jwmrc to be able to capture a screenshot of the active window by using 'Alt+PrintScreen' ? (with mtPaint opened,of course)
Back to top
View user's profile Send private message 
gposil


Joined: 06 Apr 2009
Posts: 1305
Location: Stanthorpe (The Granite Belt), QLD, Australia

PostPosted: Sat 11 Apr 2009, 23:21    Post subject: What about this  

When you press Print Screen key you get this...
shot1.jpg
 Description   This is better
 Filesize   6.6 KB
 Viewed   2678 Time(s)

shot1.jpg

Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
Display posts from previous:   Sort by:   
Page 1 of 2 [23 Posts]   Goto page: 1, 2 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0770s ][ Queries: 13 (0.0086s) ][ GZIP on ]