Voila un script que j'ai fait pour la gestion des fenêtres au niveau de l'affichage/masquage et de la transparence

Je précise que ce script fonctionne uniquement avec des raccourcis claviers (pour en avoir la liste, il faut cliquer sur l'icône dans le tray

PS: Je crois que j'ai mis un peu trop de raccourcis

► Afficher le texte
Code : Tout sélectionner
#include <Constants.au3>
#include <GUIConstants.au3>
Opt("TrayOnEventMode", 1)
Opt("TrayMenuMode", 1)
Opt("WinTitleMatchMode", -2)
Global $gui
Global $transp
Global $info
Global $gui_x
Global $WinSwitch = 1
Global $ShellApp = ObjCreate("Shell.Application")
Global $title = "Propriétés de la Barre des tâches et du menu Démarrer"
$ShellApp.TrayProperties
WinWait($title)
WinSetState($title, "", @SW_HIDE)
SendKeepActive($title)
Send("!{TAB}")
Func Trans()
$gui = InputBox("Transparence", "Fenêtre", $gui, "", -1, 50)
$transp = InputBox("Transparence", "Opacité (0-255)", $transp, "", -1, 50)
WinSetTrans($gui, "", $transp)
RaZ()
EndFunc
Func iTrans()
$transp = InputBox("Transparence", "Opacité (0-255)", $transp, "", -1, 50)
WinSetTrans("", "", $transp)
EndFunc
Func Hide()
$gui = InputBox("Masquer", "Fenêtre", $gui, "", -1, 50)
WinSetState($gui, "", @SW_HIDE)
RaZ()
EndFunc
Func Show()
$gui = InputBox("Afficher", "Fenêtre", $gui, "", -1, 50)
WinSetState($gui, "", @SW_SHOW)
RaZ()
EndFunc
Func Bureau()
$gui_x = $gui
$gui = "[class:Progman]"
EndFunc
Func Barre()
$gui_x = $gui
$gui = "[class:Shell_TrayWnd]"
EndFunc
Func RaZ()
If $gui = "[class:Progman]" Or $gui = "[class:Shell_TrayWnd]" Then $gui = $gui_x
EndFunc
Func Quit()
WinClose($title)
If $WinSwitch = 0 Then DeskSwitch()
Exit
EndFunc
Func DeskSwitch()
If $WinSwitch = 1 Then
Send("!B!A")
WinSetState("[class:Shell_TrayWnd]", "", @SW_HIDE)
WinSetState("[class:Progman]", "", @SW_HIDE)
$WinSwitch = 0
Else
Send("!B!A")
WinSetState("[class:Shell_TrayWnd]", "", @SW_SHOW)
WinSetState("[class:Progman]", "", @SW_SHOW)
$WinSwitch = 1
EndIf
Send("!{TAB}")
EndFunc
Func Info()
If $info = 0 Then
$info = 1
Else
$info = 0
ToolTip("")
EndIf
EndFunc
Func DisplayHotKeys()
GUICreate("Raccourcis clavier", 375, 190)
GUISetBkColor(0xEEEEFF)
GUICtrlCreateLabel("Raccourcis Clavier", 70, 5, 300)
GUICtrlSetFont(-1, 15, -1, -1, "Verdana")
GUICtrlSetColor(-1, 0x55AAAA)
GUICtrlCreateLabel("" & _
"F9 <--->" & @LF & _
"F10 <--->" & @LF & _
"CTRL + F10 <--->" & @LF & _
"F11 <--->" & @LF & _
"CTRL + ALT + F8 <--->" & @LF & @LF & _
"CTRL + F8 <--->" & @LF & _
"CTRL + MAJ + F8 <--->" & @LF & _
"ALT + F10 <--->" & @LF & @LF & _
"CTRL + MAJ + F10 <--->", 10, 40)
GUICtrlSetStyle(-1, $ES_RIGHT)
GUICtrlSetColor(-1, 0x55CCCC)
GUICtrlCreateLabel("" & _
"Cacher une fenêtre" & @LF & _
"Changer la transparence d'une fenêtre" & @LF & _
"Changer la trans. de la fenêtre active" & @LF & _
"Afficher une fenêtre" & @LF & _
"Cacher / Afficher le bureau et la barre des tâches" & @LF & @LF & _
"Mettre en mémoire le bureau" & @LF & _
"Mettre en mémoire le barre de tâches" & @LF & _
"Afficher la position de la souris" & @LF & @LF & _
"Quitter", 135, 40)
GUICtrlSetColor(-1, 0x55CCCC)
GUISetState()
EndFunc
HotKeySet("^{f8}", "Bureau")
HotKeySet("^+{f8}", "Barre")
HotKeySet("^!{f8}", "DeskSwitch")
HotKeySet("{f9}", "Hide")
HotKeySet("{f10}", "Trans")
HotKeySet("^{f10}", "iTrans")
HotKeySet("!{f10}", "Info")
HotKeySet("{f11}", "Show")
HotKeySet("^+{f10}", "Quit")
TraySetOnEvent($TRAY_EVENT_PRIMARYDOWN, "DisplayHotKeys")
TraySetOnEvent($TRAY_EVENT_SECONDARYDOWN, "DisplayHotKeys")
While Sleep(10)
If $info = 1 Then
$pos = MouseGetPos()
ToolTip("X: " & $pos[0] & @LF & "Y: " & $pos[1], 0, 0, "MouseGetPos()")
EndIf
If GUIGetMsg() == $GUI_EVENT_CLOSE Then GUIDelete()
WEnd