티스토리 뷰
// RelativeLayout mView = (RelativeLayout)findViewById(R.id.gview); RelativeLayout.LayoutParams params = new RelativeLayout.LayoutParams(WIDTH, HEIGHT); params.addRule(RelativeLayout.ALIGN_PARENT_TOP); params.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); //
위와같이 사용하여서 RelativeLayout 를 선언하고 처리할 수 있다.
순수한 코딩에서 할때에는 위에
RelativeLayout mView = (RelativeLayout)findViewById(R.id.gview);
대신에
RelativeLayout mView = new RelativeLayout (this);
사용하면 된다는거 아시죠?
'개발 > 개발 자료' 카테고리의 다른 글
(Android) Bitmap 2장 이어붙이기 (2) | 2014.04.02 |
---|---|
(Android) SurfaceView Canvas 를 Bitmap으로 저장하기(가져오기) (5) | 2014.03.26 |
(Android) Assets에서 Bitmap 읽어오기 (0) | 2014.03.24 |
(Android) String.format 이용하기 (0) | 2014.03.24 |
(Android) 안드로이드에서 플래시 실행하기 (3) | 2014.03.21 |
댓글