Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Narfss/ParallaxEverywhere
Parallax everywhere is a library with alternative android widgets with parallax effects.
https://github.com/Narfss/ParallaxEverywhere
Last synced: 14 days ago
JSON representation
Parallax everywhere is a library with alternative android widgets with parallax effects.
- Host: GitHub
- URL: https://github.com/Narfss/ParallaxEverywhere
- Owner: Narfss
- License: mit
- Created: 2014-11-24T19:06:44.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2018-06-20T13:24:30.000Z (over 6 years ago)
- Last Synced: 2024-07-31T18:17:25.698Z (3 months ago)
- Language: Java
- Size: 18.6 MB
- Stars: 713
- Watchers: 26
- Forks: 96
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
- -awesome-android-ui - ParallaxEverywhere - everywhere.gif) (Index `(light-weight pages)`)
- awesome-android-ui - ParallaxEverywhere - everywhere.gif) (Index `(light-weight pages)`)
- awesome-github-android-ui - ParallaxEverywhere - 视差效果的另类Android视图库 (滚动视差(Parallex))
- awesome-android-ui - ParallaxEverywhere - everywhere.gif) (Index)
README
# ![](https://raw.githubusercontent.com/Narfss/ParallaxEverywhere/master/sample/src/main/res/drawable-mdpi/ic_launcher.png) Parallax Everywhere#
[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-ParallaxEverywhere-brightgreen.svg?style=flat)](https://android-arsenal.com/details/1/1213)
Parallax everywhere (PEW) is a library with alternative android views using parallax effects.
## Demo ##
![](https://raw.githubusercontent.com/Narfss/ParallaxEverywhere/master/parallax-everywhere-animation-optimize.gif)You can try the demo app on google play.
https://play.google.com/store/apps/details?id=com.fmsirvent.ParallaxEverywhereSample
### Views with effect? ###
Android view | PEW view
--- | ---
ImageView | PEWImageView
TextView | PEWTextView### How it works? ###
* Any parallax views (PEW*) needs to be inside a view with scroll events, ej: scrollView, listView, gridView....
* Parallax effect on views will be related to its position on device screen.
* Parallax effect in ImageView is calculated with left image in Scale mode centerCrop, centerInside or center. You can't make more parallax effect.
* Parallax effect in no image views needs a size parallax parameter (read: Attributes)### Show me the code ###
Gradle dependencies:
```groovy
compile 'com.fmsirvent:parallaxeverywhere:1.0.4'
```Code in layout:
```xml
```
Proguard:
```
-dontwarn com.fmsirvent.ParallaxEverywhere.**
```### Attributes ###
**All PEW**
* **reverse** = ["none", "reverseX", "reverseY", "reverseBoth"]
Change the direction of parallax effect. Default value "none".* **block_parallax_x** and **block_parallax_y** = "boolean"
Blocks parallax effect. Default value false.* **interpolation** = ["linear", "accelerate_decelerate", "accelerate", "anticipate", "anticipate_overshoot", "bounce", "decelerate", "overshoot"]
Animation interpolation. Default value "linear".* **update_onDraw** = = "boolean"
Experimental attribute: update the parallax effect on draw event. Try if the parents don't has scroll. Now only works on +API:16 (Jelly bean). Default value false.**Only: no image PEW**
* **parallax_x** and **parallax_y** = "dimension"
In non widgets images is necessary specify the size of parallax effect. The size will be split in half for each side. Default value 0.## License
ParallaxEverywhere is available under the MIT license. See the LICENSE file for more info.