 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Thu Feb 18, 2010 9:21 pm Post subject: |
|
|
| ossandcad: Does it move but not resize the window? If so, try adding an exception to IsResizable(). |
|
| Back to top |
|
 |
mccartrey
Joined: 17 Oct 2007 Posts: 3 Location: Maidenhead
|
Posted: Fri Feb 26, 2010 10:42 am Post subject: active window across both monitors - is it possible? |
|
|
Is it possible by default or by defining keys in the ini file to make WindowPad stretch the active window across both monitors please?
Hopefully this post is the right place as this thread is all about WindowPad
 |
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Fri Feb 26, 2010 2:37 pm Post subject: |
|
|
No. However, if you add the following to WindowPad.ahk you may then assign the pseudo-command "FillVirtualScreen" to a hotkey:
| Code: | FillVirtualScreen:
if WindowPad_WinExist(Params)
{
SysGet, vX, 76 ; SM_XVIRTUALSCREEN
SysGet, vY, 77 ; SM_YVIRTUALSCREEN
SysGet, vW, 78 ; SM_CXVIRTUALSCREEN
SysGet, vH, 79 ; SM_CYVIRTUALSCREEN
WinMove,,, vX, vY, vW, vH
}
return
|
| Code: | [Hotkeys]
...
; Active window
#f = FillVirtualScreen
; Previous window
#g = FillVirtualScreen, P
; Window at mouse
#MButton = FillVirtualScreen, M
|
|
|
| Back to top |
|
 |
codybear
Joined: 15 Sep 2009 Posts: 560
|
Posted: Thu Mar 04, 2010 3:44 am Post subject: nice |
|
|
thanks for this.
I was going to start making something similar in my constant script, well I actually had started to, but only has like 1 or 2 things so far, but definitely no where near the quality of this.
This will definitely save me some time. |
|
| Back to top |
|
 |
ossandcad
Joined: 18 Feb 2010 Posts: 5
|
Posted: Fri Mar 05, 2010 6:36 pm Post subject: No move, No resize, no nothing |
|
|
| Lexikos wrote: | | ossandcad: Does it move but not resize the window? If so, try adding an exception to IsResizable(). |
Sorry Lexikos for the delayed answer, but I relied on the forum to send me an email if a reply had been posted - and I got no such email.
As for the answer to your question - Nope. ScottradeELITE does not respond to the keyboard shortcuts at all. Caps+Space does not move it, Caps+Tab does not maximize/restore it. These are the shortcuts I use most. Not sure if I can provide any debug information to you to help with this? Any links/suggestions you can provide to debug this would also be most helpful.
Thanks for the wonderful script again. |
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Sat Mar 06, 2010 5:33 am Post subject: |
|
|
Double-click the tray icon (or right click, Debug) and confirm that the appropriate hotkeys are listed. Since you use the CapsLock set, CapsLock should appear in the list. If you have pressed CapsLock since starting the script, Tab, Space, z, x, c, etc. should also appear but will be "OFF" unless you're actually holding CapsLock down.
If you press Ctrl+K while the debug window is active (or View, Key history and script info) it will show the last 20 key-presses/releases. Pressing Caps+Space should show something like this:
| Code: | 14 03A h d 3.61 Caps Lock
20 039 h d 0.22 Space
20 039 s u 0.09 Space
14 03A s u 0.42 Caps Lock | "h" indicates the keypress was recognized as a hotkey.
If the hotkeys are being recognized, you may press Ctrl+L (or View, Lines most recently executed) to determine which lines of script they are executing.
The following lines may appear as a result of navigating through the debug window, and may be ignored:
| Code: | 896: Critical
897: id := wParam & 0xFFFF
898: if id in 65305,65404,65306,65403
906: } (27.75) |
|
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Sat Mar 06, 2010 4:58 pm Post subject: |
|
|
| Quote: | Version 1.60
- Functions with up to 5 parameters may now be used as commands in WindowPad.ini.
- Added WPM as an alias for WindowPadMove.
- Added FillVirtualScreen command.
- Added config file for Compile_AHK II (for recompiling with icons).
- If WinTitle is _ (a single underscore), the last minimized window is used.
|
At some point I added the capability to restore the window to its most recent "non-WindowPad" position. For instance, I use something like this:
| Code: | [Hotkeys: Active Window (WADS)]
...
LAlt = WPM, R, R0, , 1.0
| If the window is already in a position not set by WindowPad, pressing CapsLock+LAlt will expand the window vertically to the height of the screen. Otherwise WindowPad attempts to restore the window's position. Omitting X or Y has the same effect as specifying "R". |
|
| Back to top |
|
 |
ossandcad
Joined: 18 Feb 2010 Posts: 5
|
Posted: Mon Mar 08, 2010 3:34 pm Post subject: Keyboard shortcut combo not recognized |
|
|
| Lexikos wrote: | Double-click the tray icon (or right click, Debug) and confirm that the appropriate hotkeys are listed. Since you use the CapsLock set, CapsLock should appear in the list. If you have pressed CapsLock since starting the script, Tab, Space, z, x, c, etc. should also appear but will be "OFF" unless you're actually holding CapsLock down.
CapsLock does appear in the list. And the shortcut key CapsLock+Space works with other windows.
If you press Ctrl+K while the debug window is active (or View, Key history and script info) it will show the last 20 key-presses/releases. Pressing Caps+Space should show something like this:
| Code: | 14 03A h d 3.61 Caps Lock
20 039 h d 0.22 Space
20 039 s u 0.09 Space
14 03A s u 0.42 Caps Lock | "h" indicates the keypress was recognized as a hotkey.
I pressed Ctrl+K but the above lines do not show up anywhere even after a few refreshes. Which tells me that the shortcut key combo is not being recognized by the window in question.
So now the question is - is there a possibility that I can get WindowPad to work with this window (ScottradeElite) or is it a lost cause and I should look elsewhere.
If the hotkeys are being recognized, you may press Ctrl+L (or View, Lines most recently executed) to determine which lines of script they are executing.
The following lines may appear as a result of navigating through the debug window, and may be ignored:
| Code: | 896: Critical
897: id := wParam & 0xFFFF
898: if id in 65305,65404,65306,65403
906: } (27.75) |
|
|
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Tue Mar 09, 2010 9:09 am Post subject: |
|
|
| So after pressing CapsLock+Space with that window active and refreshing the key history, CapsLock and Space do not show up? If that is the case, I think you are out of luck. |
|
| Back to top |
|
 |
ossandcad
Joined: 18 Feb 2010 Posts: 5
|
Posted: Mon Mar 15, 2010 4:28 am Post subject: thanks for your help |
|
|
| Lexikos wrote: | | So after pressing CapsLock+Space with that window active and refreshing the key history, CapsLock and Space do not show up? If that is the case, I think you are out of luck. |
Oh well. I guess I am out of luck. any suggestions on other similar scripts I could try - perhaps ones inspired by WindowPad or ones WindowPad is inspired from? |
|
| Back to top |
|
 |
lexikos* Guest
|
Posted: Mon Mar 15, 2010 6:19 am Post subject: |
|
|
If those keystrokes don't appear in the key history, it's unlikely any AutoHotkey script will work. To be sure, check that the following also doesn't register the keystrokes:
| Code: | #InstallKeybdHook
KeyHistory
; Switch to your app and press Caps+Space,
; then switch back to this and refresh (F5). |
|
|
| Back to top |
|
 |
ossandcad
Joined: 18 Feb 2010 Posts: 5
|
Posted: Mon Mar 15, 2010 6:04 pm Post subject: Not sure where to check this |
|
|
| lexikos* wrote: | If those keystrokes don't appear in the key history, it's unlikely any AutoHotkey script will work. To be sure, check that the following also doesn't register the keystrokes:
| Code: | #InstallKeybdHook
KeyHistory
; Switch to your app and press Caps+Space,
; then switch back to this and refresh (F5). |
|
Thanks for the comment lexikos, but I am afraid I don't know how to follow your instructions. Where do I need to check the code that you posted? In the WindowPad.ahk or in the Debug screen? I searched both places and am not able to find those lines of code. Sorry for being such a noob, but any help you can provide would be most helpful. |
|
| Back to top |
|
 |
Maestr0
Joined: 18 Oct 2008 Posts: 159
|
Posted: Tue Mar 30, 2010 11:14 am Post subject: |
|
|
absolutely brilliant, great job!
something you might want to add: ontop or notontop:
| Code: | hotkey_ontop:
WinGet , active_id, ID, A
WinSet , Alwaysontop, On, ahk_id %active_id%
return
hotkey_offtop:
WinGet , active_id, ID, A
WinSet , Alwaysontop, Off, ahk_id %active_id%
return
|
| Code: | [Hotkeys]
...
hotkey, %Prefix_Active%Up , hotkey_ontop
hotkey, %Prefix_Active%DOWN , hotkey_offtop
|
I use win up and win down combo's to do the ontop-ness... well, you get the idea
I'm missing a "restore" button, in case I accidentily do a win+numpad5 on a window and want it back to the way it was originally... maybe save all original sizes in a variable and then call them if the restore hotkey is pressed?
and I like a nice icon for each script I run, so I added this line as well:
| Code: |
Menu, Tray, Icon, Shell32.dll, 25
|
|
|
| Back to top |
|
 |
Lexikos
Joined: 17 Oct 2006 Posts: 7299 Location: Australia
|
Posted: Fri Apr 02, 2010 7:15 am Post subject: |
|
|
| Maestr0 wrote: | | I'm missing a "restore" button, | Download the latest version via the "Download Latest Version" link. It appears you've copied the script under "Ye Olde Version". Once you've done that, read my previous post mentioning this feature. Note that the "non-WindowPad" positions are stored for each window via window properties, which remain until the window is closed even if the script is restarted.
| Quote: | | and I like a nice icon for each script I run, so I added this line as well: | More recent versions include an icon, though I don't know if you'd call it "nice".
| Quote: | | something you might want to add: ontop or notontop: | I use WindowPad alongside my private hotkey script, which includes:
| Code: | ; Toggle always-on-top.
#`::WinSet, AlwaysOnTop, Toggle, A
|
| ossandcad wrote: | | Where do I need to check the code that you posted? | Sorry for the late reply; the code is to be copied into a new standalone script and run. It merely shows the key history while ensuring the keyboard hook is active. |
|
| Back to top |
|
 |
Maestr0
Joined: 18 Oct 2008 Posts: 159
|
Posted: Fri Apr 02, 2010 9:28 am Post subject: |
|
|
heh, you're right, copied the code instead of downloading the zip, my bad, thanks  |
|
| 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
|