Dear John, Thanks for your remarks. I did not intend to inherit from TCanvas; I overlooked this. Rene has told this already to me and I got what I wanted this time. > Hi Zaldy, > > I think your problem is due to the fact that SB_WindowSession inherits > from TCanvas, so that when you create an instance of your class, you are > in fact creating a TCanvas - that would be the TCanvas called "c1" that you > see appearing, which is the default name. > > Note that you will not (as your code stands) be able to access this > TCanvas through your > member pointer myCanvas (you could if you did "myCanvas = > (TCanvas*)this", but I > don't think this is very interesting or a good idea), which is > initialised to be NULL. If you want to change > the name of the canvas, for example, you could use SetTitle("some name") > in your > constructor (or elsewhere in your class) - as you have not redefined a > SetTitle > method, this is in fact TCanvas::SetTitle. > > Hope this helps > > John > > > -- -------------------------------------------------------- Zaldy A. Nawang PS Users Room 2 Yon Gokan, E362, Neutrino Group, IPNS, KEK, Japan e-mail: zaldy@neutrino.kek.jp Tel. No. : (81) 029864 - 5387 --------------------------------------------------------
This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:13 MET