Re: adding new NSButtons to an application "on the fly"
Re: adding new NSButtons to an application "on the fly"
- Subject: Re: adding new NSButtons to an application "on the fly"
- From: Mike Abdullah <email@hidden>
- Date: Tue, 1 May 2007 12:44:38 +0100
Well buttons are fairly simple objects. You can create as many as you
like:
-[NSButton initWithFrame:]
and add them to a window
[[myWindow contentView] addSubview:button]
Alternatively, you could use an NSMatrix of NSButtonCells to do the job.
Mike
On 30 Apr 2007, at 11:26, Tim Simon wrote:
Hi all.
I have been thinking of starting a project which will basically be a
lot of buttons which, when clicked, will run a script for a remote
server via ssh. I want to know if it is possible for me to build the
program in such a way taht i will be able to add or remove buttons as
i go, without havign to use xtools? Maybe using a file which would
record what buttons i have "opened", and then when the program is
initiated it would read the file, and create those buttons. That way,
i can have a button for each script, and when i need another i can add
it, when i dont need it i can deleate it?
Is this possible, (i sortof figure its not the easiest or most
efficient way of doing this) and how would i implement this?
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
40mikeabdullah.net
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden