Pierre87 Posted July 5, 2010 Share Posted July 5, 2010 je cherche à faire un drawable un peu complexe : xmlns:android="http://schemas.android.com/apk/res/android" android:top="0dip"> android:shape="rectangle"> android:startColor="#daf1d6" android:centerColor="#daf1d6" android:endColor="#b3e2ac" android:angle="-90" /> android:top="0dip" android:bottom="93dip"> android:shape="line"> android:width="1dip" android:color="#000000" /> en gros, c'est un dégradé, avec une ligne en haut mon problème, c'est que je n'arrive pas à mettre la ligne en haut :( je suis obligé de tricher avec android:bottom="93dip" , car c'est approximativement la hauteur de ma view vous avez une solution ? merci ! Link to comment Share on other sites More sharing options...
popolbx Posted July 5, 2010 Share Posted July 5, 2010 bah à part dessiner "à la main" dans le bitmap et le charger là où tu veux, je vois pas... Link to comment Share on other sites More sharing options...
Cyril Mottier Posted July 6, 2010 Share Posted July 6, 2010 Il n'est pas possible d'avoir un contrôle aussi précis sur tes dégradés. Par contre tu peux facilement utiliser un NinePatchDrawable ou un InsetDrawable combiné avec un GradientDrawable pour gérer ce "trait" ;) Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.