Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Menu is not expanding to it full extend
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Menu is not expanding to it full extend

 Post Reply Post Reply
Author
Message
KumarCJ View Drop Down
Groupie
Groupie
Avatar

Joined: 02 April 2007
Location: India
Status: Offline
Points: 96
Post Options Post Options   Thanks (0) Thanks(0)   Quote KumarCJ Quote  Post ReplyReply Direct Link To This Post Topic: Menu is not expanding to it full extend
    Posted: 24 April 2007 at 2:39am
Hi,
 
Thanks for your reply, my concern is below:
 
The Edit menu looks like below
 
Cut       ctrl+x
Copy    ctrl+c
Paste   ctrl+v
 
But for the edit menu, system is displaying
 
Cut       square box in front of Cut
Copy    square box in front of Copy
Paste   square box in front of Paste
 
it is not displaying, ctrl+x, ctrl+c, ctrl+v for Cut, Copy, Paste.
 
I checked with privious version of application exe, the issue is "Edit" menu is not able expand to it full extend and some thing happening with one more menu.
 
 
pls let me why this is happening.
 
Here is the code what i had added for Code jock 10.4.2
 
int CMainFrame::OnCreate()
{
   // Initialize the command bars
   if (!InitCommandBars())
   return -1;
   // Get Commandbar
   CXTPCommandBar* pCommandBars = GetCommandBars();
   // Create MenuBar using CXTPMenuBar*
   CXTPMenuBar* m_wndMenuBar = pCommandBars->SetMenu(_T("Menu Bar"),  IDR_MAINFRAME);
  if(m_wndMenuBar == NULL)
  {
       TRACE0("Failed to create menu bar.\n");
       return -1;      // fail to create
  }
  m_wndMenuBar->SetFlags(xtpFlagAddMDISysPopup);
 
// Create ToolBar
    CXTPToolBar* m_wndToolBar = (CMCToolBar *) pCommandBars->Add(_T(g_cmcstandard), xtpBarTop);
    if (!m_wndToolBar || !m_wndToolBar->LoadToolBar(IDR_MAINFRAMELO))
    {
        TRACE0("Failed to create toolbar\n");
        return -1;
    }
 
m_wndToolBar->EnableDocking(xtpFlagAlignAny | xtpFlagFloating);
 EnableDocking(CBRS_ALIGN_ANY);
 
CXTPPaintManager::SetTheme(xtpThemeOffice2003);
}
 
 
Is i need add something which is going to expand the menu to its full extend?
 
waiting for your reply.
 
Thanks,
Saket Kumar.
 
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 24 April 2007 at 7:10am
Hi,
 
Call pCommandBars->GetShortcutManager()->SetAccelerators(IDR_RESOURCE);
where IDR_RESOURCE is accelerator table from your resources. (Check that it has accelerators for Cut/Copy etc)
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
KumarCJ View Drop Down
Groupie
Groupie
Avatar

Joined: 02 April 2007
Location: India
Status: Offline
Points: 96
Post Options Post Options   Thanks (0) Thanks(0)   Quote KumarCJ Quote  Post ReplyReply Direct Link To This Post Posted: 24 April 2007 at 8:25am
Thanks alot Oleg for your reply.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.047 seconds.