connect two wxRichTextBuffers

Julian Smart julian at anthemion.co.uk
Wed May 21 22:48:34 PDT 2008


Karol Bielecki wrote:
> Julian Smart pisze:
>> aafe at tagmet.com.pl wrote:
>>> I try to connect two wxRichTextBuffers in one.
>>> What I have to do?
>>>   
>> I'm not sure what you mean by "connect" exactly...
> I tray connect two files in one file
> Is This way  correct?
> wxRichTextBuffer *bufor_1,*bufor_2;
> ...
> bufor_1->LoadFile(stream1,wxRICHTEXT_TYPE_XML);
> bufor_2->LoadFile(stream2,wxRICHTEXT_TYPE_XML);
>
> for (i=0;i<bufor_2->GetChildCount();i++)
>         {
>             bufor_1->AppendChild(bufor_pom->GetChild(i)->Clone());
>         }
Yes, or you could simply do:

(*buffer1) = (*buffer2);

I'm assuming these two pointers are initialised to the address of two 
existing buffers.

I wouldn't use the word 'connect' for simply assigning the contents of 
one to the other - that implies a more dynamic relationship between the 
two objects. However this may simply be a language issue.

Regards,

Julian


More information about the wx-users mailing list