1
00:00:00,420 --> 00:00:05,470
So as you can see here these are the lines of code that I pasted here.

2
00:00:05,580 --> 00:00:12,570
So again we have two buttons in the preview you can see these two buttons inside these linearly or horizontal.

3
00:00:12,630 --> 00:00:18,360
And again we have these buttons with the same attributes that we have here for this first linearly or

4
00:00:18,360 --> 00:00:19,220
horizontal.

5
00:00:19,410 --> 00:00:27,110
So again the lay out which is a 0 DP The layout height is the up content delay outwait is zero point

6
00:00:27,110 --> 00:00:30,330
five and lines is number two as you can see here.

7
00:00:30,330 --> 00:00:37,590
So this means that this button can accept two lines of text and the layout margin for each of the directions

8
00:00:38,280 --> 00:00:41,670
left top right and bottom is five deep.

9
00:00:41,730 --> 00:00:44,000
And again we have another button here.

10
00:00:44,190 --> 00:00:46,520
Again the lead out is zero.

11
00:00:46,600 --> 00:00:54,710
DP and the layout height is that content the layout weight is zero point five and lines is number 2.

12
00:00:54,990 --> 00:00:57,720
And the left margin is five right.

13
00:00:57,720 --> 00:01:00,450
So we need another linearly or horizontal here.

14
00:01:00,450 --> 00:01:06,440
So after the end the stack of these linearly Olthuis until now we need to create another linearly or

15
00:01:06,480 --> 00:01:07,460
horizontal here.

16
00:01:07,560 --> 00:01:14,760
So just typing in here linearly out and for the layout we assign the value match parent and for the

17
00:01:14,840 --> 00:01:18,480
layout height assign the value of that content.

18
00:01:19,000 --> 00:01:22,670
And now let's actually specify the orientation.

19
00:01:22,890 --> 00:01:32,640
So the orientation is horizontal and let's specify the ID and the ID is going to be first row filled

20
00:01:32,870 --> 00:01:37,670
a row linear layout.

21
00:01:37,950 --> 00:01:38,500
Right.

22
00:01:38,710 --> 00:01:46,610
But again we didn't specify here that we want to create an ID soap at sign Plus Id slash.

23
00:01:46,810 --> 00:01:52,450
And this is going to be the ID first row linearly out and now inside Enceladus linearly out here we

24
00:01:52,450 --> 00:01:58,320
just need to put two more buttons here so we can actually copy these buttons here as you can see.

25
00:01:58,570 --> 00:02:00,940
I can copy these buttons here and put them here.

26
00:02:00,950 --> 00:02:03,150
Inside is linearly out here.

27
00:02:03,430 --> 00:02:09,280
So as you can see here these are the lines of code that I put in say these ferde rolling out as you

28
00:02:09,280 --> 00:02:10,060
can see here.

29
00:02:10,180 --> 00:02:16,360
So again we have the same attributes play out with is zero the layout height is the content lay out

30
00:02:16,360 --> 00:02:21,360
of it is 0.5 lines and number two and lay out margin is 5 DP.

31
00:02:21,370 --> 00:02:27,730
And again we have another another button here which is that the layout is zero DP The layout height

32
00:02:27,730 --> 00:02:31,920
is Rabbe content the layout of it is 0.5 lines.

33
00:02:31,930 --> 00:02:35,400
Number two and the layout margin is five DP Right.

34
00:02:35,440 --> 00:02:37,500
So hopefully that makes sense.

35
00:02:37,510 --> 00:02:42,160
So now after the end in touch of this linearly out horizontal here.

36
00:02:42,260 --> 00:02:45,040
Now I want to add some lines of code here.

37
00:02:45,040 --> 00:02:50,480
I'm going to paste in some lines of code here and then I'm going to explain to you what's going on here.

38
00:02:50,500 --> 00:02:55,250
So as you can see here these are the lines of code that I pasted here.

39
00:02:55,270 --> 00:03:02,350
So if we have a text view right and lay out which is that content the layout height is that content.

40
00:03:02,440 --> 00:03:06,250
And here we have a new attribute text appearance.

41
00:03:06,250 --> 00:03:06,850
OK.

42
00:03:07,300 --> 00:03:11,170
So now I have to specify the appearance of my text view.

43
00:03:11,320 --> 00:03:13,140
So I put a question mark here.

44
00:03:13,180 --> 00:03:13,690
OK.

45
00:03:13,900 --> 00:03:16,280
Question mark and throw it colon.

46
00:03:16,400 --> 00:03:19,080
83 R which stands for attributes.

47
00:03:19,120 --> 00:03:19,780
OK.

48
00:03:19,870 --> 00:03:23,450
Slash and now I can specify the appearance of my tastes.

49
00:03:23,590 --> 00:03:24,520
So we have taste.

50
00:03:24,520 --> 00:03:25,750
Appearance Large.

51
00:03:26,050 --> 00:03:27,130
We have taste.

52
00:03:27,130 --> 00:03:28,910
Appearance small.

53
00:03:29,560 --> 00:03:32,050
And we have also taste appearance.

54
00:03:32,050 --> 00:03:32,770
Medium.

55
00:03:33,000 --> 00:03:33,670
OK.

56
00:03:34,090 --> 00:03:37,300
So for our application we choose text.

57
00:03:37,300 --> 00:03:39,230
Appearance Large.

58
00:03:40,120 --> 00:03:45,070
And as you can see here this means that it's going to actually make our taste feel a little bit larger

59
00:03:45,970 --> 00:03:48,470
and we have this taste attribute.

60
00:03:48,700 --> 00:03:54,350
And now as you can see here we are referring to our strange resource inside this inside this thing that

61
00:03:54,350 --> 00:03:55,000
they smell.

62
00:03:55,150 --> 00:03:58,470
So now let's actually open our project structure.

63
00:03:58,600 --> 00:04:04,780
So just click on the view here at the top tool windows and we can project and now double click on this

64
00:04:04,840 --> 00:04:10,870
app here and then double click on this race folder and here double click on these values here and now

65
00:04:11,110 --> 00:04:12,820
inside this as you can see here.

66
00:04:12,830 --> 00:04:15,090
So these values folders we have this file here.

67
00:04:15,100 --> 00:04:17,930
This is a modified strings that ASML right.

68
00:04:18,070 --> 00:04:22,400
So just double click this file here and now as you can see we have this file here.

69
00:04:22,570 --> 00:04:26,170
So now inside this file you have substring resources.

70
00:04:26,200 --> 00:04:31,730
The first one is the name of our application string named app underlined name which is this name animal

71
00:04:31,760 --> 00:04:38,000
quis and we have this name which is actions the settings for the Settings button.

72
00:04:38,450 --> 00:04:41,380
And now I want to add other resources here.

73
00:04:41,500 --> 00:04:45,030
So let's go back to our fragment underline minute example here.

74
00:04:45,160 --> 00:04:50,770
As you can see I refer to this string resource here at science 3 inch slash question text and as you

75
00:04:50,770 --> 00:04:54,870
can see here our project does not recognize this value here right.

76
00:04:54,880 --> 00:04:56,470
Question underlying text.

77
00:04:56,470 --> 00:05:00,700
So now let's actually create our string source with this name here.

78
00:05:00,700 --> 00:05:05,630
So let's go inside the strings that gets them in here and then open attack streams.

79
00:05:06,070 --> 00:05:11,520
And the name is going to be question underlined text and then and the tag as you can see here.

80
00:05:11,650 --> 00:05:20,120
Close the tile here by by putting this piece of code here and now inside this string here inside the

81
00:05:20,130 --> 00:05:21,130
string tag.

82
00:05:21,310 --> 00:05:23,120
I can add my value here.

83
00:05:23,170 --> 00:05:33,610
So now I can't just type indices animal per cent one dollar sign.

84
00:05:33,630 --> 00:05:40,230
D of percent to dollar sign the.

85
00:05:40,290 --> 00:05:42,150
So now what does this mean.

86
00:05:42,180 --> 00:05:50,840
As you can see it says this is animal per cent one dollar Sainty of per cent to Dollar Signs.

87
00:05:51,000 --> 00:05:57,720
So this one as you can see here per cent one dollar sign D is actually an integer value is going to

88
00:05:57,720 --> 00:05:57,950
be.

89
00:05:57,990 --> 00:06:05,170
This is going to be an integer argument actually we have an integer argument as you can see here D right.

90
00:06:05,250 --> 00:06:12,630
So here as you can see because we need to actually provide this format here per cent one dollar sign.

91
00:06:12,630 --> 00:06:14,220
So what is this one here.

92
00:06:14,220 --> 00:06:18,130
This one is actually means that this is actually the first argument.

93
00:06:18,270 --> 00:06:18,830
Right.

94
00:06:18,870 --> 00:06:23,250
And this number two here means this is going to be the second argument.

95
00:06:23,250 --> 00:06:23,720
Right.

96
00:06:23,820 --> 00:06:30,900
So we need to put this format here in order to specify that that this is going to be our first argument

97
00:06:30,950 --> 00:06:33,000
which is going to be of type integer.

98
00:06:33,000 --> 00:06:33,450
Right.

99
00:06:33,480 --> 00:06:36,750
So now let me show you are the emulator here.

100
00:06:36,750 --> 00:06:39,280
Our application is running on this emulator here right.

101
00:06:39,330 --> 00:06:42,460
So now you can see that it says this is animal 1.

102
00:06:42,510 --> 00:06:45,050
So as you can see here our crew is just started.

103
00:06:45,330 --> 00:06:47,530
And this is animal one of 10.

104
00:06:47,550 --> 00:06:54,350
So we have 10 animals 10 questions as you can see here and now this is going to be the first one.

105
00:06:54,600 --> 00:06:55,170
Right.

106
00:06:55,170 --> 00:06:57,600
So as you can see the first one is number one here right.

107
00:06:57,630 --> 00:06:59,080
And the second one is number 10.

108
00:06:59,220 --> 00:07:06,780
So here we are actually code in our application when we are actually providing the logic our application

109
00:07:06,810 --> 00:07:12,140
of for our application in inside the main activity of a file or other dhaba files.

110
00:07:12,150 --> 00:07:15,870
I'll teach you that what is going to be the use of this format here.

111
00:07:15,870 --> 00:07:16,130
OK.

112
00:07:16,140 --> 00:07:19,240
Later you will understand how this format here works.

113
00:07:19,350 --> 00:07:25,020
OK for now just put this here and for now just understand that here this present one dollar sign means

114
00:07:25,290 --> 00:07:28,950
that this is going to be our first argument which is going to be off the integer.

115
00:07:29,310 --> 00:07:35,100
And here this person's two dollar sign D means that the this is going to be our second argument which

116
00:07:35,100 --> 00:07:36,570
is going to be of type integer.

117
00:07:36,720 --> 00:07:37,410
Right.

118
00:07:37,740 --> 00:07:39,900
So hopefully that makes sense.

119
00:07:39,900 --> 00:07:44,290
So now let's actually go inside a fragment underlying minute that example here.

120
00:07:44,490 --> 00:07:45,660
And as you can see here.

121
00:07:45,680 --> 00:07:47,910
So as you can see the error is gone here.

122
00:07:47,910 --> 00:07:53,450
So question underlying text and here I provided an I.D. for this text view.

123
00:07:53,640 --> 00:08:01,110
So the IDs question number takes you right as you can see here we can actually change this ID for example

124
00:08:01,110 --> 00:08:08,700
to TXI the question number right.

125
00:08:09,110 --> 00:08:10,090
This is very good.

126
00:08:10,200 --> 00:08:17,270
The question number and they lay out gravity as you can see here it says Center horizontal.

127
00:08:17,270 --> 00:08:18,010
Right.

128
00:08:18,020 --> 00:08:24,920
So this lay out gravity is going to specify what it's going to be the position of this takes you according

129
00:08:24,920 --> 00:08:26,120
to its parent.

130
00:08:26,180 --> 00:08:26,610
Right.

131
00:08:26,630 --> 00:08:29,020
So the parent of this textbook is this linearly.

132
00:08:29,060 --> 00:08:29,800
Right.

133
00:08:29,810 --> 00:08:32,610
So here it says Center horizontal.

134
00:08:32,630 --> 00:08:38,930
So here this can actually put this takes you Center horizontally inside this linear layout as you can

135
00:08:38,930 --> 00:08:39,800
see here.

136
00:08:40,310 --> 00:08:44,340
So you already know about Lyell's gravity's anti-gravity attribute.

137
00:08:44,480 --> 00:08:50,180
And as you can see we have this lay out marching but him as you can see here you provided a margin bottom

138
00:08:50,180 --> 00:08:58,960
here and now again we need to provide a resource here so let's actually open our project structure so

139
00:08:59,290 --> 00:09:06,420
click on this view here at the top tool windows and then project and then as you can see Enceladus values

140
00:09:06,420 --> 00:09:07,000
fall there.

141
00:09:07,160 --> 00:09:13,100
We have these demons that examined here to just double click on it here and now inside these resources

142
00:09:13,100 --> 00:09:13,760
tagged.

143
00:09:13,820 --> 00:09:20,540
Now we need to provide another dimension here so just to just open attach here and type in deman and

144
00:09:20,540 --> 00:09:24,220
the name is going to be Margene underlined value

145
00:09:27,460 --> 00:09:32,120
and then just close this tag and just provide a value in nine.

146
00:09:32,140 --> 00:09:34,800
DP OK.

147
00:09:34,870 --> 00:09:39,880
Now let's actually go back into our fragment underlayment and examine here and now you can see here

148
00:09:39,880 --> 00:09:41,050
the error is gone.

149
00:09:41,050 --> 00:09:45,880
So now let me double click on this fragment underline militarism and tab here in order to make this

150
00:09:45,880 --> 00:09:47,610
area wider.

151
00:09:47,740 --> 00:09:50,890
And now just a click on this preview here at the right hand side.

152
00:09:51,000 --> 00:09:57,000
And now you can see that you've got free rows with actually buttons inside them.

153
00:09:57,040 --> 00:09:59,710
And as you can see we have also this takes you here right.

154
00:09:59,950 --> 00:10:06,880
So now as you can see here the margin button is much in value which we provided here in say the statements

155
00:10:06,880 --> 00:10:07,650
that they examined here.

156
00:10:07,660 --> 00:10:09,030
As you can see 90.

157
00:10:09,550 --> 00:10:14,460
And now we have also the text color attribute which is actually the value.

158
00:10:14,520 --> 00:10:19,400
White right hash that f f f means white as you can see here.

159
00:10:19,420 --> 00:10:25,390
So now we can actually change this value for example to another value but let's actually change the

160
00:10:25,390 --> 00:10:27,630
background color of this linear layout.

161
00:10:27,640 --> 00:10:30,190
So let's just scroll to the top here.

162
00:10:30,250 --> 00:10:32,300
And as you can see here these are linearly out.

163
00:10:32,350 --> 00:10:35,580
So now I want to add another attribute to this linearly or.

164
00:10:35,600 --> 00:10:37,810
So just type in here Paglen don't.

165
00:10:38,110 --> 00:10:42,810
And as you can see here I just select Ispahan on attributes and now I can't just type in hash tag.

166
00:10:42,920 --> 00:10:44,280
Zero zero zero.

167
00:10:44,620 --> 00:10:49,170
And now as you can see here the background color of my linearly out is now black.

168
00:10:49,300 --> 00:10:51,070
And now I can see this text here.

169
00:10:51,070 --> 00:10:56,330
This is animal per cent one dollar Sainty of person two dollar sign.

170
00:10:56,440 --> 00:10:57,250
Right.

171
00:10:57,310 --> 00:10:59,840
So now scroll down here.

172
00:11:00,220 --> 00:11:02,510
And as you can see here these are tasteful here.

173
00:11:02,530 --> 00:11:03,370
Right.

174
00:11:03,370 --> 00:11:09,370
So now we're going to actually paste in some more lines of code here and then I'm going to explain to

175
00:11:09,370 --> 00:11:10,870
you what's going on here.

