-
5 Attachment(s)
Simple Transparent Frame User Control v1.14
Just a simple transparent Frame (container) control.
Place control on a Form or inside a Picture box that has an image.
Properties: Caption, BackColor, BorderColor(XP/7 styles), FrameStyle, Font, ForeColor, ForeColorDisabled, Transparent, and Enable.
v1.14 - Fix: Selecting a system color for XP\7 border color was always black.
v1.13 - Add option to disable transparency and set background color.
v1.12 - Add Windows XP/7 frame styles. (includes TabStrip Demo for XP Style)
v1.09 - Fix bugs in v1.06 to v1.08. (support and fix Framez inside of Framez)
v1.05 - General usage.
Notes:
Vista and Windows 7 have the same look for frames.
Transparency is now disabled by default in v1.13 and greater.
-
Re: Simple Transparent Frame User Control
-
Re: Simple Transparent Frame User Control
v1.05 -
Caption now changes as you type in design mode.
Simplified Font code.
Demo includes 2 pictures and how to update background of frames.
-
Transparent User Control That display Gif /Animated file
hi,
I have a task to display a transparent user control that display gif / animated file. Currently I am using a webbrowser control in a user control.
But the problem is, the webbrowser doesn't have the transparent property. As such my gif file always has a solid white background, against the container's image background.
May I know what is the alternative ways?
Thanks and best regards,
-
Re: Simple Transparent Frame User Control
The WebBrowser does display transparent gif images. Are you sure your gif image has a transparent background? Post your gif image and I will test it with my WebBrowser
-
Re: Transparent User Control That display Gif /Animated file
Quote:
Originally Posted by johnliang
But the problem is, the webbrowser doesn't have the transparent property. As such my gif file always has a solid white background, against the container's image background.
For animated Gifs you might want to take a look at LaVolpe's Animated Image Control
-
Re: Simple Transparent Frame User Control
Program has error running in design mode.
Run-time error '398'
Client-Site not available
Code:
Private Function ManageTimers(ByVal Mode As Long) As Boolean
If Mode = 0 Then
If UserControl.Ambient.UserMode = True Then KillTimer c_tmrOwner c_tmrOwner, ObjPtr(Me)
c_aniState = gfaStop
Else
'
'
'
'
'
End Function
-
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by jmsrickland
Program has error running in design mode.
Run-time error '398'
Client-Site not available
Please use quotes so people reading your replies know who/what you are referring/replying to.
I assume you are talking about LaVolpe's Animated Image Control I posted a link to, I don't get any errors like that here.
-
1 Attachment(s)
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by Edgemeal
For animated Gifs you might want to take a look at LaVolpe's Animated Image Control
Thanks Edgemeal. It looked useful to me. Cheers.
Quote:
Originally Posted by jmsrickland
The WebBrowser does display transparent gif images. Are you sure your gif image has a transparent background? Post your gif image and I will test it with my WebBrowser
As requested, attached is the gif file. Thanks.
-
Re: Simple Transparent Frame User Control
Well I see that your gif is transparent (I can't test it because it is not the .gif file attached) but for a fact WebBrowser displays all transparent gif images as transparent so I don't know what your problem could be but if you can use LaVolpe's program then go for it.
-
Re: Simple Transparent Frame User Control
hi jmsrickland,
thanks for your help. my problem is i have created a uc which has a webbrowser control. this webbrowser control will display a gif animated file.
secondly i have a picturebox which has a background picture.
I put the webbrowser uc into this picturebox container. It is supposed to display the animated gif over the background picture. But instead, it displays the gif with a white solid background thereby covering the picturebox's background image.
Is there any solution?
Rgrds,
-
Re: Simple Transparent Frame User Control
Still not completely understanding this.
OK, you have a UC. The UC has a WebBrowser Control in it. That is all, right? OK, the WebBrowser in the UC can display the animated gif correctly, right?
So now you take this UC and put it in a Picturebox which is on the parent Form, right?
The Picturebox already has a picture in it as the background. Now wouldn't putting the UC inside the Picturebox cover the background picture? I think so.
OK, here is where I get lost. Putting the UC inside the Picturebox. What do you expect it to do? The UC sits on top of the background picture of the Picturebox. Am I getting this wrong? But the gif image inside the WebBrowser still shows as a transparent image. What am I missing here?
-
Re: Simple Transparent Frame User Control
You are right on all your assumptions.
Basically I want the animated gif to be displayed on top of the picturebox with the picturebox's image as its background.
I see your point that the webbrowser (being not tranparent) will block the image of the picturebox underneath.
The reason I use put the webbrowser control on the uc is because I wish to be able to position the gif, to set the webbrowser scrollbars off and to display image in flat border mode (not 3D) during runtime, therefore using the uc to perform these functions.
All gif parameters are read from an external xml file.
-
Re: Simple Transparent Frame User Control
Basically I want the animated gif to be displayed on top of the picturebox with the picturebox's image as its background.
I think this is going to be a problem. As a rule, Pictureboxes do not have the ability to display a transparent gif image. There might be some code around here and perhaps the code is in LaVolpe's program that can emulate, so the speak, the effect of a transparent image in a Picturebox but I don't know what that code is but I bet there is some. But like I said, without some special technique you simply cannot display a transparent image in a Picturebox.
Why don't you make the WebBrowser's background the picture you want and put the animated gif on top of that? Wouldn't that work as well?
Make your document like this....
Code:
<html>
<body background="background_picture.jpg">
<img src="animated.gif">
</body>
</html>
....and load this into the WebBrowser UserControl.
-
Re: Simple Transparent Frame User Control
thanks for all your constructive feedbacks. I will keep those comments in mind.
you all have been very kind.
cheers.
-
Re: Simple Transparent Frame User Control
Hi,
Nice Control, really useful.
Just one thing thou...
I am trying to include this frame in an activex control, but the redraw method does not seem to work. Do you have any ideas?
Thanks in advance!
-
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by
broc028
Hi,
Nice Control, really useful.
Just one thing thou...
I am trying to include this frame in an activex control, but the redraw method does not seem to work. Do you have any ideas?
Thanks in advance!
Sorry for not replying sooner, I'm not sure I know the correct answer, my guess is the control you are putting my transparent framez UC into doesn't have the needed properties for the BitBlt call, like a .hDC, .ScaleMode, .ScaleX and .ScaleY.
I recently ran into that same problem and added this to my main container control.
Code:
Public Property Get hDC() As Long
hDC = UserControl.hDC
End Property
Public Property Get ScaleMode() As ScaleModeConstants
ScaleMode = UserControl.ScaleMode
End Property
see post #23 for the rest
-
Re: Simple Transparent Frame User Control v1.07
v1.06 & v1.07 didn't work correctly when put into a Picture Box, forgot to set AutoReDraw.
-
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by
Edgemeal
Sorry for not replying sooner, I'm not sure I know the correct answer, my guess is the control you are putting my transparent framez UC into doesn't have the needed properties for the BitBlt call, like a .hDC, .ScaleMode, .ScaleX and .ScaleY.
I recently ran into that same problem and added this to my main container control.
Code:
Public Property Get hDC() As Long
hDC = UserControl.hDC
End Property
Public Property Get ScaleMode() As ScaleModeConstants
ScaleMode = UserControl.ScaleMode
End Property
Public Property Get ScaleX(Width As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleX = UserControl.ScaleX(Width, FromScale, ToScale)
End Property
Public Property Get ScaleY(Height As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleY = UserControl.ScaleY(Height, FromScale, ToScale)
End Property
But to get my framez control to show up properly inside other framez I had to also divide the Extender.Left & .Top values by Screen.TwipsPerPix... too, though I thought the scaleX/Y would of taken care of that, weird. :confused:
Can you pls upload a copy of what you did for others 2 share
-
1 Attachment(s)
Re: Simple Transparent Frame User Control v1.08
Quote:
Originally Posted by
Edgemeal
Just a simple transparent Frame (container) control.
Place control on a Form or inside a Picture box that has an image.
Properties: Caption, FrameStyle, Font, ForeColor, ForeColorDisabled and Enable.
The control doesnt seem to be transparent to me.
Place it on a tabstrip and compile with xp style to see what i mean
-
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by
Edgemeal
Sorry for not replying sooner, I'm not sure I know the correct answer, my guess is the control you are putting my transparent framez UC into doesn't have the needed properties for the BitBlt call, like a .hDC, .ScaleMode, .ScaleX and .ScaleY.
I recently ran into that same problem and added this to my main container control.
Code:
Public Property Get hDC() As Long
hDC = UserControl.hDC
End Property
Public Property Get ScaleMode() As ScaleModeConstants
ScaleMode = UserControl.ScaleMode
End Property
Public Property Get ScaleX(Width As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleX = UserControl.ScaleX(Width, FromScale, ToScale)
End Property
Public Property Get ScaleY(Height As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleY = UserControl.ScaleY(Height, FromScale, ToScale)
End Property
But to get my framez control to show up properly inside other framez I had to also divide the Extender.Left & .Top values by Screen.TwipsPerPix... too, though I thought the scaleX/Y would of taken care of that, weird. :confused:
Can you please place or upload a copy of what you did so i could see it. you said you got it to work.
-
Re: Simple Transparent Frame User Control v1.08
Quote:
Originally Posted by
coolcurrent4u
The control doesnt seem to be transparent to me.
Place it on a tabstrip and compile with xp style to see what i mean
Might be easier if you uploaded a sample demo project of just that tabstrip with the xp style for me to play with.
-
Re: Simple Transparent Frame User Control
Quote:
Originally Posted by
coolcurrent4u
Can you please place or upload a copy of what you did so i could see it. you said you got it to work.
Well the Framez control is in Pixel mode so I thought the above scaleX/Y code would work correctly but after trying some other controls inside the Framez (that call the scaleX/Y of its container) I noticed they weren't drawing correctly, so I changed the scaleX/Y code (Framez v1.09) and no longer need to check if a framez is inside another framez, so I guess my scalex/y properties above were wrong after all, at least for a UC that is set to pixel mode.
Code:
Public Property Get ScaleX(Width As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleX = UserControl.ScaleX(Width, FromScale, ToScale) / Screen.TwipsPerPixelX
End Property
Public Property Get ScaleY(Height As Single, FromScale As ScaleModeConstants, ToScale As ScaleModeConstants)
ScaleY = UserControl.ScaleY(Height, FromScale, ToScale) / Screen.TwipsPerPixelY
End Property
I don't really get how UCs work, even though you set them to Pixel mode the cords act like they are in twips!
-
Re: Simple Transparent Frame User Control v1.09
can you pls post a project example that uses xp style and the tabstrip control. am still battleing with you code
-
Re: Simple Transparent Frame User Control v1.09
A vb tabstrip doesn't have a picture property nor does it have an .hDC that the Framez control needs. I'm puzzled why you need the frame to be transparent since the tabstrip isn't a container with a pic property to begin with.
-
Re: Simple Transparent Frame User Control v1.09
the control is not a container
how do i make it one?
-
Re: Simple Transparent Frame User Control v1.09
You dont. You can place other controls on top of it but you cannot make it the parent.
-
Re: Simple Transparent Frame User Control v1.09
if i can't place controls on it, then its of no use.
-
Re: Simple Transparent Frame User Control v1.09
Well the TabStrip control is not a container but the MS Tabbed Dialog control is.
Why not just post a stripped down version of what it is you are trying to do so we can see it and maybe help better, post it in the vb6 earlier forum.
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
Edgemeal
Well the TabStrip control is not a container but the MS Tabbed Dialog control is.
Why not just post a stripped down version of what it is you are trying to do so we can see it and maybe help better, post it in the vb6 earlier forum.
pls check this forum
http://www.vbforums.com/showthread.p...29#post3529829
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
So far from what I can gather you want a transparent frame on top of a tabstrip control, but I can't understand why, when using the TabStrip control you would set your controls .Zorder, .Visible, .Container, etc,etc, properties to show, move, hide the controls when the tabstrip index changes.
If you have objects/controls under the frame that you want to see you could just set their .Container property to the frame.
I can only guess you are taking the wrong approach to achieve the desired result.. You still haven't attached any sample project so I'm done trying to guess.
-
1 Attachment(s)
Re: Simple Transparent Frame User Control v1.09
ok here is a sample project
pls chk it out
-
Re: Simple Transparent Frame User Control v1.09
I can't see the project above, because I've done a hard drive format and haven't installed VB yet, but I guess you're having the same problem as what I had in the topic below.
http://www.vbforums.com/showthread.php?t=507336
Simply put a Picturebox with a white backcolor on the TabStrip and make the backcolor of the Frame white as well. You will only lose the gradient backcolor of the TabStrip, but I don't think anybody will notice (see the difference between first and third picture in the topic above).
-
Re: Simple Transparent Frame User Control v1.09
i am already using this solution, but its not good for a proffesional looking app. i would'nt have bothre about making a frame control transparent anyway
-
Re: Simple Transparent Frame User Control v1.09
Ok I think I see what you mean...,
When you apply the XP style to the form the TabStrip control actually has a gradient look to it and you want the Frame background to match the TabStrip background.
The only way I can think of doing that besides what you already tried in the other thread would be to use a picbox (or usercontrol) and draw the same looking gradient effect onto it, then draw the borders and caption for a XP style looking frame on top of that.
-
1 Attachment(s)
Re: Simple Transparent Frame User Control v1.09
Even if you get your transparent frame effect working you'll also have to make other controls like check & option boxes appear transparent too, I know it's not impossible just seems like a lot of work/resources to use up instead of just going with a solid background color for everything. Best of Luck!
-
Re: Simple Transparent Frame User Control v1.09
can you send me this project to play with
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
can you send me this project to play with
Have fun playing. :)
-
Re: Simple Transparent Frame User Control v1.09
thanks i'll play with it and see what i can do
can't i enable theme in ur control?
how do i do that
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
thanks i'll play with it and see what i can do
can't i enable theme in ur control?
how do i do that
No, if you look at the Framez code it just uses the DrawEdge API, thats one of the reasons I called it "Simple". ;)
I just slapped together another transparent Framez control real quick just to see if I could draw a XP looking one, it's nothing special, you'll probably want to look at sites like Planet Source Code for controls that support themes to learn from, there are a lot of controls on that site.
EDIT TabStrip_Experiment_2.zip Removed - Updates in Progress....
.
-
Re: Simple Transparent Frame User Control v1.09
thanks again
you have saved me from much trouble
i this i'll try this one
-
Re: Simple Transparent Frame User Control v1.09
oops you removed the code why?
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
oops you removed the code why?
Adding some properties to XP_Framez control, like Font, Colors, just a few basics. PM sent.
-
Re: Simple Transparent Frame User Control v1.09
-
1 Attachment(s)
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
ok thanks. waiting......
Try this demo and let me know how it works out for you.
-
Re: Simple Transparent Frame User Control v1.09
thanks again for you bright idea
-
Re: Simple Transparent Frame User Control v1.09
Updated the Framez control to v1.12.
Added WinXP/Win7 to Frame Styles.
Also includes an updated demo of the TabStrip Experiment, the Windows XP frame style now looks correct.
-
Re: Simple Transparent Frame User Control v1.09
Quote:
Originally Posted by
coolcurrent4u
thanks again for you bright idea
Glad I could help, though it looks great under WinXP that gradient look isn't used under Win7.
I was just playing with Windows 7 RC and the styles are different, the TabStrip no longer has that gradient look in its body, that area is all white. The Frames also look a little different, Win7 frames are single line too but with a less rounded corner. Not sure if it is the same way in Vista or not, haven't played with Vista much at all.
-
Re: Simple Transparent Frame User Control v1.12
windows 7 or vista? whats d difference am using xp
-
Re: Simple Transparent Frame User Control v1.12
so for win7 what do you suggest
-
Re: Simple Transparent Frame User Control v1.12
Quote:
Originally Posted by
coolcurrent4u
so for win7 what do you suggest
If we wanted the tabstrip experiment project to match the OS (as close as possible) we'd first check to see what OS is running, if its Vista or Win7 then we don't apply the gradient to the pic box container and leave it as a solid white, and set the style of the v1.1.2 Framez control to Win7.
I looked at some screen shots of Vista and Win7 and the tabstrip and frame look the same to me, though depending on the theme selected I'm sure the colors will change. If you really want your program to match the OS style at all times you really need to look at theme aware type controls, or possibly subclass so your project always knows if the theme/colors have changed and apply the needed changes to your controls.
-
Re: Simple Transparent Frame User Control v1.12
and just how do i do that?
you know i was just wandering if all this effort is not too much for just the frame control
remeber that the initial aim was to make the frame control look transparent. i had a code that does that but was slower when i had like three or four frame controls on a tabstrip
-
Re: Simple Transparent Frame User Control v1.12
Quote:
Originally Posted by
coolcurrent4u
and just how do i do that?
you know i was just wandering if all this effort is not too much for just the frame control
remeber that the initial aim was to make the frame control look transparent. i had a code that does that but was slower when i had like three or four frame controls on a tabstrip
Probably best if you search and ask those specific questions in the vb6 & earlier forum.
-
Re: Simple Transparent Frame User Control v1.12
Also remember there are different themes available: the best way to go is to use the theme drawing APIs or hack around the default Windows controls (group box in this case), but that requires advanced knowledge and tricks.
Code:
Private Declare Sub GetMem4 Lib "msvbvm60" (ByVal Ptr As Long, Value As Long)
' ..
Dim lnghWnd As Long
GetMem4 ObjPtr(Frame1) + 68, lnghWnd
This is how you get the hWnd of the native VB frame (and actually any VB control that must have a hWnd in the first place).
-
Re: Simple Transparent Frame User Control v1.12
i got this themeing project from vbaccelerator but i don't know how to use it. the theming program is to help anyone doing themming
as regards theming which do you think would be better
app theming or windows theming
-
Re: Simple Transparent Frame User Control v1.12
This relates to this topic a bit so I'm posting this here. I hacked around a bit to figure out if I could have an alpha transparent frame. I got it somewhat working but I don't have the time to play with this further.
Two issues: 1) the control does not move when the form is moved and 2) the z-index is lost, I don't know if it is possible to restore it while maintaining alpha transparency.
It is a hack that relies on SetParent, because normally you can't use SetLayeredWindow on a child window of another window, you can only use it to top level windows.
Start a new project, add Frame1 and paste:
Code:
Option Explicit
Private Const GWL_EXSTYLE = -20
Private Const GWL_STYLE = -16
Private Const LWA_ALPHA = &H2
Private Const WS_CHILD = &H40000000
Private Const WS_EX_LAYERED = &H80000
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Private Declare Sub GetMem4 Lib "msvbvm60" (ByVal Ptr As Long, Value As Long)
Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
Private Declare Function GetWindowRect Lib "user32" (ByVal hWnd As Long, lpRect As RECT) As Long
Private Declare Function MoveWindow Lib "user32" (ByVal hWnd As Long, ByVal X As Long, ByVal Y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal bRepaint As Long) As Long
Private Declare Function SetLayeredWindowAttributes Lib "user32" (ByVal hWnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal dwFlags As Long) As Long
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Private Declare Function SetWindowPos Lib "user32" (ByVal hWnd As Long, ByVal hWndInsertAfter As Long, ByVal X As Long, ByVal Y As Long, ByVal cX As Long, ByVal cY As Long, ByVal wFlags As Long) As Long
Private Sub Form_Resize()
Static lngWnd As Long, udtRect As RECT, udtRectP As RECT
Dim udtRectPN As RECT
If lngWnd = 0 Then
GetMem4 ObjPtr(Frame1) + 68, lngWnd
GetWindowRect lngWnd, udtRect
GetWindowRect Me.hWnd, udtRectP
SetParent lngWnd, 0
SetWindowLong lngWnd, GWL_EXSTYLE, GetWindowLong(lngWnd, GWL_EXSTYLE) Or WS_EX_LAYERED
SetLayeredWindowAttributes lngWnd, 0, 50, LWA_ALPHA
'MoveWindow lngWnd, udtRect.Left - udtRectPN.Left, udtRect.Top - udtRectPN.Top, udtRect.Right - udtRect.Left, udtRect.Bottom - udtRect.Top, 0
SetParent lngWnd, Me.hWnd
Else
GetWindowRect Me.hWnd, udtRectPN
udtRectPN.Left = udtRectP.Left - udtRectPN.Left
udtRectPN.Top = udtRectP.Top - udtRectPN.Top
'SetWindowLong lngWnd, GWL_EXSTYLE, GetWindowLong(lngWnd, GWL_EXSTYLE) And Not WS_EX_LAYERED
End If
SetWindowPos lngWnd, 1, udtRect.Left - udtRectPN.Left, udtRect.Top - udtRectPN.Top, udtRect.Right - udtRect.Left, udtRect.Bottom - udtRect.Top, 0
End Sub
Happy hacking if someone catches this up and tries to get it to work.
Edit!
It still doesn't maintain zindex, but it is possible to have the transparent window behind other controls! Now the hard part is tracking window movement...
-
Re: Simple Transparent Frame User Control v1.12
Quote:
Originally Posted by
Merri
Happy hacking if someone catches this up and tries to get it to work.
This would be a sort of a cool effect for disabling a frame since you can't click on any of the controls inside the frame when you apply this code.
-
Re: Simple Transparent Frame User Control v1.12
Framez doesnt support tooltiptext for labels does anyone know how to fix this issue?
I need that label for making check boxes and option boxes transparent.
Instead of tooltiptex from label i could show tooltiptext of check box or option if i know how to do that programically.
thx
-
Re: Simple Transparent Frame User Control v1.12
Quote:
Originally Posted by
seba.kwiat
Framez doesnt support tooltiptext for labels does anyone know how to fix this issue?
I need that label for making check boxes and option boxes transparent.
Instead of tooltiptex from label i could show tooltiptext of check box or option if i know how to do that programically.
thx
That problem doesn't have anything to do with the Framez control in particular, if you create a new usercontrol and set it as a container you'll see the lable control (even if set to opaqe) doesn't show it's tooltip, though I'm not sure why.
Unless someone knows why and a solution I'd suggest trying something else for your tooltips, like a ballon tooltip class (copy of the class posted here) instead. You wont have that problem with labels then and have nicer looking tooltips also IMO.
btw, to use a label with that class you would pass the labels container handle since a label doesn't have a handle.
-
Re: Simple Transparent Frame User Control v1.12
Quote:
Originally Posted by
Edgemeal
That problem doesn't have anything to do with the Framez control in particular, if you create a new usercontrol and set it as a container you'll see the lable control (even if set to opaqe) doesn't show it's tooltip, though I'm not sure why.
Unless someone knows why and a solution I'd suggest trying something else for your tooltips, like a ballon tooltip class (
copy of the class posted here) instead. You wont have that problem with labels then and have nicer looking tooltips also IMO.
btw, to use a label with that class you would pass the labels container handle since a label doesn't have a handle.
Thanks for your reply.
you can not use that class because labels has no hwnd but i solved the problem by placing the label inside the picturebox. I set the labels to transparent and i cut out picturebox from the backgrount so it all looks transparent and tooltip works fine on that.