Hi,
The panel show/hide behaviour isn't theme related so don't go hunting through cinnamon.css
You can change the settings programmatically via interacting with the dconf settings database. You can use these commands in a bash script.
Examples - check existing settings.
gsettings get org.cinnamon panels-enabled
returns for me
['1:0:top', '2:0:left']
This basically means I have two panels on the primary monitor, one on the top and one on the left.
gsettings get org.cinnamon panels-autohide
returns for me
['1:false', '2:intel']
My left panel intelligently autohides and the top is always there.
Set new settings. So if I wanted my top panel to autohide I would do.
gsettings set org.cinnamon panels-autohide "['1:true', '2:intel']"
It's probably worth installing dconf-editor to get a GUI with a nice overview of the backend settings. Or you can use gsettings to do the same.
gsettings list-recursively org.cinnamon
To check the window state from a bash script you are looking at tools like
wmctrl
,
xdotool
and
xwininfo
Some example commands
xwininfo -id $(xdotool getactivewindow) -stats
wmctrl -lG
If you want to avoid the hackery of doing this via a bash script then you are looking at either modifying your Cinnamon install or writing an extension. A lot of the UI is in JavaScript - take a look at
/usr/share/cinnamon/js/ui/panel.js
Extensions are JavaScript based as-well - take a look at
https://github.com/linuxmint/cinnamon-spices-extensions for examples of how they are put together.