Guidance
指路人
g.yi.org
Guidance Forums / wxWidgets (wxWindows) in C++ / how to generate a window in a window?

Register 
注册
Search 搜索
首页 
Home Home
Software
Upload

  
Forum List • Thread List • Refresh • New Topic • Search • Previous • Next First 1 Last
Message1. how to generate a window in a window?
#3553
Posted by: 2004-03-23 06:54:25
Dear experts,

the solution to my problem probably so easy, but I simply don't know (too new, to little experience with c++, but eager to learn)

I have defined a wxScrolledWindow (= first window) where I would like to write and paint data in two other windows that may be scrolled together in this first window.

I am looking for a key hint that makes these other two windows go into the scrolled window and depend on it instead of floating on top of my desktop.

All input is appreciated.

Best regards,

Wolfi
Message2. Re: how to generate a window in a window?
#3595
Posted by: 2004-03-26 06:20:31
Seems to be solved.

In the beginning, I had defined several frames in the style

TextFrame *frame_01 = new TextFrame
        ("   .: WopHOp :.     Main Window", 0, 0, 1023, 767);
    frame_01->Show(TRUE);
    SetTopWindow(frame_01);
which of course leads to a set of windows.

Now I just define 1 Frame as above ans then include the definitions for the windows like


myTextCtrl = new wxTextCtrl( 
    this, 
    -1,  //wxWindowID
    wxString("Type some text...some more some more"),
    wxPoint(0,0), 
    wxSize(300,300), 
    wxTE_MULTILINE | wxTE_RICH); //wxTE_READONLY | 

myTextCtrl2 = new wxTextCtrl( 
    this, 
    -1,  //wxWindowID
    wxString("Type some text...some more some more"),
    wxPoint(000,300), 
    wxSize(885,50), 
    wxTE_MULTILINE | wxTE_RICH); //wxTE_READONLY |  

Afterwards, everything is soooo logical.

Have fun,

Wo
Forum List • Thread List • Refresh • New Topic • Search • Previous • Next First 1 Last
掌柜推荐
 
 
 
 
 
 
 
 
 
 
 
 
© Fri 2024-4-19  Guidance Laboratory Inc.
Email:webmaster1g.yi.org Hits:0