1
votes

Is there a way we can access the Forms Layout (Grid, StackLayout, Frame etc designed in Forms using XAML) on an IOS renderer & add a native control inside it (Say add a Native UIImageView)?

I understand that we can write a custom renderer for the Image View & then change its source in IOS native renderer, but in our case we need to create an entire page renderer.

To keep you in context, we are trying to create a XAML based page in forms & create a Page Renderer in IOS for this, so we have access to all controls of this forms page in renderer. Now we need to create a native control (Camera Streaming in fact but let’s consider a simple UIImageView to keep things simple) & add it inside the layout (Grid, Stacklayout, Frame etc) that we created in Forms using XAML on this page..

Any ideas how this can be done?

1
You'll need to write your own custom renderers based on the ones that come with XF and modify their implementation - Sten Petrov
I understand Sten, infect we do have our own page renderer. We are stuck at converting the Forms.Frame to its native view counterpart & then add more native controls inside of it. - Supreet
Can you share your renderer code? There's a Control property (if I remember correctly) which you can cast to your actual native type and add children to it - Sten Petrov
Ive run into a similar problem. there dosnt seem to be a StackLayoutRenderer you can inherit from - Ewan

1 Answers

0
votes

I have listed almost every renderer related native control in xamarin forms following image contains few renderers that may help in your way.

Renderer Image

@supreet: You can find your suitable more custom renderer Here

Good Luck