Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Sat Sep 21, 2019 9:00 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: taking my elaborate windowcontrol and making a class with it
PostPosted: Tue Aug 09, 2011 9:53 pm 
Offline

Joined: Fri Jan 08, 2010 9:59 am
Posts: 315
Hi there -
I wonder if this can be done?

I have a canvas (It has a guitar as a backdrop) in my window - it also has another canvas inside that canvas which contains 149 canvases at very specific sizes and it's a array called "Notescanvas"

Is there any way to convert that to a class - I want to be able to copy this to any new window and it have the canvas keep their names. Right now, when I copy the main canvas and paste it into another window, I get the notecanvas array calling itself canvas4, canvas5 and not the notescanvas array that it was originally called.

Any ideas?


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Wed Aug 10, 2011 9:38 am 
Offline

Joined: Mon Aug 14, 2006 9:33 pm
Posts: 1774
Use the "Export Canvas1" menu item (File Menu I believe) and export it as an .rbo class.

_________________
Roger Clary
Class One Software
Educational Software for Lifelong Learning
http://www.classonesoftware.com


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Wed Aug 10, 2011 6:13 pm 
Offline

Joined: Fri Jan 08, 2010 9:59 am
Posts: 315
I clicked on the canvas, no where can I see export as a class in any of the menus

I only get export (window name) as a .rbw file


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Wed Aug 10, 2011 6:58 pm 
Offline

Joined: Mon Aug 14, 2006 9:33 pm
Posts: 1774
Sorry, I thought you had already subclassed the control. You will need to subclass the canvas control and then you can export that. The export command is under the File Menu.

_________________
Roger Clary
Class One Software
Educational Software for Lifelong Learning
http://www.classonesoftware.com


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Thu Aug 11, 2011 8:57 am 
Offline

Joined: Fri Jan 08, 2010 9:59 am
Posts: 315
Sorry - this whole subject has a big gap in my knowledge (I did did a huge music notation class in VB.net

But I would really like to take the canvas that I made already in a window and turn that into a class object that I can add.

Once I have it as a class I can add all sorts of features that would be an incredibly useful class.

Do I have to make it all again?
If so, do I make it (as a reusable class) - do i use the container control?
Sorry I'm a nwebie at this.


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Thu Aug 11, 2011 9:10 am 
Offline

Joined: Mon Aug 14, 2006 9:33 pm
Posts: 1774
Add a new class to your project.
Set the new class's super to canvas.
Go to your canvas you previously built and change its super to the new class you have created.
Now make the changes to your canvas class as you need.

BTW - As others have told you in posts you have peppered across this forum, a container control would be a likely candidate for this situation. But I "think" you would need to create your container then drag all of your controls into that container.

_________________
Roger Clary
Class One Software
Educational Software for Lifelong Learning
http://www.classonesoftware.com


Top
 Profile  
Reply with quote  
 Post subject: Re: taking my elaborate windowcontrol and making a class wit
PostPosted: Thu Aug 11, 2011 10:15 am 
Offline

Joined: Fri Jan 08, 2010 9:59 am
Posts: 315
Thanks Classone,

Sorry about the "Peppering" I got more articulate about what it was that I was after as I went along - I'll try not to do it again...
Thanks for the answer :)


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group