paste a picture in total commander

English support forum

Moderators: white, Hacker, petermad, Stefan2

techbuddy
Junior Member
Junior Member
Posts: 20
Joined: 2008-07-10, 17:28 UTC

paste a picture in total commander

Post by *techbuddy »

Is there any way that I can paste the print screen snapshot directly in the total commander window ( By pressing Ctrl V on the keyboard ) ? It is very cumbersome, everytime to open mspaint and then paste and then save and then give the location etc.
Maybe there is a a plug in totalcommander or maybe there is a freeware which can do it?
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

[mod]Moved to the English forum.

Hacker (Moderator)[/mod]
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

techbuddy,
Personally I use AHK which calls Pngout. Pressing Alt-PrintScreen creates a PNG screenshot of the active window (application) in the currently active dir in TC.

Code: Select all

; Save screenshot
$!PrintScreen::
	Clipboard =
	Send, !{PrintScreen}
	ClipWait, , 1
	DetectHiddenText, On
	WinGetText, TCWindowText, ahk_class TTOTAL_CMD
	Loop, Parse, TCWindowText, `n, `r
		If (SubStr(A_LoopField, 0) = ">")
			StringTrimRight, TCPath, A_LoopField, 1
	Run, c:\Programy\Pngout\pngout.exe /i /s4 "%TCPath%\%A_YYYY%-%A_MM%-%A_DD% %A_Hour%-%A_Min%-%A_Sec%", , Min
Return
HTH
Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
HolgerK
Power Member
Power Member
Posts: 5406
Joined: 2006-01-26, 22:15 UTC
Location: Europe, Aachen

Post by *HolgerK »

Alternative solution with NirCmd as Button:
asking for file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
?"%O.png"
WCMICONS.DLL,26
nircmd clipboard saveimage

0
-1
or directly with date_time as file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
WCMICONS.DLL,26
nircmd clipboard saveimage


-1
Regards
Holger
User avatar
Samuel
Power Member
Power Member
Posts: 1929
Joined: 2003-08-29, 15:44 UTC
Location: Germany, Brandenburg an der Havel
Contact:

Post by *Samuel »

I use ahk, irfanview and a fixed path:

Code: Select all

#F11::
formattime, Timestamp, A_now, yyyy-MM-dd HH.mm.ss
run,"C:\Programme\IrfanView\i_view32.exe" "/capture=1 /convert=%A_Desktop%\Screenshot %Timestamp%.png"
return
Jon Canale
Member
Member
Posts: 141
Joined: 2003-02-07, 12:54 UTC

Post by *Jon Canale »

@HolgerK

Thanks for tip. Works very well!
damjang
Senior Member
Senior Member
Posts: 215
Joined: 2003-10-09, 15:58 UTC
Contact:

Post by *damjang »

... or you can use one of the clipboard filesystem plugin like decClipboardFS or FSClipboard
Last edited by damjang on 2011-10-24, 22:29 UTC, edited 1 time in total.
User avatar
Vochomurka
Power Member
Power Member
Posts: 814
Joined: 2005-09-14, 22:19 UTC
Location: Russia
Contact:

Post by *Vochomurka »

The button I often use

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_DRIVE%\Graphics\Viewers\Irfan\i_view32.exe
/clippaste
e:\Storage\Graphics\Icons\SoftScraps\Clipboard Paste-01.ico
Open + Paste

-1
-1
opens IrfanView to display image from the clipboard.
Single user license #329241
PowerPro scripts for Total Commander
User avatar
Mjolnir
Member
Member
Posts: 132
Joined: 2005-10-08, 21:03 UTC

Post by *Mjolnir »

Idem, but, with XnView, and adding a delay of 2 seconds, before taking the screenshot to c:\XnViewScreenshot_<date>.jpg (allowing user to select another window except current (TC) one) :

Code: Select all

TOTALCMD#BAR#DATA
%commander_path%\DelayExec.exe 1 "%ProgramFiles%\XnView\xnview.exe"
-capture=window,c:\XnViewScreenshot_$.jpg
%ProgramFiles%\XnView\xnview.exe
XnView ScreenSchot (after 1 sec.) to c:\

-1
-1
DelayExec tool : here (source here)
Longue vie a TC... déjà + de 20 ans de bons et loyaux services chez moi !
User avatar
ThurahT
Member
Member
Posts: 112
Joined: 2003-07-24, 14:43 UTC

Post by *ThurahT »

XnView.. The IrfanView copycat master..
Total Commander and Gaming. Only reasons left to use Windows.
Ahu_Lee
Junior Member
Junior Member
Posts: 37
Joined: 2016-08-09, 19:34 UTC
Location: Russia

Post by *Ahu_Lee »

HolgerK wrote:Alternative solution with NirCmd as Button:
asking for file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
?"%O.png"
WCMICONS.DLL,26
nircmd clipboard saveimage

0
-1
or directly with date_time as file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
WCMICONS.DLL,26
nircmd clipboard saveimage


-1
Regards
Holger
This places the file where NirCmd utility is located, but how can we save it to the current directory of the active panel in TC?

Many thanks.
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6450
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

Ahu_Lee wrote:
HolgerK wrote:Alternative solution with NirCmd as Button:
asking for file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
?"%O.png"
WCMICONS.DLL,26
nircmd clipboard saveimage

0
-1
or directly with date_time as file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
WCMICONS.DLL,26
nircmd clipboard saveimage


-1
Regards
Holger
This places the file where NirCmd utility is located, but how can we save it to the current directory of the active panel in TC?

Many thanks.
From its help:
clipboard saveimage "c:\temp\clip01.gif"
Windows 11 Home x64 Version 23H2 (OS Build 22631.3374)
TC 11.03 x64 / x86
Everything 1.5.0.1371a (x64), Everything Toolbar 1.3.2, Listary Pro 6.3.0.69
QAP 11.6.3.2 x64
Ahu_Lee
Junior Member
Junior Member
Posts: 37
Joined: 2016-08-09, 19:34 UTC
Location: Russia

Post by *Ahu_Lee »

Horst.Epp wrote:
Ahu_Lee wrote:
HolgerK wrote:Alternative solution with NirCmd as Button:
asking for file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
?"%O.png"
WCMICONS.DLL,26
nircmd clipboard saveimage

0
-1
or directly with date_time as file name:

Code: Select all

TOTALCMD#BAR#DATA
%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage
~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
WCMICONS.DLL,26
nircmd clipboard saveimage


-1
Regards
Holger
This places the file where NirCmd utility is located, but how can we save it to the current directory of the active panel in TC?

Many thanks.
From its help:
clipboard saveimage "c:\temp\clip01.gif"
I'm sorry but I do not understand what you were trying to say. Could you please elaborate? Thank you.
User avatar
HolgerK
Power Member
Power Member
Posts: 5406
Joined: 2006-01-26, 22:15 UTC
Location: Europe, Aachen

Post by *HolgerK »

As long as the button parameter "Start path" is empty, the picture should be saved inside the current directory of the active panel.

Anyway, you can also add %P (Source path) or %T (Target path) to the parameter field:

Code: Select all

?"%P%O.png" 
or

Code: Select all

"%P"~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
Regards
Holger
Make our planet great again
Ahu_Lee
Junior Member
Junior Member
Posts: 37
Joined: 2016-08-09, 19:34 UTC
Location: Russia

Post by *Ahu_Lee »

HolgerK wrote:As long as the button parameter "Start path" is empty, the picture should be saved inside the current directory of the active panel.

Anyway, you can also add %P (Source path) or %T (Target path) to the parameter field:

Code: Select all

?"%P%O.png" 
or

Code: Select all

"%P"~$currdate.MM_dd_yyyy$-~$currtime.HH_mm_ss$.png
Regards
Holger
Thank you, HolgerK. Everything works just the way I want now.


Just some more little questions if you guys don't mind.

1) What do the dots do in this line below, what's their pupose?.

Code: Select all

%COMMANDER_PATH%\..\SYS\NirLauncher\NirSoft\nircmd.exe clipboard saveimage 
2) NirCmd program saves .png as 32bit. What parameters (or arguments.. whatever they are called) should I use to have it saved as 24bit. There's no real reason for that, but I think I'd just prefer it be more like MS Paint.

3) What language is used in the above code. For example this "clipboard saveimage", where does it come from? Where can a simple user like me read more about expressions like that?

Thank you very much!
Post Reply