Reputation: 1140
If I have just a single LinearLayout with a few items in it, then what effects will be of replacing it with ConstraintLayout
<LinearLayout>
<TextView>
<TextView>
<TextView>
</LinearLayout>
vs
<ConstraintLayout>
<TextView>
<TextView>
<TextView>
</ConstraintLayout>
Are there any differences in their efficiencies?
Upvotes: 23
Views: 10779
Reputation: 676
For such a simple layout with no nesting and only 3 children TextView, LinearLayout is the best on conceptual complexity, on performance, on drag and drop user interface of Android Studio, on XML lines, on kB size of the app. Maybe I forgot something, but I would not dare to waste time and mess things with any other layout than the LinearLayout in this case.
Upvotes: 27