PDA

View Full Version : Panel header titleposition



svper
18 Apr 2013, 1:41 AM
i want to position my title before anything ( items & tools )
No matter what i set the titleposition to, the button i have in the items keeps showing before the title

slemmon
19 Apr 2013, 12:51 PM
Can you share the code you're using to put the button in the header?

svper
22 Apr 2013, 4:20 AM
header:{
xtype:'header',
height:100,
title:localisation[localisation.currentLanguage].lblScreen3Header,
titlePosition:500,
items:[
{
xtype:'button',
docked:'right',
text:'test'
}
]
},

slemmon
22 Apr 2013, 9:00 AM
Does this work for you?



Ext.create('Ext.panel.Panel', {
title: 'Hello',
width: 200,
html: '<p>World!</p>',
renderTo: Ext.getBody()
, header:{
xtype:'header',
height:100,
title:'MyTitle',
titlePosition: 0,
items:[
{
xtype:'button',
docked:'right',
text:'test'
}
]
}
, tools: [{
type: 'expand'
}]
});

svper
25 Apr 2013, 1:46 AM
Even after removing that expand button it still works... lord knows why cause i already tried titleposition 0

Thank you very much

Rohan Jalil
6 Apr 2017, 4:14 AM
Hi
this is my code



Ext.define('MyPanel', {
extend: 'Ext.panel.Panel',


title: 'MyTitle' ,
header:{
titlePosition: 0,
items:[{

xtype:'button',
scale: 'small',
cls: 'info-Button-learningObjectives',
html: '<i class="fa fa-info-circle fa-lg info-Button-color "></i>',
tooltip:'Tool Tip for this button'
},{
xtype: 'radiogroup',
reference: 'ref',
name: 'radioSubjectsGroup',
defaults: {
listeners: {

}
}
}]
},


The issue is both these items come at the most right of my panel, (Title of my panel is aligned left).
I want to bring that button right after my title and that radiogroup to the most right.
Is there any way
Please help me, Thanks