Click here to Skip to main content
15,892,643 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Menu item font resizing Pin
enhzflep15-Jul-14 22:34
enhzflep15-Jul-14 22:34 
QuestionDraggin and dropping functionality in windows 8 environment Pin
Member 377895414-Jul-14 2:31
Member 377895414-Jul-14 2:31 
AnswerRe: Draggin and dropping functionality in windows 8 environment Pin
Richard MacCutchan14-Jul-14 5:19
mveRichard MacCutchan14-Jul-14 5:19 
QuestionRe: Draggin and dropping functionality in windows 8 environment Pin
Member 377895414-Jul-14 18:22
Member 377895414-Jul-14 18:22 
AnswerRe: Draggin and dropping functionality in windows 8 environment Pin
Richard MacCutchan14-Jul-14 22:00
mveRichard MacCutchan14-Jul-14 22:00 
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Member 377895415-Jul-14 19:03
Member 377895415-Jul-14 19:03 
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Richard MacCutchan15-Jul-14 22:06
mveRichard MacCutchan15-Jul-14 22:06 
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Member 377895416-Jul-14 21:36
Member 377895416-Jul-14 21:36 
Hi Richard,

I have added below lines of code in my App class init function to make the application aware of DPI settings.

HMODULE hUser32 = LoadLibrary(_T("user32.dll"));
typedef BOOL (*SetProcessDPIAwareFunc)();
SetProcessDPIAwareFunc setDPIAware = (SetProcessDPIAwareFunc)GetProcAddress(hUser32, "SetProcessDPIAware");
if (setDPIAware)
setDPIAware();
FreeLibrary(hUser32);



User32.dll library is present in "System" folder of windows directory.


After adding the above code, my application is now scaling according to DPI settings but menu items font size is increased too much so that it is hiding behind the toolbar.

Menu bar is created by default as it is created in a MDI application.

if(!m_wndMenuBar.Create(this))
{
TRACE0("Failed to create menubar\n");
return -1;
}


When application get scaled automatically based on DPI settings (Larger 150%), menu bar text become large and hide behind the toolbar.

Any help would be appreciated.

Regards,
Aniket
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Richard MacCutchan16-Jul-14 22:35
mveRichard MacCutchan16-Jul-14 22:35 
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Member 377895417-Jul-14 19:33
Member 377895417-Jul-14 19:33 
GeneralRe: Draggin and dropping functionality in windows 8 environment Pin
Richard MacCutchan17-Jul-14 22:28
mveRichard MacCutchan17-Jul-14 22:28 
QuestionPass Image or text data from MFC to c# application Pin
low198813-Jul-14 6:56
low198813-Jul-14 6:56 
AnswerRe: Pass Image or text data from MFC to c# application Pin
Albert Holguin14-Jul-14 6:33
professionalAlbert Holguin14-Jul-14 6:33 
QuestionView with color txt added automatically by one thread,No flash and auto scrolling Pin
PaulKvm9-Jul-14 20:59
PaulKvm9-Jul-14 20:59 
SuggestionRe: View with color txt added automatically by one thread,No flash and auto scrolling Pin
Richard MacCutchan9-Jul-14 23:39
mveRichard MacCutchan9-Jul-14 23:39 
AnswerRe: View with color txt added automatically by one thread,No flash and auto scrolling Pin
leon de boer11-Jul-14 2:36
leon de boer11-Jul-14 2:36 
Questionsendto problem Pin
Member 103497468-Jul-14 22:47
Member 103497468-Jul-14 22:47 
SuggestionRe: sendto problem Pin
Richard MacCutchan8-Jul-14 23:16
mveRichard MacCutchan8-Jul-14 23:16 
AnswerRe: sendto problem Pin
leon de boer11-Jul-14 3:00
leon de boer11-Jul-14 3:00 
QuestionAbout Sobel operator in Image Processing Pin
Sweety088-Jul-14 11:22
Sweety088-Jul-14 11:22 
QuestionRe: About Sobel operator in Image Processing Pin
David Crow8-Jul-14 17:09
David Crow8-Jul-14 17:09 
AnswerRe: About Sobel operator in Image Processing Pin
Chris Losinger10-Jul-14 4:57
professionalChris Losinger10-Jul-14 4:57 
QuestionSuitable Application type in VS2008 for my Purpose Pin
manoharbalu6-Jul-14 19:53
manoharbalu6-Jul-14 19:53 
AnswerRe: Suitable Application type in VS2008 for my Purpose Pin
Richard MacCutchan6-Jul-14 20:46
mveRichard MacCutchan6-Jul-14 20:46 
QuestionWinsock Event Select Model Pin
Richard Andrew x645-Jul-14 20:54
professionalRichard Andrew x645-Jul-14 20:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.