Solved

How to change Popup menu colors,fonts..etc

Posted on 2000-04-16
4
388 Views
Last Modified: 2013-12-03
I want to change the background color and the font color in my popup menus...I'd like to be able to do this using D2 and D3  I looked at a couple
of free components I found but they were really lame.. one did not allow
sub menu items using the free version and another would not install.. maybe someone here has modified a popup menu component to add font and color?

..Gwen..
0
Comment
Question by:Gwena
4 Comments
 
LVL 9

Expert Comment

by:ITugay
ID: 2720206
Hi Gwena,
It seems not possible to change color and font in standard TPopupMenu by easy way. You need to write your own class from TPopupMenu.  And draw menu items yourself. Set OwnerDraw to True to indicate that the application will draw menu items in an OnDrawItem event handler.
-----
Igor
0
 
LVL 3

Accepted Solution

by:
bryan7 earned 50 total points
ID: 2721512
hey Gwena, I remember I once did it.. look at the sources of RxLib .. there is a unit that shows how to change the popup menus' font color/name/size etc... about the background color.. sorry I have no idea

umm, sorry, I'm not sure now.. does the standard popup menu have a canvas property ? if so you can do:

with PopupMenu.Canvas.Font do begin
    Name := 'Courier New';
    Style := [fsBold];
    Size := 20;
    Color := clWhite;
  end;

I got from the RxDemo ..
0
 
LVL 3

Expert Comment

by:ckaneta
ID: 2723409
check out the Triton 2000 delphi components.
they have a popup menu where you can change the color of the popup menu and the font, can even set a bitmap as the background of the popup if you like

can get them at Torry's Delphi pages or
www.tritontools.com
0
 
LVL 5

Author Comment

by:Gwena
ID: 2761666
:-)
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

758 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