Solved

Overlay of TEdit (alpha blend? or clear background) for Timer App

Posted on 2003-11-23
5
483 Views
Last Modified: 2010-04-05
I want to create a simple timer, but I want the display to appear like a digital clock, such that you can see the grey template of 88:88:88 and the actual display numbers being a much darker overlay.  I thought of having two TEdit boxes, the first with a grey font of 88:88:88 and the second with black font and a clear background, but I don't seem to be able to give the TEdit control a see-through background.  Annoted/Explained Code preferable
0
Comment
Question by:jazzygm
  • 3
  • 2
5 Comments
 
LVL 22

Expert Comment

by:Ferruccio Accalai
ID: 9806960
i'd go to another way....
A Timagelist with 11 images (for 0 to 9 in led style and the : sign) then a panel with 8 Timage.
On timer read the Time String value (for example 13:00:12) and assign to the same pos image  the correspondent image from imagelist....It's just an idea, but so you can customize your images, and so your digital numbers, as you prefere.....

F68 ;-)

0
 
LVL 22

Expert Comment

by:Ferruccio Accalai
ID: 9807034
btw to use your idea should be bettere to use a led styled label....there're lots of led label components on the web and expecially on torry.net

in this package there's TPieLedLabel with source that's a good solution for your job
http://homepages.borland.com/torry/vcl/packs/middle/pietools.zip

F68 ;-)
0
 

Author Comment

by:jazzygm
ID: 9807088
It seems wasteful of resources though, I would have thought that maybe subclassing the Tedit and fiddling with its background properties to allow it to be transparent would be better, but I have no idea how to!
0
 
LVL 22

Accepted Solution

by:
Ferruccio Accalai earned 75 total points
ID: 9807118
so go to a more simple way....use 2 tlabel, the first with font color clInactiveCaption.
The second exactly over the first with font color clblack and transparent property to true....the easiest way...

F68 ;-)
0
 

Author Comment

by:jazzygm
ID: 9811851
Thanks, i REALLY should have thought of that myself, I think I got hit with a stupid stick at the start of the weekend!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

896 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now