1. 程式人生 > >自定義View和Animator

自定義View和Animator

https://github.com/codepath/android-custom-view-demos/blob/master/README.md

http://www.vogella.com/tutorials/AndroidCustomViews/article.html

https://github.com/codepath/android_guides/wiki/Basic-Painting-with-Views

 

2018.9.17

1.用法

https://www.jianshu.com/p/1a1491f059fc

2.用法

https://www.cnblogs.com/mengdd/p/3332882.html

3.自定義View

  • create drawing objects

   Canvas+Paint

  • handle layout events

   View.MeasureSpec

   LayoutParams

   onMeasure

https://developer.android.com/training/custom-views/custom-drawing

4.同樣大的面積裡會有不同個數的畫素點,這就是造成高低解析度的原因。

  • pixel和dp的轉換
  • 佈局大小(dp)和字型大小(sp)的單位

https://developer.android.com/training/multiscreen/screendensities

 

 

https://developer.android.com/guide/topics/graphics/drawables

https://developer.android.com/reference/android/graphics/package-summary

 

2018.9.20

Animator

 

https://blog.csdn.net/vanpersie_9987/article/details/51699595

ViewAnimator

https://blog.csdn.net/zhanhong39/article/details/78956553

https://abhiandroid.com/ui/viewanimator

 

ViewAnimation

https://blog.csdn.net/kisso143/article/details/52808272

https://blog.csdn.net/weixin_35791555/article/details/62883184

http://www.cnblogs.com/yc-755909659/p/4290114.html

https://github.com/daimajia/AndroidViewAnimations

https://github.com/lygttpod/AndroidCustomView

 

 

View in Camera

 

  • 坑一

selector使用失敗

  • 坑二
LayoutParams所有控制元件都可以使用LinearLayout的這個類嗎?

 

References

Android自定義View三(座標系與View的繪製流程)