Solved

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

Posted on 2003-11-23
5
482 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

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Suggested Solutions

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

757 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

21 Experts available now in Live!

Get 1:1 Help Now