public class ParallaxPage extends WelcomePage<ParallaxPage>
WelcomePage.OnChangeListener
index, isRtl, totalPages
Constructor and Description |
---|
ParallaxPage(int layoutResId,
java.lang.String title,
java.lang.String description)
A page with a title and description that applies a parallax effect to the supplied layout.
|
Modifier and Type | Method and Description |
---|---|
ParallaxPage |
descriptionColor(int color)
Set the color of the header
|
ParallaxPage |
descriptionColorResource(android.content.Context context,
int colorRes)
Set the color of the description from a color resource id
|
ParallaxPage |
descriptionTypefacePath(java.lang.String path)
Set the typeface of the description
|
ParallaxPage |
firstParallaxFactor(float factor)
The factor that the first item in the layout should move, relative to
the movement of the page.
|
Fragment |
fragment() |
ParallaxPage |
headerColor(int color)
Set the color of the header
|
ParallaxPage |
headerColorResource(android.content.Context context,
int colorRes)
Set the color of the header from a color resource id
|
ParallaxPage |
headerTypeface(java.lang.String path)
Set the typeface of the header
|
ParallaxPage |
lastParallaxFactor(float factor)
The factor that the last item in the layout should move, relative to
the movement of the page.
|
ParallaxPage |
recursive(boolean recursive)
Whether or not the parallax effect should be recursive.
|
void |
setup(WelcomeConfiguration config) |
background, background, createFragment, getFragment, onPageScrolled, onPageScrollStateChanged, onPageSelected
public ParallaxPage(@LayoutRes int layoutResId, java.lang.String title, java.lang.String description)
layoutResId
- The layout to show/apply parallax effect totitle
- A title, shown in large fontdescription
- String shown below titlepublic ParallaxPage firstParallaxFactor(float factor)
factor
- The parallax factor for the first item in the layoutpublic ParallaxPage lastParallaxFactor(float factor)
factor
- The parallax factor for the last item in the layoutpublic ParallaxPage recursive(boolean recursive)
recursive
- Whether or not the effect should be recursive (travel through ViewGroups)public ParallaxPage headerTypeface(java.lang.String path)
path
- The path to a typeface in the assets folderpublic ParallaxPage descriptionTypefacePath(java.lang.String path)
path
- The path to a typeface in the assets folderpublic ParallaxPage headerColor(int color)
color
- Color intpublic ParallaxPage headerColorResource(android.content.Context context, @ColorRes int colorRes)
context
- Context used to resolve colorcolorRes
- Resource id of color to setpublic ParallaxPage descriptionColor(int color)
color
- Color intpublic ParallaxPage descriptionColorResource(android.content.Context context, @ColorRes int colorRes)
context
- Context used to resolve colorcolorRes
- Resource id of color to setpublic void setup(WelcomeConfiguration config)
setup
in class WelcomePage<ParallaxPage>
public Fragment fragment()
fragment
in class WelcomePage<ParallaxPage>