Solved

how to draw??

Posted on 1998-10-11
3
214 Views
Last Modified: 2013-11-20
how to draw in csplitterwnd...? derived from ceditview...
i want to draw a bitmap in one of the views

how??
0
Comment
Question by:eXcalibur
3 Comments
 

Expert Comment

by:ashishp092098
ID: 1323179
Forget the splitter for the time being...
Why would you derive from CEditView if you want to draw a bitmap in there? You should be deriving from CView and get your bitmap stuff working for it first. Once you have done that, same View class can also be used thru a splitter effortlessly.
0
 

Author Comment

by:eXcalibur
ID: 1323180
i dun quite get u....
but i tried deriving from a CView, it works, so now how to turn the other pne into a text editor?
how can i get the handle to individual panes??
0
 
LVL 1

Accepted Solution

by:
VAM345 earned 20 total points
ID: 1323181
BOOL CMyChildFrame::OnCreateClient(LPCREATESTRUCT, CCreateContext* pContext)
{
      if (!m_wndSplitter.CreateStatic(this, 1, 2))
      {
            TRACE0("Failed to CreateStaticSplitter\n");
            return FALSE;
      }

      // add the second splitter pane - an input view in column 1
      if (!m_wndSplitter.CreateView(0, 1,
            pContext->m_pNewViewClass, CSize(0, 0), pContext))
      {
            TRACE0("Failed to create first pane\n");
            return FALSE;
      }

      // add the first splitter pane - the default view in column 0
      if (!m_wndSplitter.CreateView(0, 0,
            RUNTIME_CLASS(CMyView), CSize(180, 50), pContext))
      {
            TRACE0("Failed to create second pane\n");
            return FALSE;
      }

      // activate the input view
      SetActiveView((CView*)m_wndSplitter.GetPane(0,1));
      
      return TRUE;
}

0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now