AutoHotkey has PostMessage and SendMessage commands that can send internal "messages" to windows or controls. Often programs use these types of messages for their menu commands. To find out the proper message values you need, you use a program like Winspector to log messages of possible interest.
For more information, see SendMessage Tutorial.
(This tutorial is also buried in the AutoHotkey help file: go to the bottom of the PostMessage/SendMessage page, and in the Related links, click on Message Tutorial.)
The program pictured in Barlop's question is Rainlendar.
Using the methods from the tutorial above, I made the following example AutoHotkey script that sets F11 to "Hide all windows" and F12 to "Show all windows".
WM_COMMAND := 0x111
SHOW_ALL := 598
HIDE_ALL := 599
DetectHiddenWindows, On
#IfWinExist Rainlendar2 Control Window ahk_class wxWindowClassNR
F11::
window_id := WinExist("Rainlendar2 Control Window ahk_class wxWindowClassNR")
PostMessage, %WM_COMMAND%,%HIDE_ALL%,,,ahk_id %window_id%
Return
F12::
window_id := WinExist("Rainlendar2 Control Window ahk_class wxWindowClassNR")
PostMessage, %WM_COMMAND%,%SHOW_ALL%,,,ahk_id %window_id%
Return