Solved

How to set a font to a CMenu ?

Posted on 2008-10-09
3
1,285 Views
Last Modified: 2013-11-20
Hi,
I have a dialog box with a menu attached to it. How do I set a font to the menu?

Thanks
0
Comment
Question by:UdiRaz
3 Comments
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 500 total points
ID: 22683530
Not possible with regular options, all menus uses the default windows appeareance settings. You will need to do with owner-draw functions. This is a complex task.
Some related articles:
http://www.codeproject.com/KB/menus/CMenuEx.aspx
http://www.codeproject.com/KB/menus/menuch.aspx
http://www.codeguru.com/Cpp/controls/menu/article.php/c3721


0
 
LVL 5

Expert Comment

by:isprabu
ID: 22685253
Jaime is right. You need to implement owner drawn menu to achive what you want. There is also an article in MSDN which you can refer to. This one has many different examples and you can look at the section titled "Setting Fonts for Menu-Item Text Strings" in this page.
http://msdn.microsoft.com/en-us/library/ms647558(VS.85).aspx#_win32_Creating_Owner_Drawn_Menu_Items
Hope this helps!
0
 

Author Closing Comment

by:UdiRaz
ID: 31504886
thanks
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Modbus - whats the maximum I can store in one register? 4 80
Work with App store 7 68
Why  my code (program) build with old compiler? 11 76
Outlook 13 41
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

856 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