In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
What are the three member variables of the VS Ribbon interface? for this question, this article introduces the corresponding analysis and solution in detail, hoping to help more partners who want to solve this problem to find a more simple and feasible way.
Visual C++ has a lot to learn. Here we mainly introduce the VS Ribbon interface, including the composition of the Ribbon interface. In order to support the development of new interface styles, MFC provides a lot of new and extended application classes, interface classes and so on. For example, the CRibbonApp,CMainFrame used in our example program is derived from CWinAppEx,CMDIFrameWndEx respectively.
CWinAppEx and CMDIFrameWndEx are derived from traditional CWinApp and CMDIFrameWnd, adding support for new interface styles on the basis of the original classes.
Friends who are familiar with MFC interface development know that the CMainFrame class of the application is responsible for the creation and management of the entire main framework interface. In the traditional menu interface, it is responsible for creating and managing menu bars, status bars, toolbars and so on. Similarly, under the VS Ribbon interface, it is also responsible for the creation and management of the VS Ribbon interface.
Class CMainFrame: public CMDIFrameWndEx {DECLARE_DYNAMIC (CMainFrame) public: CMainFrame (); / / Attributes public: / / Operations public: / / Overrides public: virtual BOOL PreCreateWindow (CREATESTRUCT& cs); / / Implementation public: virtual ~ CMainFrame (); # ifdef _ DEBUG virtual void AssertValid () const; virtual void Dump (CDumpContext& dc) const; # endif protected:// control bar embedded members CMFCRibbonBar massiwndRibbonBar. CMFCRibbonApplicationButton MainButton; CMFCToolBarImages massively PanelImages; CMFCRibbonStatusBarm_wndStatusBar / / Generated message map functions protected: afx_msg int OnCreate (LPCREATESTRUCT lpCreateStruct); afx_msg void OnWindowManager (); afx_msg void OnApplicationLook (UINT id); afx_msg void OnUpdateApplicationLook (CCmdUI* pCmdUI); DECLARE_MESSAGE_MAP () void InitializeRibbon ();}
As we can see from the above code, under the VS Ribbon interface, the CMainFrame class contains three member variables: m_wndRibbonBar, m_MainButton, and m_wndStatusBar, which are used to control the command panel of the VS Ribbon interface, the application button, and the status bar. Once we know the VS Ribbon interface elements corresponding to each variable, we can manipulate the corresponding member variables to add what we need to the VS Ribbon interface.
This is the answer to the question about what the three member variables of the VS Ribbon interface are. I hope the above content can be of some help to you. If you still have a lot of doubts to be solved, you can follow the industry information channel to learn more about it.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.