2023年全國碩士研究生考試考研英語一試題真題(含答案詳解+作文范文)_第1頁
已閱讀1頁,還剩50頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權說明:本文檔由用戶提供并上傳,收益歸屬內容提供方,若內容存在侵權,請進行舉報或認領

文檔簡介

1、<p><b>  MFC/C++</b></p><p>  Adding a docking pane to your application</p><p>  Author: Kirk Stowell</p><p>  Posted: November 16, 2007</p><p>  Envir

2、onment:Visual C++ MFC</p><p>  The following is a tutorial on how to create an MDI application with Docking Pane using the Visual Studio 6.0 Application Wizard. The same technique can be used for later versi

3、ons of Visual Studio . NET as well.</p><p>  Create a simple MDI application using the MFC AppWizard:</p><p>  From Visual Studio select ‘File’ then ‘New’ and select the ‘Projects’ tab.</p>

4、;<p>  Choose MFC Appwizard(exe) as your project type and enter ‘MDISample’ as the project name.</p><p>  For the first step, make sure that "Multiple documents" is selected then press the ‘

5、Finish’ button.</p><p>  Add Empty Docking Pane</p><p>  Add the following line to your StdAfx.h file: </p><p>  Xtreme Toolkit Pro users:</p><p>  #include <XTToolk

6、itPro.h> // Xtreme Toolkit Pro components</p><p>  Xtreme DockingPane users:</p><p>  #include <XTDockingPanePro.h> // Xtreme DockingPane components</p><p>  Add CXTPDockin

7、gPaneManager member to CMainFrame class.</p><p>  // Attributes</p><p><b>  public:</b></p><p>  CXTPDockingPaneManager m_paneManager;</p><p>  Add string r

8、esources for the titles of the future panes</p><p>  IDR_PANE_OPTIONS</p><p><b>  61446</b></p><p><b>  Options</b></p><p>  PROPERTIES</p>

9、;<p><b>  61447</b></p><p>  Properties</p><p>  Add following to CMainFrame::OnCreate.</p><p>  // Initialize the docking pane manager and set the</p><

10、;p>  // initial them for the docking panes. Do </p><p>  // this only after all control bars objects have been </p><p>  // created and docked.</p><p>  m_paneManager.InstallDoc

11、kingPanes(this);</p><p>  m_paneManager.SetTheme(xtpPaneThemeOffice);</p><p>  // Create docking panes.</p><p>  CXTPDockingPane* pwndPane1 = m_paneManager.CreatePane(</p>&l

12、t;p>  IDR_PANE_OPTIONS, CRect(0, 0,200, 120), dockLeftOf);</p><p>  CXTPDockingPane* pwndPane2 = m_paneManager.CreatePane(</p><p>  IDR_PANE_PROPERTIES, CRect(0, 0,200, 120),</p><p

13、>  dockBottomOf, pwndPane1);</p><p>  Attach CWnd derived class to the panes:</p><p>  Add Cwnd derived class as member of CMainFrame.</p><p>  // Attributes</p><p>

14、<b>  public:</b></p><p>  CStatic m_wndOptions;</p><p>  CEdit m_wndProperties;</p><p><b>  </pre></b></p><p>  <li>Add OnDockingPan

15、eNotify handler.</li></p><p>  <pre class="code"></p><p>  BEGIN_MESSAGE_MAP(CMainFrame, CMDIFrameWnd)</p><p>  //{{AFX_MSG_MAP(CMainFrame)</p><p>

16、;  ON_WM_CREATE()</p><p>  //}}AFX_MSG_MAP</p><p>  ON_MESSAGE(XTPWM_DOCKINGPANE_NOTIFY,</p><p>  OnDockingPaneNotify)</p><p>  END_MESSAGE_MAP()</p><p>  

17、LRESULT CMainFrame::OnDockingPaneNotify(WPARAM</p><p>  wParam, LPARAM lParam)</p><p><b>  {</b></p><p>  if (wParam == XTP_DPN_SHOWWINDOW)</p><p><b>

18、  {</b></p><p>  CXTPDockingPane* pPane =</p><p>  (CXTPDockingPane*)lParam;</p><p>  if (!pPane->IsValid())</p><p><b>  {</b></p><p>

19、  switch (pPane->GetID())</p><p><b>  {</b></p><p>  case IDR_PANE_PROPERTIES:</p><p>  { </p><p><b>  if (</b></

20、p><p>  m_wndProperties.GetSafeHwnd() == 0)</p><p><b>  {</b></p><p>  m_wndProperties.Create(WS_CHILD|</p><p>  ES_AUTOVSCROLL|ES_MULTILINE,</p><p&

21、gt;  CRect(0, 0, 0, 0), this, 0);</p><p><b>  }</b></p><p>  pPane->Attach(&m_wndProperties);</p><p><b>  break;</b></p><p><b>  }&

22、lt;/b></p><p>  case IDR_PANE_OPTIONS:</p><p>  { </p><p>  if (m_wndOptions.GetSafeHwnd() == 0)</p><p><b>  {</b></p>&l

23、t;p>  m_wndOptions.Create(_T("\n\nOptions"),</p><p>  WS_CHILD|WS_CLIPCHILDREN|</p><p>  WS_CLIPSIBLINGS|SS_CENTER,</p><p>  CRect(0, 0, 0, 0), this, 0);</p><

24、;p><b>  }</b></p><p>  pPane->Attach(&m_wndOptions);</p><p><b>  break;</b></p><p><b>  }</b></p><p><b>  }</b>

25、;</p><p><b>  }</b></p><p>  return TRUE;</p><p><b>  }</b></p><p>  return FALSE;</p><p><b>  }</b></p><p&g

26、t;  Add image to pane.</p><p>  Create Bitmap with icons for created panes</p><p>  Add to CMainFrame::OnCreate.</p><p>  nt nIDIcons[] = {IDR_PANE_OPTIONS, IDR_PANE_PROPERTIES};<

27、;/p><p>  m_paneManager.SetIcons(IDB_BITMAP_ICONS, nIDIcons,</p><p>  _countof(nIDIcons), RGB(0, 255, 0));</p><p>  Add Save/Load State</p><p>  Add following to the OnCre

28、ate function for CMainFrame. This will restore the previous state of docking panes.</p><p>  int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)</p><p><b>  {</b></p><

29、p><b>  ...</b></p><p>  // Load the previous state for docking panes.</p><p>  CXTPDockingPaneLayout layoutNormal(&m_paneManager);</p><p>  if (layoutNormal.Load(

30、_T("NormalLayout")))</p><p><b>  {</b></p><p>  m_paneManager.SetLayout(&layoutNormal);</p><p><b>  }</b></p><p><b>  return

31、 0;</b></p><p><b>  }</b></p><p>  Add the OnClose message handler to CMainFrame and the following before the call to the base class. This will save the current state of your d

32、ocking pane.</p><p>  void CMainFrame::OnClose()</p><p><b>  {</b></p><p>  // Save the current state for docking panes.</p><p>  CXTPDockingPaneLayout layo

33、utNormal(&m_paneManager);</p><p>  m_paneManager.GetLayout(&layoutNormal);</p><p>  layoutNormal.Save(_T("NormalLayout"));</p><p>  CMDIFrameWnd::OnClose();</p&

34、gt;<p><b>  }</b></p><p>  Outlook Style Menu and Pager Control</p><p>  Author: Kirk Stowell</p><p>  Posted: November 16, 2007</p><p>  Environment

35、:Visual C++ MFC</p><p>  Downloads:</p><p>  PagerDemo.zip - Source Files with Demo Project [66.10 KB]</p><p>  PagerDemoSrc.zip - Source Files Only [8.64 KB]</p><p>  

36、The CXTOutlookBar class is a CListBox derived class that implements a Outlook style control. The CXTPagerCtrl class is used to contain and scroll the CXTOutlookBar window. This class wraps the windows pager API. Bot

37、h classes are fairly easy to use and can be used the same way you would any standard MFC control.</p><p>  This example was created using a standard MFC SDI application, two CView derived classes COutbarView

38、 ( the left view ) and CPagerView and a splitter window. The left view is used to contain the pager and Outlook style controls. To use these controls, add a member variable for each to the COutbarView class, for example:

39、</p><p>  // Attributes</p><p>  protected:</p><p>  CXTOutlookBar m_wndOutlookBar;</p><p>  CXTPagerCtrl m_wndPager;</p><p>  Next add a WM_CREATE messag

40、e handler to COutbarView. This is where we will create the pager and Outlook menu. Here we will also initialize the Outlook menu by adding menu items to the control and set pager button size and child window.</p>

41、<p>  int COutbarView::OnCreate(LPCREATESTRUCT lpCreateStruct)</p><p><b>  {</b></p><p>  if (CView::OnCreate(lpCreateStruct) == -1)</p><p>  return -1;</p>

42、<p>  // Create the pager control.</p><p>  if (!m_wndPager.Create(WS_CHILD|WS_VISIBLE|PGS_VERT,</p><p>  CRect(0,0,0,0), this, IDC_PAGER_CTRL ))</p><p><b>  {</b>

43、</p><p>  TRACE0("Failed to create CPagerCtrl...\n");</p><p>  return -1;</p><p><b>  }</b></p><p>  // Create the OutlookBar control using m_wndP

44、ager as the</p><p>  // parent.</p><p>  if (!m_wndOutlookBar.Create( WS_CHILD | WS_VISIBLE |</p><p>  WS_TABSTOP, CRect(0,0,0,0), &m_wndPager, IDC_OUTBAR))</p><p>

45、<b>  {</b></p><p>  TRACE0("Failed to create COutlookBar...\n");</p><p>  return -1;</p><p><b>  }</b></p><p>  // Set the CWnd object

46、 you want messages sent to.</p><p>  m_wndOutlookBar.SetOwner(this);</p><p>  m_wndOutlookBar.SetColors(RGB(0xff,0xff,0xff),</p><p>  RGB(0x3a,0x6e,0xa5));</p><p>  //

47、Add items to the Outlook Bar control.</p><p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_OUTLOOK, _T("Outlook Today"));</p><p>  m_wndOutlookBar.AddMenuItem(</p>

48、;<p>  IDI_ICON_CONTACTS, _T("Contacts"));</p><p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_TASKS, _T("Tasks"));</p><p>  m_wndOutlookBar.AddMenuIt

49、em(</p><p>  IDI_ICON_JOURNAL, _T("Journal"));</p><p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_NOTES, _T("Notes"));</p><p>  m_wndOutlookBar

50、.AddMenuItem(</p><p>  IDI_ICON_DELETED, _T("Deleted Items"));</p><p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_PUBLIC, _T("Public"));</p><p>

51、;  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_DRAFTS, _T("Drafts"));</p><p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_OUTBOX, _T("Outbox"));</p>

52、<p>  m_wndOutlookBar.AddMenuItem(</p><p>  IDI_ICON_SENT, _T("Sent"));</p><p>  // Insert menu items at a specific index.</p><p>  m_wndOutlookBar.InsertMenuItem(&

53、lt;/p><p>  1, IDI_ICON_INBOX, _T("Inbox"));</p><p>  m_wndOutlookBar.InsertMenuItem(</p><p>  2, IDI_ICON_CALENDAR, _T("Calendar"));</p><p>  // Set t

54、he child HWND to COutlookBar, and button size to 15.</p><p>  m_wndPager.SetChild(m_wndOutlookBar.GetSafeHwnd());</p><p>  m_wndPager.SetButtonSize(15);</p><p><b>  return 0;&

55、lt;/b></p><p><b>  }</b></p><p>  Next we will add a WM_SIZE message handler, this will ensure that our pager control will be correctly positioned whenever the view is resized. Y

56、ou can use the class wizard to do this.</p><p>  void COutbarView::OnSize(UINT nType, int cx, int cy)</p><p><b>  {</b></p><p>  CView::OnSize(nType, cx, cy);</p>

57、<p>  if(m_wndPager.GetSafeHwnd()) {</p><p>  m_wndPager.MoveWindow(0,0,cx,cy);</p><p><b>  }</b></p><p><b>  }</b></p><p>  Our final tas

58、k will be to add the PGN_SCROLL and PGN_CALCSIZE message handlers for the pager control. This will notify us when the pager is being scrolled and allow us to set the scrollable size of the Outlook menu window. In additio

59、n to the PGN_ handlers, we will need to add a XTWM_OUTBAR_NOTIFY message handler. This will notify us whenever the user clicks an item in the Outlook menu. In the .cpp file for COutbarView, add the following to the messa

60、ge map:</p><p>  BEGIN_MESSAGE_MAP(COutbarView, CView)</p><p>  //{{AFX_MSG_MAP(COutbarView)</p><p>  ON_WM_SIZE()</p><p>  ON_WM_CREATE()</p><p>  ON_MESS

61、AGE( XTWM_OUTBAR_NOTIFY, OnOutbarNotify )</p><p>  //}}AFX_MSG_MAP</p><p>  ON_NOTIFY(PGN_SCROLL, IDC_PAGER_CTRL, OnPagerScroll)</p><p>  ON_NOTIFY(PGN_CALCSIZE, IDC_PAGER_CTRL, On

62、PagerCalcSize)</p><p>  END_MESSAGE_MAP()</p><p>  And the following member functions to the .cpp...</p><p>  void COutbarView::OnPagerCalcSize(</p><p>  NMHDR* pNMHDR,

63、 LRESULT* pResult)</p><p><b>  {</b></p><p>  NMPGCALCSIZE* pNMPGCalcSize = (NMPGCALCSIZE*)pNMHDR;</p><p>  *pResult = 0;</p><p>  switch(pNMPGCalcSize->

64、dwFlag)</p><p><b>  {</b></p><p>  case PGF_CALCWIDTH:</p><p><b>  break;</b></p><p>  case PGF_CALCHEIGHT:</p><p>  pNMPGCalcSize-

65、>iHeight = m_wndOutlookBar.GetCount()</p><p>  *(::GetSystemMetrics(SM_CYICON)*2);</p><p><b>  break;</b></p><p><b>  }</b></p><p><b> 

66、 }</b></p><p>  void COutbarView::OnPagerScroll(NMHDR* pNMHDR, LRESULT* pResult)</p><p><b>  {</b></p><p>  NMPGSCROLL* pNMPGScroll = (NMPGSCROLL*)pNMHDR;</p>

67、;<p>  *pResult = 0;</p><p><b>  }</b></p><p>  LRESULT COutbarView::OnOutbarNotify(UINT lParam, LONG wParam)</p><p><b>  {</b></p><p>  

68、switch( wParam ) // control id.</p><p><b>  {</b></p><p>  case IDC_OUTBAR:</p><p><b>  {</b></p><p>  // Get the menu item.</p><p>

69、;  XT_CONTENT_ITEM* pContentItems =</p><p>  m_wndOutlookBar.GetMenuItem((int)lParam);</p><p>  ASSERT(pContentItems);</p><p>  AfxMessageBox(pContentItems->m_strText);</p>

70、<p><b>  }</b></p><p><b>  break;</b></p><p><b>  }</b></p><p><b>  return 0;</b></p><p><b>  }</b>&l

71、t;/p><p>  and header file.</p><p>  // Generated message map functions</p><p>  protected:</p><p>  //{{AFX_MSG(COutbarView)</p><p>  afx_msg void OnSize(UIN

72、T nType, int cx, int cy);</p><p>  afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);</p><p>  afx_msg LRESULT OnOutbarNotify(UINT lParam, LONG wParam);</p><p>  //}}AFX_MSG</p

73、><p>  afx_msg void OnPagerScroll(</p><p>  NMHDR* pNMHDR, LRESULT * pResult);</p><p>  afx_msg void OnPagerCalcSize(</p><p>  NMHDR* pNMHDR, LRESULT* pResult);</p>

74、<p>  DECLARE_MESSAGE_MAP()</p><p>  And that should just about do it. If you are using Visual C++ 5 you will need to install the latest platform SDK for Visual C++ 5 to use the pager control...have f

75、un!</p><p>  Office Style Toolbars and Menus</p><p>  Author: Kirk Stowell</p><p>  Posted: November 16, 2007</p><p>  Environment:Visual C++ MFC</p><p>  

76、The following is a tutorial on how to create an MDI application using the Visual Studio 6.0 Application Wizard that will have Office style menus and toolbars. The same technique can be used for later versions of Visual S

77、tudio .NET as well.</p><p>  Create a simple MDI application using the MFC AppWizard:</p><p>  From Visual Studio and select ‘File’ then ‘New’ and select the ‘Projects’ tab.</p><p>

78、  Choose MFC Appwizard(exe) as your project type and enter ‘MDISample’ as the project name.</p><p>  For the first step, make sure that "Multiple documents" is selected then press the ‘Finish’ butt

79、on.</p><p>  Add Xtreme CommandBars components:</p><p>  Add the following line to your StdAfx.h file:</p><p>  Xtreme Toolkit Pro users: #include <XTToolkitPro.h>; // Xtrem

80、e Toolkit Pro components</p><p>  Xtreme CommandBars users:#include <XTCommandBarsPro.h> // Xtreme CommandBars components</p><p>  #include <XTCommandBarsPro.h>; // Xtreme CommandB

81、ars components</p><p>  In your MainFrm.h file you need to change your base class to be CXTPMDIFrameWnd (CXTPFrameWnd for SDI applications):</p><p>  class CMainFrame : public CXTPMDIFrameWnd<

82、;/p><p><b>  {</b></p><p><b>  ...</b></p><p><b>  };</b></p><p>  If you plan to override either PreTranslateMessage or OnWndMsg make

83、sure that you call the CXTPMDIFrameWnd base class, for example:</p><p>  BOOL CMainFrame::PreTranslateMessage(MSG* pMsg)</p><p><b>  {</b></p><p>  // TODO: Add your spe

84、cialized code here and/or call the base class</p><p>  return CXTPMDIFrameWnd::PreTranslateMessage(pMsg);</p><p><b>  }</b></p><p>  BOOL CMainFrame::OnWndMsg(UINT messa

85、ge, WPARAM wParam,</p><p>  LPARAM lParam, LRESULT* pResult)</p><p><b>  {</b></p><p>  // TODO: Add your specialized code here and/or call the base class</p><

86、;p>  return CXTPMDIFrameWnd::OnWndMsg(message, wParam, lParam, pResult);</p><p><b>  }</b></p><p>  Replace int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) function to<

87、/p><p>  int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)</p><p><b>  {</b></p><p>  if (CMDIFrameWnd::OnCreate(lpCreateStruct) == -1)</p><p>  return -

88、1;</p><p>  // Create Status bar. </p><p>  // Important: All control bars including the Status Bar </p><p>  // must be created before CommandBars....</p><p>  if (!m_

89、wndStatusBar.Create(this) ||</p><p>  !m_wndStatusBar.SetIndicators(indicators,</p><p>  sizeof(indicators)/sizeof(UINT)))</p><p><b>  {</b></p><p>  TRACE0

90、("Failed to create status bar\n");</p><p>  return -1; // fail to create</p><p><b>  }</b></p><p>  // Initialize the Command Bar</p><p>  if

91、 (!InitCommandBars())</p><p>  return -1;</p><p>  // Get a pointer to the Command Bar object.</p><p>  CXTPCommandBars* pCommandBars = GetCommandBars();</p><p>  if(pC

92、ommandBars == NULL)</p><p><b>  {</b></p><p>  TRACE0("Failed to create Command Bar object.\n");</p><p>  return -1; // fail to create</p><p>

93、;<b>  }</b></p><p>  // Add the menu bar</p><p>  CXTPCommandBar* pMenuBar = pCommandBars->SetMenu(</p><p>  _T("Menu Bar"), IDR_MDISAMTYPE); </p>

94、;<p>  if(pMenuBar == NULL)</p><p><b>  {</b></p><p>  TRACE0("Failed to create menu bar.\n");</p><p>  return -1; // fail to create</p><

95、;p><b>  }</b></p><p>  // Create ToolBar</p><p>  CXTPToolBar* pToolBar = (CXTPToolBar*)</p><p>  pCommandBars->Add(_T("Standard"), xtpBarTop);</p>

96、<p>  if (!pToolBar || !pToolBar->LoadToolBar(IDR_MAINFRAME))</p><p><b>  {</b></p><p>  TRACE0("Failed to create toolbar\n");</p><p>  return -1;<

97、;/p><p><b>  }</b></p><p>  // Set Office 2003 Theme</p><p>  CXTPPaintManager::SetTheme(xtpThemeOffice2003);</p><p><b>  return 0;</b></p>

98、<p><b>  }</b></p><p>  Now we have an MDI application with an Office 2003 interface...it's that Easy!</p><p>  Allowing the Popup Window to be Moved</p><p>  A

99、uthor: Mike Palmatier</p><p>  Posted: May 3, 2008</p><p>  Environment:Visual C++ 6.0</p><p>  By default you are not allowed to move the popup window when it is displayed. To allo

100、w your users to move the popup window all you need to do is set the AllowMove property to True. Now you will be able to click on the popup window and drag it around.</p><p>  m_pActivePopup->AllowMove(TRU

101、E);</p><p>  Making a Group Special</p><p>  Author: Mike Palmatier</p><p>  Posted: May 3, 2008</p><p>  Environment:Visual C++ 6.0</p><p>  You can desig

102、nate a task panel group as "special." Groups marked as special will be displayed differently than normal groups drawing the users attention to that particular group. This is an excellent way to show the user

103、the "default" or important items.</p><p>  "Special" group</p><p>  Normal group</p><p>  To set a group as special all you need to do is use the SetSpecialG

104、roup method.</p><p>  CXTPTaskPanelGroup* pGroupSystem = m_wndTaskPanel.AddGroup(ID_TASKGROUP_SYSTEM);</p><p>  pGroupSystem->SetIconIndex(IDI_SYSTEM_TASKS);</p><p>  pGroupSyste

105、m->AddLinkItem(ID_TASKITEM_HIDECONTENTS, 0);</p><p>  pGroupSystem->AddLinkItem(ID_TASKITEM_ADDORREMOVE, 1);</p><p>  pGroupSystem->AddLinkItem(ID_TASKITEM_SEARCH, 2);</p><p&

106、gt;  pGroupSystem->SetSpecialGroup();</p><p>  Applying the Office 2007 Skin</p><p>  Author: Mike Palmatier</p><p>  Posted: May 3, 2008</p><p>  Environment:Visual

107、 C++ 6.0</p><p>  First a skin must be loaded before it can be applied to your application. The LoadSkin method loads a skin from a .cjstyles or .msstyles file.The Office 2007 skin is located in the Office

108、2007.cjstyles skin file and is loaded using the NormalOffice2007.ini file name.</p><p>  'Loads the NormalOffice2007.ini skin</p><p>  SkinFramework.LoadSkin App.Path + _</p><p>

109、;  XTPSkinManager()->LoadSkin(_T("..\..\..\Styles\WinXP.Luna.cjstyles"),</p><p>  _T("NormalBlue.ini"));</p><p>  By default, the skin framework will automatically skin al

110、l child windows of your application. If you do not want this to happen you can call the SetAutoApplyNewWindows method to specify that all windows will not automatically receive the skin. You can then individually specify

111、 which windows will receive the skin by using the ApplyWindow method.</p><p>  XTPSkinManager()->SetAutoApplyNewWindows(FALSE);</p><p>  XTPSkinManager()->ApplyWindow(pWnd->GetSafeHwnd(

112、));</p><p>  Removing the Expand Button</p><p>  Author: Mike Palmatier</p><p>  Posted: April 28, 2008</p><p>  Environment:Visual C++ 6.0</p><p>  The ex

113、pand button can is used to display a popup menu with items related to the shortcut bar. Sometimes you might not want to display the expand button in your shortcut bar.</p><p>  The ShowExpandButton method is

114、 used to remove the expand button. You can use the IsExpandButtonVisible method to determine if the button is visible.</p><p>  m_wndShortcutBar.ShowExpandButton(FALSE);</p><p>  Adding Multi-Ro

115、w Tabs</p><p>  Author: Mike Palmatier</p><p>  Posted: May 3, 2008</p><p>  Environment:Visual C++ 6.0</p><p>  The TabControl can display more than one row of tabs by

116、 using the SetLayout method to apply the xtpTabLayoutMultiRow flag. The number of rows is automatically set by the width and number of the tabs. The number of rows can change if the control is resized, which ensures that

117、 the tabs wrap to the next row. If the tab layout is not set to xtpTabLayoutMultiRow, and the last tab exceeds the width of the control, left and right arrow buttons are added at the right end of the TabControl.</p>

118、;<p>  'The TabControl can display more than one row of tabs</p><p>  'by changing the Layout to xtpTabLayoutMultiRow.</p><p>  m_wndTabControl.GetPaintManager()->SetLayout(xtp

119、TabLayoutMultiRow);</p><p>  The m_bMultiRowJustified property specifies the justification of the tabs in the TabControl. When True, each tab is wide enough to accommodate its caption and, if needed, the wid

120、th of each tab is increased so that each row of tabs spans the width of the TabControl. This will stretch each row of tabs to fill the entire width of the TabControl.If False, the tab rows will be non-justified. Each t

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權益所有人同意不得將文件中的內容挪作商業(yè)或盈利用途。
  • 5. 眾賞文庫僅提供信息存儲空間,僅對用戶上傳內容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內容本身不做任何修改或編輯,并不能對任何下載內容負責。
  • 6. 下載文件中如有侵權或不適當內容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論