Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1 pixel line between refresh view and collection view #71

Open
michaelschwinges opened this issue Jul 30, 2017 · 3 comments
Open

1 pixel line between refresh view and collection view #71

michaelschwinges opened this issue Jul 30, 2017 · 3 comments

Comments

@michaelschwinges
Copy link

michaelschwinges commented Jul 30, 2017

Hi,

A one-pixel line appears at the moment when when releasing - as can be seen in the attached image. It flashes for the briefest moment in time, but my app's contrast between the two colours is very high so it's quite obvious.

Is this in the library or could it be something weird in the way my UI is put together?

screen shot 2017-07-30 at 20 30 17

@michaelschwinges
Copy link
Author

Update - doesn't do it on any other collection views in the app. What's different about the screen where this occurs is that there is a header cell with a white background. The top insets are all zero. However with pull to refresh the 1 pixel line must be creeping in somehow when released.

@AlexanderKvamme
Copy link

Any solution for this? I found that the color of the line is controlled by the tableView.backgroundColor

@michaelschwinges
Copy link
Author

I my case the tableView.backgroundColor is white and the screen background is dark blue. In some cases when bouncing a 1 pixel gap appeared between the tableView and the pullToRefreshView above it.

I eventually solved it by making pullToRefreshView 1 pixel higher than it theoretically needed to be, so that this line would not sometimes appear:

DGElasticPullToRefreshView.swift line 370:

  • frame = CGRect(x: 0.0, y: -height - 1.0, width: width, height: height)
  • frame = CGRect(x: 0.0, y: -height - 1.0, width: width, height: height + 1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants