Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Android AND-801 Exam - Topic 8 Question 72 Discussion

Posted by Beckie on Sep 14, 2024 at 02:56 AM

Which of the below choices is the best answer to fill the empty space in the following sentence? If you want to give all text widgets in an app the same format such as font color, font size, and font family, you should add the style attribute to the TextView XML tags in layout file and set the attribute value to the same style name. You should define that style by adding a new style tag "style name-style_name" inside...............................

Suggested Answer: C

Get Premium AND-801 Questions as Interactive Web-Based Practice Test or PDF Real Exam Format Detailed Explanations Instant Access Get Your Practice Test
32 comments · newest first
TA
Tanesha 10 months ago
I thought it could be in MainActivity.java too, but styles.xml makes more sense.
QU
Quentin 11 months ago
No way, it has to be styles.xml!
TA
Tarra 11 months ago
Wait, are we sure it’s not activity_main.xml?
AL
Allene 11 months ago
I agree, styles.xml is the right place for that.
LA
Laurel 11 months ago
It’s definitely styles.xml!
BI
Billi 12 months ago
I definitely recall something about styles being in a separate file, so I’m leaning towards C as well.
DE
Desirae 12 months ago
I’m a bit confused; I thought we could define styles in the activity_main.xml too, but that might not be the best practice.
LA
Latonia 12 months ago
I remember practicing a question about XML layouts, and I feel like the answer might be C, styles.xml.
MI
Mira 1 year ago
I think the styles should be defined in the styles.xml file, but I'm not completely sure.
SH
Shawnda 1 year ago
Okay, let me think this through. The question is asking where we should define a style that we want to apply to all TextViews in the app. I'm pretty sure the answer is the `styles.xml` file, but I'll double-check the options just to be sure.
SH
Shaun 1 year ago
Ah, I've seen this type of question before. The key is to remember that styles are defined in the `styles.xml` file, not in the manifest or activity files. I'm confident I can get this one right.
JO
Joni 1 year ago
Hmm, I'm a bit unsure about this one. I know styles are defined in a separate XML file, but I can't quite remember the exact name of that file. I'll have to think this through step-by-step.
TY
Tyra 1 year ago
This seems like a straightforward question about Android app development. I'll carefully read through the options and think about where styles are typically defined in an Android app.
AL
Alpha 1 year ago
Okay, let me think this through step-by-step. The question is asking about the 'traditional' view, so I need to consider what the conventional wisdom has been historically. I'm leaning towards B, but I'll double-check the other options just to be sure.
LI
Linette 2 years ago
Haha, definitely not D) MainActivity.java or MainActivity.kt file. That would be like trying to style your clothes in your pocket instead of your wardrobe.
LO
Lourdes 2 years ago
↳ replying to Linette
Haha, definitely not D) MainActivity.java or MainActivity.kt file. That would be like trying to style your clothes in your pocket instead of your wardrobe.
MA
Margery 2 years ago
↳ replying to Linette
C) stytes.xml file
MA
Magda 2 years ago
↳ replying to Linette
B) activity_main.xml file
TY
Ty 2 years ago
↳ replying to Linette
A) AadroiddManifest-xml file
SH
Sharika 2 years ago
I agree, C) styles.xml file is the way to go. Defining the style in the layout file would be too much of a hassle.
TU
Tula 2 years ago
↳ replying to Sharika
D) MainActivity.java or MainActivity.kt file
AR
Arlyne 2 years ago
↳ replying to Sharika
C) stytes.xml file
RE
Ressie 2 years ago
↳ replying to Sharika
B) activity_main.xml file
DA
Dan 2 years ago
↳ replying to Sharika
A) AadroiddManifest-xml file
TH
Theron 2 years ago
I agree with Charlesetta. Adding the style in styles.xml file makes sense.
KA
Karl 2 years ago
I'm not sure, but I think it might be B) activity_main.xml file.
HA
Harrison 2 years ago
The correct answer is C) styles.xml file. You need to define the style in the styles.xml file to apply it to all the TextView widgets in the app.
DO
Dorian 2 years ago
↳ replying to Harrison
D) MainActivity.java or MainActivity.kt file
MA
Marica 2 years ago
↳ replying to Harrison
C) stytes.xml file
CA
Casie 2 years ago
↳ replying to Harrison
B) activity_main.xml file
LA
Lacey 2 years ago
↳ replying to Harrison
A) AadroiddManifest-xml file
CH
Charlesetta 2 years ago
I think the answer is C) styles.xml file.
0/2000 characters

Save Cancel