PDA

View Full Version : column header with br



sofway
30 Apr 2010, 7:37 AM
Hi,
is there any way to have a grid column header with two lines?
The header title is to long and i need to split it . When i use br, the style gets wrong on all headers
Thanks

cnelissen
30 Apr 2010, 11:15 AM
The column headers weren't designed to span multiple lines.. You could of course hack it up to make it work, which would involve numerous changes to the CSS... Probably not worth doing, but entirely possible.

veerai2i
12 Aug 2010, 10:45 PM
hi..

i also need column header like below
Time
Hr:min

do we need to change the css manually or any config we have in ext-js 3.1?

thanks ,

veera

Screamy
13 Aug 2010, 11:35 AM
In version 3.2.1, embedding a <br/> in the column header text will work. If you sort on such a column, note that only the bottom-most word(s) in the header will be highlighted and show the ascending/descending indicator. On the whole, it's workable and doesn't look too bad...

sosy
13 Aug 2010, 4:49 PM
And if you are looking in the header menu, you will see that the <br /> causes an bad layout. You can find an fix for that here:

http://www.sencha.com/forum/showthread.php?106830-Columnheader-columnselect-linebreaks

and for the extended search plugin from Saki, you can find an fix here:

http://www.sencha.com/forum/showthread.php?23615-Grid-Search-Plugin&p=496574#post496574

Regards
Sosy

veerai2i
13 Aug 2010, 8:52 PM
hi..

thanks a lot for reply, but i used 3.1, i changed lot in source files, hence i can't upgrade to 3.2.1. is any other choic?

i am trying with column-header-group.js??? is it useful?? or can we play around with css???

thanks again,

veera

Screamy
14 Aug 2010, 12:08 PM
Modified source files == A Bad Thing™ in my book...

Maybe you could migrate your source modifications into extended classes?

As for overriding GridPanel CSS, you could probably start with x-grid3-hd-row and see what happens from there...