3. @Aerilys#HoloToMaterial
De Holo à Material design
• Mais enfin c’est quoi le Material design ?
• Steam Explorer
• Thème
• FAB
• Cards
• Animations
• Material design dans le monde réel
11. @Aerilys#HoloToMaterial
Mais je suis développeur moi !
• Material Design = Guidelines != Règles
• Outils pour faciliter le design
• Ce n’est qu’un guide, à vous de faire le reste… Mais ce
n’est pas une raison pour faire n’importe quoi !
16. @Aerilys#HoloToMaterial
Material theme
• Créer un dossier pour
Android 5.0
•res/values-v21/styles.xml
• Faire hériter son thème du
thème Material
• <style name="SteamTheme"
parent="@android:style/Theme
.Material.Light.DarkActionBar">
• Trois thèmes
• Theme.Material (dark)
• Theme.Material.Light (light)
• Theme.Material.Light.DarkActi
onBar
23. @Aerilys#HoloToMaterial
FAB - design rules
• Bouton flottant
• Au-dessus de l’UI (couche
supérieure)
• Action majeure de l’écran
• Pas plus d’un par écran, mais
pas obligatoire
24. @Aerilys#HoloToMaterial
FAB - code
• View customisée, drawable
ou reprise d’un projet Github
existant
•iosched
•FloatingActionButton
• Compatible jusqu’à 2.x avec
des adaptations
25. @Aerilys#HoloToMaterial
public void init(int fabColor)
{
setWillNotDraw(false);
this.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
mButtonPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
mButtonPaint.setColor(fabColor);
mButtonPaint.setStyle(Paint.Style.FILL);
mButtonPaint.setShadowLayer(10.0f, 0.0f, 3.5f,
Color.argb(100, 0, 0, 0));
invalidate();
}
FAB - code
28. @Aerilys#HoloToMaterial
FAB - scrolling effect
• Effet à la Google Plus pour ne pas cacher le contenu
• Cache le bouton en scroll descendant, l’affiche en scroll ascendant
• Utilise un ScrollListener sur une ScrollView ou une
ListView/GridView
• QuickReturnListView Github
• Pensez à la petite animation
30. @Aerilys#HoloToMaterial
Cards - Design rules
• Popularisées par Google
Now, Facebook…
• 1 card = 1 idée, notion ou
contenu
• Ne s’applique pas à toutes
les listes
31. @Aerilys#HoloToMaterial
Cardviews - code
• Avant : cards avec un
drawable
Peu customisable
Pas standard
Pas de gestion dynamique
des ombres
• Avec Android Lollipop
Facilement customisable
Support v7
Attribut elevation pour
gérer les ombres
45. @Aerilys#HoloToMaterial
Quelques liens
Material design guidelines:
http://www.google.com/design/
Material with Polymer:
http://www.polymer-project.org/docs/elements/material.html
Material with Angular:
http://material.angularjs.org/
Material is the metaphor
A material metaphor is the unifying theory of a rationalized space and a system of motion. The material is grounded in tactile reality, inspired by the study of paper and ink, yet technologically advanced and open to imagination and magic.Surfaces and edges of the material provide visual cues that are grounded in reality. The use of familiar tactile attributes helps users quickly understand affordances. Yet the flexibility of the material creates new affordances that supercede those in the physical world, without breaking the rules of physics.The fundamentals of light, surface, and movement are key to conveying how objects move, interact, and exist in space in relation to each other. Realistic lighting shows seams, divides space, and indicates moving parts.
Bold, graphic, intentional
The foundational elements of print-based design—typography, grids, space, scale, color, and use of imagery—guide visual treatments. These elements do far more than please the eye; they create hierarchy, meaning, and focus. Deliberate color choices, edge-to-edge imagery, large-scale typography, and intentional white space create a bold and graphic interface that immerses the user in the experience.An emphasis on user actions makes core functionality immediately apparent and provides waypoints for the user.
Motion provides meaning
Motion respects and reinforces the user as the prime mover. Primary user actions are inflection points that initiate motion, transforming the whole design. All action takes place in a single environment. Objects are presented to the user without breaking the continuity of experience even as they transform and reorganize.Motion is meaningful and appropriate, serving to focus attention and maintain continuity. Feedback is subtle yet clear. Transitions are efficient yet coherent.