K
K
korvin22018-08-25 20:31:14
Java
korvin2, 2018-08-25 20:31:14

How to fit elements in an activity?

Hello
Such a question: how can so much content fit into the application screens if it is impossible to "scroll" the screen down in Android Studio? I understand how this happens when a list is created programmatically. There is no need to "insert" elements into the screen or enter them into xml. Or are such long screens created only with the help of lists? For example, I inserted buttons, pictures, text into the activity, there is no more space on the screen, the bottommost element is a button. How can I insert another element under this button and look at it?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
D
Denis Zagaevsky, 2018-08-25
@korvin2

If it really does not fit, you can use ScrollView. As for the viewer in the studio, I might surprise you, but most developers don't use it. Write xml by hand.

A
Azim Kurt, 2015-02-19
@Run

* {
    margin: 0;
}

or in your case
img {
    display: block;
}
h1,h2,h3,h4,h5,h6 {
    margin: 0;
}

R
Roman, 2015-02-19
@paradoxo

Taken from the headlines.
In order to find where the indents come from, use the developer toolbar in your browser. Then you will see what the indent gives you.
In your case, there was a "collapse". What is it and how to overcome it read here - htmlbook.ru/samlayout/blochnaya-verstka/skhlopyvay...

E
Evgeny Nechepurenko, 2015-02-19
@nitroua

.block_1 {
position: relative;
margin-bottom: -4px;
}

h1 {
color: #754f4f;
margin-left: 16px;
margin-top: 0;
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question