0

So know how to set up a custom renderer (only partially apparently) with an OnElementChanged method. I followed this (http://forums.xamarin.com/discussion/17654/tabbedpage-icons-not-visible-android)

protected override void OnElementChanged(ElementChangedEventArgs<TabbedPage> e)
    {
        base.OnElementChanged(e);
        _activity = this.Context as Activity;
    }

This gets hit, but it never displays the page afterwards.

Anyone have any ideas?

ArbiterUnknown
  • 113
  • 2
  • 13

2 Answers2

0

It is showing up now. I had to use the base class of TabbedRender rather than TabbedPageRenderer. I also had to add this.SetWillNotDraw(false) in the CustomRenderer constructor.

ArbiterUnknown
  • 113
  • 2
  • 13
  • Can you post the code you used to solve the problem? The derived class? Thank you. – Emanuele Sabetta Sep 21 '16 at 09:47
  • https://forums.xamarin.com/discussion/comment/219263/#Comment_219263 have a look on this page... The second post of Mubi did it for me ;-) – klingu Sep 21 '16 at 14:56
  • Do you have a full code example of what worked for you? I tried this.setwillnotdraw and am using TabbedRenderer, and I have the same problem where it gets hit but then my page is just blank white. it never loads. Thanks! – Kyle Mar 15 '17 at 16:22
0

Here you can find a full TabbedPageRenderer ready to be modified. It comes directly from Xamarin.Forms Android.
Still I'm trying to set a different Font Size...