Hi,
I want to hide the area around a icon in the toolbarbutton.
Please help?
Hi,
I want to hide the area around a icon in the toolbarbutton.
Please help?
Always Believe in Urself
Merry
You mean icons with transparent borders,,, isnt it ?I want to hide the area around a icon in the toolbarbutton.
I guess the icons you are using have opaque borders.
you can take it like this ,
suppose i have a toolbutton of size 50 ,40
and a icon in that of size 20, 20 .........
Now i want to hide the area of the button which doesn't contain icon.........
Always Believe in Urself
Merry
If you hide that area, wont the size of the button reduce to 20,20 ??
So you can either resize the button to fit the icon, or you can resize the icon to fit the button.
Also may be QWidget::setMask might be of some use to you.
Actually the height of Toolbutton is controlling the height of my toolbar ,which i can't compromise with .
So i can't change the size.
QWidget::setMask() is not working for me.
Always Believe in Urself
Merry
What did you try with setMask ? you need to apply mask on the toolbutton.
I guess simplest way would be using a png/jpg with transparent backgroung.
If this is not what you want, can you some snapshot of what functionality you want to achieve ?
Bookmarks