jQuery EasyUI Forum
May 18, 2013, 05:32:11 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Title in collapsed Layout Panel  (Read 1432 times)
skellenb
Newbie
*
Posts: 4


View Profile Email
« on: June 29, 2012, 06:13:43 AM »

Hi,

Is there a way to set/show the Title in a collapsed Layout Panel?

When collapsed east or west panel the Title should be visible rotated 90 degrees like in ExtJS
In north, south and Center Panel the Title should be visible like when its expanden...



Logged
stworthy
Administrator
Hero Member
*****
Posts: 644


View Profile Email
« Reply #1 on: July 02, 2012, 02:16:37 AM »

This feature is not available in current version. The code below shows a simple way to display the rotated title when the west panel is collapsed.
Code:
$(function(){
var p = $('body').layout('panel','west').panel({
onCollapse:function(){
var title = $('body').layout('panel','west').panel('options').title;  // get the west panel title
var p = $('body').data('layout').panels['expandWest'];  // the west expand panel
p.html('<div style="-moz-transform: rotate(90deg);padding:6px 2px">'+title+'</div>');
}
});
});
Logged
skellenb
Newbie
*
Posts: 4


View Profile Email
« Reply #2 on: July 03, 2012, 03:07:51 PM »

many thanks for the Help Grin

can i do something like this to show the title in collapsed east panel (closed at init with collapsed=true)??

Code:
$.parser.onComplete = function(){
$('body').css('visibility','visible');
var title = $('#mainlayout').layout('panel','east').panel('options').title;  // get the east panel title
var p = $('#mainlayout').data('layout').panels['expandEast'];  // the east expand panel
p.html('<div style="-moz-transform: rotate(90deg);-webkit-transform: rotate(90deg);-ms-transform: rotate(90deg);padding:6px 2px;font-weight:bold;">'+title+'</div>');
};

Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.13 | SMF © 2006-2011, Simple Machines LLC Valid XHTML 1.0! Valid CSS!