Category "android-jetpack-compose"

Why Surface child compasable fill max size if i don't wrap it in an other container?

This code fills the full screen if i specify the size to be 100.dp. ComposeTheme { Surface( modifier = Modifier.fillMaxSize(), color = Mater

How to add/remove characters inside TextField?

I have a Room database with a table that holds users. Each user has an ID and a name. My goal is to change the name of the user based on the ID. Here is what I

Problems with android Compose

I am trying to work through a tutorial on android compose. It works well while I use:kotlin-gradle-plugin:1.5.31, but the android studio has updated to :kotlin-

Android Jetpack Compose - java.lang.NoSuchMethodError: No virtual method setContent(Lkotlin/jvm/functions/Function0;)

I'm getting a java.lang.NoSuchMethodError exception when trying to run setContent{ Composable() }. Full code: class ComposeFragment : Fragment() { override fun

Jetpack compose with Google Place API

I am trying to use Place SDK with jetpack compose but I can not find any resource on how to implement this. @Composable fun PlaceSearchView() { // Initializ

Modal Bottom Sheet in Jetpack Compose for Activity

I have bottom navigation bar. So my composable functions do not take up the full screen size. When I use ModalBottomSheetLayout, it opens in the composable fun,

What is the Jetpack Compose equivalent of RecyclerView or ListView?

In Jetpack Compose, how can I display a large list of data while laying out only the visible items, instead of composing and laying out every item on the initia

Compose: remember() with keys vs. derivedStateOf()

What is the difference between these two approaches? val result = remember(key1, key2) { computeIt(key1, key2) } (Docs) val result by remember { derivedStateOf

Does Android Jetpack Compose support Toolbar widget?

I'd like to use Toolbar with Jetpack Compose. Does it have such a Composable component?

How can I make an accompanist navigation BottomSheet fully expanded?

I know that a normal bottom sheet can be setup like this rememberModalBottomSheetState( initialValue = ModalBottomSheetValue.Hidden, confirmStateChange = {

Fixed Grid inside LazyColumn in Jetpack Compose?

Currently in Jetpack Compose, this code throws an IllegalStateException because you cannot nest two vertically scrolling Composables: @ExperimentalFoundationApi

How to create GridView using Jetpack Compose

How to create Gridview in Jetpack compose without using recycler view or android.widget.gridview ?

How to make middle ellipsis in Text with Jetpack Compose

I need to make Middle Ellipsis in Jetpack Compose Text. As far as I see there is only Clip, Ellipsis and Visible options for TextOverflow. Something like this:

Store data and "Cannot create an instance of class ViewModel" - Hilt - Room - JetpackCompose

I try to store some days from ScheduleScreen screen. Lib uses in theme topic. While I was doing this, I had two questions: why i got this error Cannot create an

Time Selector- Jetpack Compose

I am trying to develop a time selector ui as given below. But i m not getting any idea what is the best approach to it. tried using lazy columns and android vie

How to show error message in OutlinedTextField in Jetpack Compose

I need to show error message in OutlinedTextField and I don't find any documentation about how to do it. I found several ways in tutorials, for example to creat

How to show error message in OutlinedTextField in Jetpack Compose

I need to show error message in OutlinedTextField and I don't find any documentation about how to do it. I found several ways in tutorials, for example to creat

Can´t put the background in white on jetpack compose

I'm making a Login page on Jetpack compose. I'm using themes with MaterialTheme. When I choose the background colour as white, it shows me a dark grey colour. I

How to clear textfield value in Jetpack Compose?

I've developed a textInput composable with a trailing icon, and I'd like to clear the textInput when the icon is clicked. How can I access the textInput value,

How to add drawable to a Text in Compose?

As in XML we used to add a drawable to a TextView, so What is the equivalent of android:drawableLeft, android:drawableRight in Jetpack Compose Text? Is there an