View Full Version : turn off tabbing in borderLayout
luke83
4 Nov 2006, 2:48 AM
i would like to turn of the tabbing in a region of borderLayout 8)
is there something like tab:false to set in the region setup? i played around with no results :?
if there isn't, what is the way to turn off them? :twisted:
(i know it can appear stupid to turn off, but the contentPanel in the region are activated by tabs of center region :D)
jack.slocum
4 Nov 2006, 1:06 PM
Currently there isn't. You could probably mess with the code and find a work around, possibily by setting the display of the tabstrip to display none?
luke83
5 Nov 2006, 2:42 AM
i will try something like this... the problem is that i want this only for a region not for every region..
it could be nice to have a parameter in the region "declaretion" like tabs:false as solution.. but i'm not to that level.. so i will try to play with the display...:D
[edit]
i used .ytab-wrap{display:none} and all the tabs go away.. but how can i say to css that only the tabs in the west region have to go away? is there a container for all region? what is the naming?
jack.slocum
5 Nov 2006, 4:05 AM
#your-container .ylayout-panel-west .ytab-wrap{display:none}
luke83
5 Nov 2006, 4:37 AM
of course it works... :D
i used this code:
.ylayout-panel-west .ytab-wrap{display:none}
using also the container id it don't work... :roll:
SteveEisner
6 Nov 2006, 1:39 PM
By the way, this works well - except when you have nested layout. Specifically, I'm controlling multiple panels with a north region, and each of those center panels has its own layout. There's unfortunately no way to turn off tabs in the outer center region without also disabling it on the inner layout...
It would definitely be nice to be able to disable tab display in a more controlled fashion (it could even just be the addition of a css class...)
Luckily it worked out that I wanted to disable tab display on the inner layout too ;)
Chroder
6 Nov 2006, 4:06 PM
I was looking for this two, I ended up doing:
layout.regions['center'].getTabs().el.setStyle('display', 'none');
But that hides all... So I'll go the CSS route :) Thanks for the tip.
Chroder
6 Nov 2006, 4:15 PM
You could do:
layout.regions['center'].getTabs().el.addClass('hidetabs');
Then just add CSS for hidetabs:
.hidetabs .ytab-wrap {
display: none;
}
To make it apply to only the tab strip you want it to.
jack.slocum
6 Nov 2006, 5:06 PM
You code also use CSS:
#outer-container .ylayout-west-panel .ytab-wrap{
display:none;
}
#inner-container .ylayout-west-panel .ytab-wrap{
display:block !important;
}
I don't know if the !important is required but I added it in just in case. :)
Powered by vBulletin® Version 4.1.5 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.