 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
Rhetticus
Joined: 12 Jul 2008 Posts: 1 Location: Australia
|
|
| Back to top |
|
 |
Max99
Joined: 10 Jul 2008 Posts: 3
|
Posted: Sat Jul 12, 2008 9:46 pm Post subject: |
|
|
| Lexikos wrote: | | ...which functions did you try? WindowPad originally used Win+Numpad, but the latest version uses Numpad0/NumpadDot+Numpad or Capslock+q/w/e/a/s/d/z/x/c. If I download the latest version and extract it somewhere, it Just Works. |
Problem solved as I must somehow have missed the fact that the Windows key is no longer the operator key. Now all working fine and exactly what I need (and more) to replace the buggy nView software. Will also definitely now try to use AutoHotkey for other applications.
Many thanks for help and for a great little utility. |
|
| Back to top |
|
 |
HelgeFin
Joined: 04 Apr 2007 Posts: 8
|
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 2558 Location: Australia, Qld
|
Posted: Sat Aug 30, 2008 3:12 am Post subject: |
|
|
Thanks for posting, HelgeFin. Here are my biased findings after a quick try:
- Redirect maximize is an interesting idea, but not so useful in practice if you must click the maximize button. It is too small to be efficient - I use a mouse gesture instead.
- The WinMove features do not seem applicable to single-monitor set-ups, or they simply don't work on my system.
- WinMem might be useful to some, but I probably wouldn't use it.
- WinResize (multi-window resizer) is excellent.
ezuk requested similar hotkey-based functionality a while back, but I never got around to implementing it.
Interestingly, the GUI paints very slowly when Aero is enabled (on Vista). This does not happen with AutoHotkey GUIs. |
|
| Back to top |
|
 |
HelgeFin
Joined: 04 Apr 2007 Posts: 8
|
Posted: Sat Aug 30, 2008 1:16 pm Post subject: |
|
|
You are right,
| Lexikos wrote: | WinResize (multi-window resizer) is excellent.  |
It is the killer feature. That alone makes it worth having that program running. |
|
| Back to top |
|
 |
deepfriedcheese
Joined: 04 Jul 2008 Posts: 3
|
Posted: Wed Sep 03, 2008 1:58 pm Post subject: WinMove in Windowpad |
|
|
I monkeyed with the windowpad code to get something like the WinMove feature in splitmon some time ago. I use a five monitor setup in my office and a two or three monitor system at client's offices. The software for the nVidia card in my docking station included this function, but I wanted it while in the field without the dock.
I inserted the following lines in the code:
| Code: | Prefix_Alternate = #^ ; Ctrl+Win+Numpad = Move window directly to a monitor
|
Defined at the same time as the other prefixes.
| Code: | | Hotkey, %Prefix_Alternate%Numpad%A_Index%, DoMoveWindowToMonitor |
In the loop registering hotkeys.
| Code: | ;
; Move window directly to monitor number selected without resizing (relative to screen).
;
DoMoveWindowToMonitor:
gosub WP_SetLastFoundWindowByHotkey
WinGet, state, MinMax
if state = 1
{ ; Maximized windows don't move correctly on XP
; (and possibly other versions of Windows)
WinRestore
DoMoveWindowToMonitor()
WinMaximize
}
else
DoMoveWindowToMonitor()
return
DoMoveWindowToMonitor()
{
WinGetPos, x, y, w, h
; Determine which monitor contains the center of the window.
ms := GetMonitorAt(x+w/2, y+h/2)
; Determine which monitor to move to.
StringRight, md, A_ThisHotkey, 1
SysGet, mon, MonitorCount
; This may happen if someone tries to move to a monitor number that does not exist.
if (md > mon)
return
; This may happen if someone tries it with only one screen. :P
if (md = ms)
return
; Get source and destination work areas (excludes taskbar-reserved space.)
SysGet, ms, MonitorWorkArea, %ms%
SysGet, md, MonitorWorkArea, %md%
msw := msRight - msLeft, msh := msBottom - msTop
mdw := mdRight - mdLeft, mdh := mdBottom - mdTop
; Calculate new size.
if (IsResizable()) {
w *= (mdw/msw)
h *= (mdh/msh)
}
SetWinDelay, -1
; Move window, using resolution difference to scale co-ordinates.
WinMove,,, mdLeft + (x-msLeft)*(mdw/msw), mdTop + (y-msTop)*(mdh/msh), w, h
} |
This is the routine that actually moves the window.
I also wanted to be able to move either direction with NumpadDot so I added this.
| Code: | | Hotkey, %Prefix_Alternate%NumpadDot, MoveWindowBackOneScreen |
So I could easily move forward and back one screen using NumpadDot.
| Code: | MoveWindowBackOneScreen:
gosub WP_SetLastFoundWindowByHotkey
WinGet, state, MinMax
if state = 1
{ ; Maximized windows don't move correctly on XP
; (and possibly other versions of Windows)
WinRestore
MoveWindowBackOneScreen()
WinMaximize
}
else
MoveWindowBackOneScreen()
return
MoveWindowBackOneScreen()
{
WinGetPos, x, y, w, h
; Determine which monitor contains the center of the window.
ms := GetMonitorAt(x+w/2, y+h/2)
; Determine which monitor to move to.
md := ms-1
SysGet, mon, MonitorCount
if (md < 1)
md := mon
; This may happen if someone tries it with only one screen. :P
if (md = ms)
return
; Get source and destination work areas (excludes taskbar-reserved space.)
SysGet, ms, MonitorWorkArea, %ms%
SysGet, md, MonitorWorkArea, %md%
msw := msRight - msLeft, msh := msBottom - msTop
mdw := mdRight - mdLeft, mdh := mdBottom - mdTop
; Calculate new size.
if (IsResizable()) {
w *= (mdw/msw)
h *= (mdh/msh)
}
SetWinDelay, -1
; Move window, using resolution difference to scale co-ordinates.
WinMove,,, mdLeft + (x-msLeft)*(mdw/msw), mdTop + (y-msTop)*(mdh/msh), w, h
} |
This is a barely modified version of the MoveWindowToNextScreen to move it back instead.
I looked at the splitmon page, but I didn't try it out. I don't get what the WinResize actually does.
Lexikos, I hope you don't mind me posting the changes I've made. Windowpad is a great program that adds a big dose of efficiency to my days. |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|