开发者

How many different way are there for creating GUI in Android Programming?

开发者 https://www.devze.com 2023-03-16 07:37 出处:网络
I am new to Android P开发者_如何学Pythonrogramming, and I saw via tutorial that we can create GUI using main.xml or via Graphical Layout, but it is not that much flexible, like I choose a button and w

I am new to Android P开发者_如何学Pythonrogramming, and I saw via tutorial that we can create GUI using main.xml or via Graphical Layout, but it is not that much flexible, like I choose a button and want show it on my chosen pixels of screen (as I do CGReckMake in iPhone programming), any suggestion or better way to get flexibility in Android GUI?


As Android supports different hardware with different specs related to screen side, density, etc. it is not recommended to do pixel-precise layout of elements on the screen.

There is an AbsoluteLayout which allows you to specify exact location for the elements, but it's use is discouraged if you want your app to run on different devices.


In Android i know two way to design GUI by XML or By JavaCode but my suggestion is you should use XML because it is easy compare to javacode learning about layouts and view then you find it is very easy.


You can use droiddraw also.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号