Search found 687 matches

by mesajflaviu
23 Feb 2015, 22:41
Forum: MFC, ATL, WTL si GDI+.
Topic: Vector to CArray
Replies: 23
Views: 18710

Re: Vector to CArray

Daca una dintre clone inchide acel handle (sa zicen ca e o fereastra care este distrusa), clelalte clone devin un fel de zombie iar aplicatia ta intra intr-un fel de scenariu post-apocaliptic in care developeri satui de vanat zombies, se inarmeaza cu furci si topoare ca sa taie gatul la boieri, par...
by mesajflaviu
23 Feb 2015, 22:40
Forum: MFC, ATL, WTL si GDI+.
Topic: Vector to CArray
Replies: 23
Views: 18710

Re: Vector to CArray

Revenind la OP Am gasit o clasa derivata din CBitmap, care foloseste intern un vector: vector<vector<COLORREF>> [...] La ce dracu' ar fi bun asa ceva? CBitmap e o clasa care contine un hahdle la un GDI object (HBITMAP) si expune cateva metode de lucru cu acesta. Un HBITMAP valid iti poate da printr...
by mesajflaviu
02 Feb 2015, 15:51
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Desi totul pare correct, totusi nu functioneaza :D void CGridCtrlExt::OnDraw(CDC* pDC) { // draw the grid HTHEME hTheme = OpenThemeData(m_hWnd, L"WINDOW"); // HTHEME hTheme = OpenThemeData(m_hWnd, L"MFCGridCtrl"); if(NULL != hTheme) { if(WS_VSCROLL & GetStyle()) { SCROLLBARINFO si; si.cbSize = size...
by mesajflaviu
28 Jan 2015, 20:06
Forum: MFC, ATL, WTL si GDI+.
Topic: Problema CListCtrl intr-un View
Replies: 4
Views: 6248

Re: Problema CListCtrl intr-un View

Poti sa postezi aici codul cu care inserezi coloanele in listcontrol ?
Ideea e ca parametrul 4 (nWidth) al metodei CListCtrl::InsertColumn iti seteaza latimea coloanei inserate in CListCtrl ... ai verificat asta ?
by mesajflaviu
23 Jan 2015, 13:50
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Ce e curios e ca, daca pun un rectangle cat clientul, vad doar galben in fata ochilor :)) void CGridCtrlExt::OnDraw(CDC* pDC) { // draw the grid HTHEME hTheme = OpenThemeData(m_hWnd, L"WINDOW"); // HTHEME hTheme = OpenThemeData(m_hWnd, L"MFCGridCtrl"); if(NULL != hTheme) { if(WS_VSCROLL & GetStyle()...
by mesajflaviu
23 Jan 2015, 13:47
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Desi totul pare correct, totusi nu functioneaza :D void CGridCtrlExt::OnDraw(CDC* pDC) { // draw the grid HTHEME hTheme = OpenThemeData(m_hWnd, L"WINDOW"); // HTHEME hTheme = OpenThemeData(m_hWnd, L"MFCGridCtrl"); if(NULL != hTheme) { if(WS_VSCROLL & GetStyle()) { SCROLLBARINFO si; si.cbSize = sizeo...
by mesajflaviu
22 Jan 2015, 12:26
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Am incercat in modul urmator: HTHEME hTheme = OpenThemeData(m_hWnd, L"WINDOW"); // HTHEME hTheme = OpenThemeData(m_hWnd, L"MFCGridCtrl"); if(NULL != hTheme) { CScrollBar* pScrollbar = GetScrollBarCtrl(SB_VERT); if(NULL != pScrollbar->GetSafeHwnd()) // <-- is always null { CRect rect; pScrollbar->Get...
by mesajflaviu
21 Jan 2015, 16:56
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Cred ca nu sant departe: void CGridCtrlExt::OnDraw(CDC* pDC) { // draw the grid HTHEME hTheme = OpenThemeData(m_hWnd, L"WINDOW"); if(NULL != hTheme) { CRect rect; GetClientRect(&rect); DrawThemeBackground(hTheme, pDC->GetSafeHdc(), WP_VERTSCROLL, VSS_NORMAL, &rect, NULL); CloseThemeData(hTheme); } }...
by mesajflaviu
20 Jan 2015, 10:26
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

ai putea sa schimbi tema unei fereste cu una cu scrollbar-uri care a arate asa cum vrea sefu
Incerc sa vad ce iese ...
by mesajflaviu
19 Jan 2015, 10:48
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

Daca as putea, i-as spune-o ! :biggrin:
by mesajflaviu
18 Jan 2015, 20:51
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Re: Custom scrollbar

In acel dialogbar am pus un CGridCtrl (un pic customizat) pentru a face o lista cu item-uri text, bitmap-uri, etc., totul pe fond negru ... Functioneaza, dar sefului meu nu-i place scrollbar-ul standard ... m-a pus sa-l fac negru/gri ... si la asta imi storc neuronul ...
by mesajflaviu
14 Jan 2015, 16:31
Forum: MFC, ATL, WTL si GDI+.
Topic: Custom scrollbar
Replies: 11
Views: 10285

Custom scrollbar

Ce solutie ar fi sa customizez scrollbar-ul unui control ? Am gasit ceva aici , si am incercat sa cusomizez scrollbar-ul unui gridcontrol ... incercarea este atasata ca aplicatie de test ... arata naspa, dar o mai luam eu la pila, daca mergea in aplicatia reala ... insa, acel grid-control, imi trebu...
by mesajflaviu
05 Jan 2015, 12:22
Forum: MFC, ATL, WTL si GDI+.
Topic: return CTypedPtrArray
Replies: 3
Views: 4776

Re: return CTypedPtrArray

Da, merge brici ! Multumesc.
by mesajflaviu
18 Dec 2014, 20:51
Forum: MFC, ATL, WTL si GDI+.
Topic: return CTypedPtrArray
Replies: 3
Views: 4776

Re: return CTypedPtrArray

Multumesc, o sa incerc solutia data de tine, dar cred ca voi reveni aici doar la anu' ... Numai bine !
by mesajflaviu
17 Dec 2014, 16:23
Forum: MFC, ATL, WTL si GDI+.
Topic: return CTypedPtrArray
Replies: 3
Views: 4776

return CTypedPtrArray

Am o situatie urmatoare: class CMyClass : public COtherClass { /// /// protected: class CHighlightCell : public CObject { // Attributes public: int m_nRow, m_nCol; // Implementation public: CHighlightCell(); CHighlightCell(int nRow, int nCol); virtual ~CHighlightCell(); }; CTypedPtrArray<CPtrArray, ...