1
00:00:00,240 --> 00:00:02,050
Hello this is Martez of course.

2
00:00:02,100 --> 00:00:07,530
And in this story all let's change the Paglen color of our relatively Also inside this componentry section

3
00:00:07,530 --> 00:00:15,210
description relatively out and inside these attributes here you can see that we have this icon view

4
00:00:15,270 --> 00:00:17,360
all attributes and view.

5
00:00:17,460 --> 00:00:23,180
Again if I click on it you can see this list attributes of view all attributes and search for the background

6
00:00:23,250 --> 00:00:24,460
attributes.

7
00:00:24,660 --> 00:00:25,830
So here for this.

8
00:00:25,830 --> 00:00:30,170
Back in an attribute you can see this spot and you can see this from that spot.

9
00:00:30,210 --> 00:00:35,790
If I hover over these attributes or just click on it and here this window is going to be orphant you

10
00:00:35,790 --> 00:00:39,260
can see we have some Papiss click on color top.

11
00:00:39,480 --> 00:00:40,640
And here we can change.

12
00:00:40,680 --> 00:00:41,990
We can select a color.

13
00:00:42,000 --> 00:00:45,900
So for example we can change click on color axent right.

14
00:00:46,230 --> 00:00:51,390
If you want to you can change the color here or here it says add new resource right.

15
00:00:51,390 --> 00:00:58,840
Just click on it and here just click on new color value and for example we can select a new color.

16
00:00:58,840 --> 00:01:01,390
Here we have we have red color.

17
00:01:01,410 --> 00:01:03,240
We have Hallward red light.

18
00:01:03,300 --> 00:01:05,710
We can just choose this color and then click on OK.

19
00:01:05,940 --> 00:01:08,310
So now the background color is changed.

20
00:01:08,460 --> 00:01:15,660
So now let's add our linearly out horizontal into our little lives inside this palette section.

21
00:01:15,660 --> 00:01:22,860
Click on layouts and just click on linearly or horizontal and just drag it here into our relatively

22
00:01:22,860 --> 00:01:25,100
out OK.

23
00:01:25,320 --> 00:01:30,340
So let's put it here and now are to select this linearly as horizontal.

24
00:01:30,360 --> 00:01:34,220
Let's close this search and for the lay out of it.

25
00:01:34,290 --> 00:01:41,310
Let's assign the value of content to this for the height assigned the value of content for this linearly

26
00:01:41,310 --> 00:01:42,090
and horizontal.

27
00:01:42,180 --> 00:01:42,960
OK.

28
00:01:43,080 --> 00:01:45,520
Now literally out of with as much apparent.

29
00:01:45,870 --> 00:01:51,580
So now let's add some buttons to our linearly as horizontal inside this palette section and all.

30
00:01:51,580 --> 00:01:55,140
And at the bottom two are linearly at all isn't.

31
00:01:55,160 --> 00:02:00,740
So here we have the spot and let's change the takes of this button to button one.

32
00:02:01,010 --> 00:02:03,040
And the president of your keyboard.

33
00:02:03,590 --> 00:02:07,520
And here you can see that the layout of our button is wrapped content.

34
00:02:07,550 --> 00:02:08,210
Right.

35
00:02:08,660 --> 00:02:11,550
But the layout weight is number one.

36
00:02:11,570 --> 00:02:14,980
Just delete this number one and then present it to the key on your keyboard.

37
00:02:15,260 --> 00:02:16,580
So I thought what about this.

38
00:02:16,580 --> 00:02:22,280
Lay out great leader for now let's just click on this view all attributes in order to see list attributes

39
00:02:22,280 --> 00:02:23,030
here.

40
00:02:23,090 --> 00:02:28,760
Let's add another part into our linearly or horizontal and below this pattern here inside this componentry

41
00:02:28,760 --> 00:02:29,690
section.

42
00:02:29,690 --> 00:02:37,460
So just select a spot in change that takes up the spot into Potin to and delete the value of this play

43
00:02:37,470 --> 00:02:39,810
out we lay out a wait actually.

44
00:02:40,390 --> 00:02:43,950
And here you can see that the last bit which is rap content.

45
00:02:44,080 --> 00:02:48,790
Let's add another button to this linearly horizontal inside this linearly horizontally so you can see

46
00:02:48,790 --> 00:02:56,230
that these blue lines are actually guiding us that very we don't exactly put our patents or just put

47
00:02:56,230 --> 00:03:05,560
it here and here at Selecta spotted for the text choose a button of free and then precedented on your

48
00:03:05,560 --> 00:03:09,110
keyboard and the lay out weight should be nothing.

49
00:03:10,140 --> 00:03:17,330
So here you can see that we have these buttons but it is these buttons are this organized.

50
00:03:17,370 --> 00:03:20,660
I don't like how these buttons are actually organized.

51
00:03:20,970 --> 00:03:25,500
So in order to solve this problem we need to assume just assume.

52
00:03:25,500 --> 00:03:34,740
Imagine imagine that this linearly at horizontal is actually divided into three parts because we have

53
00:03:34,740 --> 00:03:37,080
only five buttons free buttons right.

54
00:03:37,110 --> 00:03:44,280
So if you imagine that only nearly horizontal is divided into three parts each button should take one

55
00:03:44,280 --> 00:03:45,100
part.

56
00:03:45,400 --> 00:03:51,910
OK the beat of each button should take one part of this linearly or horizontal.

57
00:03:52,320 --> 00:03:57,960
We don't want to do anything with the height because the height is rock content but you want to solve

58
00:03:58,020 --> 00:04:01,080
the problem of the beat.

59
00:04:01,090 --> 00:04:03,510
So now here we are going to do.

60
00:04:03,790 --> 00:04:05,650
So just select for example.

61
00:04:05,650 --> 00:04:09,920
These buttons hold down inside this componentry section if you find two cities.

62
00:04:09,940 --> 00:04:15,040
All of these patterns you can either hold down the Shift key and select all of them or you can't just

63
00:04:15,190 --> 00:04:16,540
if you're using a Mac.

64
00:04:16,660 --> 00:04:19,970
Just hold down the command key on your keyboard and select each of these buttons.

65
00:04:20,140 --> 00:04:24,890
And if you're using Windows hold down the construction on your keyboard and track each of these buttons.

66
00:04:25,450 --> 00:04:30,500
And here for the layout V we just assign the value zero here.

67
00:04:31,390 --> 00:04:38,410
Because we assumed that our linearly as horizontal is divided into three free parts of our linearly

68
00:04:38,410 --> 00:04:46,320
authority until it's divided into three parts and each part in it should take one part each part in

69
00:04:46,340 --> 00:04:50,310
which should take one part of our linearly or horizontally.

70
00:04:50,530 --> 00:04:54,640
So now we assign the value zero for the layout with our patterns.

71
00:04:54,640 --> 00:04:57,450
Now we have this lay out weight attributes.

72
00:04:57,580 --> 00:05:03,390
So I told you that we have three parts so each button should take one part and we assign the value.

73
00:05:03,390 --> 00:05:09,540
Number one for the button for the Leanna's varied of each button in that holding area horizontally so

74
00:05:09,550 --> 00:05:13,610
just as I did another one here and then press on on your keyboard.

75
00:05:14,050 --> 00:05:21,370
So now you can see that our buttons are now completely organized inside Onelia horizontal.

76
00:05:21,550 --> 00:05:28,420
So this is how you solve the problem of linearly outs in and right whether you want to specify the lay

77
00:05:28,420 --> 00:05:32,980
out Viets or the outside this lay of weight is very usable.

78
00:05:33,060 --> 00:05:40,090
OK so for example I imagine that might lay out linearly at present or is divided into three parts.

79
00:05:40,300 --> 00:05:46,170
And I wanted that each button should take one part of that linearly out horizontal.

80
00:05:46,240 --> 00:05:53,450
So I assign the values 0 to the layout of each bartend and is I assigned to lay out vate value.

81
00:05:53,500 --> 00:05:55,700
Number one for that we have to wait up each button.

82
00:05:55,720 --> 00:06:03,070
So now you can see that our linearly horizontal is actually divided into three parts and each part is

83
00:06:03,070 --> 00:06:05,990
taken by each button here.

84
00:06:06,250 --> 00:06:06,630
Right.

85
00:06:06,640 --> 00:06:08,160
So you learn more about this later.

86
00:06:08,170 --> 00:06:14,680
But here I just wanted to tell you that before we use the persons so we just said for example I said

87
00:06:14,680 --> 00:06:22,810
that assume that this linearly or horizontal or this in the area vertical is for example Davidovits

88
00:06:22,930 --> 00:06:26,420
or the height is for example 100 percent.

89
00:06:26,420 --> 00:06:33,960
And for example we want our button all we want are text views to take for example a 20 percent or that

90
00:06:33,960 --> 00:06:40,990
pattern to take 25 percent dispersants is not used anymore in Android studio and it can actually show

91
00:06:40,990 --> 00:06:48,130
you a compiler error if you use percent for the base attributes of your for example but in all your

92
00:06:48,130 --> 00:06:48,930
layouts.

93
00:06:49,150 --> 00:06:52,050
So for example here we cannot say 50 percent is going to.

94
00:06:52,300 --> 00:06:57,850
If you want to run your app can actually show you a compiler error for that here.

95
00:06:57,950 --> 00:06:59,440
Here is the formula.

96
00:06:59,710 --> 00:07:06,400
If you are using a linearly out for example a horizontal linearly or a vertical linearly out just as

97
00:07:06,400 --> 00:07:12,880
soon or imagined that that's linearly out is actually divided into a number of parts.

98
00:07:12,940 --> 00:07:14,200
It doesn't really matter.

99
00:07:14,200 --> 00:07:20,500
It depends on your application and how you how many items you want to add into that specific linearly

100
00:07:20,500 --> 00:07:21,240
out.

101
00:07:21,340 --> 00:07:22,570
Just assume that it is.

102
00:07:22,570 --> 00:07:33,490
Imagine it is divided into a number of parts and 40 lay out Viets or lay out height of your for example

103
00:07:33,490 --> 00:07:35,400
of specific items.

104
00:07:35,470 --> 00:07:37,350
Just assign the values here.

105
00:07:37,390 --> 00:07:39,910
I just want to solve the problem of lay out.

106
00:07:40,060 --> 00:07:48,010
So I assign the value 0 to the layout width of each button and here for example here I wanted to for

107
00:07:48,010 --> 00:07:52,730
example my button each button to take each part to take one part.

108
00:07:52,750 --> 00:07:56,450
So I assigned the value number one for the lay out weight of each button.

109
00:07:56,740 --> 00:08:04,780
So here for example you may say that I want to assume or imagine that my linearly or horizontal is divided

110
00:08:04,780 --> 00:08:06,510
into 10 parts.

111
00:08:06,510 --> 00:08:06,820
Right.

112
00:08:06,820 --> 00:08:09,800
You can imagine that you can imagine anything.

113
00:08:10,090 --> 00:08:16,870
So now I am going to imagine that my linearly authorities aren't all is divided into 10 parts and one

114
00:08:16,870 --> 00:08:23,800
of my Bettina's So for example Potten number three I want this patent to take eight parts.

115
00:08:24,190 --> 00:08:26,080
So how you're going to solve this problem.

116
00:08:26,260 --> 00:08:31,200
So in order to solve this problem so use it that we have put in number one but in two we have both in

117
00:08:31,260 --> 00:08:37,660
the bottom three should take eight parts of the vse of the linearly out horizontally.

118
00:08:37,660 --> 00:08:41,070
So in order to solve this problem you just need to select a pattern free.

119
00:08:41,270 --> 00:08:47,930
So the left of should be zero because here we want at the bottom free to take eight parts of the bit

120
00:08:48,220 --> 00:08:49,600
of the linearly and horizontal.

121
00:08:49,720 --> 00:08:53,020
OK so that's why we assign the number 0 to the lay out.

122
00:08:53,470 --> 00:08:59,740
And for the lay out rate instead of number one we just assign the value number 8 and then present until

123
00:08:59,740 --> 00:09:00,910
January.

124
00:09:01,270 --> 00:09:08,940
So now we can see that this part in free is taking eight parts of the linearly out horizontally.

125
00:09:09,310 --> 00:09:10,800
Right.

126
00:09:10,930 --> 00:09:18,490
So now somebody else says OK now I want to imagine that my linearly out to the width of my linear layout

127
00:09:18,520 --> 00:09:27,530
is actually divided into 20 parts and I want my number one to take for example a 10 parts.

128
00:09:27,730 --> 00:09:33,290
So here you can see that bottom number three is eight parts of the 20 parts.

129
00:09:33,320 --> 00:09:39,020
Right and bottom number two is actually taking one part.

130
00:09:39,380 --> 00:09:42,900
So now there are actually 11 parts left.

131
00:09:42,980 --> 00:09:50,880
So we can now say that button number one can take 11 parts and then press on until you on your table.

132
00:09:51,260 --> 00:09:53,870
So you can see that how these layouts change.

133
00:09:53,870 --> 00:09:54,140
Right.

134
00:09:54,140 --> 00:09:56,070
We have number one button free.

135
00:09:56,210 --> 00:09:58,030
So you learn all about it later.

136
00:09:58,040 --> 00:10:04,430
But here I just wanted to actually let you know about the lay out weight and how you are going to design

137
00:10:04,430 --> 00:10:10,590
your layouts later in this course because we're going to create about 90 applications in the scores.

138
00:10:10,790 --> 00:10:17,300
So it is necessary that you learn all about these attributes and how you're going to design your layouts

139
00:10:17,300 --> 00:10:18,100
in this course.

140
00:10:18,440 --> 00:10:21,610
So I think that's enough for this tutorial in the next tutorial.

141
00:10:21,620 --> 00:10:26,300
I'm going to show you how you can run your application on the Android emulator.

142
00:10:26,300 --> 00:10:27,750
Thank you very much for watching.

143
00:10:27,800 --> 00:10:33,950
If you have any questions about these concepts that I've taught you so far please what's the discussion

144
00:10:33,950 --> 00:10:34,590
in the course.

145
00:10:34,760 --> 00:10:36,870
And then I do my best to answer all of your questions.

146
00:10:37,280 --> 00:10:40,000
And I look forward to seeing you in the next tutorial.

