66 questions
1
vote
1
answer
31
views
Why is my Jetpack Compose Image taking up all space in the row and hiding the text?
Here are my two previews:
@Preview(showBackground = true)
@Composable
fun RegionsTest1() {
PromVendorsTheme {
Row(
horizontalArrangement = Arrangement.spacedBy(40.dp),
...
1
vote
0
answers
70
views
How to create a LazyVerticalStaggeredGrid that items aligned to start for every even index?
I need to have a LazyVerticalStaggeredGrid that aligns every even item to the left no matter of other which height other items have but while aligning depends height of last 2 items it aligns item to ...
2
votes
1
answer
70
views
Unable to specify weight in Composable with no Column declared in it
I am trying to build a simple calculator using jetpack compose, my composables are:
calculator(): this composable composes the whole calculator
calculatorRow(): it creates a Row of Buttons
When I ...
1
vote
0
answers
60
views
Compose Scaffold does not get the max height of custom bottom bar
I have a custom bottom bar and i want Scaffold to get this bottomBar's max height and give me the padding of it from the bottom so my content is properly placed when there is a scroll for example.
...
0
votes
1
answer
71
views
How do I align an icon in the top left of a Column that has verticalArrangement of Center
As title says, I have a compose Column where I center the contents vertically but I want an icon in top left.
2
votes
0
answers
231
views
How to align a bigger child within a smaller parent in Jetpack Compose?
I have created a Box with a fixed size and it has a child that doesn't respect the parent's constraints. The child uses a requiredSize modifier to do this.
Box(Modifier
.size(50.dp)
.border(2....
1
vote
0
answers
314
views
How to create a custom Layout which will be displayed as floating element in jetpack compose?
I have requirement to create a component which will be displayed by the nested child component but it should not be constrained inside to any it's parent component. And I can position it like top, ...
3
votes
1
answer
1k
views
Custom layout doesn't cause parent to wrap content in jetpack compose
So I have a layout with the following structure:
The layout is as follows:
Card(
modifier = Modifier.fillMaxWidth()
) {
Row(
modifier = Modifier
....
0
votes
1
answer
393
views
Why LazyColumn always seems not showing part of the custom layout view from left and right side?
I have code below which I experiment with LazyColumn and Column on CustomLayoutModifier on Text (or can be on anything).
@Composable
fun Greeting() {
Column(
horizontalAlignment = ...
0
votes
1
answer
620
views
Why the constraint offsetting behave like sizing (width/height) while the layout sizing (width/height) behave like offset
I have the following top-level code where a Box is centered on the device
@Composable
fun Greeting() {
Column(
horizontalAlignment = CenterHorizontally,
verticalArrangement = ...
0
votes
1
answer
361
views
Why adding and subtracting Compose Placeable constraint behave differently?
When I set my pleaceable constraint as below.
LazyColumn(
contentPadding = PaddingValues(all =64.dp),
verticalArrangement = Arrangement.spacedBy(16.dp),
) {
val adjust = 32.dp
item {
...
5
votes
0
answers
989
views
Jetpack compose DropDownMenu position inside a surface not showing
I have a surface (which acts like a card) and at the right top corner I have menu dots. The idea is that when a user taps the menu dots a drop down menu should appear.
The issue I have is that the ...
2
votes
2
answers
1k
views
Can a Compose LazyList be scrolled to adjust for keyboard?
I have been wrestling with IME padding/adjustment for my app. I have written a little toy app to try and focus on just the problem. The app presents a scrollable list of cards with info on them, the ...
1
vote
1
answer
4k
views
Jetpack Compose Row Item Positioning
I've struggled with this layout, which seems like it should be trivial, but I guess since I'm a somewhat beginner with Compose that I can't quite get it right.
All I want to do is have these two ...
0
votes
1
answer
767
views
What is the working logic of Row Arrangement in Android jetpack compose?
I've been currently developing and learning android jetpack compose and there are some things I don't know and wonder about this. One thing I'm wondering I'm trying to do a back button positioned in ...