Solved

How to change Popup menu colors,fonts..etc

Posted on 2000-04-16
4
389 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

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
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…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
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…

910 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

19 Experts available now in Live!

Get 1:1 Help Now