Toolbars under Leopard and IB 3

  • Hi, all,

    I fear that I must be missing something obvious, but how do we set a
    toolbar item -- instantiated in an Interface Builder 3 .xib file -- to
    be *selectable*, rather than a normal toolbar item?  I read the
    following document:

    <file:///Developer/Documentation/DocSets/com.apple.ADC_Reference_Library.DeveloperTools.docset/Contents/Resources/Documents/documentation/DeveloperTools/Conceptual/IB_UserGuide/BuildingaNibFile/chapter_4_section_4.html
    >

    But it says nothing of customizing the selectability of toolbar items.

    If I need to do this manually, with the usual (traditional) -
    toolbarSelectableItemIdentifiers:, how am I to get the identifiers of
    the toolbar items?  IB doesn't appear to display these.

    Cheers,
    Andrew
  • On Nov 14, 2007, at 1:33 PM, Andrew Merenbach wrote:

    > Hi, all,
    >
    > I fear that I must be missing something obvious, but how do we set
    > a toolbar item -- instantiated in an Interface Builder 3 .xib file
    > -- to be *selectable*, rather than a normal toolbar item?  I read
    > the following document:
    >
    > <file:///Developer/Documentation/DocSets/
    > com.apple.ADC_Reference_Library.DeveloperTools.docset/Contents/
    > Resources/Documents/documentation/DeveloperTools/Conceptual/
    > IB_UserGuide/BuildingaNibFile/chapter_4_section_4.html>

    This doesn't appear to be available in IB.  If you implement the
    ordinary toolbar delegate methods, you can return items in addition
    to those you create in IB, and make those additional items selectable
    through the delegate method.
  • I don't know if I understand you problem correctly!?

    In my application, I setup the Toolbar completely in IB3. But to get
    the Items selected, I had to return their IDs in the delegate method
    like this.

    - (NSArray *)toolbarSelectableItemIdentifiers: (NSToolbar *)toolbar
    {
    return [NSArray arrayWithObjects:[toolItem1 itemIdentifier],
    [toolItem2 itemIdentifier], nil];
    }

    To accomplish this, I created IBOutlets for every ToobarItem within my
    "ToolbarController" and returned the IDs of the Items the way
    described above.

    Hope this helps

    regards
    Joachim

    Am 15.11.2007 um 00:13 schrieb Peter Ammon:

    >
    > On Nov 14, 2007, at 1:33 PM, Andrew Merenbach wrote:
    >
    >> Hi, all,
    >>
    >> I fear that I must be missing something obvious, but how do we set
    >> a toolbar item -- instantiated in an Interface Builder 3 .xib file
    >> -- to be *selectable*, rather than a normal toolbar item?  I read
    >> the following document:
    >>
    >> <file:///Developer/Documentation/DocSets/com.apple.ADC_Reference_Library.DeveloperTools.docset/Contents/Resources/Documents/documentation/DeveloperTools/Conceptual/IB_UserGuide/BuildingaNibFile/chapter_4_section_4.html
    >>>
    >
    > This doesn't appear to be available in IB.  If you implement the
    > ordinary toolbar delegate methods, you can return items in addition
    > to those you create in IB, and make those additional items
    > selectable through the delegate method.
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