CMenu is white background

Hi

I'm having an MFC application (which are compiled with /CLR option to use 
..Net components), and I've got
a strang behavior when clicking on the menu of the main frame.

First, this is a MDI application.

When a click on a menu, everything works fine except that the redraw of the 
Menu lets its background in white

Is there any way to solve this probleme ?

Nicolas , Toulouse, France


0
2/8/2006 5:18:32 PM
vc.mfc 33608 articles. 0 followers. Follow

15 Replies
964 Views

Similar Articles

[PageSpeed] 21

I'm not sure I understand.  Almost every menu on my system has a white 
background.  What color is it usually?

Tom

"nicolas ETIENNE" <nicolas.etienne@oktal.fr> wrote in message 
news:dsd9es$j8o$1@apollon.grec.isp.9tel.net...
> Hi
>
> I'm having an MFC application (which are compiled with /CLR option to use 
> .Net components), and I've got
> a strang behavior when clicking on the menu of the main frame.
>
> First, this is a MDI application.
>
> When a click on a menu, everything works fine except that the redraw of 
> the Menu lets its background in white
>
> Is there any way to solve this probleme ?
>
> Nicolas , Toulouse, France
>
> 


0
tserface (3860)
2/8/2006 7:08:54 PM
>Almost every menu on my system has a white background.

??? Its usually shade of gray.

I think what OP is saying is that once menu disappears, repainting is
not done properly.

I am in middle of porting a MFC app to VS2005 and I am experiencing a
similar issue.  

------
Ajay Kalra
ajaykalra@yahoo.com

0
ajaykalra (6841)
2/8/2006 7:18:04 PM
Ah, I thought they were talking about the menu that drops down.  Sorry if I 
misunderstood.  You're talking about the menu toolbar?

Tom

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139426284.078396.21830@f14g2000cwb.googlegroups.com...
> >Almost every menu on my system has a white background.
>
> ??? Its usually shade of gray.
>
> I think what OP is saying is that once menu disappears, repainting is
> not done properly.
>
> I am in middle of porting a MFC app to VS2005 and I am experiencing a
> similar issue.
>
> ------
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
tserface (3860)
2/8/2006 7:27:31 PM
I was thinking about the pop up menu; eg Alt-F will pop up the menu. I
may be wrong though.

-----
Ajay Kalra
ajaykalra@yahoo.com

0
ajaykalra (6841)
2/8/2006 7:43:17 PM
It's white on my computer. GetSysColor with COLOR_MENU to see for yourself.

-- 
Vipin Aravind

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139426284.078396.21830@f14g2000cwb.googlegroups.com...
> >Almost every menu on my system has a white background.
>
> ??? Its usually shade of gray.
>
> I think what OP is saying is that once menu disappears, repainting is
> not done properly.
>
> I am in middle of porting a MFC app to VS2005 and I am experiencing a
> similar issue.
>
> ------
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
vipin (697)
2/8/2006 7:43:41 PM
Hmmm... Mine are all white because that's the menu background the system has 
set up.  I'm porting a big project to 2005 too so maybe I'll see the same 
issue.

Tom

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139427797.338789.237850@g47g2000cwa.googlegroups.com...
>I was thinking about the pop up menu; eg Alt-F will pop up the menu. I
> may be wrong though.
>
> -----
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
tserface (3860)
2/8/2006 7:45:44 PM
Its white if you are running XP theme and some gray if you are running
Classic Theme.

------
Ajay Kalra
ajaykalra@yahoo.com

0
ajaykalra (6841)
2/8/2006 8:10:49 PM
I had not seen the white menus for a long time until I just changed my
them. Yikes, no wonder I stayed with the classic look.  I have no idea
what OP is now saying. I still think its the redraw issue but its all
up in the air.

--------
Ajay Kalra
ajaykalra@yahoo.com

0
ajaykalra (6841)
2/8/2006 8:12:28 PM
yes. Actually, it is dictated by
Display Properties->Appearance->Advanced->Item->Menu and then Color.
I have gone through one round of red/blue/green and finally switched back to 
white,
as my eyes started paining with others. :(

-- 
Vipin Aravind

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
> Its white if you are running XP theme and some gray if you are running
> Classic Theme.
>
> ------
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
vipin (697)
2/8/2006 8:21:43 PM
OK, that makes sense... I don't like classic theme so I never run it...

Tom

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
> Its white if you are running XP theme and some gray if you are running
> Classic Theme.
>
> ------
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
tserface (3860)
2/8/2006 10:46:33 PM
I wonder if it's a manifest thing since the 2005 compiler does more with 
adding the manifest for you than the old one did.  Could be a conflict 
there.  I know I got a warning (even though I'm not linking yet - long story 
about libraries) so I haven't seen anything concrete.

Tom

"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
> Its white if you are running XP theme and some gray if you are running
> Classic Theme.
>
> ------
> Ajay Kalra
> ajaykalra@yahoo.com
> 


0
tserface (3860)
2/8/2006 10:47:35 PM
The problem is due to XP Theme.

In fact, using "Windows Classic style" makes it looks like before...

I just wish it could be possible to get the same result but being with XP 
style...

because if not , it means that the look and feel of my menus will be 
different depending on what
the user will have setup for its configuration ...


Any issue ?

Nicolas, Toulouse, France




"Tom Serface" <tserface@msn.com> a �crit dans le message de news: 
uvr3nGQLGHA.1124@TK2MSFTNGP10.phx.gbl...
>I wonder if it's a manifest thing since the 2005 compiler does more with 
>adding the manifest for you than the old one did.  Could be a conflict 
>there.  I know I got a warning (even though I'm not linking yet - long 
>story about libraries) so I haven't seen anything concrete.
>
> Tom
>
> "Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
> news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
>> Its white if you are running XP theme and some gray if you are running
>> Classic Theme.
>>
>> ------
>> Ajay Kalra
>> ajaykalra@yahoo.com
>>
>
> 


0
2/9/2006 7:06:35 AM
This is expected and is not an issue. It should depend upon user's
settings. Windows takes care of all this.

-----------
Ajay Kalra
ajaykalra@yahoo.com

nicolas ETIENNE wrote:
> The problem is due to XP Theme.
>
> In fact, using "Windows Classic style" makes it looks like before...
>
> I just wish it could be possible to get the same result but being with XP
> style...
>
> because if not , it means that the look and feel of my menus will be
> different depending on what
> the user will have setup for its configuration ...
>
>
> Any issue ?
>
> Nicolas, Toulouse, France
>
>
>
>
> "Tom Serface" <tserface@msn.com> a =E9crit dans le message de news:
> uvr3nGQLGHA.1124@TK2MSFTNGP10.phx.gbl...
> >I wonder if it's a manifest thing since the 2005 compiler does more with
> >adding the manifest for you than the old one did.  Could be a conflict
> >there.  I know I got a warning (even though I'm not linking yet - long
> >story about libraries) so I haven't seen anything concrete.
> >
> > Tom
> >
> > "Ajay Kalra" <ajaykalra@yahoo.com> wrote in message
> > news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
> >> Its white if you are running XP theme and some gray if you are running
> >> Classic Theme.
> >>
> >> ------
> >> Ajay Kalra
> >> ajaykalra@yahoo.com
> >>
> >
> >

0
ajaykalra (6841)
2/9/2006 11:37:23 AM
I agree with Ajay.  I think you're users are going to expect you to use the 
colors they set in the Display Properties.  Users can change just about any 
setting there so they may have special contrast needs, or whatever.  For 
example, I really like the black letters on white background.  I find it 
easy to read. Someone else may read red on black better (can't imagine how, 
but you never know).

That said, you could create your own class and draw the menus yourself any 
way you'd like, but I'm not sure that's a good use of programmer time.

Tom

"nicolas ETIENNE" <nicolas.etienne@oktal.fr> wrote in message 
news:dseq00$a72$1@apollon.grec.isp.9tel.net...
> The problem is due to XP Theme.
>
> In fact, using "Windows Classic style" makes it looks like before...
>
> I just wish it could be possible to get the same result but being with XP 
> style...
>
> because if not , it means that the look and feel of my menus will be 
> different depending on what
> the user will have setup for its configuration ...
>
>
> Any issue ?
>
> Nicolas, Toulouse, France
>
>
>
>
> "Tom Serface" <tserface@msn.com> a �crit dans le message de news: 
> uvr3nGQLGHA.1124@TK2MSFTNGP10.phx.gbl...
>>I wonder if it's a manifest thing since the 2005 compiler does more with 
>>adding the manifest for you than the old one did.  Could be a conflict 
>>there.  I know I got a warning (even though I'm not linking yet - long 
>>story about libraries) so I haven't seen anything concrete.
>>
>> Tom
>>
>> "Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
>> news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
>>> Its white if you are running XP theme and some gray if you are running
>>> Classic Theme.
>>>
>>> ------
>>> Ajay Kalra
>>> ajaykalra@yahoo.com
>>>
>>
>>
>
> 


0
tserface (3860)
2/9/2006 3:32:02 PM
It is supposed to work that way. That gives the user the ability to set up 
what they want to use for colors, etc.  This was actually true on the older 
Windows, they just changed some of the default colors.

Tom

"nicolas ETIENNE" <nicolas.etienne@oktal.fr> wrote in message 
news:dsuor4$m1b$1@aphrodite.grec.isp.9tel.net...
> The problem is due to XP Theme.
>
> In fact, using "Windows Classic style" makes it looks like before...
>
> I just wish it could be possible to get the same result but being with XP 
> style...
>
> because if not , it means that the look and feel of my menus will be 
> different depending on what
> the user will have setup for its configuration ...
>
>
> Any issue ?
>
> Nicolas, Toulouse, France
>
>
>
>
> "Tom Serface" <tserface@msn.com> a �crit dans le message de news: 
> uvr3nGQLGHA.1124@TK2MSFTNGP10.phx.gbl...
>>I wonder if it's a manifest thing since the 2005 compiler does more with 
>>adding the manifest for you than the old one did.  Could be a conflict 
>>there.  I know I got a warning (even though I'm not linking yet - long 
>>story about libraries) so I haven't seen anything concrete.
>>
>> Tom
>>
>> "Ajay Kalra" <ajaykalra@yahoo.com> wrote in message 
>> news:1139429449.178387.232960@f14g2000cwb.googlegroups.com...
>>> Its white if you are running XP theme and some gray if you are running
>>> Classic Theme.
>>>
>>> ------
>>> Ajay Kalra
>>> ajaykalra@yahoo.com
>>>
>>
>>
>
> 


0
tserface (3860)
2/15/2006 4:22:56 PM
Reply:

Similar Artilces:

Override CMenu
Hi, i need to override a CMenu so to draw a Menu like the one used in VisualStudio .NET, DrawItem function let me to draw the items but what about the rest of Popup frame and MenuBar!? DrawItem doesn't work if OWNERDRAW style is missing, is it right!? In MS Sample they create another Menu and add items readed by the main window menu, than they attach it to Mainframe.. Is there another way!? Thanks.. Ale Look here for some good examples http://www.codeguru.com/menu/index.shtml Ali R. "Ale" <anonymous@discussions.microsoft.com> wrote in message news:036101c3bf67...

cmenu margine
Hello, anybody know if its possible to remove cmenu left margine, usually used for "check box" ? I need to have narrower menu. thanks "adamus" <ss@yahoo.com> wrote in message news:OqoSWZzqGHA.4992@TK2MSFTNGP05.phx.gbl... > Hello, > anybody know if its possible to remove cmenu left margine, > usually used for "check box" ? > I need to have narrower menu. > thanks My first guess would be SetMenuInfo and the MNS_NOCHECK style. -- Jeff Partch [VC++ MVP] thanks, I'll try that. "Jeff Partch" <jeffp@mvps.org> wrote in m...

Created a Logo in MP'03
I created a logo that is mainly words with a single clip art replacing one letter. It is 1 LARGE word with 3 smaller font words underneath. I want to be able to save this with a transparent background. I dont know how to import into something like photoshop and manipulate (dont have photoshop). Is it possible to save "off the white page" on publisher? I need to be able to send to an embroiderer without the white in back. Could I save the text box off the white area as a file without color behind? Any help greatly appreciated! Debbie momon2acres wrote: > I created a logo...

Printing Issues with Background Images
I have created a Background image that basically is a header and footer. I have a text box in the mid section of the page where text would be typed. It looks good and works the way I want it too when it is opened. However, when I go to print, I get multiple thumbnail size images duplicated all over the page. Any ideas on what I can do to fix this? I am using Word 2003...This is driving me crazy, please help! "KW45" wrote: > I have created a Background image that basically is a header and footer. I > have a text box in the mid section of the page where tex...

white screen
I am running a single module vba macro that downloads and sorts data into an excel spreadsheet. I am having white screen problems. When I get a white screen I cannot interrupt the code to see where the problem might be. and when I end process I lose all the data. It happens if I open other programs or after about 30mins of running. The program takes about 3 hours to run and is math intensive. Putting a msgbox in the code forces it out of the white screen but means i have to be at the computer to restart the code. Is there code to force the program out of white screen an all...

Change background color of inbound email
In Outlook 2007, I have from left to right, Mail - shows all inbound, sent, and mail folders, the next is my inbox, and the third is the actual email being show that is highlighted in my inbox. My problem is that some email when it is displayed can not be seen due to colors. 90 percent of my email is fine, but some email I can not read because of the font color, or the background color. I want to know how do I change the background color, or font color of a displayed email? A quick trick is to click somewhere in that message and then press CTRL+A. The message will then be shown...

How do I get rid of extra white space when row autofit is on?
When row autofit is on, I get a lot of extra white space above or below text in the cell with the most text. How do I get rid of it without manually adjusting every row? I don't get it for all the cells, but this might work for you... make the columnwidth just a bit wider--then autofit the rowheights. (It might just make the problem occur on different cells, though.) Jane wrote: > > When row autofit is on, I get a lot of extra white space above or below text > in the cell with the most text. How do I get rid of it without manually > adjusting every row? -- Dave Pe...

CMenu
Hi, I'm trying to add bitmaps to a CMenu object, but the bitmap is not proportionate (it's 32 x 16 pixels) so the text on the right of a menu item clips and covers half of the bitmap. This is basically what I've done in my code: //some variables are already initialized and declared but not shown m_thisFeatureBitmap.LoadBitmap(IDB_BITMAP_THIS_FEATURE); menu.LoadMenu(IDR_POPUP_FEATURE_MENU); popup = menu.GetSubMenu(0); popup->SetMenuItemBitmaps(ID_INSTALL_THIS, MF_BYCOMMAND, &m_thisFeatureBitmap, &m_thisFeatureBitmap); Any help is appreciated, Josh ...

Opens in Black & White
I received a publisher file in an e-mail and when I open it, it opens in black and white and it should open in color. Is there a setting that I should change, or do you have any clue why it opens in black and white? I am using Publisher 2003 Thanks! Amber :) Are you sure it was a color file to start with? I know, sounds like a dumb question but you need to rule out the obious things first. -- JoAnn Two things are aesthetically perfect in the world - the clock and the cat. --Emile-August Chartier "Amber" <anonymous@discussions.microsoft.com> wrote in...

CMenu::GetSubMenu
I have been given the task of temporarily maintaining an old MFC application. I got a debug assert caused by code that had used GetSubMenu( 0 ) and stored the pointer, then later on tried to use it. At the time the pointer was valid but later on it appeared to be a dangling pointer even though there was no apparent "delete" and the original menu was still in existence. I found a workaround: created a new CMenu object and attached the HMENU to it (which was still valid even after the lifetime of the submenu object). Before the parent menu was destroyed I detatched the HMENU again. ...

transparent background not working right
Hi I have a logo in CMYK colors, 300 dpi in tiff. format set for commercial printing. The problem I'm having is that i import it, then i go to the set transparent icon and the white background becomes transparent. The problem though is that even the white lettering becomes transparent. I've cut and pasted the logo it to a transparent background through photoshop but there is still a white background when I bring it in publisher. How can I make my logos background tranparent without making the letters transparent? -- Thanks a million! mJ wrote: > Hi I have a logo in CMY...

OWA, once logged in ONLY has white boackground and bkue center line
server is win2003, exchange2003, sp2. it doesn't happen to all users, seems like it only happens to some, mostly win2000 boxes. I'm the exchange admin and when I try to log on to owa with a problem box, my owa does the same thing. but when I use my laptop, no issue? AL ...

Transparent CMenu
Hello All, Does anyone have/know of an example on creating transparent popup windows using CMenu. I have searched high/low and come up with very little. Any information is appreciated. Thx in advance. look for "owner draw menus" -- Vipin Aravind http://www.explorewindows.com "Lost" <gormanst@saic.com> wrote in message news:1144532273.559604.163740@z34g2000cwc.googlegroups.com... > Hello All, > > Does anyone have/know of an example on creating transparent popup > windows using CMenu. I have searched high/low and come up with very > little. Any i...

Background page number
Can anyone tell me how to finally rid my spreadsheets of that annoyin background watermark page number? It shows a big over-powering "Pag 1" on the sheet. Must get rid of it. Please send some relief. I hav tried everything -- srcd ----------------------------------------------------------------------- srcdc's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=1554 View this thread: http://www.excelforum.com/showthread.php?threadid=27107 It appears that you are in the page break preview mode. Go to the view menu option and select 'Normal'. Th...

How do I duplicate background, bar colors, etc. to other charts?
I have 11 charts in one Workbook that tall need to have the same backgrounds, bar colors, fonts, etc. How can I customize one and then duplicate the customization on the other 10? I'm running Excel 2007. -- BWeech Hi, Save the customized chart as a template and then apply that to the other charts: 1. Chart Tools, Design, Save As Template... 2. with another chart selected choose Chart Tools, Design, Change Chart Type, Templates ... -- If this helps, please click the Yes button. Cheers, Shane Devenshire "BWeech" wrote: > I have 11 charts in one Workbook that tall...

How to resize background
Here goes my qustn I've tried to put an image as background in a worksheet but, it's size becomes too large. Is it possible to resize this image without change its own dimensions? Thanks to all -- LUIS ANTONIO MEDINA - C.P.T. MENUFazt - El Men� de Excel genial Configure Botones, Citas, Contactos, Correo electr�nico Obs�rvelo y desc�rguelo: http://www11.brinkster.com/LUISM0/ http://i.1asphost.com/luism0/ http://www.websamba.com/luism Email: luismedina@cable.net.co - luism0@yahoo.es Hi Luis not sure how you resize something without changing its dimensions - but you might like...

how do I set all my worksheet background colours to white?
How can I do this please? Chris Hi Chris, Here's two ways, Tools>Options>View tab and uncheck gridlines or Ctrl+A to select your entire spreadsheet then set the fill color to white. HTH Martin "CD" <CD@discussions.microsoft.com> wrote in message news:12C149AB-3E6C-4CDB-88AB-6D0A098B2B3B@microsoft.com... > How can I do this please? > Chris > I should add that setting your entire worksheet to have a white fill color is not a good idea, better to just select the area that you need if you are going to use this method. HTH Martin "MartinW"...

CMenu with images
Hi, I am having a CMenu created on the fly and in that menu I am showing all open windows. I am able to get the name of the opened window that I am puting in the menu. now I need to have icons of the opened windows to show up in the popup menu. please let me know how to do it. Also please let me know what attributes (flags to set tio show images with menu items) thanks Anup > I am having a CMenu created on the fly and in that menu I am showing > all open windows. > I am able to get the name of the opened window that I am puting in the > menu. > > now I need to have ic...

Can Publisher be used to print directly on white CD's or DVD's?
I have an Epson 810 printer that can print directly on the disc for labeling. Their software is terrible. They suggest a half dozen others, but not Publisher. I have hundreds of labels (for paper stick on labels) already made in Publisher for previous projects. Is there any way to use them with the Epson? More importantly, is there a way to use Publisher 2007 to print/label directly on a white labeled (printable) disc for new projects? Thanks for any help or suggestions. Leo Have you tried? I know nothing about printing directly onto a disk, but I do know you can setup...

White paper for Microsoft CRM
Hi, If possible, I would appreciate a white paper for Microsoft CRM. Thanks in advance, Jonas Edlund jonas_edlund@msn.com There are quite a few of them at www.mscrmexperts.com "Jonas Edlund" <Jonas Edlund@discussions.microsoft.com> wrote in message news:64DA0784-A009-4D13-9F9A-A3D6ABD64CB1@microsoft.com... > Hi, > > If possible, I would appreciate a white paper for Microsoft CRM. > > Thanks in advance, > Jonas Edlund > > jonas_edlund@msn.com > ...

Vista x64, computer only shows background
Whenever I start up my computer, all I see is my background. No icons, no start bar, nothing. If I press ctrl+alt+delete, all I see is a black screen (pressing escape goes back to my background.) I literally JUST installed mass effect 2 and tried to restart to fix another problem with the game not starting when this problem appeared. Any quick help would be appreciated. -- docwalrus Restore point to before the install of the game. "docwalrus" <guest@unknown-email.com> wrote in message news:386edd2398d324b6c8f134bcfa463cfb@nntp-gateway.com... > > Whe...

resource ID of a CMenu object
Hi, Given a CMenu object, is it possible to get a resource ID for it? For instance, in the OnInitMenuPopup() function, we're passed: void CMainFrame::OnInitMenuPopup(CMenu* pPopupMenu, UINT nIndex, BOOL bSysMenu) { } Is there a way to do something like: DWORD dwResId = pPopupMenu->GetResourceId(); ??? I need to find that resource ID to dynamically modify a toolbar on the mainframe menu, and this is the only way I can think to uniquely identify one menu over another. Thanks markww wrote: > Hi, > > Given a CMenu object, is it possible to get a resource ID for it? F...

Colours change to black & white for one user only
I have designed an Access 2003 application that has several forms with different coloured backgrounds. I also have warning text messages in red. Most users can run my application without any problem. However, one user gets what is an almost monochrome version of my interface. The red text comes out as black. The coloured backgrounds are either white or light grey. She is running Windows XP on a Dell laptop. Display settings are for 'true color'. I have not had the time to do a side by side comparison with a 'normal' PC, but I suspect that some websites are displaying wi...

Problem with CMenu
Hi all... In a CMDIChildWnd-derived class I have a pop-up menu that appears when the user right-clicks over a tree ctrl.. One of the menu items is a pop-up menu that I create dynamically. The problem I have is that all new items appears disabled when the pop-up appears. I'm filling the menu in BOOL CChildFrame::OnCreateClient handler this way: m_Menu.LoadMenu(IDR_CONSOLA_POPUP); // Llena los estados en el men� pop-up de negocios m_StatusMenu.CreatePopupMenu(); m_Menu.GetSubMenu(0)->ModifyMenu(4,MF_BYPOSITION|MF_POPUP, (UINT)m_StatusMenu.GetSafeHmenu(), "Estado"); if(...

How do I remove the page number from the background of my excel w.
When working in Excel, the background page number is always obscuring my work. Can it be removed? Hi goto 'View' and choose the normal view. You currently have the 'Pagebreak view' enabled -- Regards Frank Kabel Frankfurt, Germany "NancyLyons" <NancyLyons@discussions.microsoft.com> schrieb im Newsbeitrag news:4476930A-38E1-4BAD-89D1-79DBA1E17B38@microsoft.com... > When working in Excel, the background page number is always obscuring my > work. Can it be removed? Maybe go View and check Normal instead of Page Break Preview, Regards, "NancyLyons...