Building Interface logic via IB
Building Interface logic via IB
- Subject: Building Interface logic via IB
- From: jordibares <email@hidden>
- Date: Tue, 20 Feb 2007 11:32:55 +0000
- Thread-topic: Building Interface logic via IB
Hi,
I am new to Cocoa and I am developing a little tool but I am stuck with some
concepts that I feel should be easier via IB rather than programmatically.
BTW I have been going through the book "Cocoa programming for the OS X".
The motivation is basically that I want to build the logic inside IB via
Bindings? Instead of having this very basic logic pollute the code with
trivial tasks.
Hopefully this premise is correct, it can be done easily, and I am talking
some sense.
To make my explanations easier I have zipped an example project with all my
problems narrowed down and you can download it at
http://www.jordibares.co.uk/tmp/InterfaceTest.zip
And here are my questions to two little problems;
Problem 1 :
1.a ) I want the flag to activate/deactivate the numeric field without
having to create an action and then programatically turn on/off the state of
the button.
1.b ) Also I plan to trigger an action when pressing the Test button so I am
relying on the user changes to interactively collect all the data I need.
Hopefully this is correct too.
Problem 2 :
2.a ) More interface questions, Here I am using a NSMatrix (radio buttons)
to drive multiple elements visibility on/off, and the idea is that hide
would hide all 4 elements in the bottom of the page, while unactive will
make the field and the combo box unactive yet visible.
2.b ) Hopefully also I can via IB set the default value of the NSMatrix? Do
I have to do this programmatically via awakeFromNib?
2.c ) Is it correct to use a ComboBox instead of a PopUp box? My intention
is to have some combo boxes with completely static values and I found I can
do easily that via IB, while other should be filled programmatically.
2.d ) In case the combobox has to be filled programmatically do I need to
build an ArrayController to handle this or can I resort to pass an array
from the program somehow? This is particulary confusing as the concepts are
not that clear and going through the Apple documentation has not many
examples.
Problem 3 :
Here lies the last one I think (for now), these two tabs will call the same
AppController? Should I have one app controller for one tab view and another
for the other?
I guess this is not right but wanted to make sure I pack all my questions in
one single email.
Thanks for you help
Jordi Bares
PS. Also I would like to meet some Cocoa developer to share ideas/questions
and help each other (probably I will only be able to help on other areas at
the moment, please visit my web site to see the kind of work I do). Either
that or I will pay the beers :-)
_______________________________________________
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