You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
|
Jul
(30) |
Aug
(6) |
Sep
(3) |
Oct
(1) |
Nov
(13) |
Dec
(15) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
|
Feb
(17) |
Mar
(7) |
Apr
(10) |
May
(34) |
Jun
(17) |
Jul
(150) |
Aug
(59) |
Sep
(186) |
Oct
(57) |
Nov
(45) |
Dec
(22) |
2005 |
Jan
(10) |
Feb
(10) |
Mar
(6) |
Apr
(24) |
May
(10) |
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
(35) |
Nov
(12) |
Dec
(1) |
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(7) |
Nov
(1) |
Dec
|
From: boca4711 <boc...@us...> - 2004-11-01 14:46:14
|
Update of /cvsroot/anyedit/AnyEditToolkit/Samples/Gui_DevStudio In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3335/Samples/Gui_DevStudio Removed Files: Gui_DevStudio.clw Log Message: Removed file from repository because it can be created from VS --- Gui_DevStudio.clw DELETED --- |
From: boca4711 <boc...@us...> - 2004-11-01 14:40:33
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2204/GuiLib Modified Files: GuiWorkTab.cpp Log Message: This tab control doesn't change the window title of parent window. Index: GuiWorkTab.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiWorkTab.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiWorkTab.cpp 15 Oct 2004 14:01:52 -0000 1.2 --- GuiWorkTab.cpp 1 Nov 2004 14:40:25 -0000 1.3 *************** *** 58,61 **** --- 58,62 ---- m_EnableL = FALSE; m_EnableR = FALSE; + SetActualTitle(FALSE); } |
From: boca4711 <boc...@us...> - 2004-11-01 14:38:05
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1686/GuiLib Modified Files: GuiToolBarWnd.cpp GuiToolBarWnd.h Log Message: Add GetAllToolbars to get a list of all toolbars. Index: GuiToolBarWnd.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiToolBarWnd.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiToolBarWnd.cpp 15 Oct 2004 14:01:52 -0000 1.3 --- GuiToolBarWnd.cpp 1 Nov 2004 14:37:56 -0000 1.4 *************** *** 62,65 **** --- 62,69 ---- } }; + + /// All CGuiToolBarWnd collection: + CObList gAllToolbars; + ////////////////////////////////////////////////////////////////////// // Construction/Destruction *************** *** 114,133 **** } int CGuiToolBarWnd::OnCreate(LPCREATESTRUCT lpCreateStruct) { ! lpCreateStruct->dwExStyle |= WS_CLIPSIBLINGS|WS_CLIPCHILDREN; // prevents flashing if (CToolBar::OnCreate(lpCreateStruct) == -1) return -1; ! if (m_pDockContext==NULL) ! m_pDockContext=new CGuiDockContext(this); ASSERT(m_pDockContext); ! ModifyStyle(0,TBSTYLE_FLAT); SetSizes(m_sizeButton, m_sizeImage); return 0; } - - - void CGuiToolBarWnd::SetTextOptions() { --- 118,136 ---- } + /// Creation of a toolbar int CGuiToolBarWnd::OnCreate(LPCREATESTRUCT lpCreateStruct) { ! lpCreateStruct->dwExStyle |= WS_CLIPSIBLINGS | WS_CLIPCHILDREN; // prevents flashing if (CToolBar::OnCreate(lpCreateStruct) == -1) return -1; ! if (m_pDockContext == NULL) ! m_pDockContext = new CGuiDockContext(this); ASSERT(m_pDockContext); ! ModifyStyle(0, TBSTYLE_FLAT); SetSizes(m_sizeButton, m_sizeImage); + gAllToolbars.AddTail (this); return 0; } void CGuiToolBarWnd::SetTextOptions() { *************** *** 409,416 **** } //Thanks to Ernesto Garcia void CGuiToolBarWnd::OnDestroy() { ! for( int i=0; i<m_iElements; i++ ) { CDropmenu *pArr = (CDropmenu*)m_pArray.GetAt(i); --- 412,420 ---- } + /// Toolbar window is destroyed //Thanks to Ernesto Garcia void CGuiToolBarWnd::OnDestroy() { ! for( int i = 0; i < m_iElements; i++ ) { CDropmenu *pArr = (CDropmenu*)m_pArray.GetAt(i); *************** *** 419,423 **** } CToolBar::OnDestroy(); ! // TODO: Add your message handler code here } --- 423,446 ---- } CToolBar::OnDestroy(); ! ! // Remove toolbar from global list ! for (POSITION pos = gAllToolbars.GetHeadPosition (); pos != NULL;) ! { ! POSITION posSave = pos; ! ! CGuiToolBarWnd* pToolBar = (CGuiToolBarWnd*) gAllToolbars.GetNext (pos); ! ASSERT (pToolBar != NULL); ! ! if (CWnd::FromHandlePermanent (pToolBar->m_hWnd) != NULL) ! { ! ASSERT_VALID(pToolBar); ! ! if (pToolBar == this) ! { ! gAllToolbars.RemoveAt (posSave); ! break; ! } ! } ! } } *************** *** 1705,1706 **** --- 1728,1734 ---- } + /// Get a list of all toolbars. + const CObList& CGuiToolBarWnd::GetAllToolbars () + { + return gAllToolbars; + } Index: GuiToolBarWnd.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiToolBarWnd.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiToolBarWnd.h 15 Oct 2004 14:01:52 -0000 1.3 --- GuiToolBarWnd.h 1 Nov 2004 14:37:56 -0000 1.4 *************** *** 102,105 **** --- 102,106 ---- // void LockEspecial(); // void UnLockEspecial(); + static const CObList& GetAllToolbars (); protected: UINT m_style; |
From: boca4711 <boc...@us...> - 2004-11-01 14:34:41
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1035/GuiLib Modified Files: GuiTabWnd.cpp GuiTabWnd.h Log Message: - Added flickerfree drawing - ShowTitle send ID_GUI_SHOWTITLE instead of WM_SHOWTITLE to parent window - AddTab calls ShowTitle - DeleteTab shows correct window after deletion - Registered message GUITK_CHANGE_ACTIVE_TAB is send when the current tab is changed Index: GuiTabWnd.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** GuiTabWnd.h 20 Oct 2004 16:27:27 -0000 1.6 --- GuiTabWnd.h 1 Nov 2004 14:34:28 -0000 1.7 *************** *** 63,74 **** void SetTypeTab(TypeTab Type=TYPE_NORMAL); void virtual Drawtabs(CDC* dc); ! void Addtab(CWnd* pParent, CString lpMsg, UINT uIcon, LPCTSTR lpcsTooltip = NULL); void SetImageList(UINT nBitmapID, int cx, int nGrow, COLORREF crMask); void RecalLayout(); virtual void AjustTabs(); ! void SetCurtab(int m_numtab); int GetCurtab(); ! void DeleteTab(int m_numTab); ! void ShowTitle(CString m_Caption); CWnd* GetActiveWnd () const; CWnd* GetNumWnd(int m_numtab) const; --- 63,74 ---- void SetTypeTab(TypeTab Type=TYPE_NORMAL); void virtual Drawtabs(CDC* dc); ! void Addtab(CWnd* pParent, CString strTitle, UINT uIcon, LPCTSTR lpszTooltip = NULL); void SetImageList(UINT nBitmapID, int cx, int nGrow, COLORREF crMask); void RecalLayout(); virtual void AjustTabs(); ! void SetCurtab(int nTab); int GetCurtab(); ! void DeleteTab(int nTab); ! void ShowTitle(CString strCaption); CWnd* GetActiveWnd () const; CWnd* GetNumWnd(int m_numtab) const; *************** *** 129,132 **** --- 129,134 ---- }; + extern GUILIBDLLEXPORT UINT GUITK_CHANGE_ACTIVE_TAB; + ///////////////////////////////////////////////////////////////////////////// Index: GuiTabWnd.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** GuiTabWnd.cpp 20 Oct 2004 16:27:27 -0000 1.7 --- GuiTabWnd.cpp 1 Nov 2004 14:34:28 -0000 1.8 *************** *** 22,35 **** ****************************************************************************/ - - - - - #include "stdafx.h" #include "GuiTabWnd.h" #include "GuiBasetab.h" ! #ifdef _DEBUG --- 22,30 ---- ****************************************************************************/ #include "stdafx.h" #include "GuiTabWnd.h" #include "GuiBasetab.h" ! #include "memdc.h" #ifdef _DEBUG *************** *** 45,48 **** --- 40,45 ---- #define DEFAULT_FLAT 18 + UINT GUITK_CHANGE_ACTIVE_TAB = ::RegisterWindowMessage (_T("GUITK_ON_CHANGE_ACTIVE_TAB")); + CGuiTabWnd::CGuiTabWnd() { *************** *** 107,111 **** --- 104,110 ---- m_TypeTab=Type; } + //**************************************************************************** + /// Erase background of tab control. BOOL CGuiTabWnd::OnEraseBkgnd(CDC* pDC) { *************** *** 117,123 **** CRect m_rect; GetClientRect(m_rect); ! pDC->FillRect(m_rect,&cbr); cbr.DeleteObject(); - } return TRUE; --- 116,121 ---- CRect m_rect; GetClientRect(m_rect); ! pDC->FillRect(m_rect, &cbr); cbr.DeleteObject(); } return TRUE; *************** *** 136,214 **** } void CGuiTabWnd::OnPaint() { ! CPaintDC dc(this); // device context for painting ! if (m_Numtabs <=0) return; ! CBrush cbr; ! CRect m_rectDraw; ! CGuiTab* ct=(CGuiTab*) m_pArray[m_iSelectTab]; ! if (m_alnTab!=ALN_TOP) ! cbr.CreateSolidBrush((GuiDrawLayer::m_Style== GUISTYLE_XP)?GuiDrawLayer::GetRGBColorTabs(): ct->m_clrHtab); ! else ! cbr.CreateSolidBrush(GuiDrawLayer::m_Style == GUISTYLE_XP?GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style):ct->m_clrHtab); ! GetClientRect(m_rectCliente); ! m_rectTab=m_rectCliente; ! m_rectDraw=m_rectCliente; ! if (m_alnTab==ALN_BOTTOM) ! m_rectDraw.bottom=m_rectCliente.bottom-(m_sizeImag.cy+SPACE_TAB+2); ! else ! m_rectDraw.top=m_rectCliente.top+(m_sizeImag.cy+SPACE_TAB+2); ! if (m_style != S3D) //si son carpetas estilo excel o tabbed como devstudio 7 ! { ! if (m_alnTab==ALN_BOTTOM) ! { ! m_rectCliente.bottom=m_rectCliente.bottom-(DEFAULT_FLAT); ! m_rectTab.top=m_rectCliente.bottom+2; ! } else { ! m_rectTab.bottom=m_rectCliente.top+(DEFAULT_FLAT)+3; } - } ! if (m_alnTab!=ALN_TOP) ! { ! dc.FillRect(m_rectTab,&cbr); ! m_rectDraw.left+=1; ! dc.Draw3dRect(m_rectDraw,GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style),GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); ! if (GuiDrawLayer::m_Style!= GUISTYLE_XP) { ! //eliminar la linea inferior ! m_rectDraw.top=m_rectDraw.bottom-1; ! m_rectDraw.left+=1; ! m_rectDraw.right-=1; ! dc.Draw3dRect(m_rectDraw,ct->m_clrHtab,ct->m_clrHtab); } ! m_rectDraw.left-=1; ! } ! else ! { ! CRect rc=m_rectDraw; ! for (int i=0; i< 2; i++) { ! dc.Draw3dRect(rc,GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style),GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style)); ! rc.DeflateRect(1,1); } ! rc.InflateRect(3,3); ! dc.Draw3dRect(m_rectDraw,GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style),GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); ! rc=m_rectDraw; ! rc.bottom=rc.top+3; ! dc.FillRect(rc,&cbr); } - - - cbr.DeleteObject (); - Drawtabs(&dc); - } - - BOOL CGuiTabWnd::Create(DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID) { --- 134,216 ---- } + /// Paint tab control void CGuiTabWnd::OnPaint() { + CRect rect; + if (GetUpdateRect(&rect, FALSE)) + { + CPaintDC dc(this); // device context for painting ! CMemDC memDC(&dc, &rect); ! if (m_Numtabs <= 0) return; ! CBrush cbr; ! CRect m_rectDraw; ! CGuiTab* ct=(CGuiTab*) m_pArray[m_iSelectTab]; ! if (m_alnTab != ALN_TOP) ! cbr.CreateSolidBrush((GuiDrawLayer::m_Style== GUISTYLE_XP) ? GuiDrawLayer::GetRGBColorTabs() : ct->m_clrHtab); ! else ! cbr.CreateSolidBrush(GuiDrawLayer::m_Style == GUISTYLE_XP ? GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style) : ct->m_clrHtab); ! GetClientRect(m_rectCliente); ! m_rectTab = m_rectCliente; ! m_rectDraw = m_rectCliente; ! if (m_alnTab == ALN_BOTTOM) ! m_rectDraw.bottom = m_rectCliente.bottom - (m_sizeImag.cy + SPACE_TAB + 2); else + m_rectDraw.top = m_rectCliente.top + (m_sizeImag.cy + SPACE_TAB + 2); + + if (m_style != S3D) //si son carpetas estilo excel o tabbed como devstudio 7 { ! if (m_alnTab == ALN_BOTTOM) ! { ! m_rectCliente.bottom = m_rectCliente.bottom - (DEFAULT_FLAT); ! m_rectTab.top = m_rectCliente.bottom + 2; ! } ! else ! { ! m_rectTab.bottom = m_rectCliente.top + (DEFAULT_FLAT) + 3; ! } } ! if (m_alnTab != ALN_TOP) { ! memDC.FillRect(m_rectTab, &cbr); ! m_rectDraw.left += 1; ! memDC.Draw3dRect(m_rectDraw, GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style), GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); ! if (GuiDrawLayer::m_Style != GUISTYLE_XP) ! { ! //eliminar la linea inferior ! m_rectDraw.top = m_rectDraw.bottom - 1; ! m_rectDraw.left += 1; ! m_rectDraw.right -= 1; ! memDC.Draw3dRect(m_rectDraw, ct->m_clrHtab, ct->m_clrHtab); + } + m_rectDraw.left -= 1; } ! else { ! CRect rc = m_rectDraw; ! for (int i = 0; i < 2; i++) ! { ! memDC.Draw3dRect(rc, GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style), GuiDrawLayer::GetRGBColorFace(GuiDrawLayer::m_Style)); ! rc.DeflateRect(1, 1); ! } ! ! rc.InflateRect(3, 3); ! memDC.Draw3dRect(m_rectDraw, GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style), GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); ! rc = m_rectDraw; ! rc.bottom = rc.top+3; ! memDC.FillRect(rc, &cbr); } ! cbr.DeleteObject(); ! Drawtabs(&memDC); + DefWindowProc(WM_PAINT, (WPARAM)memDC.m_hDC, (LPARAM)0); } } BOOL CGuiTabWnd::Create(DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID) { *************** *** 230,234 **** } - void CGuiTabWnd::RecalLayout() { --- 232,235 ---- *************** *** 288,292 **** } - void CGuiTabWnd::AjustTabs() { --- 289,292 ---- *************** *** 578,614 **** } ! void CGuiTabWnd::ShowTitle(CString m_Caption) { ! if (m_ActualTitle==TRUE) { ! CWnd* pParent=GetParent(); ! pParent->SetWindowText(m_Caption); ! pParent->SendMessage(WM_COMMAND, WM_SHOWTITLE); } - } /// Add tab to tab control. ! void CGuiTabWnd::Addtab(CWnd *pParent, CString lpMsg, UINT uIcon, LPCTSTR lpcsTooltip) { ASSERT_VALID(pParent); ! m_pArray.SetAtGrow(m_Numtabs,new CGuiTab(pParent,lpMsg,uIcon)); ! if (m_alnTab!=ALN_TOP || m_TypeTab == TYPE_NORMAL) { ! if (m_Numtabs==0) pParent->ShowWindow(SW_SHOW); else pParent->ShowWindow(SW_HIDE); ! m_iSelectTab=0; } else ! m_iSelectTab=m_Numtabs; m_Numtabs++; //assign color ! CGuiTab* ctn=(CGuiTab*) m_pArray[m_Numtabs-1]; ! GuiDrawLayer::GetNextColor(m_Numtabs,ctn->m_clrLTab,ctn->m_clrHtab); ! if (m_alnTab==ALN_TOP && m_TypeTab != TYPE_NORMAL) { pParent->ShowWindow(SW_SHOWMAXIMIZED); --- 578,619 ---- } ! ! /// Set title of parent window. ! void CGuiTabWnd::ShowTitle(CString strCaption) { ! if (m_ActualTitle == TRUE) { ! CWnd* pParent = GetParent(); ! pParent->SetWindowText(strCaption); ! pParent->SendMessage(WM_COMMAND, ID_GUI_SHOWTITLE); } } /// Add tab to tab control. ! void CGuiTabWnd::Addtab(CWnd *pParent, CString strTitle, UINT uIcon, LPCTSTR lpszTooltip) { ASSERT_VALID(pParent); ! m_pArray.SetAtGrow(m_Numtabs, new CGuiTab(pParent, strTitle, uIcon)); ! if (m_alnTab != ALN_TOP || m_TypeTab == TYPE_NORMAL) { ! if (m_Numtabs == 0) ! { ! // first tab is added pParent->ShowWindow(SW_SHOW); + ShowTitle(strTitle); + } else pParent->ShowWindow(SW_HIDE); ! m_iSelectTab = 0; } else ! m_iSelectTab = m_Numtabs; m_Numtabs++; //assign color ! CGuiTab* ctn = (CGuiTab*) m_pArray[m_Numtabs-1]; ! GuiDrawLayer::GetNextColor(m_Numtabs, ctn->m_clrLTab, ctn->m_clrHtab); ! if (m_alnTab == ALN_TOP && m_TypeTab != TYPE_NORMAL) { pParent->ShowWindow(SW_SHOWMAXIMIZED); *************** *** 617,634 **** if (m_style == S3D || m_TypeTab == TYPE_MDI) { ! if (lpcsTooltip != NULL) ! CToolTip.AddTool(this, lpcsTooltip, CRect(0,0,0,0), m_Numtabs); else ! CToolTip.AddTool(this, lpMsg, CRect(0,0,0,0), m_Numtabs); } RecalLayout(); } ! ! void CGuiTabWnd::DeleteTab(int m_numtab) { ! if (m_numtab < m_Numtabs) { ! CGuiTab* ctn = (CGuiTab*) m_pArray[m_numtab]; if (m_alnTab != ALN_TOP) ASSERT_VALID(ctn->pParent); --- 622,639 ---- if (m_style == S3D || m_TypeTab == TYPE_MDI) { ! if (lpszTooltip != NULL) ! CToolTip.AddTool(this, lpszTooltip, CRect(0,0,0,0), m_Numtabs); else ! CToolTip.AddTool(this, strTitle, CRect(0,0,0,0), m_Numtabs); } RecalLayout(); } ! /// Remove tab with number nTab. ! void CGuiTabWnd::DeleteTab(int nTab) { ! if (nTab < m_Numtabs) { ! CGuiTab* ctn = (CGuiTab*) m_pArray[nTab]; if (m_alnTab != ALN_TOP) ASSERT_VALID(ctn->pParent); *************** *** 638,656 **** delete ctn; m_Numtabs--; ! m_pArray.RemoveAt(m_numtab, 1); if (m_Numtabs > 0) { ! if (m_iSelectTab == m_numtab) { m_iSelectTab = m_iSelectTab-1; ! if (m_iSelectTab< 0) m_iSelectTab = 0; ! CGuiTab* ctn =(CGuiTab*) m_pArray[m_iSelectTab]; CWnd* pParentNew = ctn->pParent; ASSERT_VALID(pParentNew); pParentNew->ShowWindow(SW_SHOW); } else { ! if (m_iSelectTab > m_numtab) { m_iSelectTab--; --- 643,663 ---- delete ctn; m_Numtabs--; ! m_pArray.RemoveAt(nTab, 1); if (m_Numtabs > 0) { ! if (m_iSelectTab == nTab) { m_iSelectTab = m_iSelectTab-1; ! if (m_iSelectTab < 0) ! m_iSelectTab = 0; ! CGuiTab* ctn = (CGuiTab*) m_pArray[m_iSelectTab]; CWnd* pParentNew = ctn->pParent; ASSERT_VALID(pParentNew); pParentNew->ShowWindow(SW_SHOW); + pParentNew->BringWindowToTop(); } else { ! if (m_iSelectTab > nTab) { m_iSelectTab--; *************** *** 659,663 **** RecalLayout(); } ! } } --- 666,670 ---- RecalLayout(); } ! GetParent()->SendMessage (GUITK_CHANGE_ACTIVE_TAB, m_iSelectTab); } } *************** *** 671,686 **** } ! ! void CGuiTabWnd::SetCurtab(int m_numtab) { ! if (m_numtab < m_Numtabs && m_numtab != m_iSelectTab ) { ! CGuiTab* ctn=(CGuiTab*) m_pArray[m_numtab]; ! CWnd* pParentNew= ctn->pParent; ! CGuiTab* ct =(CGuiTab*) m_pArray[m_iSelectTab]; ! CWnd* pParentActual=ct->pParent; ASSERT_VALID(pParentNew); ASSERT_VALID(pParentActual); ! if (m_alnTab==ALN_TOP && m_TypeTab != TYPE_NORMAL) { pParentNew->BringWindowToTop(); --- 678,693 ---- } ! /// Set current tab. ! void CGuiTabWnd::SetCurtab(int nTab) { ! if (nTab < m_Numtabs && nTab != m_iSelectTab ) { ! CGuiTab* ctn = (CGuiTab*) m_pArray[nTab]; ! CWnd* pParentNew = ctn->pParent; ! CGuiTab* ct = (CGuiTab*) m_pArray[m_iSelectTab]; ! CWnd* pParentActual = ct->pParent; ASSERT_VALID(pParentNew); ASSERT_VALID(pParentActual); ! if (m_alnTab == ALN_TOP && m_TypeTab != TYPE_NORMAL) { pParentNew->BringWindowToTop(); *************** *** 692,703 **** } ! m_iSelectTab=m_numtab; ! if (m_alnTab==ALN_TOP) AjustTabs(); Invalidate(); UpdateWindow(); - } - } --- 699,708 ---- } ! m_iSelectTab = nTab; ! if (m_alnTab == ALN_TOP) AjustTabs(); Invalidate(); UpdateWindow(); } } *************** *** 707,728 **** } ! void CGuiTabWnd::OnLButtonDown(UINT nFlags, CPoint point) { // TODO: Add your message handler code here and/or call default CWnd::OnLButtonDown(nFlags, point); ! for (int iCont=0; iCont< m_Numtabs;iCont++) { ! CGuiTab* ct=(CGuiTab*) m_pArray[iCont]; if (ct->rect.PtInRect(point) != 0) { SetCurtab(iCont); ShowTitle(ct->lpMsg); ! m_InTab=TRUE; return; } - } - } --- 712,732 ---- } ! /// Handle mouse click with left button void CGuiTabWnd::OnLButtonDown(UINT nFlags, CPoint point) { // TODO: Add your message handler code here and/or call default CWnd::OnLButtonDown(nFlags, point); ! for (int iCont = 0; iCont < m_Numtabs; iCont++) { ! CGuiTab* ct = (CGuiTab*) m_pArray[iCont]; if (ct->rect.PtInRect(point) != 0) { SetCurtab(iCont); + GetParent()->SendMessage (GUITK_CHANGE_ACTIVE_TAB, iCont); ShowTitle(ct->lpMsg); ! m_InTab = TRUE; return; } } } |
From: boca4711 <boc...@us...> - 2004-11-01 14:25:52
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31979/GuiLib Modified Files: GuiLib.dsp Log Message: Add memdc.h a class for flickerfree drawing. Index: GuiLib.dsp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiLib.dsp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiLib.dsp 13 Oct 2004 23:30:00 -0000 1.2 --- GuiLib.dsp 1 Nov 2004 14:25:42 -0000 1.3 *************** *** 720,723 **** --- 720,727 ---- # Begin Source File + SOURCE=.\memdc.h + # End Source File + # Begin Source File + SOURCE=.\MenuBar.h # End Source File |
From: boca4711 <boc...@us...> - 2004-11-01 14:24:45
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31787/GuiLib Added Files: memdc.h Log Message: Class for flickerfree drawing. --- NEW FILE: memdc.h --- #ifndef _MEMDC_H_ #define _MEMDC_H_ ////////////////////////////////////////////////// // CMemDC - memory DC // // Author: Keith Rule // Email: ke...@eu... // Copyright 1996-2002, Keith Rule // // You may freely use or modify this code provided this // Copyright is included in all derived versions. // // History - 10/3/97 Fixed scrolling bug. // Added print support. - KR // // 11/3/99 Fixed most common complaint. Added // background color fill. - KR // // 11/3/99 Added support for mapping modes other than // MM_TEXT as suggested by Lee Sang Hun. - KR // // 02/11/02 Added support for CScrollView as supplied // by Gary Kirkham. - KR // // This class implements a memory Device Context which allows // flicker free drawing. class CMemDC : public CDC { private: CBitmap m_bitmap; // Offscreen bitmap CBitmap* m_oldBitmap; // bitmap originally found in CMemDC CDC* m_pDC; // Saves CDC passed in constructor CRect m_rect; // Rectangle of drawing area. BOOL m_bMemDC; // TRUE if CDC really is a Memory DC. public: CMemDC(CDC* pDC, const CRect* pRect = NULL) : CDC() { ASSERT(pDC != NULL); // Some initialization m_pDC = pDC; m_oldBitmap = NULL; m_bMemDC = !pDC->IsPrinting(); // Get the rectangle to draw if (pRect == NULL) { pDC->GetClipBox(&m_rect); } else { m_rect = *pRect; } if (m_bMemDC) { // Create a Memory DC CreateCompatibleDC(pDC); pDC->LPtoDP(&m_rect); m_bitmap.CreateCompatibleBitmap(pDC, m_rect.Width(), m_rect.Height()); m_oldBitmap = SelectObject(&m_bitmap); SetMapMode(pDC->GetMapMode()); SetWindowExt(pDC->GetWindowExt()); SetViewportExt(pDC->GetViewportExt()); pDC->DPtoLP(&m_rect); SetWindowOrg(m_rect.left, m_rect.top); } else { // Make a copy of the relevent parts of the current DC for printing m_bPrinting = pDC->m_bPrinting; m_hDC = pDC->m_hDC; m_hAttribDC = pDC->m_hAttribDC; } // Fill background FillSolidRect(m_rect, pDC->GetBkColor()); } ~CMemDC() { if (m_bMemDC) { // Copy the offscreen bitmap onto the screen. m_pDC->BitBlt(m_rect.left, m_rect.top, m_rect.Width(), m_rect.Height(), this, m_rect.left, m_rect.top, SRCCOPY); //Swap back the original bitmap. SelectObject(m_oldBitmap); } else { // All we need to do is replace the DC with an illegal value, // this keeps us from accidently deleting the handles associated with // the CDC that was passed to the constructor. m_hDC = m_hAttribDC = NULL; } } // Allow usage as a pointer CMemDC* operator->() { return this; } // Allow usage as a pointer operator CMemDC*() { return this; } }; #endif |
From: boca4711 <boc...@us...> - 2004-11-01 14:22:04
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31317/GuiLib Modified Files: GuiDockToolBarEx.cpp GuiDockToolBarEx.h Log Message: Moved static InitGlobalFont from header to implementation file Index: GuiDockToolBarEx.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiDockToolBarEx.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiDockToolBarEx.cpp 15 Oct 2004 14:01:50 -0000 1.3 --- GuiDockToolBarEx.cpp 1 Nov 2004 14:21:47 -0000 1.4 *************** *** 27,30 **** --- 27,64 ---- #include "GuiFrameWnd.h" + static CFont m_fontHorzMenu, m_fontVertMenu; + static int _cyHorzFont, _cyMenuOnBar, _cyTextMargin; + const int CXTEXTMARGIN = 5; + + static BOOL InitGlobalFont() + { + if (m_fontHorzMenu.GetSafeHandle() != NULL && m_fontVertMenu.GetSafeHandle() != NULL) + return TRUE; + m_fontHorzMenu.DeleteObject(); + m_fontVertMenu.DeleteObject(); + + // create fonts + NONCLIENTMETRICS info; info.cbSize = sizeof(info); + ::SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(info), &info, 0); + if(!m_fontHorzMenu.CreateFontIndirect(&info.lfMenuFont)) + return FALSE; + + // create vertical font + info.lfMenuFont.lfEscapement = -900; + info.lfMenuFont.lfOrientation = -900; + _tcscpy(info.lfMenuFont.lfFaceName,_T("verdana")); + if(!m_fontVertMenu.CreateFontIndirect(&info.lfMenuFont)) + return FALSE; + + _cyHorzFont = abs(info.lfMenuFont.lfHeight); + + // calc Y text margin + _cyMenuOnBar = info.iMenuHeight; + _cyMenuOnBar = max(_cyMenuOnBar, ::GetSystemMetrics(SM_CYSMICON)); + _cyTextMargin = (_cyMenuOnBar - _cyHorzFont) / 2; + + return TRUE; + } + ///////////////////////////////////////////////////////////////////////////// // CDockButton Index: GuiDockToolBarEx.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiDockToolBarEx.h,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** GuiDockToolBarEx.h 15 Oct 2004 14:01:50 -0000 1.4 --- GuiDockToolBarEx.h 1 Nov 2004 14:21:47 -0000 1.5 *************** *** 3,41 **** #include "GuiControlBar.h" - static CFont m_fontHorzMenu, m_fontVertMenu; - static int _cyHorzFont, _cyMenuOnBar, _cyTextMargin; - const int CXTEXTMARGIN = 5; - - static BOOL InitGlobalFont() - { - - if (m_fontHorzMenu.GetSafeHandle() != NULL && m_fontVertMenu.GetSafeHandle() != NULL) - return TRUE; - m_fontHorzMenu.DeleteObject(); - m_fontVertMenu.DeleteObject(); - - // create fonts - NONCLIENTMETRICS info; info.cbSize = sizeof(info); - ::SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(info), &info, 0); - if(!m_fontHorzMenu.CreateFontIndirect(&info.lfMenuFont)) - return FALSE; - - // create vertical font - info.lfMenuFont.lfEscapement = -900; - info.lfMenuFont.lfOrientation = -900; - _tcscpy(info.lfMenuFont.lfFaceName,_T("verdana")); - if(!m_fontVertMenu.CreateFontIndirect(&info.lfMenuFont)) - return FALSE; - - _cyHorzFont = abs(info.lfMenuFont.lfHeight); - - // calc Y text margin - _cyMenuOnBar = info.iMenuHeight; - _cyMenuOnBar = max(_cyMenuOnBar, ::GetSystemMetrics(SM_CYSMICON)); - _cyTextMargin = (_cyMenuOnBar - _cyHorzFont) / 2; - - return TRUE; - } - class CDockButton : public CWnd { --- 3,6 ---- |
From: boca4711 <boc...@us...> - 2004-11-01 14:16:44
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30224 Modified Files: ScintillaEx.cpp Log Message: Bugfix: InsertTextIntoLines handles no selection and selection which ends in the middle of a line. Index: ScintillaEx.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/ScintillaEx.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** ScintillaEx.cpp 25 Oct 2004 13:36:02 -0000 1.18 --- ScintillaEx.cpp 1 Nov 2004 14:16:32 -0000 1.19 *************** *** 1664,1671 **** int nLineStart = LineFromPosition(GetSelectionStart()); int nLineEnd = LineFromPosition(GetSelectionEnd()); int nPosition; BeginUndoAction(); ! for(int nLine = nLineStart; nLine < nLineEnd; nLine++) { switch (nPos) --- 1664,1676 ---- int nLineStart = LineFromPosition(GetSelectionStart()); int nLineEnd = LineFromPosition(GetSelectionEnd()); + + // Remove last line if selection ends on first position of line. + if (GetSelectionEnd() == PositionFromLine(nLineEnd) && nLineEnd > nLineStart) + nLineEnd--; + int nPosition; BeginUndoAction(); ! for(int nLine = nLineStart; nLine <= nLineEnd; nLine++) { switch (nPos) *************** *** 1694,1697 **** --- 1699,1707 ---- int nLineStart = LineFromPosition(GetSelectionStart()); int nLineEnd = LineFromPosition(GetSelectionEnd()); + + // Remove last line if selection ends on first position of line. + if (GetSelectionEnd() == PositionFromLine(nLineEnd) && nLineEnd > nLineStart) + nLineEnd--; + int nPosition; *************** *** 1702,1706 **** BeginUndoAction(); ! for(int nLine = nLineStart; nLine < nLineEnd; nLine++) { nPosition = PositionFromLine(nLine); --- 1712,1716 ---- BeginUndoAction(); ! for(int nLine = nLineStart; nLine <= nLineEnd; nLine++) { nPosition = PositionFromLine(nLine); |
From: boca4711 <boc...@us...> - 2004-11-01 14:13:57
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29695 Modified Files: inserttextdlg.cpp Log Message: - Corrected initialisation from config file - Set last inserted text to default in next call - Disabled text combo box when number mode was active Index: inserttextdlg.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/inserttextdlg.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** inserttextdlg.cpp 29 Sep 2004 08:04:47 -0000 1.2 --- inserttextdlg.cpp 1 Nov 2004 14:13:47 -0000 1.3 *************** *** 93,103 **** m_nInsert = pConfigFile->GetInsertTextType(); m_spinPosition.SetRange(0, 9999); ! m_spinPosition.SetPos( pConfigFile->GetInsertTextPosition() ); m_spinFirstNumber.SetRange32(0, 9999999); ! m_spinFirstNumber.SetPos( pConfigFile->GetInsertTextFirstNumber() ); m_spinStep.SetRange(-99, 99); ! m_spinStep.SetPos( pConfigFile->GetInsertTextStep() ); m_spinLength.SetRange(1, 99); ! m_spinLength.SetPos( pConfigFile->GetInsertTextLength() ); m_strSeperator = pConfigFile->GetInsertTextSeparator(); --- 93,103 ---- m_nInsert = pConfigFile->GetInsertTextType(); m_spinPosition.SetRange(0, 9999); ! m_nPosition = pConfigFile->GetInsertTextPosition(); m_spinFirstNumber.SetRange32(0, 9999999); ! m_nFirstNumber = pConfigFile->GetInsertTextFirstNumber(); m_spinStep.SetRange(-99, 99); ! m_nStep = pConfigFile->GetInsertTextStep(); m_spinLength.SetRange(1, 99); ! m_nLength = pConfigFile->GetInsertTextLength(); m_strSeperator = pConfigFile->GetInsertTextSeparator(); *************** *** 106,109 **** --- 106,111 ---- UpdateControls(); + m_cbText.SetCurSel(0); + return TRUE; } *************** *** 198,201 **** --- 200,204 ---- bEnable = (m_wndNumber.GetCheck() == 1); + m_cbText.EnableWindow(! bEnable); m_wndFirstNumber.EnableWindow(bEnable); m_spinFirstNumber.EnableWindow(bEnable); |
From: boca4711 <boc...@us...> - 2004-11-01 14:12:13
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29389 Modified Files: AnyEdit.rc Log Message: Added CBS_AUTOHSCROLL to text combo box in insert into line dialog Index: AnyEdit.rc =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/AnyEdit.rc,v retrieving revision 1.104 retrieving revision 1.105 diff -C2 -d -r1.104 -r1.105 *** AnyEdit.rc 29 Sep 2004 12:43:25 -0000 1.104 --- AnyEdit.rc 1 Nov 2004 14:12:01 -0000 1.105 *************** *** 2165,2170 **** GROUPBOX "",IDC_STATIC,7,7,207,76 LTEXT "&Text",IDC_STATIC1,19,19,70,8 ! COMBOBOX IDC_TEXT,94,15,114,132,CBS_DROPDOWN | CBS_SORT | ! WS_VSCROLL | WS_TABSTOP CONTROL "&Begin of line",IDC_BEGIN_OF_LINE,"Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,19,35,70,10 --- 2165,2170 ---- GROUPBOX "",IDC_STATIC,7,7,207,76 LTEXT "&Text",IDC_STATIC1,19,19,70,8 ! COMBOBOX IDC_TEXT,94,15,114,132,CBS_DROPDOWN | CBS_AUTOHSCROLL | ! CBS_SORT | WS_VSCROLL | WS_TABSTOP CONTROL "&Begin of line",IDC_BEGIN_OF_LINE,"Button", BS_AUTORADIOBUTTON | WS_GROUP | WS_TABSTOP,19,35,70,10 |
From: Leon W. <moo...@us...> - 2004-10-28 13:43:54
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13149 Modified Files: OutputEdit.cpp OutputEdit.h Log Message: Added automatic showing/hiding of the scrollbars. Index: OutputEdit.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/OutputEdit.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** OutputEdit.cpp 6 Oct 2004 20:40:34 -0000 1.4 --- OutputEdit.cpp 28 Oct 2004 13:43:28 -0000 1.5 *************** *** 149,152 **** --- 149,153 ---- ON_COMMAND(ID_OUTPUT_ERROR, OnOutputError) ON_COMMAND(ID_OUTPUT_SAVE, OnOutputSave) + ON_CONTROL_REFLECT(EN_CHANGE, OnChange) //}}AFX_MSG_MAP END_MESSAGE_MAP() *************** *** 159,162 **** --- 160,166 ---- //CPaintDC dc(this); // device context for painting Default(); + + SetAutoScrollBars(); + if (m_bCanPaint) DrawLine(TRUE); *************** *** 381,382 **** --- 385,430 ---- return CEdit::PreTranslateMessage(pMsg); } + + void COutputEdit::OnChange() + { + SetAutoScrollBars(); + } + + void COutputEdit::SetAutoScrollBars() + { + // How about some automatic ScrollBars + + // First determine the longest line. + int iLine = 0; + for( int i = 0; i < GetLineCount(); ++ i ) + { + if( LineLength( LineIndex( iLine ) ) < LineLength( LineIndex( i ) ) ) + { + iLine = i; + } + } + + // Get the text of the longest line. + CString szText; + GetLine( iLine, szText.GetBuffer( LineLength( LineIndex( iLine ) ) ), LineLength( LineIndex( iLine ) ) ); + szText.ReleaseBuffer(); + + // Get the size of the client window + CRect rcClient; + GetClientRect( rcClient ); + + // Get the size of the line + CFont* pFont = GetFont(); + CClientDC dc(this); + dc.SelectObject(pFont); + CSize sizeText = dc.GetTextExtent( szText ); + + // Enable/Disable the scrollbars. + if( sizeText.cx > rcClient.Width() ) ShowScrollBar( SB_HORZ, TRUE ); + else ShowScrollBar( SB_HORZ, FALSE ); + + if( sizeText.cy * GetLineCount() > rcClient.Height() ) ShowScrollBar( SB_VERT, TRUE ); + else ShowScrollBar( SB_VERT, FALSE ); + + // End of automatic ScrollBar code. + } Index: OutputEdit.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/OutputEdit.h,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** OutputEdit.h 6 Oct 2004 20:40:34 -0000 1.3 --- OutputEdit.h 28 Oct 2004 13:43:28 -0000 1.4 *************** *** 49,52 **** --- 49,53 ---- afx_msg void OnOutputError(); afx_msg void OnOutputSave(); + afx_msg void OnChange(); //}}AFX_MSG protected: *************** *** 64,67 **** --- 65,69 ---- int GetCurLine(); BOOL CanParseLine(); + void SetAutoScrollBars(); public: |
From: Leon W. <moo...@us...> - 2004-10-25 13:36:10
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20067 Modified Files: ScintillaEx.cpp ScintillaEx.h Log Message: Fixed Bookmark code to correctly handle deletion of lines and bookmarks. Index: ScintillaEx.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/ScintillaEx.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** ScintillaEx.cpp 18 Oct 2004 17:00:18 -0000 1.17 --- ScintillaEx.cpp 25 Oct 2004 13:36:02 -0000 1.18 *************** *** 304,327 **** void CScintillaEx::ToggleBookmark(long lLine) { ! std::deque<long>::iterator pos; ! ! if( !dqBookmarks.empty() ) { ! for( pos = dqBookmarks.begin(); pos < dqBookmarks.end(); ++ pos ) ! { ! if( lLine == *pos ) { ! MarkerDelete(lLine, SC_BOOKMARK); ! dqBookmarks.erase(pos); ! return; ! } ! } } - - dqBookmarks.push_back(lLine); - std::sort(dqBookmarks.begin(), dqBookmarks.end()); - - // Add the marker. - MarkerAdd(lLine, SC_BOOKMARK); } --- 304,332 ---- void CScintillaEx::ToggleBookmark(long lLine) { ! if( MarkerGet( lLine ) & ( 1 << SC_BOOKMARK ) ) { ! MarkerDelete( lLine, SC_BOOKMARK ); ! // Check if all the handles are still valid. ! if( !dqBookmarks.empty() ) ! { ! std::deque<int>::iterator pos; ! pos = dqBookmarks.begin(); ! while( pos < dqBookmarks.end() ) ! { ! if( -1 == MarkerLineFromHandle( *pos ) ) ! { ! pos = dqBookmarks.erase( pos ); ! } ! else ! { ! ++ pos; ! } ! } ! } ! } ! else { ! dqBookmarks.push_back( MarkerAdd( lLine, SC_BOOKMARK ) ); } } *************** *** 335,341 **** void CScintillaEx::FirstBookmark() { ! if( dqBookmarks.empty() ) return; ! ! GotoLineEnsureVisible( dqBookmarks[0] ); } --- 340,348 ---- void CScintillaEx::FirstBookmark() { ! if( HasBookmarks() ) ! { ! int rc = MarkerNext( 0, ( 1 << SC_BOOKMARK )); ! if( -1 != rc ) GotoLineEnsureVisible( rc ); ! } } *************** *** 343,349 **** void CScintillaEx::LastBookmark() { ! if( dqBookmarks.empty() ) return; ! ! GotoLineEnsureVisible( dqBookmarks[dqBookmarks.size()-1] ); } --- 350,358 ---- void CScintillaEx::LastBookmark() { ! if( HasBookmarks() ) ! { ! int rc = MarkerPrevious( LineFromPosition( GetLength() ), ( 1 << SC_BOOKMARK ) ); ! if( -1 != rc ) GotoLineEnsureVisible( rc ); ! } } *************** *** 351,376 **** void CScintillaEx::PreviousBookmark() { ! int iIndex; ! long lLine = LineFromPosition( GetCurrentPos() ); ! ! if( dqBookmarks.empty() ) return; ! ! for( iIndex = 0; iIndex < dqBookmarks.size(); ++ iIndex ) ! { ! if( dqBookmarks[iIndex] >= lLine ) { ! -- iIndex; ! if( iIndex < 0 ) ! { ! LastBookmark(); ! } ! else ! { ! GotoLineEnsureVisible( dqBookmarks[iIndex] ); ! } ! return; ! } } - GotoLineEnsureVisible( dqBookmarks[-- iIndex] ); } --- 360,372 ---- void CScintillaEx::PreviousBookmark() { ! if( HasBookmarks() ) { ! int rc = MarkerPrevious( LineFromPosition( GetCurrentPos() ) - 1, ( 1 << SC_BOOKMARK ) ); ! if( -1 == rc ) ! { ! rc = MarkerPrevious( LineFromPosition( GetLength() ), ( 1 << SC_BOOKMARK ) ); ! } ! if( -1 != rc ) GotoLineEnsureVisible( rc ); } } *************** *** 378,395 **** void CScintillaEx::NextBookmark() { ! int iIndex; ! long lLine = LineFromPosition( GetCurrentPos() ); ! ! if( dqBookmarks.empty() ) return; ! ! for( iIndex = 0; iIndex < dqBookmarks.size(); ++ iIndex ) { ! if( dqBookmarks[iIndex] > lLine ) { ! GotoLineEnsureVisible( dqBookmarks[iIndex] ); ! return; } } - FirstBookmark(); } --- 374,386 ---- void CScintillaEx::NextBookmark() { ! if( HasBookmarks() ) { ! int rc = MarkerNext( LineFromPosition( GetCurrentPos() ) + 1, ( 1 << SC_BOOKMARK ) ); ! if( -1 == rc ) { ! rc = MarkerNext( 0, ( 1 << SC_BOOKMARK ) ); } + if( -1 != rc ) GotoLineEnsureVisible( rc ); } } Index: ScintillaEx.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/ScintillaEx.h,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** ScintillaEx.h 23 Sep 2004 21:32:14 -0000 1.14 --- ScintillaEx.h 25 Oct 2004 13:36:02 -0000 1.15 *************** *** 151,156 **** CStringArray m_saBlockComment; ! /// The deque to store the lines with a bookmark ! std::deque<long> dqBookmarks; public: bool IsSaveConvertTabToSpaces(void); --- 151,156 ---- CStringArray m_saBlockComment; ! /// The deque to store the bookmark handles ! std::deque<int> dqBookmarks; public: bool IsSaveConvertTabToSpaces(void); |
From: Leon W. <moo...@us...> - 2004-10-25 13:32:43
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19163 Modified Files: AnyEditToDoList.xml Log Message: Updates with Sourceforge items and bugs found in the test. Index: AnyEditToDoList.xml =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/AnyEditToDoList.xml,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** AnyEditToDoList.xml 4 Oct 2004 07:58:31 -0000 1.29 --- AnyEditToDoList.xml 25 Oct 2004 13:32:32 -0000 1.30 *************** *** 1,4 **** <?xml version="1.0" encoding="windows-1252"?> ! <TODOLIST FILEFORMAT="6" PROJECTNAME="AnyEdit ToDo List" NEXTUNIQUEID="683" LASTSORTBY="5" FILEVERSION="104" LASTSORTDIR="1" LASTMODIFIED="2004-10-04"> <TASK STARTDATESTRING="2004-04-20" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38240.34590278" TITLE="Source Code" TIMEESTUNITS="H" COMMENTS="Coding Conventions and Development Guidelines." ID="154" STARTDATE="38097.00000000" POS="1"> <TASK STARTDATESTRING="2004-04-07" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38125.66063657" TITLE="Doxygen Comment" TIMEESTUNITS="H" PERSON="LW, DP, CS, GH" COMMENTS="Source Documentation is Mandatory. We shall gradually add it along the way." ID="16" STARTDATE="38084.00000000" POS="1"/> --- 1,4 ---- <?xml version="1.0" encoding="windows-1252"?> ! <TODOLIST FILEFORMAT="6" PROJECTNAME="AnyEdit ToDo List" NEXTUNIQUEID="694" LASTSORTBY="5" FILEVERSION="110" LASTSORTDIR="1" LASTMODIFIED="2004-10-25"> <TASK STARTDATESTRING="2004-04-20" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38240.34590278" TITLE="Source Code" TIMEESTUNITS="H" COMMENTS="Coding Conventions and Development Guidelines." ID="154" STARTDATE="38097.00000000" POS="1"> <TASK STARTDATESTRING="2004-04-07" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38125.66063657" TITLE="Doxygen Comment" TIMEESTUNITS="H" PERSON="LW, DP, CS, GH" COMMENTS="Source Documentation is Mandatory. We shall gradually add it along the way." ID="16" STARTDATE="38084.00000000" POS="1"/> *************** *** 23,33 **** <TASK STARTDATESTRING="2004-09-29" PRIORITY="1" TIMEESPENTUNITS="H" LASTMOD="38259.51017361" TITLE="Renaming tool doesn't affect toobar" TIMEESTUNITS="H" PERSON="None" COMMENTS="[#1032164][#100020] [LW] This is a BCG problem, we can't change the Tooltip to the name of the tool. This must be solved in GuiToolkit." ID="432" STARTDATE="38259.00000000" POS="5"/> ! <TASK STARTDATESTRING="2004-10-03" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38263.83456019" TITLE="not W98 compatible" TIMEESTUNITS="H" COMMENTS="Because of function in the FileSpec class we are not w98 compatible." ID="682" STARTDATE="38263.00000000" POS="6"/> ! <TASK STARTDATESTRING="2004-07-22" PRIORITY="3" TIMEESPENTUNITS="H" LASTMOD="38263.84944444" TITLE="EOL characters get colored" TIMEESTUNITS="H" PERSON="CS" COMMENTS="On a document with CRLF EOL characters the CR gets the same color as the text on the line, but the LF is black. Scinitlla bug? ! [LW] Can you update with a status of the bug report to scintilla and monitor it so we know when it's fixed." ID="299" STARTDATE="38190.00000000" POS="7"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38261.87687500" TITLE="build 401" TIMEESTUNITS="H" COMMENTS="Beta 3" ID="433" STARTDATE="38261.00000000" POS="3"> <TASK STARTDATESTRING="2004-08-02" PRIORITY="8" TIMEESPENTUNITS="H" LASTMOD="38261.87697917" TITLE="New images for items." TIMEESTUNITS="H" PERSON="GH" ID="336" STARTDATE="38201.00000000" POS="1"/> ! <TASK STARTDATESTRING="2004-09-17" PRIORITY="2" TIMEESPENTUNITS="H" LASTMOD="38261.87704861" TITLE="Outputbar Ctrl+A" TIMEESTUNITS="H" PERSON="DP" COMMENTS="[CS] COutputEdit: Add Ctrl-A for select all in COutputEdit like in VS." ID="417" STARTDATE="38247.00000000" POS="2"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38261.73966435" TITLE="build 402" TIMEESTUNITS="H" COMMENTS="Integration of GuiToolkit, Testers Release" ID="434" STARTDATE="38261.00000000" POS="4"> --- 23,44 ---- <TASK STARTDATESTRING="2004-09-29" PRIORITY="1" TIMEESPENTUNITS="H" LASTMOD="38259.51017361" TITLE="Renaming tool doesn't affect toobar" TIMEESTUNITS="H" PERSON="None" COMMENTS="[#1032164][#100020] [LW] This is a BCG problem, we can't change the Tooltip to the name of the tool. This must be solved in GuiToolkit." ID="432" STARTDATE="38259.00000000" POS="5"/> ! <TASK STARTDATESTRING="2004-10-03" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38267.36766204" TITLE="not W98 compatible" TIMEESTUNITS="H" PERSON="GH" COMMENTS="Because of function in the FileSpec class we are not w98 compatible." ID="682" PERCENTDONE="100" STARTDATE="38263.00000000" DONEDATESTRING="2004-10-07" POS="6" DONEDATE="38267.00000000"/> ! <TASK STARTDATESTRING="2004-07-22" PRIORITY="3" TIMEESPENTUNITS="H" LASTMOD="38266.78995370" TITLE="EOL characters get colored" TIMEESTUNITS="H" PERSON="CS" COMMENTS="On a document with CRLF EOL characters the CR gets the same color as the text on the line, but the LF is black. Scinitlla bug? ! [LW] It's added to the Scintilla Repository. Now al we need is update to the next version when it is released. ! " ID="299" STARTDATE="38190.00000000" POS="7"/> ! <TASK STARTDATESTRING="2004-10-05" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38267.36753472" TITLE="OutputBar and Escape" TIMEESTUNITS="H" PERSON="LW" COMMENTS="Pressing escape when focus is on OutputBar removes all tabs, but the window can still be edited. Tool output is gone." ID="683" PERCENTDONE="100" STARTDATE="38265.00000000" DONEDATESTRING="2004-10-07" POS="8" DONEDATE="38267.00000000"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="1" TIMEESPENTUNITS="H" LASTMOD="38285.49134259" TITLE="AnyEdit freezes when starting with splashscreen off." TIMEESTUNITS="H" PERSON="None" COMMENTS="[#1045820]" ID="688" STARTDATE="38285.00000000" POS="9"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38285.49194444" TITLE="Language Tool buttons don't all work" TIMEESTUNITS="H" PERSON="LW" COMMENTS="[#1048921]" ID="689" STARTDATE="38285.00000000" POS="10"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38285.49318287" TITLE="Closing file from association Crash" TIMEESTUNITS="H" PERSON="LW" COMMENTS="[#1050284] I think this is already fixed, shall test it before closing it." ID="690" STARTDATE="38285.00000000" POS="11"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38285.49483796" TITLE="$FILENAME bug under W98" TIMEESTUNITS="H" PERSON="LW" COMMENTS="[#1052500] It also returnes part of the path!" ID="691" STARTDATE="38285.00000000" POS="12"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38285.64331019" TITLE="Class View parsing of C# files get stuck in an endless loop." TIMEESTUNITS="H" PERSON="None" ID="693" STARTDATE="38285.64252315" POS="13"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="10" TIMEESPENTUNITS="H" LASTMOD="38261.87687500" TITLE="build 401" TIMEESTUNITS="H" COMMENTS="Beta 3" ID="433" STARTDATE="38261.00000000" POS="3"> <TASK STARTDATESTRING="2004-08-02" PRIORITY="8" TIMEESPENTUNITS="H" LASTMOD="38261.87697917" TITLE="New images for items." TIMEESTUNITS="H" PERSON="GH" ID="336" STARTDATE="38201.00000000" POS="1"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38285.48218750" TITLE="Horizontal Scrollbar OutputBar" TIMEESTUNITS="H" PERSON="None" ID="685" STARTDATE="38285.00000000" POS="2"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38285.48247685" TITLE="Bookmark problem deleting lines" TIMEESTUNITS="H" PERSON="LW" ID="686" STARTDATE="38285.00000000" POS="3"/> ! <TASK STARTDATESTRING="2004-10-25" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38285.48452546" TITLE="Class View bug" TIMEESTUNITS="H" PERSON="GH" COMMENTS="Putting a forward declaration of a function at the top of your source file and having the implementation in the same file, result in a double entry in the class view. ! Is this a ctags or an AE problem? ! [LW] I'll test it some more and put an example on the developer list." ID="687" STARTDATE="38285.00000000" POS="4"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38261.73966435" TITLE="build 402" TIMEESTUNITS="H" COMMENTS="Integration of GuiToolkit, Testers Release" ID="434" STARTDATE="38261.00000000" POS="4"> *************** *** 41,45 **** --- 52,58 ---- [#1000520] " ID="347" STARTDATE="38222.00000000" POS="3"/> + <TASK STARTDATESTRING="2004-10-05" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38267.36815972" TITLE="GHOutputWnd" TIMEESTUNITS="H" PERSON="GH" ID="684" STARTDATE="38265.00000000" POS="4"/> </TASK> + <TASK STARTDATESTRING="2004-09-17" PRIORITY="2" TIMEESPENTUNITS="H" LASTMOD="38261.87704861" TITLE="Outputbar Ctrl+A" TIMEESTUNITS="H" PERSON="DP" COMMENTS="[CS] COutputEdit: Add Ctrl-A for select all in COutputEdit like in VS." ID="417" STARTDATE="38247.00000000" POS="2"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38261.74032407" TITLE="build 403" TIMEESTUNITS="H" COMMENTS="Beta 4" ID="435" STARTDATE="38261.00000000" POS="5"> *************** *** 254,258 **** [LW] Guy do you know what is meant?" ID="349" STARTDATE="38229.00000000" POS="26"/> <TASK STARTDATESTRING="2004-05-22" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38131.38060185" TITLE="Mark compile errors while typing" TIMEESTUNITS="H" PERSON="None" COMMENTS="This other neat feature allows background compiling of the current file as you type, and will mark all the errors and warnings as squiggly lines under the text (same as misspelled words in Word)" ID="240" STARTDATE="38129.00000000" POS="27"/> ! <TASK STARTDATESTRING="2004-04-07" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38263.86586806" TITLE="New Tool Tokens" TIMEESTUNITS="H" PERSON="LW" COMMENTS="$FILE $FILENAME $BASENAME --- 267,271 ---- [LW] Guy do you know what is meant?" ID="349" STARTDATE="38229.00000000" POS="26"/> <TASK STARTDATESTRING="2004-05-22" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38131.38060185" TITLE="Mark compile errors while typing" TIMEESTUNITS="H" PERSON="None" COMMENTS="This other neat feature allows background compiling of the current file as you type, and will mark all the errors and warnings as squiggly lines under the text (same as misspelled words in Word)" ID="240" STARTDATE="38129.00000000" POS="27"/> ! <TASK STARTDATESTRING="2004-04-07" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38285.49934028" TITLE="New Tool Tokens" TIMEESTUNITS="H" PERSON="None" COMMENTS="$FILE $FILENAME $BASENAME *************** *** 268,271 **** --- 281,286 ---- Note not all are added and working yet. [LW] Posted a question to the teammembers for more ideas. No reaction yet." ID="41" STARTDATE="38084.00000000" POS="28"/> + <TASK STARTDATESTRING="2004-10-25" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38285.50010417" TITLE="Auto insert EOL character after word wrap" TIMEESTUNITS="H" PERSON="None" COMMENTS="[#1039736] Automatically adding a EOL after a word wrap. + [LW] I think saving with hard EOL's is a better solution (and easier to implement?)?" ID="692" STARTDATE="38285.00000000" POS="29"/> </TASK> <TASK STARTDATESTRING="2004-10-01" PRIORITY="5" TIMEESPENTUNITS="H" LASTMOD="38261.75159722" TITLE="Old Task" TIMEESTUNITS="H" COMMENTS="Tasks I still need to put somewere." ID="674" STARTDATE="38261.00000000" POS="11"> |
From: Leon W. <moo...@us...> - 2004-10-21 13:27:13
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30802 Modified Files: XMLFile.cpp Log Message: Changed parsing options so whitespace isn't trimmed. Index: XMLFile.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/XMLFile.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** XMLFile.cpp 18 Sep 2004 15:10:00 -0000 1.7 --- XMLFile.cpp 21 Oct 2004 13:27:00 -0000 1.8 *************** *** 87,91 **** { if( xnode.empty() ) return _T( "" ); ! pug::xml_node elnode( xnode.first_element_by_name( element ) ); if( elnode.empty() || !elnode.has_child_nodes() ) return _T(""); --- 87,91 ---- { if( xnode.empty() ) return _T( "" ); ! pug::xml_node elnode( xnode.first_element_by_name( element ) ); if( elnode.empty() || !elnode.has_child_nodes() ) return _T(""); *************** *** 198,202 **** if( xnode.empty() ) return _T(""); } ! if( !xnode.has_attributes() ) return _T(""); --- 198,202 ---- if( xnode.empty() ) return _T(""); } ! if( !xnode.has_attributes() ) return _T(""); *************** *** 274,278 **** // Ok parse the file. ! if( !m_xml_parser.parse_file( m_sFileName ) ) return false; // Set the flag and return true. --- 274,278 ---- // Ok parse the file. ! if( !m_xml_parser.parse_file( m_sFileName, pug::parse_pi | pug::parse_doctype | pug::parse_comments | pug::parse_cdata ) ) return false; // Set the flag and return true. |
From: boca4711 <boc...@us...> - 2004-10-20 16:33:46
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12456/GuiLib Modified Files: GuiTabbed.cpp GuiTabbed.h Log Message: - Implemented OnScrollClose Index: GuiTabbed.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabbed.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** GuiTabbed.cpp 15 Oct 2004 14:01:52 -0000 1.5 --- GuiTabbed.cpp 20 Oct 2004 16:33:33 -0000 1.6 *************** *** 21,26 **** ****************************************************************************/ - - #include "stdafx.h" #include "guitabbed.h" --- 21,24 ---- *************** *** 33,36 **** --- 31,35 ---- #define IDD_COMBOBOX 0x889 + // #define countof(array) (sizeof(array)/sizeof(array[0])) CGuiTabbed::CGuiTabbed(void) *************** *** 323,326 **** --- 322,326 ---- } dc->DrawText(ctb->lpMsg,m_rectTabAux,DT_SINGLELINE|DT_CENTER|DT_VCENTER); + CToolTip.SetToolRect(this, iCont+1, mrt); if (iCont !=m_iSelectTab) *************** *** 392,396 **** Drawtabs(&dc); //RecalLayout(); - } --- 392,395 ---- *************** *** 403,412 **** } void CGuiTabbed::OnScrollClose() { ! //no es nuestro problema lo debe manejar la clase derivada } - int CGuiTabbed::OnCreate(LPCREATESTRUCT lpCreateStruct) { --- 402,412 ---- } + /// Close current window void CGuiTabbed::OnScrollClose() { ! CWnd* pWnd = GetNumWnd(GetCurtab()); ! pWnd->SendMessage(WM_CLOSE); } int CGuiTabbed::OnCreate(LPCREATESTRUCT lpCreateStruct) { *************** *** 487,489 **** return TRUE; ! }*/ \ No newline at end of file --- 487,489 ---- return TRUE; ! }*/ Index: GuiTabbed.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabbed.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiTabbed.h 15 Oct 2004 14:01:52 -0000 1.2 --- GuiTabbed.h 20 Oct 2004 16:33:33 -0000 1.3 *************** *** 38,41 **** --- 38,43 ---- int m_nDif; ExtTab m_ExtTab; + + public: CGuiTabbed(void); |
From: boca4711 <boc...@us...> - 2004-10-20 16:31:44
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11965/GuiLib Modified Files: GuiMDITabbed.cpp GuiMDITabbed.h Log Message: - Caption shows filename only - Pathname is shown as tooltip Index: GuiMDITabbed.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiMDITabbed.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiMDITabbed.cpp 15 Oct 2004 14:01:50 -0000 1.3 --- GuiMDITabbed.cpp 20 Oct 2004 16:31:35 -0000 1.4 *************** *** 34,42 **** END_MESSAGE_MAP() - - - - - LRESULT CGuiMDITabbed::OnSizeParent(WPARAM, LPARAM lParam) { --- 34,37 ---- *************** *** 140,193 **** } void CGuiMDITabbed::UpdateWindows() { ! CFrameWnd* pParent = STATIC_DOWNCAST(CFrameWnd, AfxGetMainWnd()); ! ! SetTimer(1,200,NULL); ! CWnd* pWnd=CWnd::FromHandle(::GetTopWindow(GetParentFrame()->GetSafeHwnd())); TCHAR ClassName[32]; while (pWnd != NULL) { ! ::GetClassName(pWnd->GetSafeHwnd(),ClassName,32); ! CString szClassName=ClassName; ! if(szClassName=="MDIClient") break; ! pWnd=pWnd->GetNextWindow(); } ASSERT(::IsWindow(pWnd->GetSafeHwnd())); //primero adicionar los nuevos ! ! CWnd* pChild= CWnd::FromHandle(::GetTopWindow(pWnd->GetSafeHwnd())); ! ! while(pChild != NULL) { ! CString m_Caption; ! pChild->GetWindowText(m_Caption); ! if (!m_Caption.IsEmpty()) { - if (!FindItem(pChild->GetSafeHwnd())) { ! Addtab(pChild,m_Caption,-1); SetTabMenu(hMenu); } else ! UpdateCaption(pChild,m_Caption); ! } pChild= CWnd::FromHandle(::GetNextWindow(pChild->GetSafeHwnd(), GW_HWNDNEXT)); - } //---eliminar las ventanas borradas ! int nNumtabs=GetCount(); ! for (int i=0; i< nNumtabs; i++) { CWnd* pWnd=GetNumWnd(i); --- 135,194 ---- } + /// Update all tab captions. + /// Tab captions show file name. void CGuiMDITabbed::UpdateWindows() { + CFrameWnd* pParent = STATIC_DOWNCAST(CFrameWnd, AfxGetMainWnd()); ! SetTimer(1, 200, NULL); ! CWnd* pWnd = CWnd::FromHandle(::GetTopWindow(GetParentFrame()->GetSafeHwnd())); TCHAR ClassName[32]; while (pWnd != NULL) { ! ::GetClassName(pWnd->GetSafeHwnd(), ClassName, 32); ! CString szClassName = ClassName; ! if(szClassName == "MDIClient") break; ! pWnd = pWnd->GetNextWindow(); } ASSERT(::IsWindow(pWnd->GetSafeHwnd())); //primero adicionar los nuevos + CWnd* pChild = CWnd::FromHandle(::GetTopWindow(pWnd->GetSafeHwnd())); ! CString strCaption; ! CString strTooltip; while(pChild != NULL) { ! pChild->GetWindowText(strCaption); ! int y = strCaption.ReverseFind('\\'); ! strCaption = strCaption.Right(strCaption.GetLength() - 1 - y); ! if (!strCaption.IsEmpty()) { if (!FindItem(pChild->GetSafeHwnd())) { + strTooltip.Empty(); + CMDIChildWnd* pChildWnd = (CMDIChildWnd*) FromHandlePermanent(pChild->GetSafeHwnd()); + CDocument* pDoc=((CMDIChildWnd*)pChildWnd)->GetActiveDocument(); + if(pDoc != NULL) + strTooltip = pDoc->GetPathName(); ! if(strTooltip.IsEmpty()) ! strTooltip = strCaption; ! ! Addtab(pChild, strCaption, -1, strTooltip); SetTabMenu(hMenu); } else ! UpdateCaption(pChild, strCaption); } pChild= CWnd::FromHandle(::GetNextWindow(pChild->GetSafeHwnd(), GW_HWNDNEXT)); } //---eliminar las ventanas borradas ! int nNumtabs = GetCount(); ! for (int i=0; i < nNumtabs; i++) { CWnd* pWnd=GetNumWnd(i); *************** *** 199,206 **** } } ! SetTimer(1,100,NULL); ! } - - --- 200,204 ---- } } ! SetTimer(1, 100, NULL); } Index: GuiMDITabbed.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiMDITabbed.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiMDITabbed.h 15 Oct 2004 14:01:50 -0000 1.2 --- GuiMDITabbed.h 20 Oct 2004 16:31:35 -0000 1.3 *************** *** 44,47 **** //}}AFX_MSG DECLARE_MESSAGE_MAP(); - }; --- 44,46 ---- |
From: boca4711 <boc...@us...> - 2004-10-20 16:27:36
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10791/GuiLib Modified Files: GuiTabWnd.cpp GuiTabWnd.h Log Message: - Addtab extended with tooltip text - DeleteTab calls DestroyWindow Index: GuiTabWnd.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** GuiTabWnd.h 15 Oct 2004 14:01:52 -0000 1.5 --- GuiTabWnd.h 20 Oct 2004 16:27:27 -0000 1.6 *************** *** 63,67 **** void SetTypeTab(TypeTab Type=TYPE_NORMAL); void virtual Drawtabs(CDC* dc); ! void Addtab(CWnd* pParent,CString lpMsg,UINT uIcon); void SetImageList(UINT nBitmapID, int cx, int nGrow, COLORREF crMask); void RecalLayout(); --- 63,67 ---- void SetTypeTab(TypeTab Type=TYPE_NORMAL); void virtual Drawtabs(CDC* dc); ! void Addtab(CWnd* pParent, CString lpMsg, UINT uIcon, LPCTSTR lpcsTooltip = NULL); void SetImageList(UINT nBitmapID, int cx, int nGrow, COLORREF crMask); void RecalLayout(); Index: GuiTabWnd.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** GuiTabWnd.cpp 15 Oct 2004 14:01:52 -0000 1.6 --- GuiTabWnd.cpp 20 Oct 2004 16:27:27 -0000 1.7 *************** *** 589,594 **** } ! ! void CGuiTabWnd::Addtab(CWnd *pParent, CString lpMsg, UINT uIcon) { ASSERT_VALID(pParent); --- 589,594 ---- } ! /// Add tab to tab control. ! void CGuiTabWnd::Addtab(CWnd *pParent, CString lpMsg, UINT uIcon, LPCTSTR lpcsTooltip) { ASSERT_VALID(pParent); *************** *** 615,620 **** } ! if (m_style == S3D) ! CToolTip.AddTool(this,lpMsg,CRect(0,0,0,0),m_Numtabs); RecalLayout(); } --- 615,625 ---- } ! if (m_style == S3D || m_TypeTab == TYPE_MDI) ! { ! if (lpcsTooltip != NULL) ! CToolTip.AddTool(this, lpcsTooltip, CRect(0,0,0,0), m_Numtabs); ! else ! CToolTip.AddTool(this, lpMsg, CRect(0,0,0,0), m_Numtabs); ! } RecalLayout(); } *************** *** 625,643 **** if (m_numtab < m_Numtabs) { ! CGuiTab* ctn=(CGuiTab*) m_pArray[m_numtab]; ! if (m_alnTab!=ALN_TOP) ASSERT_VALID(ctn->pParent); if (ctn) delete ctn; m_Numtabs--; ! m_pArray.RemoveAt(m_numtab,1); ! if (m_Numtabs >0) { if (m_iSelectTab == m_numtab) { ! m_iSelectTab=m_iSelectTab-1; ! if (m_iSelectTab< 0) m_iSelectTab=0; CGuiTab* ctn =(CGuiTab*) m_pArray[m_iSelectTab]; ! CWnd* pParentNew=ctn->pParent; ASSERT_VALID(pParentNew); pParentNew->ShowWindow(SW_SHOW); --- 630,650 ---- if (m_numtab < m_Numtabs) { ! CGuiTab* ctn = (CGuiTab*) m_pArray[m_numtab]; ! if (m_alnTab != ALN_TOP) ASSERT_VALID(ctn->pParent); + if (::IsWindow(HWND(ctn->pParent->GetSafeHwnd()))) + ctn->pParent->DestroyWindow(); if (ctn) delete ctn; m_Numtabs--; ! m_pArray.RemoveAt(m_numtab, 1); ! if (m_Numtabs > 0) { if (m_iSelectTab == m_numtab) { ! m_iSelectTab = m_iSelectTab-1; ! if (m_iSelectTab< 0) m_iSelectTab = 0; CGuiTab* ctn =(CGuiTab*) m_pArray[m_iSelectTab]; ! CWnd* pParentNew = ctn->pParent; ASSERT_VALID(pParentNew); pParentNew->ShowWindow(SW_SHOW); |
From: boca4711 <boc...@us...> - 2004-10-18 17:00:26
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2716 Modified Files: ScintillaEx.cpp Log Message: SaveFile remembers line and col of last selection because remove trailing spaces can move selection Index: ScintillaEx.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/ScintillaEx.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** ScintillaEx.cpp 28 Sep 2004 20:07:02 -0000 1.16 --- ScintillaEx.cpp 18 Oct 2004 17:00:18 -0000 1.17 *************** *** 1800,1804 **** bool CScintillaEx::SaveFile(LPCTSTR filename) { ! CharacterRange crange = GetSelection(); if (IsSelection()) SetSel(GetCurrentPos(), GetCurrentPos()); --- 1800,1809 ---- bool CScintillaEx::SaveFile(LPCTSTR filename) { ! // Save selection as line and column ! long nLineStart = LineFromPosition(GetSelectionStart()); ! long nColStart = GetColumn(GetSelectionStart()); ! long nLineEnd = LineFromPosition(GetSelectionEnd()); ! long nColEnd = GetColumn(GetSelectionEnd()); ! if (IsSelection()) SetSel(GetCurrentPos(), GetCurrentPos()); *************** *** 1819,1823 **** SetSavePoint(); ! SetSel(crange.cpMin, crange.cpMax); return bSuccess; } --- 1824,1833 ---- SetSavePoint(); ! // Restore selection ! SetSelectionStart(PositionFromLine(nLineStart) + nColStart); ! if (PositionFromLine(nLineEnd) + nColEnd > GetLineEndPosition(nLineEnd)) ! SetSelectionEnd(GetLineEndPosition(nLineEnd)); ! else ! SetSelectionEnd(PositionFromLine(nLineEnd) + nColEnd); return bSuccess; } |
From: boca4711 <boc...@us...> - 2004-10-18 16:58:12
|
Update of /cvsroot/anyedit/AnyEditv2 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2197 Modified Files: filegrep.cpp Log Message: Bugfix: files and folder arrays were not cleared before search Index: filegrep.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditv2/filegrep.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** filegrep.cpp 19 Sep 2004 13:27:33 -0000 1.2 --- filegrep.cpp 18 Oct 2004 16:58:04 -0000 1.3 *************** *** 96,99 **** --- 96,101 ---- m_bCountOnly = (dwFlags & flagCountOnly ? true : false); m_bFolders = (dwFlags & flagFolders ? true : false); + m_arFolders.RemoveAll(); + m_arFiles.RemoveAll(); if (m_bFolders) { |
From: boca4711 <boc...@us...> - 2004-10-17 19:15:22
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16941/GuiLib Modified Files: GuiStatusBar.cpp GuiStatusBar.h Log Message: - Removed drawing of sizing control - Renamed some member functions Index: GuiStatusBar.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiStatusBar.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiStatusBar.h 15 Oct 2004 14:01:50 -0000 1.2 --- GuiStatusBar.h 17 Oct 2004 19:15:13 -0000 1.3 *************** *** 43,56 **** BOOL SetIndicators (const UINT* lpIDArray, int nIDCount); ! void Drawpanels(CDC *pDC); virtual void PreSubclassWindow(); ! void DrawLB(CRect *rcLb,CDC* pDC); ! void ClearRect(CDC* pDC,CRect rc); ! void SetStyle(Style nStyle=CGuiStatusBar::DEVSTUDIO); ! void SetPanelText(CString szText,UINT uPanel); ! virtual void StyleDispl(DWORD dwDsp=GUISTYLE_XP) { ! m_StyleDisplay=dwDsp; ! SendMessage(WM_NCPAINT);Invalidate(); UpdateWindow(); } --- 43,56 ---- BOOL SetIndicators (const UINT* lpIDArray, int nIDCount); ! void DrawPanes(CDC *pDC); virtual void PreSubclassWindow(); ! void DrawLB(CRect *rcLb, CDC* pDC); ! void ClearRect(CDC* pDC, CRect rc); ! void SetStyle(Style nStyle = CGuiStatusBar::DEVSTUDIO); ! void SetPanelText(CString szText, UINT uPanel); ! virtual void StyleDispl(DWORD dwDsp = GUISTYLE_XP) { ! m_StyleDisplay = dwDsp; ! SendMessage(WM_NCPAINT); Invalidate(); UpdateWindow(); } Index: GuiStatusBar.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiStatusBar.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiStatusBar.cpp 15 Oct 2004 14:01:50 -0000 1.3 --- GuiStatusBar.cpp 17 Oct 2004 19:15:13 -0000 1.4 *************** *** 29,45 **** // CGuiStatusBar IMPLEMENT_DYNAMIC(CGuiStatusBar, CStatusBar) CGuiStatusBar::CGuiStatusBar() { ! m_Style=DEVSTUDIO; ! m_cfont.CreateFont(14,0,0,0,400,0,0,0,0,1,2,1,34,_T("Arial")); ! m_StyleDisplay=GUISTYLE_XP; } CGuiStatusBar::~CGuiStatusBar() { } - BEGIN_MESSAGE_MAP(CGuiStatusBar, CStatusBar) //{{AFX_MSG_MAP(CGuiStatusBar) --- 29,46 ---- // CGuiStatusBar + /// ctor IMPLEMENT_DYNAMIC(CGuiStatusBar, CStatusBar) CGuiStatusBar::CGuiStatusBar() { ! m_Style = DEVSTUDIO; ! m_cfont.CreateFont(14, 0, 0, 0, 400, 0, 0, 0, 0, 1, 2, 1, 34, _T("Arial")); ! m_StyleDisplay = GUISTYLE_XP; } + /// dtor CGuiStatusBar::~CGuiStatusBar() { } BEGIN_MESSAGE_MAP(CGuiStatusBar, CStatusBar) //{{AFX_MSG_MAP(CGuiStatusBar) *************** *** 48,103 **** END_MESSAGE_MAP() - - // CGuiStatusBar message handlers void CGuiStatusBar::SetStyle(Style nStyle) { ! m_Style=nStyle; } void CGuiStatusBar::PreSubclassWindow() { ! ModifyStyle(0,BS_OWNERDRAW); CStatusBar::PreSubclassWindow(); } void CGuiStatusBar::OnPaint() { ! CRect rcClient,rcTemp; CBrush cb; CPaintDC dc(this); GetClientRect(&rcClient); cb.CreateSolidBrush(GuiDrawLayer::GetRGBColorFace(m_StyleDisplay)); ! CWnd::DefWindowProc( WM_PAINT, (WPARAM)dc.m_hDC, 0 ); ! rcTemp=rcClient; ! rcClient.bottom=rcClient.top+2; ! rcClient.right+=50; ! // dc.FillRect(rcClient,&cb); ! Drawpanels(&dc); cb.DeleteObject(); } ! void CGuiStatusBar::Drawpanels(CDC *pDC) { ! int iCont=GetCount(); ! CRect rcCli,rcCliente; ! CString m_cad; ! int OldMode=pDC->SetBkMode(TRANSPARENT); ! for (int i=0; i < iCont; i++) { ! GetItemRect(i,&rcCli); ! GetPaneText(i, m_cad); ! if (i == iCont-1) { ! CSize m_sChar=pDC->GetTextExtent(m_cad,m_cad.GetLength()); ! if (rcCli.Width() < m_sChar.cx) { ! int dif=m_sChar.cx-rcCli.Width(); ! rcCli.right=rcCli.left+m_sChar.cx-dif; } - } ! /*if(m_StyleDisplay=GUISTYLE_2003) { CFont m_fontMenu; --- 49,106 ---- END_MESSAGE_MAP() // CGuiStatusBar message handlers + /// Set style of status bar. void CGuiStatusBar::SetStyle(Style nStyle) { ! m_Style = nStyle; } + + /// Set owner draw mode to status bar. void CGuiStatusBar::PreSubclassWindow() { ! ModifyStyle(0, BS_OWNERDRAW); CStatusBar::PreSubclassWindow(); } + /// Paint status bar void CGuiStatusBar::OnPaint() { ! CRect rcClient, rcTemp; CBrush cb; CPaintDC dc(this); GetClientRect(&rcClient); cb.CreateSolidBrush(GuiDrawLayer::GetRGBColorFace(m_StyleDisplay)); ! CWnd::DefWindowProc( WM_PAINT, (WPARAM) dc.m_hDC, 0 ); ! rcTemp = rcClient; ! rcClient.bottom = rcClient.top + 2; ! rcClient.right += 50; ! // dc.FillRect(rcClient, &cb); ! DrawPanes(&dc); cb.DeleteObject(); } ! /// Draw all panels of status bar. ! void CGuiStatusBar::DrawPanes(CDC *pDC) { ! int nCount = GetCount(); ! CRect rcPane, rcClient; ! CString strPaneText; ! int OldMode = pDC->SetBkMode(TRANSPARENT); ! for (int i = 0; i < nCount; i++) { ! GetItemRect(i, &rcPane); ! GetPaneText(i, strPaneText); ! if (i == nCount - 1) { ! CSize m_sChar = pDC->GetTextExtent(strPaneText, strPaneText.GetLength()); ! if (rcPane.Width() < m_sChar.cx) { ! int dif = m_sChar.cx - rcPane.Width(); ! rcPane.right = rcPane.left + m_sChar.cx - dif; } } ! /*if(m_StyleDisplay = GUISTYLE_2003) { CFont m_fontMenu; *************** *** 106,116 **** SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(info), &info, 0); VERIFY(m_fontMenu.CreateFontIndirect(&info.lfMenuFont)); ! CFont* oldfont=(CFont*)pDC->SelectObject(&m_fontMenu); ! CGradient M(CSize(rcCli.Width(),rcCli.Height())); ! M.PrepareReverseVert(pDC,m_StyleDisplay); ! M.Draw(pDC,rcCli.left,rcCli.top,0,0,rcCli.Width(),rcCli.Height(),SRCCOPY); ! rcCli.top+=2; ! rcCli.left+=3; ! pDC->DrawText(m_cad,rcCli,DT_LEFT ); pDC->SelectObject(oldfont); --- 109,119 ---- SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(info), &info, 0); VERIFY(m_fontMenu.CreateFontIndirect(&info.lfMenuFont)); ! CFont* oldfont = (CFont*) pDC->SelectObject(&m_fontMenu); ! CGradient M(CSize(rcPane.Width(), rcPane.Height())); ! M.PrepareReverseVert(pDC, m_StyleDisplay); ! M.Draw(pDC, rcPane.left, rcPane.top, 0, 0, rcPane.Width(), rcPane.Height(), SRCCOPY); ! rcPane.top += 2; ! rcPane.left += 3; ! pDC->DrawText(strPaneText, rcPane,DT_LEFT); pDC->SelectObject(oldfont); *************** *** 119,218 **** {*/ if (m_Style == DEVSTUDIO) ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style),GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); else ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorTabs(),GuiDrawLayer::GetRGBColorTabs()); //} ! if (i == iCont-1) { ! rcCli.left=rcCli.right; ! rcCli.right=rcCli.left+2; ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorFace(),GuiDrawLayer::GetRGBColorFace()); ! rcCli.right+=1; ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorFace(),GuiDrawLayer::GetRGBColorFace()); ! rcCli.right+=1; ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorFace(),GuiDrawLayer::GetRGBColorFace()); ! } - - - } pDC->SetBkMode(OldMode); ! GetClientRect(&rcCliente); ! if ((rcCliente.right - rcCli.right) != 0) { CBrush cb; cb.CreateSolidBrush(GuiDrawLayer::GetRGBColorFace()); ! rcCliente.left = rcCli.right; ! rcCliente.bottom= rcCliente.top+6; ! pDC->FillRect(rcCliente,&cb); ! //DrawLB(&rcCliente,pDC); } CRect rc; GetClientRect(&rc); ! rc.left=rc.right-15; ! rc.top=rc.bottom-15; CPen pWhite; CPen pDark; ! pWhite.CreatePen(PS_SOLID,1,RGB(255,255,255)); ! pDark.CreatePen(PS_SOLID,1,GuiDrawLayer::m_Style==GUISTYLE_2003?GuiDrawLayer::GetRGBColorShadow():GuiDrawLayer::GetRGBPressBXP()); CPen* pPt= pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left,rc.bottom); ! pDC->LineTo(rc.right,rc.top); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left+1,rc.bottom); ! pDC->LineTo(rc.right,rc.top+1); ! pDC->MoveTo(rc.left+2,rc.bottom); ! pDC->LineTo(rc.right,rc.top+2); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left+4,rc.bottom); ! pDC->LineTo(rc.right,rc.top+4); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left+5,rc.bottom); ! pDC->LineTo(rc.right,rc.top+5); ! pDC->MoveTo(rc.left+6,rc.bottom); ! pDC->LineTo(rc.right,rc.top+6); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left+8,rc.bottom); ! pDC->LineTo(rc.right,rc.top+8); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left+9,rc.bottom); ! pDC->LineTo(rc.right,rc.top+9); ! pDC->MoveTo(rc.left+10,rc.bottom); ! pDC->LineTo(rc.right,rc.top+10); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left+12,rc.bottom); ! pDC->LineTo(rc.right,rc.top+12); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left+13,rc.bottom); ! pDC->LineTo(rc.right,rc.top+13); pDC->SelectObject(pPt); ! } ! void CGuiStatusBar::ClearRect(CDC* pDC,CRect rc) { ! CRect rcCli=rc; ! rcCli.left+=1; ! rcCli.top+=1; ! for (int i=0; i < 3; i++) { ! rcCli.right-=1; ! rcCli.bottom-=1; ! pDC->Draw3dRect(rcCli,GuiDrawLayer::GetRGBColorFace(),GuiDrawLayer::GetRGBColorFace()); } } ! void CGuiStatusBar::DrawLB(CRect* rcLb,CDC* pDC) { pDC->SelectStockObject(COLOR_3DSHADOW); ! int gap=10; ! for (int i=0; i< 3; i++) { ! pDC->MoveTo(rcLb->left+gap,rcLb->bottom); ! pDC->LineTo(rcLb->right,rcLb->top+gap+1); ! gap+=2; } } --- 122,225 ---- {*/ if (m_Style == DEVSTUDIO) ! pDC->Draw3dRect(rcPane, GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style), GuiDrawLayer::GetRGBColorShadow(GuiDrawLayer::m_Style)); else ! pDC->Draw3dRect(rcPane, GuiDrawLayer::GetRGBColorTabs(), GuiDrawLayer::GetRGBColorTabs()); //} ! if (i == nCount - 1) { ! rcPane.left = rcPane.right; ! rcPane.right = rcPane.left + 2; ! pDC->Draw3dRect(rcPane, GuiDrawLayer::GetRGBColorFace(), GuiDrawLayer::GetRGBColorFace()); ! rcPane.right += 1; ! pDC->Draw3dRect(rcPane, GuiDrawLayer::GetRGBColorFace(), GuiDrawLayer::GetRGBColorFace()); ! rcPane.right += 1; ! pDC->Draw3dRect(rcPane, GuiDrawLayer::GetRGBColorFace(), GuiDrawLayer::GetRGBColorFace()); } } pDC->SetBkMode(OldMode); ! GetClientRect(&rcClient); ! if ((rcClient.right - rcPane.right) != 0) { CBrush cb; cb.CreateSolidBrush(GuiDrawLayer::GetRGBColorFace()); ! rcClient.left = rcPane.right; ! rcClient.bottom = rcClient.top + 6; ! pDC->FillRect(rcClient, &cb); ! //DrawLB(&rcClient,pDC); } + /** \todo: Do we need this part? + * Without the following code it works fine too. (Win2000). + * This code draws the resizeable button on the right side. + * Without this code the button is only drawn in normal mode. In full screen + * mode the button was hidden. + * This code does not detect fullscreen mode. + */ + /* CRect rc; GetClientRect(&rc); ! rc.left = rc.right - 15; ! rc.top = rc.bottom - 15; CPen pWhite; CPen pDark; ! pWhite.CreatePen(PS_SOLID, 1, RGB(255,255,255)); ! pDark.CreatePen(PS_SOLID, 1, GuiDrawLayer::m_Style == GUISTYLE_2003 ? GuiDrawLayer::GetRGBColorShadow() : GuiDrawLayer::GetRGBPressBXP()); CPen* pPt= pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left, rc.bottom); ! pDC->LineTo(rc.right, rc.top); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left + 1, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 1); ! pDC->MoveTo(rc.left + 2, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 2); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left + 4, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 4); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left + 5, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 5); ! pDC->MoveTo(rc.left + 6, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 6); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left + 8, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 8); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left + 9, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 9); ! pDC->MoveTo(rc.left + 10, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 10); pDC->SelectObject(&pWhite); ! pDC->MoveTo(rc.left + 12, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 12); pDC->SelectObject(&pDark); ! pDC->MoveTo(rc.left + 13, rc.bottom); ! pDC->LineTo(rc.right, rc.top + 13); pDC->SelectObject(pPt); ! */ } ! void CGuiStatusBar::ClearRect(CDC* pDC, CRect rc) { ! CRect rcCli = rc; ! rcCli.left += 1; ! rcCli.top += 1; ! for (int i = 0; i < 3; i++) { ! rcCli.right -= 1; ! rcCli.bottom -= 1; ! pDC->Draw3dRect(rcCli, GuiDrawLayer::GetRGBColorFace(), GuiDrawLayer::GetRGBColorFace()); } } ! void CGuiStatusBar::DrawLB(CRect* rcLb, CDC* pDC) { pDC->SelectStockObject(COLOR_3DSHADOW); ! int gap = 10; ! for (int i = 0; i < 3; i++) { ! pDC->MoveTo(rcLb->left + gap, rcLb->bottom); ! pDC->LineTo(rcLb->right, rcLb->top + gap + 1); ! gap += 2; } } *************** *** 220,232 **** void CGuiStatusBar::SetPanelText(CString szText,UINT uPanel) { ! int nIndex=CommandToIndex(uPanel); ! SetPaneText(nIndex,szText); CWindowDC dc(this); ! CSize sizeText=dc.GetTextExtent(szText); ! SetPaneInfo(nIndex,uPanel,SBPS_NORMAL,sizeText.cx); ! } - BOOL CGuiStatusBar::SetIndicators (const UINT* lpIDArray, int nIDCount) { --- 227,237 ---- void CGuiStatusBar::SetPanelText(CString szText,UINT uPanel) { ! int nIndex = CommandToIndex(uPanel); ! SetPaneText(nIndex, szText); CWindowDC dc(this); ! CSize sizeText = dc.GetTextExtent(szText); ! SetPaneInfo(nIndex, uPanel, SBPS_NORMAL, sizeText.cx); } BOOL CGuiStatusBar::SetIndicators (const UINT* lpIDArray, int nIDCount) { *************** *** 243,248 **** int cxWidth; GetPaneInfo (nIndex, nID, nStyle, cxWidth); ! SetPaneInfo (nIndex, nID, nStyle|SBPS_NOBORDERS, cxWidth); } return true; ! } \ No newline at end of file --- 248,253 ---- int cxWidth; GetPaneInfo (nIndex, nID, nStyle, cxWidth); ! SetPaneInfo (nIndex, nID, nStyle | SBPS_NOBORDERS, cxWidth); } return true; ! } |
From: boca4711 <boc...@us...> - 2004-10-17 19:14:13
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16614/GuiLib Modified Files: GuiListEdit.cpp Log Message: Mouse and key commands are disabled when buttons are invisible Index: GuiListEdit.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiListEdit.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** GuiListEdit.cpp 13 Oct 2004 23:26:46 -0000 1.5 --- GuiListEdit.cpp 17 Oct 2004 19:14:04 -0000 1.6 *************** *** 118,123 **** int iSelItem = GetSelItem (); ! // if ((m_uiStandardBtns & BGCEDITLISTBOX_BTN_NEW) && iSelItem == -1) ! if (iSelItem == -1) { Insert(); --- 118,122 ---- int iSelItem = GetSelItem (); ! if ((m_uButtons & BtnInsert) && iSelItem == -1) { Insert(); *************** *** 313,329 **** { case VK_INSERT: ! Insert(); break; case VK_DELETE: Delete(); break; case VK_DOWN: case VK_RIGHT: ! if (::GetAsyncKeyState (VK_MENU) & 0x8000) Down(); break; case VK_UP: case VK_LEFT: ! if (::GetAsyncKeyState (VK_MENU) & 0x8000) Up(); break; --- 312,330 ---- { case VK_INSERT: ! if (m_uButtons & BtnInsert) ! Insert(); break; case VK_DELETE: + if (m_uButtons & BtnDelete) Delete(); break; case VK_DOWN: case VK_RIGHT: ! if ((m_uButtons & BtnDown) && ::GetAsyncKeyState (VK_MENU) & 0x8000) Down(); break; case VK_UP: case VK_LEFT: ! if ((m_uButtons & BtnUp) && ::GetAsyncKeyState (VK_MENU) & 0x8000) Up(); break; |
From: boca4711 <boc...@us...> - 2004-10-17 19:12:38
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15880/GuiLib Modified Files: GuiButton.cpp GuiButton.h Log Message: - Renamed member functions and variable names - Deleted unused code - Added doxygen comments Index: GuiButton.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiButton.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** GuiButton.cpp 11 Oct 2004 18:01:23 -0000 1.5 --- GuiButton.cpp 17 Oct 2004 19:12:29 -0000 1.6 *************** *** 43,54 **** m_iAlign = ALIGN_LEFT; m_iStyle = STYLE_SEMIFLAT; - m_lpMsg = _T(""); m_iSelected = 0; m_bShowImage = FALSE; m_bShowText = TRUE; m_iTypeButton = TYPE_NORMAL; // Normal by default ! m_iMenuActivo = FALSE; ! m_clrface = GuiDrawLayer::GetRGBColorFace(); ! m_ReposWindow = FALSE; m_bIsDark = FALSE; m_iResMenu = 0; --- 43,53 ---- m_iAlign = ALIGN_LEFT; m_iStyle = STYLE_SEMIFLAT; m_iSelected = 0; m_bShowImage = FALSE; m_bShowText = TRUE; m_iTypeButton = TYPE_NORMAL; // Normal by default ! m_bMenuActive = FALSE; ! m_clrFace = GuiDrawLayer::GetRGBColorFace(); ! m_bReposWindow = FALSE; m_bIsDark = FALSE; m_iResMenu = 0; *************** *** 120,124 **** { if (STYLEXP == m_iStyle) ! cb.CreateSolidBrush(m_clrface); } else if (m_iSelected == 1) // el mouse esta sobre el boton --- 119,123 ---- { if (STYLEXP == m_iStyle) ! cb.CreateSolidBrush(m_clrFace); } else if (m_iSelected == 1) // el mouse esta sobre el boton *************** *** 369,373 **** pDC->Draw3dRect(m_rect, GuiDrawLayer::GetRGBColorShadow(), GuiDrawLayer::GetRGBColorBTNHigh()); else if (STYLEXP == m_iStyle) ! DrawBottonXP(pDC, m_rect, NORMAL); else // si es 3d { --- 368,372 ---- pDC->Draw3dRect(m_rect, GuiDrawLayer::GetRGBColorShadow(), GuiDrawLayer::GetRGBColorBTNHigh()); else if (STYLEXP == m_iStyle) ! DrawButtonXP(pDC, m_rect, NORMAL); else // si es 3d { *************** *** 391,395 **** pDC->Draw3dRect(m_rect, GuiDrawLayer::GetRGBColorBTNHigh(), GuiDrawLayer::GetRGBColorShadow()); else if (STYLEXP == m_iStyle) ! DrawBottonXP(pDC, m_rect, OVER); else // si es 3d { --- 390,394 ---- pDC->Draw3dRect(m_rect, GuiDrawLayer::GetRGBColorBTNHigh(), GuiDrawLayer::GetRGBColorShadow()); else if (STYLEXP == m_iStyle) ! DrawButtonXP(pDC, m_rect, OVER); else // si es 3d { *************** *** 425,436 **** if (m_State & ODS_DISABLED) { ! DrawBottonXP(pDC, m_rect, DISABLED); } else { if (m_State & ODS_FOCUS) ! DrawBottonXP(pDC, m_rect, FOCUS); else ! DrawBottonXP(pDC, m_rect, NORMAL); } } --- 424,435 ---- if (m_State & ODS_DISABLED) { ! DrawButtonXP(pDC, m_rect, DISABLED); } else { if (m_State & ODS_FOCUS) ! DrawButtonXP(pDC, m_rect, FOCUS); else ! DrawButtonXP(pDC, m_rect, NORMAL); } } *************** *** 441,445 **** else { ! pDC->Draw3dRect(m_rect, m_clrface, m_clrface); } } --- 440,444 ---- else { ! pDC->Draw3dRect(m_rect, m_clrFace, m_clrFace); } } *************** *** 453,460 **** } ! ! void CGuiButton::AutoSizeButton(BOOL m_bAutoAjust) { ! m_ReposWindow = m_bAutoAjust; Invalidate(); UpdateWindow(); --- 452,458 ---- } ! void CGuiButton::AutoSizeButton(BOOL bAutoAdjust) { ! m_bReposWindow = bAutoAdjust; Invalidate(); UpdateWindow(); *************** *** 464,472 **** { CButton::OnSysColorChange(); ! m_clrface = GuiDrawLayer::GetRGBColorXP(); } //************************************************************************* ! void CGuiButton::DrawBottonXP(CDC* pDC, CRect rc, int Estado) { COLORREF clrPress = ::GetSysColor(COLOR_HIGHLIGHT); --- 462,470 ---- { CButton::OnSysColorChange(); ! m_clrFace = GuiDrawLayer::GetRGBColorXP(); } //************************************************************************* ! void CGuiButton::DrawButtonXP(CDC* pDC, CRect rc, int iState) { COLORREF clrPress = ::GetSysColor(COLOR_HIGHLIGHT); *************** *** 476,485 **** CPen cp(PS_SOLID, 1, clrPress); ! CPen cpface(PS_SOLID, 1, m_clrface); CPen cpsxp(PS_SOLID, 1, GuiDrawLayer::GetRGBColorXP()); CPen cpOver(PS_SOLID, 1, RGB(255, 193, 111)); CPen cpShadow(PS_SOLID, 1, clrShadow); CPen* pOld = NULL; ! if (Estado != DISABLED) pOld = pDC->SelectObject(&cp); else --- 474,483 ---- CPen cp(PS_SOLID, 1, clrPress); ! CPen cpface(PS_SOLID, 1, m_clrFace); CPen cpsxp(PS_SOLID, 1, GuiDrawLayer::GetRGBColorXP()); CPen cpOver(PS_SOLID, 1, RGB(255, 193, 111)); CPen cpShadow(PS_SOLID, 1, clrShadow); CPen* pOld = NULL; ! if (iState != DISABLED) pOld = pDC->SelectObject(&cp); else *************** *** 500,504 **** pDC->LineTo(rc.right - 1, rc.bottom); ! if (Estado != DISABLED) { // se dibuja algunas lineas para dar forma 3d --- 498,502 ---- pDC->LineTo(rc.right - 1, rc.bottom); ! if (iState != DISABLED) { // se dibuja algunas lineas para dar forma 3d *************** *** 520,524 **** rcBordes.left += 1; rcBordes.top += 1; ! switch (Estado) { case OVER: --- 518,522 ---- rcBordes.left += 1; rcBordes.top += 1; ! switch (iState) { case OVER: *************** *** 536,555 **** // pintar los vertices // left,top ! pDC->SetPixel(rc.left + 1, rc.top, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left, rc.top + 1, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left + 1, rc.top + 1, Estado != DISABLED ? clrPress:clrShadow); // pintar los vertices // left,bottom ! pDC->SetPixel(rc.left + 1, rc.bottom, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left, rc.bottom - 1, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left + 1, rc.bottom - 1, Estado != DISABLED ? clrPress:clrShadow); // right,top ! pDC->SetPixel(rc.right - 1, rc.top, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right, rc.top + 1, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right - 1, rc.top + 1, Estado != DISABLED ? clrPress:clrShadow); // right,bottom ! pDC->SetPixel(rc.right - 1, rc.bottom, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right, rc.bottom - 1, Estado != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right - 1, rc.bottom - 1, Estado != DISABLED ? clrPress:clrShadow); } pDC->SelectObject(pOld); --- 534,553 ---- // pintar los vertices // left,top ! pDC->SetPixel(rc.left + 1, rc.top, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left, rc.top + 1, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left + 1, rc.top + 1, iState != DISABLED ? clrPress:clrShadow); // pintar los vertices // left,bottom ! pDC->SetPixel(rc.left + 1, rc.bottom, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left, rc.bottom - 1, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.left + 1, rc.bottom - 1, iState != DISABLED ? clrPress:clrShadow); // right,top ! pDC->SetPixel(rc.right - 1, rc.top, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right, rc.top + 1, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right - 1, rc.top + 1, iState != DISABLED ? clrPress:clrShadow); // right,bottom ! pDC->SetPixel(rc.right - 1, rc.bottom, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right, rc.bottom - 1, iState != DISABLED ? GuiDrawLayer::GetRGBFondoXP():clrShadow); ! pDC->SetPixel(rc.right - 1, rc.bottom - 1, iState != DISABLED ? clrPress:clrShadow); } pDC->SelectObject(pOld); *************** *** 557,563 **** //***************************************************************************** ! void CGuiButton::SetColor(COLORREF m_clrFaces) { ! m_clrface = m_clrFaces; } --- 555,561 ---- //***************************************************************************** ! void CGuiButton::SetColor(COLORREF clrFaces) { ! m_clrFace = clrFaces; } *************** *** 566,570 **** { m_bShowImage = bShowImage; ! CalLayout(); } --- 564,568 ---- { m_bShowImage = bShowImage; ! CalcLayout(); } *************** *** 573,581 **** { m_bShowText = bShowText; ! CalLayout(); } //***************************************************************************** ! void CGuiButton::CalLayout() { CString m_str; --- 571,579 ---- { m_bShowText = bShowText; ! CalcLayout(); } //***************************************************************************** ! void CGuiButton::CalcLayout() { CString m_str; *************** *** 615,619 **** m_szButton= CSize(SizeCad.cx + sizeImag.cx + 7, m_High); ! if (m_ReposWindow == TRUE) { SetWindowPos(NULL, 0, 0, SizeCad.cx + sizeImag.cx + 10, m_High, --- 613,617 ---- m_szButton= CSize(SizeCad.cx + sizeImag.cx + 7, m_High); ! if (m_bReposWindow == TRUE) { SetWindowPos(NULL, 0, 0, SizeCad.cx + sizeImag.cx + 10, m_High, *************** *** 626,632 **** CSize CGuiButton::GetSizeButton() { ! m_ReposWindow = FALSE; ! CalLayout(); ! m_ReposWindow = TRUE; return m_szButton; } --- 624,630 ---- CSize CGuiButton::GetSizeButton() { ! m_bReposWindow = FALSE; ! CalcLayout(); ! m_bReposWindow = TRUE; return m_szButton; } *************** *** 695,705 **** //***************************************************************************** ! void CGuiButton::SetToolTip(LPCTSTR lpMsg) { - CRect rc; - m_lpMsg = lpMsg; if (GetSafeHwnd()== NULL) return; ! if (m_lpMsg != NULL) { if (m_ToolTipCtrl.GetSafeHwnd() == NULL) --- 693,701 ---- //***************************************************************************** ! void CGuiButton::SetToolTip(LPCTSTR lpszToolTip) { if (GetSafeHwnd()== NULL) return; ! if (lpszToolTip != NULL) { if (m_ToolTipCtrl.GetSafeHwnd() == NULL) *************** *** 707,715 **** m_ToolTipCtrl.Create(this, TTS_ALWAYSTIP); m_ToolTipCtrl.Activate(TRUE); ! m_ToolTipCtrl.AddTool(this, lpMsg); } else { ! m_ToolTipCtrl.UpdateTipText(lpMsg, this); } } --- 703,711 ---- m_ToolTipCtrl.Create(this, TTS_ALWAYSTIP); m_ToolTipCtrl.Activate(TRUE); ! m_ToolTipCtrl.AddTool(this, lpszToolTip); } else { ! m_ToolTipCtrl.UpdateTipText(lpszToolTip, this); } } *************** *** 719,727 **** { m_ToolTipCtrl.Create(this, TTS_ALWAYSTIP); ! m_ToolTipCtrl.AddTool(this, lpMsg); } else { ! m_ToolTipCtrl.UpdateTipText(lpMsg, this); } --- 715,723 ---- { m_ToolTipCtrl.Create(this, TTS_ALWAYSTIP); ! m_ToolTipCtrl.AddTool(this, lpszToolTip); } else { ! m_ToolTipCtrl.UpdateTipText(lpszToolTip, this); } *************** *** 731,746 **** //***************************************************************************** ! void CGuiButton::SetCaption(LPCTSTR lpMsg) { ! SetWindowText(lpMsg); m_bShowText = TRUE; ! CalLayout(); Invalidate(); } //***************************************************************************** ! void CGuiButton::SetTypeButton(TypeButton m_TypeButton) { ! m_iTypeButton = m_TypeButton; if (m_iTypeButton == TYPE_ARROW) { --- 727,742 ---- //***************************************************************************** ! void CGuiButton::SetCaption(LPCTSTR lpszCaption) { ! SetWindowText(lpszCaption); m_bShowText = TRUE; ! CalcLayout(); Invalidate(); } //***************************************************************************** ! void CGuiButton::SetTypeButton(TypeButton iType) { ! m_iTypeButton = iType; if (m_iTypeButton == TYPE_ARROW) { *************** *** 749,753 **** m_iTypeButton = TYPE_ARROW; m_iStyle = STYLE_3D; - m_lpMsg = _T(""); m_iSelected = 0; m_bShowImage = TRUE; --- 745,748 ---- *************** *** 795,808 **** //***************************************************************************** ! void CGuiButton::SetStyleBorder(Style m_Style) { ! m_iStyle = m_Style; } //***************************************************************************** ! void CGuiButton::SetAlignMsg(AlignMsg m_AlignMsg) { if (m_iTypeButton == TYPE_NORMAL) ! m_iAlign = m_AlignMsg; } --- 790,803 ---- //***************************************************************************** ! void CGuiButton::SetStyleBorder(Style iStyle) { ! m_iStyle = iStyle; } //***************************************************************************** ! void CGuiButton::SetAlign(Align iAlign) { if (m_iTypeButton == TYPE_NORMAL) ! m_iAlign = iAlign; } *************** *** 896,902 **** } ! if (m_pMenu->GetSafeHmenu() != NULL && m_iMenuActivo == FALSE) { ! m_iMenuActivo = TRUE; m_iResMenu = m_pMenu->GetSubMenu(0)->TrackPopupMenu(TPM_LEFTALIGN | TPM_LEFTBUTTON | TPM_NONOTIFY | TPM_RETURNCMD, x, y, GetParent(), NULL); --- 891,897 ---- } ! if (m_pMenu->GetSafeHmenu() != NULL && m_bMenuActive == FALSE) { ! m_bMenuActive = TRUE; m_iResMenu = m_pMenu->GetSubMenu(0)->TrackPopupMenu(TPM_LEFTALIGN | TPM_LEFTBUTTON | TPM_NONOTIFY | TPM_RETURNCMD, x, y, GetParent(), NULL); *************** *** 906,910 **** pParent->SendMessage(WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(), BN_CLICKED), (LPARAM) m_hWnd); } ! m_iMenuActivo = FALSE; } else --- 901,905 ---- pParent->SendMessage(WM_COMMAND, MAKEWPARAM(GetDlgCtrlID(), BN_CLICKED), (LPARAM) m_hWnd); } ! m_bMenuActive = FALSE; } else *************** *** 1074,1079 **** { COLORREF clrOrig = ::GetPixel (memDCDst, x, y); ! COLORREF clrFace = (m_clrface == (COLORREF)-1) ? ! GuiDrawLayer::GetRGBColorFace() : m_clrface; COLORREF clrNew = (clrOrig == clrFace) ? RGB (255, 255, 255) : clrOrig; --- 1069,1074 ---- { COLORREF clrOrig = ::GetPixel (memDCDst, x, y); ! COLORREF clrFace = (m_clrFace == (COLORREF) -1) ? ! GuiDrawLayer::GetRGBColorFace() : m_clrFace; COLORREF clrNew = (clrOrig == clrFace) ? RGB (255, 255, 255) : clrOrig; Index: GuiButton.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiButton.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** GuiButton.h 15 Oct 2004 14:01:50 -0000 1.5 --- GuiButton.h 17 Oct 2004 19:12:29 -0000 1.6 *************** *** 44,48 **** //************************************************* ! enum Style // Disposicìón del estilo { STYLE_3D = 0, --- 44,48 ---- //************************************************* ! enum Style //< style of button { STYLE_3D = 0, *************** *** 52,56 **** }; ! enum AlignMsg // alineacion del Mensaje { ALIGN_LEFT = 0, --- 52,56 ---- }; ! enum Align //< alignment { ALIGN_LEFT = 0, *************** *** 58,72 **** }; ! enum TypeButton { ! TYPE_NORMAL = 0, // Un boton normal ! TYPE_ARROW = 1, // un Boton con flecha por lo general para menus ! TYPE_LINK = 2 // Un boton con links }; enum StyleArrow { ! ARROW_RIGHT = 0, // el flecha va a la derecha ! ARROW_DOWN = 1 // el flecha va hacia abajo }; --- 58,72 ---- }; ! enum TypeButton //< type of button { ! TYPE_NORMAL = 0, //< normal button ! TYPE_ARROW = 1, //< menu button with arrow ! TYPE_LINK = 2 //< button for a link }; enum StyleArrow { ! ARROW_RIGHT = 0, //< arrow to right ! ARROW_DOWN = 1 //< arrow to down }; *************** *** 78,91 **** public: //********************************************************* ! void SetToolTip(LPCTSTR lpMsg); // pone tooltip al boton ! void SetCaption(LPCTSTR lpMsg); // pone un mensaje en el boton ! void SetStyleBorder(Style m_Style = STYLE_3D); // el boton es 3d semiflat estilo xp, etc ! void SetTypeButton(TypeButton m_TypeButton = TYPE_NORMAL); ! void SetAlignArrow(StyleArrow m_AlignArron = ARROW_RIGHT); ! void DrawBottonXP(CDC* pDC, CRect rc, BOOL bPress); ! BOOL SetImage(UINT uBitmapNormal, UINT uBitmapFoco = (UINT) - 1, UINT uBitmapPush = (UINT) - 1); void SetImage(HICON hIcon); ! void SetAlignMsg(AlignMsg m_AlignMsg = ALIGN_LEFT); /// Show image on button void ShowImage(BOOL bShowImage = TRUE); --- 78,91 ---- public: //********************************************************* ! void SetToolTip(LPCTSTR lpszToolTip); //< set tooltip text ! void SetCaption(LPCTSTR lpszCaption); //< set caption of button ! void SetStyleBorder(Style iStyle = STYLE_3D); //< set button style ! void SetTypeButton(TypeButton iType = TYPE_NORMAL); ! void SetAlignArrow(StyleArrow iAlignArrow = ARROW_RIGHT); ! void DrawButtonXP(CDC* pDC, CRect rc, int iState); ! BOOL SetImage(UINT uBitmapNormal, UINT uBitmapFocus = (UINT) - 1, UINT uBitmapPush = (UINT) - 1); void SetImage(HICON hIcon); ! void SetAlign(Align iAlign = ALIGN_LEFT); /// Show image on button void ShowImage(BOOL bShowImage = TRUE); *************** *** 93,98 **** void ShowText(BOOL bShowText = TRUE); void ShowMenu(); ! void CalLayout(); ! void SetColor(COLORREF m_clrFace); CSize GetSizeButton(); void SetDarkButton(BOOL bDark) --- 93,98 ---- void ShowText(BOOL bShowText = TRUE); void ShowMenu(); ! void CalcLayout(); ! void SetColor(COLORREF clrFace); CSize GetSizeButton(); void SetDarkButton(BOOL bDark) *************** *** 100,104 **** m_bIsDark = bDark; }; ! void AutoSizeButton(BOOL m_bAutoAjust = TRUE); void SetPopupMenu(CMenu* pMenu); //******************************************************** --- 100,104 ---- m_bIsDark = bDark; }; ! void AutoSizeButton(BOOL bAutoAdjust = TRUE); void SetPopupMenu(CMenu* pMenu); //******************************************************** *************** *** 108,129 **** //******************************************************** CToolTipCtrl m_ToolTipCtrl; ! int m_iAlign; //< message align ! int m_iStyle; //< Border Style ! int m_iTypeButton; //< Style bottom (Arrow, Normal, Link) int m_iSelected; int m_iStyleArrow; HICON m_hicon[3]; - LPCTSTR m_lpMsg; BOOL m_bShowImage; //< show image BOOL m_bShowText; //< show text int m_iResMenu; //< result of popup menu selection ! BOOL m_iMenuActivo; ! COLORREF m_clrface; CSize m_szButton; ! BOOL m_ReposWindow; BOOL m_bIsDark; ! HBITMAP m_hBitmap; //< Bitmap for buttons CSize m_sizeImage; //< size of bitmap image ! HBITMAP m_hBitmapDisabled; //< Bitmap for disabled buttons // ******************************************************* public: --- 108,128 ---- //******************************************************** CToolTipCtrl m_ToolTipCtrl; ! int m_iAlign; //< alignment ! int m_iStyle; //< border Style ! int m_iTypeButton; //< button style (Arrow, Normal, Link) int m_iSelected; int m_iStyleArrow; HICON m_hicon[3]; BOOL m_bShowImage; //< show image BOOL m_bShowText; //< show text int m_iResMenu; //< result of popup menu selection ! BOOL m_bMenuActive; ! COLORREF m_clrFace; CSize m_szButton; ! BOOL m_bReposWindow; BOOL m_bIsDark; ! HBITMAP m_hBitmap; //< bitmap for buttons CSize m_sizeImage; //< size of bitmap image ! HBITMAP m_hBitmapDisabled; //< bitmap for disabled buttons // ******************************************************* public: |
From: boca4711 <boc...@us...> - 2004-10-17 08:42:03
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24056/GuiLib Modified Files: MenuBar.cpp MenuBar.h Log Message: Added missing OnPaint handler Index: MenuBar.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/MenuBar.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** MenuBar.cpp 15 Oct 2004 14:01:52 -0000 1.4 --- MenuBar.cpp 17 Oct 2004 08:41:50 -0000 1.5 *************** *** 229,232 **** --- 229,233 ---- ON_WM_SETCURSOR() ON_WM_SYSCOLORCHANGE() + ON_WM_PAINT() //}}AFX_MSG_MAP ON_REGISTERED_MESSAGE(MB_SET_MENU_NULL, OnSetMenuNull) *************** *** 3272,3276 **** { CPaintDC pDC(this); // device context for painting - // TODO: Add your message handler code here // Do not call CControlBar::OnPaint() for painting messages CRect rect; GetClientRect(rect); --- 3273,3276 ---- *************** *** 3295,3311 **** if (m_pMenuControl) { if (IsFloating()) { ! m_pMenuControl->DelayLayoutAndDraw(&pDC, rect.Size(),bFlota); ! ! } else { if (m_dwStyle & CBRS_ORIENT_HORZ) ! m_pMenuControl->DelayLayoutAndDraw(&pDC, CSize(GetClipBoxLength(TRUE), rect.Height()),bFlota); else ! m_pMenuControl->DelayLayoutAndDraw(&pDC, CSize(rect.Width(), GetClipBoxLength(FALSE)),bFlota); } } - } - - --- 3295,3306 ---- if (m_pMenuControl) { if (IsFloating()) { ! m_pMenuControl->DelayLayoutAndDraw(&pDC, rect.Size(), bFlota); } else { if (m_dwStyle & CBRS_ORIENT_HORZ) ! m_pMenuControl->DelayLayoutAndDraw(&pDC, CSize(GetClipBoxLength(TRUE), rect.Height()), bFlota); else ! m_pMenuControl->DelayLayoutAndDraw(&pDC, CSize(rect.Width(), GetClipBoxLength(FALSE)), bFlota); } } } Index: MenuBar.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/MenuBar.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** MenuBar.h 15 Oct 2004 14:01:52 -0000 1.2 --- MenuBar.h 17 Oct 2004 08:41:50 -0000 1.3 *************** *** 385,388 **** --- 385,389 ---- afx_msg void OnSize(UINT nType, int cx, int cy); afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message); + afx_msg void OnPaint(); //}}AFX_MSG afx_msg LRESULT OnSetMenuNull(WPARAM wParam, LPARAM lParam); *************** *** 482,486 **** HWND OleMenuDescriptor(BOOL& bSend, UINT nMsg, WPARAM wParam, LPARAM lParam); CWnd* GetCmdSentOleWnd(); - afx_msg void OnPaint(); }; --- 483,486 ---- |
From: boca4711 <boc...@us...> - 2004-10-17 08:39:00
|
Update of /cvsroot/anyedit/AnyEditToolkit/Samples/OutlookDemo In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23611/Samples/OutlookDemo Modified Files: MainFrm.cpp Log Message: Changed GetImagIcon to GetImageIcon Index: MainFrm.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/Samples/OutlookDemo/MainFrm.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** MainFrm.cpp 26 Sep 2004 16:16:23 -0000 1.1 --- MainFrm.cpp 17 Oct 2004 08:38:50 -0000 1.2 *************** *** 76,80 **** pBtn->SetCaption("OutLook Today"); pBtn->SetToolTip("OutLook Today"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(0)); m_guiMiniToolLeft.RecalLayout(); } --- 76,80 ---- pBtn->SetCaption("OutLook Today"); pBtn->SetToolTip("OutLook Today"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(0)); m_guiMiniToolLeft.RecalLayout(); } *************** *** 88,92 **** pBtn->SetCaption("Calendario"); pBtn->SetToolTip("Calendario"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(1)); m_guiMiniToolLeft.RecalLayout(); } --- 88,92 ---- pBtn->SetCaption("Calendario"); pBtn->SetToolTip("Calendario"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(1)); m_guiMiniToolLeft.RecalLayout(); } *************** *** 98,102 **** pBtn->SetCaption("Contacto"); pBtn->SetToolTip("Contacto"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(2)); m_guiMiniToolLeft.RecalLayout(); } --- 98,102 ---- pBtn->SetCaption("Contacto"); pBtn->SetToolTip("Contacto"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(2)); m_guiMiniToolLeft.RecalLayout(); } *************** *** 107,111 **** pBtn->SetCaption("Tareas"); pBtn->SetToolTip("Tareas"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(3)); m_guiMiniToolLeft.RecalLayout(); } --- 107,111 ---- pBtn->SetCaption("Tareas"); pBtn->SetToolTip("Tareas"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(3)); m_guiMiniToolLeft.RecalLayout(); } *************** *** 116,120 **** pBtn->SetCaption("Notas"); pBtn->SetToolTip("Notas"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(4)); m_guiMiniToolLeft.RecalLayout(); } --- 116,120 ---- pBtn->SetCaption("Notas"); pBtn->SetToolTip("Notas"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(4)); m_guiMiniToolLeft.RecalLayout(); } *************** *** 125,129 **** pBtn->SetCaption("Eliminar"); pBtn->SetToolTip("Eliminar"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImagIcon(15)); m_guiMiniToolLeft.RecalLayout(); } --- 125,129 ---- pBtn->SetCaption("Eliminar"); pBtn->SetToolTip("Eliminar"); ! pBtn->SethIcon(m_guiMiniToolLeft.GetImageIcon(15)); m_guiMiniToolLeft.RecalLayout(); } |
From: Leon W. <moo...@us...> - 2004-10-15 14:05:30
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29995/GuiLib Removed Files: GuiLib.clw Log Message: Class Wizard Database removed, can be generated correctly. --- GuiLib.clw DELETED --- |