|
|
Comments and Discussions
|
|
 |

|
Thank you for your reply. I do find that I get depracation warnings related to the use of various buffer functions. If I don't want to switch the depracation warnings off it means I have to resolve these issues.
Is it not possible for a "out of the box" VS2005 build to be made available?
Thanks.
|
|
|
|

|
I am working with Greek Unicode characters on Vista. I discovered that on Vista, when the "Current language for the non-unicode programs" is set to English, the Unicode menus with Greek characters appear truncated i.e. the words have been cut at the end, with whole words missing some times.
BCMenu predates the release of MS Vista, and digging into the code I discovered that it has a function with the name
Win32Type IsShellType()
which determines the OS type that is used. As it predates Vista, when is run on Vista it defaults to WINNT3! And this causes all the problems. I have changed the function so when run under MS Vista (or any future versions MS Windows) it returns WINXP as the OS type. This has solved the problem of the truncated menu width.
Now all the tests when run on a 32bit Vista installation. The change most probably will work also for Vist 64-bit.
I include the changed code of the function for your reference:
Win32Type IsShellType()
{
Win32Type ShellType;
DWORD winVer;
OSVERSIONINFO *osvi;
winVer=GetVersion();
if(winVer<0x80000000){/*NT */
osvi= (OSVERSIONINFO *)malloc(sizeof(OSVERSIONINFO));
if (osvi!=NULL){
memset(osvi,0,sizeof(OSVERSIONINFO));
osvi->dwOSVersionInfoSize=sizeof(OSVERSIONINFO);
GetVersionEx(osvi);
if(osvi->dwMajorVersion==3L)ShellType=WinNT3;
else if(osvi->dwMajorVersion==4L)ShellType=WinNT4;
else if(osvi->dwMajorVersion==5L&&osvi->dwMinorVersion==0L)ShellType=Win2000;
else if(osvi->dwMajorVersion==5L&&osvi->dwMinorVersion==1L)ShellType=WinXP;
else if(osvi->dwMajorVersion==6L&&osvi->dwMinorVersion==0L)ShellType=WinXP; //- Windows Vista
else ShellType=WinXP; //- For future versions of Windows default to WinXP
free(osvi);
}
}
else if (LOBYTE(LOWORD(winVer))<4)
ShellType=Win32s;
else{
ShellType=Win95;
osvi= (OSVERSIONINFO *)malloc(sizeof(OSVERSIONINFO));
if (osvi!=NULL){
memset(osvi,0,sizeof(OSVERSIONINFO));
osvi->dwOSVersionInfoSize=sizeof(OSVERSIONINFO);
GetVersionEx(osvi);
if(osvi->dwMajorVersion==4L&&osvi->dwMinorVersion==10L)ShellType=Win98;
else if(osvi->dwMajorVersion==4L&&osvi->dwMinorVersion==90L)ShellType=WinME;
free(osvi);
}
}
return ShellType;
}
|
|
|
|

|
In Demo "BCDialogMenu303".Although the LoadToolbar() function is called , but there wasn't any toolbar show on the dialog. why?
...
m_menu.LoadMenu(IDR_MYTYPE);
m_menu.LoadToolbar(IDR_MAINFRAME);
m_menu.LoadToolbar(IDR_TOOLBAR);
SetMenu(&m_menu);
...
|
|
|
|

|
how to store the data in the database using an mfc AppWizard
vivek rai
|
|
|
|

|
Hello,
Do you know of an web article describing how somebody can imitate the painting of the highlighted menu items background?
1. highlighted menu items in normal applications running on Microsoft Vista (e.g NotePad ) have a nice blue background
2. highlighted menu items in Office 2007 (on Windows XP and Windows Vista, doesn't matter, the menu looks the same) have a nice "reflecting light" orange gradient.
By reading various articles, I've seen two approaches:
- Use themes API functions like DrawThemeBackground(). Is this possible for menus ?
Or
- Use gradient API functions like GradientFill() with GRADIENT_FILL_RECT_V?
In this case, by applying this function twice with different limiting colors for the first half and the second half of the button would produce something aproximating the "reflecting light" gradient we are seeing in Office 2007)
I would like to know how the Microsoft programmers implemented these menus.
Thanks a lot.
-- modified at 19:58 Sunday 1st April, 2007
|
|
|
|

|
Hi
Any idea of how theme support can be added to the menus.
menus looks better on vista & worth utilising them.
Regards
|
|
|
|

|
Any update on this request?
Andy
|
|
|
|

|
I'm not able to append/insert top level menu item using the POPUP flag. This behaviour works fine with CMenu, and when i use ....
BOOL InsertMenu( UINT nPosition, UINT nFlags, UINT_PTR nIDNewItem = 0, LPCTSTR lpszNewItem = NULL );
with nIDNewItem as 0, BCMenu assumes it as a separator, instead of a top level item.
Please help me with this.
Thanks.
|
|
|
|

|
Hi
Let me say thanks first for this wonderful help .
I am using this code to my SDI application. I am using 3.03 version of bcmenu.
I am facing the problem appling the true color bitmap strip at menubar. My strip background color is RGB(192,192,192) and Even i ve set the function SetBitmapbackground(RGB(192,192,192)). But still it is not showing the transparent background colors of menubar
Thx
ND
|
|
|
|

|
have created an owner drawn menu item and done required drawing in the
DrawItem function. The drawing code works as I expected bu the problems is a
box appearing outside the menu. how can I remove it? please see the following
pictured to see the output.
http://static.flickr.com/98/248788817_5aca6ca4f1_o.jpg[^]
-Sarath.
"Great hopes make everything great possible" - Benjamin Franklin
|
|
|
|
 |
|
|
General News Suggestion Question Bug Answer Joke Rant Admin
|
This class implements an owner drawn menu class that mimics the menu style used in XP, Office and Visual C++
| Type | Article |
| Licence | CPOL |
| First Posted | 18 Nov 1999 |
| Views | 758,475 |
| Downloads | 13,620 |
| Bookmarked | 263 times |
|
|