PDA

View Full Version : how to superpose 2 label on image



tdikarim
3 May 2013, 3:33 AM
Hi all,

I want to superpose 2 component
One image, and over this image, one label field


,{
xtype: 'container',
layout:
{
type: 'hbox',
align: 'left',
pack: 'center'
},
items: [
{
xtype : 'image',
id:'id_logo_login',
src : 'images/icones/login_tab.png',
style:'width: 278px; height: 45px; padding-top: 0px; margin: 0px; top: -1px;'
}

,{
xtype: 'label',
forId: 'currentUserConnected',
text: 'TESTUSER',
width: 150
}
]
}


Thanks for your suggestions

slemmon
6 May 2013, 9:12 AM
Have you tried using the vbox layout for the parent container containing your image / label?

tdikarim
13 May 2013, 12:55 AM
Hi,

with vbox, the text is placed below the image
here is a capture :
43738

Thanks for your help

smkkiran
13 May 2013, 1:15 AM
Why dont u try image in css for that container and text will come automatically on top of it
similar concept of tab...