Category "android-jetpack"

Recompose in Android Compose

I was implementing the outlinedTextField in android using new compose library. But strangely the input data was not updating in the text field. So I searched an

Jetpack Compose take screenshot of composable function?

I want to take screenshot of specific composable function on Jetpack Compose. How can I do this? Please, anyone help me. I want to take screenshot of composable

What is the better or easier way to create "nested" menus in Jetpack Compose?

So in XML you were able to structure menu items and nest them like this. But in jetpack compose, I am unable to figure out how this would work. I already read

NullPointerException on FragmentHostCallback.getContext()

I'm facing this random crash while navigating to a Fragment via deep-link which is declared in the navigation graph file. I'm using navigation component library

Compose's "AndroidView"'s factory method doesn't recall when "remember" value change

I've an AndroidView on my UI and I'm creating a custom view class using factory scope. And I've remember value above my android view which is changing by user a

How can I add a stickyHeader to LazyVerticalGrid like LazyColumn in jetpack compose?

I want to achieve a UI effect like this: <GridView> <Title of Grid content in a single row /> <Grid content arranged in the form of n * 3

Layout not moving up when keyboard is open in Jetpack Compose

I have a layout in Jetpack Compose where I have a couple of composables (text view and input) that I need to stay at the top of the screen, and then another com

How to start the same action multiple times from the same startingDestination using navigation graph?

I started recently using the navigation graph and i have a problem that i havent solved yet. I want to open the same fragment multiple times that they are stack

Recyclerview getting refreshed after come back from another screen - Android navigation

I am having a product listing page. The recyclerview is filled with data from the Firebase firestore. When I click on any product, it will go to the details pag

Failed to add navigation dependency

I am trying to Add Navigation in my project but its showing failed to add Navigation dependency, when i click on 'ok' in the window to add these now , its showi

Schedule periodic local notification based on specific dates

I want to make a periodic worker to schedule notifications based on the total number of customer collection dates. I already did apart, but I'm facing a problem

How to select all items listed in Recyclerview using androidx.recyclerview.selection?

I am using androidx.recyclerview.selection for selecting items in a RecyclerView. I am trying to build an edit fragment in which it pre-populates the old views

Duplicate class com.google.android.a.a found in modules?

I tried adding Installreferrer to my app after adding it to gradle, when rebuilding the app. I'm getting this error. Duplicate class com.google.android.a.a foun

Jetpack Compose Place every question in it's own screen

I have a JSON data looking like this questions: [ { id: "1", question_type: "FREE_TEXT", answer_type: "SINGLE_LINE_TEXT", question_text: "what's your name?", op

Sending an ID or an object as String to the next screen in Jetpack Compose?

I have 30 users displayed in a LazyColumn. On user click, I navigate forward to UserDetailsScreen. My question, is it better to pass the ID of the user and crea

Type 'State<List<User>?>' has no method 'getValue(Nothing?, KProperty<*>)' and thus it cannot serve as a delegate

I'm trying to get a value from LiveData with observeAsState in jetpack compose, but I get a weird error Type 'State<List?>' has no method 'getValue(Nothi

Manually clearing an Android ViewModel?

Edit: This question is a bit out of date now that Google has given us the ability to scope ViewModel to navigation graphs. The better approach (rather than tryi

TextField is hiding under the keyboard when focused

I have a problem with TextField that is hiding under the keyboard, I've found the answers for the similar question here, but they are not helping me in my case.

ViewPager2 crash

I am using Advance Navigation Component with BottomNavigationView. In one tab I have ViewPager2. When I clicked on the tab for the first time, it worked fine. A

How to align title at layout center in TopAppBar?

TopAppBar( backgroundColor = Color.Transparent, elevation = 0.dp, modifier= Modifier.fillMaxWidth(), navigationIcon = {