Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Large title UINavigationbar bottom line flickers on scroll

Tags:

ios

swift

I have a view controller with a tableview in it. Pulling down on the tableview expands the navigationbar as expected but the bottom hair line flickers. Has anyone faced this problem before?

?

like image 931
Zia Avatar asked Mar 22 '18 22:03

Zia


5 Answers

The easiest possible solution will be simply set self.tableView.separatorColor = UIColor.clear & add a label(identical to seprator line)inside your tableview cell or header.

like image 137
navroz Avatar answered Nov 18 '22 17:11

navroz


If you are using storyboard and have a embedded UINavigationController then just un-check Translucent property from attribute inspector.enter image description here

self.navigationController?.navigationBar.isTranslucent = false
like image 2
Priyam Dutta Avatar answered Nov 18 '22 17:11

Priyam Dutta


  1. Please check that your UITableView's content (cells, header) are clipped to bounds.
  2. The issue may be with shadows, if you use them. (Can not tell for sure)
like image 1
Misternewb Avatar answered Nov 18 '22 19:11

Misternewb


Find the source of the dark gray color and change it to UIColor.clear

I would guess it's the background color of the top UIView and as it expands and contracts its size, there's a 0.5px delay every few pixels.

It's hard to tell without seeing your code.

like image 1
KLD Avatar answered Nov 18 '22 18:11

KLD


removing navigationBar.barTintColor custom color, fix in my app (pay attention, do not set barTintColor to .clear, don't custom tintColor)

like image 1
ikanimo Avatar answered Nov 18 '22 19:11

ikanimo