Re: Interface builder, .nibs, etc ...
Re: Interface builder, .nibs, etc ...
- Subject: Re: Interface builder, .nibs, etc ...
- From: Oleg Svirgstin <email@hidden>
- Date: Wed, 17 Dec 2003 08:21:06 +0300
Hi Paul,
In cases like this for the variable part of inspector I use an instance of
NSTabView with invisible buttons. Pages of the tab view may serve as a
specific class inspector, or as whatever relevant (if some inspector starts
to be overly complicated, it is wise to divide it into several
"sub-inspectors"). It is easy to select a proper page programmatically.
When there is a lot of things to inspect, I subclass NSTabViewItem instances
for every page of such inspectors, since I hate to work in IB with objects
defining dozens of actions and outlets (I inspected 17 kinds of some stuff +
12 special pages, each with at least 5 controls, it was a nightmare). Tab
view item is a cute little subclass of NSObject, knowing a lot of its mother
tab view, current state etc. Divide and rule, so to say.
I experimented with the views, too... A good way (complete liberty!), I
liked it, but what the tab views do automatically is quite good for almost
any situation.
Regards
Oleg
>
From: Paul Mooser <email@hidden>
>
Date: Tue, 16 Dec 2003 11:32:07 -0800
>
To: email@hidden
>
Subject: Interface builder, .nibs, etc ...
>
>
Hi there,
>
>
I've been looking through the Sketch example applications, and I have
>
come up with a question to which I can find no answer. Perhaps one of
>
you can help me.
>
>
Sketch is a simple vector drawing application, and there is an
>
inspector you can use to view/modify the properties of the shapes that
>
are on the canvas. However, the different sorts of shapes all share the
>
same sort of inspector. I would like to determine a way for each shape
>
to have its own type of inspector. Now, that sounds easy, and so we
>
come to my real question.
>
>
It seems that most of the interface components that I can build in
>
interface builder are in some fashion window-based - the top level
>
component is a window or a panel or somesuch. Is it unreasonable for me
>
to want to use interface builder to lay out the interface of my various
>
inspectors, and then load those components (and attach them to a
>
window) at runtime, somehow ? In other words, I am wondering if the top
>
level component must in fact be some sort of window or panel ... or
>
should I just create these inspector user interfaces completely
>
programmatically ? Just to clarify, I realize that I could easily do
>
what I am asking and have a separate window for each type of inspector,
>
but that is not what I want to do.
>
>
Thanks for any help you can provide. I have tried to search the
>
archives, but can't find anything.
>
>
-Paul
>
_______________________________________________
>
cocoa-dev mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.