4
1
I have a shortcut that opens a PuTTy terminal. When I click the shortcut 4 times (or once), can the PuTTy windows align in the 4 corners of the screen and fill 4 equal areas? How?
4
1
I have a shortcut that opens a PuTTy terminal. When I click the shortcut 4 times (or once), can the PuTTy windows align in the 4 corners of the screen and fill 4 equal areas? How?
8
Windows and PuTTy don't have this as a default option. There might be automated screen organizing software out there, but I'm not aware of any (you can ask at http://softwarerecs.stackexchange.com).
What I would do is create an AutoHotKey script. Below is a very generic version of what you could do to launch 4 PuTTy windows and arrange them equally around the screen with a single shortcut:
SetTitleMatchMode, 2
SetTitleMatchMode Fast
Run, % "C:\Putty\Install\Folder\putty.exe"
WinWait putty
;Upper Left
WinMove, putty, , 0, 0, 960, 540
Run, % "C:\Putty\Install\Folder\putty.exe"
WinWait putty
;Upper Right
WinMove, putty, , 960, 0, 960, 540
Run, % "C:\Putty\Install\Folder\putty.exe"
WinWait putty
;Lower Left
WinMove, putty, , 0, 540, 960, 540
Run, % "C:\Putty\Install\Folder\putty.exe"
WinWait putty
;Lower Right
WinMove, putty, , 960, 540, 960, 540
This assumes that you have an HD screen (1920x1080). You can include site and login information to each window, so they will automatically start the connection you want for each one too. You'll just need to look up the PuTTy command line commands you need for the sites you are using and include them as part of the Run
command for each window.
3
This answer uses Snap Assist of Windows 10 and AutoHotKey.
Snap Assist can place and resize windows on half-screen or quarter-screen with the following Corner Snap hotkeys :
The following AutoHotKey script will place notepad on the left-upper quarter-screen and will resize it to the size of the quarter-screen:
SetTitleMatchMode, 2
SetTitleMatchMode Fast
Run, % "C:\Windows\System32\notepad.exe"
WinWait Notepad
Send {LWin down}{Left}{LWin up}{LWin down}{Up}{LWin up}
You should modify the script as follows :
notepad.exe
by the path to putty.exe
.
The parameters to putty are added immediately after the program with
a separating blank.
If a parameter contains special characters, enclose it in double quotes.{Down}
and {Right}
.For this to work, Windows 10 Snap Assist should be enabled, which is its state by default. If it needs to be enabled, launch the Settings app from the Start Menu, click System, click Multitasking on the left, and set the Snap option. The following two options must be set to On :
0
You cannot do what you want just with PuTTY but you can use MTPuTTY (Multi-Tabbed PuTTY) http://ttyplus.com/multi-tabbed-putty/
See what it does here:
The script didn't work as expected, it opened 4 putty windows on top of each other. I also tried doing
Run, % "C:\Putty\Install\Folder\putty.exe -load myprofile"
, with the same result. I ofc replacedPutty\Install\Folder
with myProgram Files\PuTTY
. I'm on Windows 10 btw – Tasos – 2018-01-09T11:41:21.1931I will admit that I didn't test this with PuTTY directly, since I don't have that installed on any computer where I use PuTTY. I have several scripts that do exactly what you described but with various apps, so I just modified it to fit for an example. It does work with a lot of windows, including command prompts, but some apps maintain too tight of control over their size and position for AHK to change it. – techturtle – 2018-01-09T13:10:29.167