Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Docking Pane
  New Posts New Posts RSS Feed - Drawing not updated after adding Docking Pane
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Drawing not updated after adding Docking Pane

 Post Reply Post Reply
Author
Message
firdausabhar View Drop Down
Newbie
Newbie


Joined: 11 January 2009
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote firdausabhar Quote  Post ReplyReply Direct Link To This Post Topic: Drawing not updated after adding Docking Pane
    Posted: 11 January 2009 at 10:24pm
Hi,

I have a problem using Docking Pane. I'm developing a simple MFC application to draw objects in OnDraw function. However, after adding the docking pane, I cannot see my drawing (Pic 1). Instead, if i 'auto-hide' my pane, then i can see what have been drawn (Pic 2). Strangely, I can also update my drawing if i minimise and then maximise back my application.

Furthuremore, the place where the dock was before turns black if both of the pane autohide. (Pic 3).

In OnDraw(CDC* ipDC), i use BitBlt and set the OnEraseBkgnd(CDC* pDC) to return TRUE.

Thanks in advance,

Cheers,
F.Abhar

Pic 1:

.


Pic 2:



Pic 3:





Product: Xtreme Toolkit Pro v12.0      
Platform: Windows Vista Business (32bit) - SP 1, Aero Activated
Language: VStudio 2005, MFC, C++
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 12 January 2009 at 1:17am
Hi,
Attach sample to show what you do.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
adrien View Drop Down
Senior Member
Senior Member


Joined: 30 April 2007
Location: New Zealand
Status: Offline
Points: 449
Post Options Post Options   Thanks (0) Thanks(0)   Quote adrien Quote  Post ReplyReply Direct Link To This Post Posted: 12 January 2009 at 2:15am
sounds like you haven't set the style WS_CLIPSIBLINGS on the main client area.
Back to Top
firdausabhar View Drop Down
Newbie
Newbie


Joined: 11 January 2009
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote firdausabhar Quote  Post ReplyReply Direct Link To This Post Posted: 12 January 2009 at 8:26am
Hi, thanks for the replies,

I follow instructions in Codejock's Tutorial (Toolkit Pro User Guide) on adding docking pane to my application. First, I create the bars in OnCreate function:

// Create docking panes. CXTPDockingPane* pwndPane1 = m_paneManager.CreatePane( IDR_PANE_OPTIONS, CRect(0, 0,200, 120), dockLeftOf); CXTPDockingPane* pwndPane2 = m_paneManager.CreatePane( IDR_PANE_PROPERTIES, CRect(0, 0,200, 120), dockBottomOf, pwndPane1)


Then I added icons for the panes:

int nIDIcons[] = {IDR_PANE_OPTIONS, IDR_PANE_PROPERTIES}; m_paneManager.SetIcons(IDB_BITMAP_ICONS, nIDIcons, _countof(nIDIcons), RGB(0, 255, 0));


I disabled the code to attach CWnd derived class (OnDockingPaneNotify) since it doesn't have any difference after I enabling it before. Am I missing something?

I also changed my MainFrm derived class to CXTPFrameWnd since I would change my application interface later.

Thanks in advanced.

Cheers,
F.Abhar.
Product: Xtreme Toolkit Pro v12.0      
Platform: Windows Vista Business (32bit) - SP 1, Aero Activated
Language: VStudio 2005, MFC, C++
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

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

This page was generated in 0.047 seconds.