[Leopard] Interface Builder - Subclassing

  • Hey Leopard Developers,

    I was wondering how I can subclass an object in the new Interface
    Builder. When I click on the View Mode selector, as I did in IB for
    Tiger, it only shows objects in the main window. Can anyone provide
    information not in the Select and Premier memberships? I am sooooo
    confused.

    Thanks in advance,
    Rick Langschultz
  • On 11/2/07, Rick Langschultz <rlangschultz...> wrote:
    > Hey Leopard Developers,
    >
    > I was wondering how I can subclass an object in the new Interface
    > Builder. When I click on the View Mode selector, as I did in IB for
    > Tiger, it only shows objects in the main window. Can anyone provide
    > information not in the Select and Premier memberships? I am sooooo
    > confused.

    Use Xcode to create the needed header, etc.

    -Shawn
  • On Nov 2, 2007, at 4:31 PM, Shawn Erickson wrote:

    > On 11/2/07, Rick Langschultz <rlangschultz...> wrote:
    >> Hey Leopard Developers,
    >>
    >> I was wondering how I can subclass an object in the new Interface
    >> Builder. When I click on the View Mode selector, as I did in IB for
    >> Tiger, it only shows objects in the main window. Can anyone provide
    >> information not in the Select and Premier memberships? I am sooooo
    >> confused.
    >
    > Use Xcode to create the needed header, etc.

    and <xcode-users...> to discuss this.
  • On 2 nov 2007, at 21.13, Rick Langschultz wrote:

    > Hey Leopard Developers,
    >
    > I was wondering how I can subclass an object in the new Interface
    > Builder. When I click on the View Mode selector, as I did in IB for
    > Tiger, it only shows objects in the main window. Can anyone provide
    > information not in the Select and Premier memberships? I am sooooo
    > confused.
    >
    > Thanks in advance,
    > Rick Langschultz
    >
    According to info during Leopard tech Talks, early 2007, Stockholm,
    Sweden,
    Interface Builder 3 won't have code generation. Create your class in
    Xcode, and then tell interface builder
    to parse the header file.
    ------------------------------------------------------
    "Home is not where you are born, but where your heart finds peace" -
    Tommy Nordgren, "The dying old crone"
    <tommy.nordgren...>
  • Thank you for all the information. I will be happy to subscribe to
    this mailing list.
    On Nov 2, 2007, at 3:34 PM, Scott Anguish wrote:

    >
    > On Nov 2, 2007, at 4:31 PM, Shawn Erickson wrote:
    >
    >> On 11/2/07, Rick Langschultz <rlangschultz...> wrote:
    >>> Hey Leopard Developers,
    >>>
    >>> I was wondering how I can subclass an object in the new Interface
    >>> Builder. When I click on the View Mode selector, as I did in IB for
    >>> Tiger, it only shows objects in the main window. Can anyone provide
    >>> information not in the Select and Premier memberships? I am sooooo
    >>> confused.
    >>
    >> Use Xcode to create the needed header, etc.
    >
    > and <xcode-users...> to discuss this.
    >
    >
  • On Nov 2, 2007, at 1:34 PM, Tommy Nordgren wrote:

    > According to info during Leopard tech Talks, early 2007, Stockholm,
    > Sweden,
    > Interface Builder 3 won't have code generation. Create your class in
    > Xcode, and then tell interface builder
    > to parse the header file.

    While this is the straightforward workflow, Interface Builder 3 does
    still support generating classes and code -- more flexibly than
    Interface Builder 2, too!

    You can drag an object out of the Library window and into your IB
    document or an IB editor window, and then Get Info on it and change
    its class to anything you want.  There, you have a subclass.  You can
    generate a file for this class by choosing "Write Class Files..." from
    the File menu while in the Identity Inspector for that object.

    Or you can simply select an outlet or action that you've added in the
    Identity Inspector, use the Copy command, and then go to the class's
    header file and choose Paste.  That will put a declaration for that
    outlet or action into the header.

    Note that you can generate not just stub Objective-C code and headers,
    but also Python and Ruby code for PyObjC and RubyCocoa, respectively!

      -- Chris
  • Chris, I'm trying very hard to follow what you've said... but I can't.

    I'm looking at IB3 and I do what you suggest. I drag NSObject out of
    the Library and drop it in my .nib document. Then you say "Get Info on
    it". But there is no "Get Info" anywhere in IB3 except for the "i"
    button in the toolbar of the .nib file and it only gets info for the
    .nib file.

    How do you create a subclass in IB3?

    Has anyone put a simple tutorial together for XCode3/IB3 that is the
    equivalent of the old "Currency Converter" example. None of the
    step-by-step tutorials from Apple apply any more. It is hard to
    believe that they released XCode3 after the past year's work without
    any basic tutorial. I must just be missing something!

    ...Eric

    On 11/3/07, Chris Hanson <cmh...> wrote:
    > On Nov 2, 2007, at 1:34 PM, Tommy Nordgren wrote:
    >
    >> According to info during Leopard tech Talks, early 2007, Stockholm,
    >> Sweden,
    >> Interface Builder 3 won't have code generation. Create your class in
    >> Xcode, and then tell interface builder
    >> to parse the header file.
    >
    > While this is the straightforward workflow, Interface Builder 3 does
    > still support generating classes and code -- more flexibly than
    > Interface Builder 2, too!
    >
    > You can drag an object out of the Library window and into your IB
    > document or an IB editor window, and then Get Info on it and change
    > its class to anything you want.  There, you have a subclass.  You can
    > generate a file for this class by choosing "Write Class Files..." from
    > the File menu while in the Identity Inspector for that object.
    >
    > Or you can simply select an outlet or action that you've added in the
    > Identity Inspector, use the Copy command, and then go to the class's
    > header file and choose Paste.  That will put a declaration for that
    > outlet or action into the header.
    >
    > Note that you can generate not just stub Objective-C code and headers,
    > but also Python and Ruby code for PyObjC and RubyCocoa, respectively!
    >
    > -- Chris
    >

    --
    Eric Celeste / http://eric.clst.org / Saint Paul, MN / 651-323-2009 /
    <efc...>
  • Apologies. I just realized that this thread should be in the
    xcode-users list. Just for the record, the document I found that looks
    like it will be a big help getting oriented is:

    http://developer.apple.com/documentation/DeveloperTools/Conceptual/IB_UserG
    uide/index.html


    Again, sorry for posting to the wrong list!
    ...Eric

    On 11/3/07, Eric Celeste <efc...> wrote:
    > Chris, I'm trying very hard to follow what you've said... but I can't.
    >
    > I'm looking at IB3 and I do what you suggest. I drag NSObject out of
    > the Library and drop it in my .nib document. Then you say "Get Info on
    > it". But there is no "Get Info" anywhere in IB3 except for the "i"
    > button in the toolbar of the .nib file and it only gets info for the
    > .nib file.
    >
    > How do you create a subclass in IB3?
    >
    > Has anyone put a simple tutorial together for XCode3/IB3 that is the
    > equivalent of the old "Currency Converter" example. None of the
    > step-by-step tutorials from Apple apply any more. It is hard to
    > believe that they released XCode3 after the past year's work without
    > any basic tutorial. I must just be missing something!
    >
    > ...Eric
    >
    > On 11/3/07, Chris Hanson <cmh...> wrote:
    >> On Nov 2, 2007, at 1:34 PM, Tommy Nordgren wrote:
    >>
    >>> According to info during Leopard tech Talks, early 2007, Stockholm,
    >>> Sweden,
    >>> Interface Builder 3 won't have code generation. Create your class in
    >>> Xcode, and then tell interface builder
    >>> to parse the header file.
    >>
    >> While this is the straightforward workflow, Interface Builder 3 does
    >> still support generating classes and code -- more flexibly than
    >> Interface Builder 2, too!
    >>
    >> You can drag an object out of the Library window and into your IB
    >> document or an IB editor window, and then Get Info on it and change
    >> its class to anything you want.  There, you have a subclass.  You can
    >> generate a file for this class by choosing "Write Class Files..." from
    >> the File menu while in the Identity Inspector for that object.
    >>
    >> Or you can simply select an outlet or action that you've added in the
    >> Identity Inspector, use the Copy command, and then go to the class's
    >> header file and choose Paste.  That will put a declaration for that
    >> outlet or action into the header.
    >>
    >> Note that you can generate not just stub Objective-C code and headers,
    >> but also Python and Ruby code for PyObjC and RubyCocoa, respectively!
    >>
    >> -- Chris
    >>
    >
    >
    > --
    > Eric Celeste / http://eric.clst.org / Saint Paul, MN / 651-323-2009 /
    > <efc...>
    >

    --
    Eric Celeste / http://eric.clst.org / Saint Paul, MN / 651-323-2009 /
    <efc...>
  • On Nov 3, 2007, at 6:23 PM, Eric Celeste wrote:

    > Chris, I'm trying very hard to follow what you've said... but I can't.
    >
    > I'm looking at IB3 and I do what you suggest. I drag NSObject out of
    > the Library and drop it in my .nib document. Then you say "Get Info on
    > it". But there is no "Get Info" anywhere in IB3 except for the "i"
    > button in the toolbar of the .nib file and it only gets info for the
    > .nib file.

    Sorry, I meant "inspect it."  Xcode's terminology is "Get Info."

    Just select the instance of NSObject that you dragged into your IB
    document, and select "Identity Inspector" directly from the Tools
    menu.  The keyboard equivalent for this is Command-6.  It will open
    the Inspector window, and take you directly to the Object Identity
    inspector from where you can change the class of your NSObject
    instance, add outlets and actions, and even add comments on it that
    will remain in the Interface Builder document.

      -- Chris
  • I am slowly figuring it out. Seems a lot more complicated then the
    previous IB used with Tiger. Taking a long time to wrap my head around
    it.

    On Nov 3, 2007, at 8:53 PM, Chris Hanson wrote:

    > On Nov 3, 2007, at 6:23 PM, Eric Celeste wrote:
    >
    >> Chris, I'm trying very hard to follow what you've said... but I
    >> can't.
    >>
    >> I'm looking at IB3 and I do what you suggest. I drag NSObject out of
    >> the Library and drop it in my .nib document. Then you say "Get Info
    >> on
    >> it". But there is no "Get Info" anywhere in IB3 except for the "i"
    >> button in the toolbar of the .nib file and it only gets info for the
    >> .nib file.
    >
    > Sorry, I meant "inspect it."  Xcode's terminology is "Get Info."
    >
    > Just select the instance of NSObject that you dragged into your IB
    > document, and select "Identity Inspector" directly from the Tools
    > menu.  The keyboard equivalent for this is Command-6.  It will open
    > the Inspector window, and take you directly to the Object Identity
    > inspector from where you can change the class of your NSObject
    > instance, add outlets and actions, and even add comments on it that
    > will remain in the Interface Builder document.
    >
    > -- Chris
previous month november 2007 next month
MTWTFSS
      1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30    
Go to today