Solved

Flash file does not "send to back" in Delphi

Posted on 2011-09-02
5
499 Views
Last Modified: 2012-05-12
Hi,

I have various Flash files in my Delphi app but I am unable to place any labels "above" or "on top of" the flash file.

Whenever I insert a label it falls behind the flash file and cannot be seen.

Any help will be much appreciated.

Thank you.
0
Comment
Question by:kylestimpson013
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 37

Expert Comment

by:Geert Gruwez
ID: 36472790
TLabel is not a "windowed" control (descendant of TWinControl)
It can only be placed at the lowest level on the container (on the form, or on a panel, or ...)

It also has no Z-order, so can not be stacked on top of other controls


Use a TPanel to place a text on top of the flash
0
 
LVL 25

Accepted Solution

by:
epasquier earned 500 total points
ID: 36472808
or use TStaticText, which is an exact TLabel alternative BUT windowed
You can find it on your 'Additional' components palette tab

more info :
http://delphi.about.com/od/tlabeltstatictext/TLabel_TStaticText_Delphi_Label_Control_Usage_Tips_and_Tricks.htm
0
 

Author Comment

by:kylestimpson013
ID: 36472835
Thank you, but how do i make the background of TStaticText transparent? i need to put text over the flash file to show labels for certain items but the TStaticText transparency is set to true but not working?

I appreciate all the help.
0
 
LVL 25

Assisted Solution

by:epasquier
epasquier earned 500 total points
ID: 36473207
yeah, I know, even with Delphi XE TStaticText transparency does not seem to work that great : it makes the background of its parent visible, not the object that is between them.

that is because what you want is a very complex issue to do perfectly.
Look there, the comments are interesting (last ones mostly)
http://stackoverflow.com/questions/4478649/draw-over-controls-in-dephi-form

in short, your best option would be to create a completely transparent windowed control that you put over all others. I might have something in store like that. I used it to display 'tactical moves' above a DirectX viewport in a strategic game I made.
The thing is, that you won't be able to interact with the controls beneath using the mouse, as your transparent windowed control will get all mouse events. So if you need it you'll have to reroute all messages in that transparent control mouse events to their rightful owners
0
 

Author Comment

by:kylestimpson013
ID: 37623207
After some further testing and research, i figured out a way to set the Flash file as the background in an application.

This is accomplished by setting the flash file for EVERYTHING that you wish to be viewed on top of it.

This takes time but its worth it in the end if you really require a flash file background.

I hope this helps someone else in the future too.

Thank you for all the help on this.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Having just graduated from college and entered the workforce, I don’t find myself always using the tools and programs I grew accustomed to over the past four years. However, there is one program I continually find myself reverting back to…R.   So …
The goal of the tutorial is to teach the user how to select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question