The prop sbstate and tbstate for windows return wrong result when the switchbar or treebar is hidden...
ex.: //swtichbar off | window @a | echo -ga $window(@a).sbstate
return 0, switchbar is hidden not the window... so, this is not be to return 1?
sorry for my english, i don't speek very well