答案1
我刚刚在 AHK 中写了这个作为解决方案(因为你提到了这个很棒的工具)。要使用它,请将Z1
、Z2
等设置为图例中显示的所需缩放级别。(如果没有为显示器设置任何内容,它将以 100% 缩放最大化。)然后,您可以结合Alt与任何显示器编号相对应的数字键来最大化/缩放该显示器上的 Firefox。例如:
按Alt+1将活动 FF 窗口最大化至
Z1
主显示屏上的缩放级别按Alt+2将活动 FF 窗口最大化,以
Z2
在辅助显示屏上缩放级别
代码:
; Set the zoom levels for FF to maximize to on each display
Z1 = 4 ; Primary display zoom level
Z2 = 0 ; Secondary display zoom level
Z3 = 0 ; etc..
; Zoom level legend
; 0 = 100% 3 = 133% 6 = 200%
; 1 = 110% 4 = 150% 7 = 240%
; 2 = 120% 5 = 170% 8 = 300%
; Count displays and create hotkeys accordingly
sysGet, monitors, 80
loop %monitors% {
sysGet, screen, monitor, %a_index%
%a_index%_screenTop := screenTop
%a_index%_screenLeft := screenLeft
hotkey, ifWinActive, ahk_class MozillaWindowClass
hotkey, $!%a_index%, moveMaxZoom
}
moveMaxZoom:
winRestore ; Restore window if necessary
thisHotkey := regExReplace(a_thisHotkey, "[^0-9A-Za-z]")
winMove, a,, %thisHotkey%_screenLeft, %thisHotkey%_screenTop
postMessage, 0x112, 0xF030 ; 0x112 = WM_SYSCOMMAND, 0xF030 = SC_MAXIMIZE
Z := Z%thisHotkey%
send ^0^{+ %Z%}
return