Bug 36991 - Unable to use Collection Views in Xamarin.Mac Storyboards
Summary: Unable to use Collection Views in Xamarin.Mac Storyboards
Status: RESOLVED UPSTREAM
Alias: None
Product: Xamarin.Mac
Classification: Desktop
Component: Library (Xamarin.Mac.dll) ()
Version: Master
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: Chris Hamons
URL:
Depends on:
Blocks:
 
Reported: 2015-12-14 19:12 UTC by Kevin Mullins
Modified: 2015-12-14 21:12 UTC (History)
2 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
Default Collection view added to a storyboard (139.72 KB, image/png)
2015-12-14 19:12 UTC, Kevin Mullins
Details
Example App (398.29 KB, application/zip)
2015-12-14 21:00 UTC, Kevin Mullins
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED UPSTREAM

Description Kevin Mullins 2015-12-14 19:12:00 UTC
Created attachment 14283 [details]
Default Collection view added to a storyboard

When you drag a Collection View onto a Mac App's storyboard it automatically adds a prototype that is used to define the individual content items in the collection with a segue type of "prototype" (see attached image).

If you return to Xamarin Studio, allow it to sync and attempt to compile or run the app, you will get an error in the form: "Unknown segue relationship: prototype" and the app will fail to build.

This issue currently prevents the user from using Collection Views from Xamarin.Mac storyboards.
Comment 1 Chris Hamons 2015-12-14 20:53:24 UTC
@Kevin - I was just about to file this as an Xcode integration bug when I ran across this:

http://stackoverflow.com/questions/25123365/unknown-segue-relationship-prototype-with-nscollectionview

Can you try that and see if that "fixes" your issue. Could you also attach the project in question to the bug.
Comment 2 Kevin Mullins 2015-12-14 20:59:41 UTC
From later in that same post, looks like Apple removed the workaround instructions because they "fixed" the issue. So, not sure what they were doing here.

However, it does look like it is an Apple bug though.

I'll include the project but a much simpler sample would to be start a new Xamarin.Mac app, edit the storyboard and drag in a collection view controller. If you switch back to Xamarin Studio, the build will fail with the above error message.
Comment 3 Kevin Mullins 2015-12-14 21:00:58 UTC
Created attachment 14287 [details]
Example App

This app has everything that can be data bound, including the Collection View in question.
Comment 4 Chris Hamons 2015-12-14 21:12:20 UTC
Yeah, the build log shows the story:

		Tool /Applications/Xcode.app/Contents/Developer/usr/bin/ibtool execution started with arguments: --errors --warnings --notices --output-format xml1 --minimum-deployment-target 10.11 --sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk --compile /Users/donblas/Downloads/MacDatabinding/MacDatabinding/obj/Debug/ibtool/Main.storyboardc /Users/donblas/Downloads/MacDatabinding/MacDatabinding/Main.storyboard
Main.storyboard: error : 
Main.storyboard: ibtool warning : Arranges All Subviews before OS X 10.11
Main.storyboard: ibtool warning : Fill Color property requires NSCustomBox type and NSLineBorder type
Main.storyboard:  ibtoolerror : Unknown segue relationship: Prototype
	Task "IBTool" execution -- FAILED
	Done building target "_CoreCompileInterfaceDefinitions" in

We're just compiling the storyboard using Apple's tool and it is erroring. If you want to file a Radar, you can, but nothing we can do about that. :(