Request to create shortcards for xfce menu panel

Hello
I want to make a shortcut:
When I press ctrl + s, my panel will be hidden and when I press ctrl + s again, it will be displayed with the mouse when I go, the method will not work …
Thank you for your help

huh?
So you mean you already tried some method?
Cuz this sounds like something you would need to write a script for.

1 Like

I did not try any method!
Only now a launcher opens in plank that when I right-click the method, two xfce4-panels appear, which when I double-click the method, it closes completely, and when I click the method again, the panel is displayed!
I wanted to see if I could write a shortcut for this.

I have a script for switching audio outputs that can be adapted to switch panel autohide setting

    #!/bin/bash
    ## xfce4-panel-toggle.sh
    ##
    ## check if autohide is disabled 
    if [ $(xfconf-query -c xfce4-panel -p /panels/panel-0/autohide-behavior -lv | awk '{print $2}') == 0 ];
    then
      ## turn autohide on
      xfconf-query -c xfce4-panel -p /panels/panel-0/autohide-behavior -t int -s 2
          else
      ## turn autohide off
      xfconf-query -c xfce4-panel -p /panels/panel-0/autohide-behavior -t int -s 0
    fi
    exit

But Ctrl + S is not a good choice for a keyboard shortcut as many packages already use that for saving a file

I suggest using something like Alt + S or Super + S would work better