Reputation: 15
I am starting to delve into Android Development and there is a lot of material online. The question is... What are the pro's and con's against the drag and drop XML design method vs coding the view manually? The only reason I ask on here is because online the views are mixed and they don't really back up what they're defending.
If I use the drag and drop method will I have issues further onto my development adventures? That is the thing that worries me the most... I don't want to learn the drag and drop method and then editting the XML to cater for my needs and then be handicapped by it.
Upvotes: 1
Views: 79
Reputation: 587
For the beginner(s), I highly recommend not to use Drag and drop. We need to understand XML
, to be comfortable with android widget. Understanding XML
will come handy in future when creating custom styles
and themes.
Here are few pointers before you dive in android XML layout
match_parent
and wrap_content
while defining android:layout_height
or android:layout_width
if possibleRelativeLayout
, LinearLayout
and FrameLayout
and how its child views are arranged.ConstraintLayout
, AppbarLayout
and similar advance layout at current.TextView
, EditText
, Button
, ImageView
and ProressBar
as far as possible.(This are most common widgets/views)ListView
, its deprecated. Try using RecyclerView
instead, it is one of the important widget that would be used in regular basis.Upvotes: 2