Closed powerje closed 7 years ago
In this case, you can call + (void)renderBarButtonItem:(UIBarButtonItem*)item
, so the code stays like that:
self.navigationItem.rightBarButtonItem = self.editButtonItem;
[NUIRenderer renderBarButtonItem:self.editButtonItem];
I have a similar error with automatic back button in navigation Controller, any idea how I can solve this?
Thanks :)
Thanks @pedro380085, that worked perfectly!
Is this something that should be considered a bug, or is using NUIRenderer directly the expected way to do this?
btw @rcabamo, I pushed onto my nav controller in the screen shot above and my back button was styled appropriately. I'll download the sample project linked to your issue and see if I can help though.
@powerje I believe it is not a feature, that's because UIBarButtonItem
is a very strange class, it doesn't even inherits from UIView
! I expect to see a better support for it on the future, but setting it programmatically is not a big deal.
This seems to affect more than just TabBarItems, I added:
View { background-color: #ECE7E4; }
to my theme and it changes nothing. But if I then in viewDidLoad for a given VC manually [NUIRenderer renderView:self.view]; it works.
I was trying out the provided Route theme:
I'm using a Storyboard and have a UITableViewController. When I enable the edit button like so:
It looks like this:
Instead of the way the styled UIBarButtonItem looks in the Route screen shot.