Example project showing how to create a custom control (UIView) with XIB so that it's available in Xamarin iOS designer. Custom UIView does not render in storyboard, but can be selected from the toolbox window. If you make rendering in storyboard work, please make a pull request and I will merge it into this repo. The reason to this example project simply is that I was looking for an example like this but could not find something that was working out of the box.
Design custom view in xib using Visual Studio or Xcode (less buggy):
CustomView is visible in Toolbox:
CustomView can be droped into your storyboard:
Simulator run. View can also be resized/rotated during runtime:
Getting Started
Clone and run .sln in Visual Studio.
Prerequisites
Visual Studio (Tested on Visual Studio CE 2017)
Author
- Sebastian Nilsson - sebastiannilsson.com
License
This project is licensed under the MIT License - see the LICENSE.md file for details
Acknowledgments
- Various forum comments in this thread - Initial work - forums.xamarin.com
- https://developer.xamarin.com/recipes/ios/general/templates/using_the_ios_view_xib_template/
- https://developer.xamarin.com/guides/ios/user_interface/designer/ios_designable_controls_walkthrough/
- https://app.pluralsight.com/
Github repo (to download code)