Questions tagged [android-jetpack]

Android Jetpack is a Google's set of libraries, tools and architectural guidance to build Android apps and provides common infrastructure code.

Android Jetpack is the next generation of Android components, bringing together the benefits of the Support Library -- backwards compatibility and immediate updates -- to a larger set of components, making it quick and easy to build robust, high quality apps.

It manages activities like background tasks, navigation, and lifecycle management, so you can eliminate boilerplate code and focus on what makes your app great.

It is designed to work well with Kotlin, saving you even more code with Android KTX. The new Android Jetpack components released today include WorkManager, Paging, Navigation, and Slices.

Useful Links

2879 questions
1
vote
1 answer

How can I use ARCore with CameraX?

I know ARCore using Camera2 by default. I was wondering about how we can use it with CameraX? Is any way to use ARCore with CameraX? I just tried shared session ARCore samples, It's using Camera2 API. Is any approach or extension to use ARCore with…
Dev007
  • 222
  • 2
  • 9
1
vote
1 answer

How to create home screen or lock screen widget using jetpack compose

I want to implement home screen or lock screen widgets using jetpack compose. I do some R&D but I didn't find any document related to this topic. So help me. Thank you in advanced
1
vote
0 answers

Compose UI recompositioned multiple times and start navigation start destination set too late

I have weird behavior in my compose app, it looks like UI is being recompositioned multiple times, but I don’t really know why. Problem is related to main activity and root nav graph: @AndroidEntryPoint class AppMainActivity : ComponentActivity() { …
1
vote
1 answer

AutoScroll the behind item in jetpack compose

I have a 3 Column. In 1st Column of components are 2nd and 3rd Column. In 2nd Column there are so many components inside that. In last 3rd Column I have a few items and I am sticking at the bottom of screen. I have done with the help of this answer.…
Kotlin Learner
  • 3,995
  • 6
  • 47
  • 127
1
vote
1 answer

Jetpack Compose run animation after recomposition

Is there any way how to run animation once recomposition (of screen, or some composable) is done? When animation is running and there is recomposition at the same time, animation has very bad performance (it is not smooth at all). I tried delay to…
1
vote
0 answers

Focusing on text cursor in jetpack compose

does anyone know how I am able to get focus on a text cursor in a textfield? I am having an issue with resizing scrollable text fields, so I want to request focus to on the cursor instead.
1
vote
0 answers

How to fix slow LazyGrid perfomance in Jetpack compose?

I am facing high lags into my list. When scrolling it just feels so slow. Here is my LazyGrid code val images = // mutable List val state = rememberReorderableLazyGridState(onMove = { from, to -> images.add(to.index,…
sanket kheni
  • 1,482
  • 2
  • 12
  • 29
1
vote
0 answers

Jetpack Compose - Show a shadow at top of the Bottom Sheet with

I want to show a shadow at the top of the Jetpack Compose bottom sheet(like in the attached picture). I tried to use ModalBottomSheetLayout and BottomDrawer composables' elevation values. The elevation seems like adding the shadow at the bottom of…
1
vote
2 answers

What is `it` in Textfield's onValueChange using Kotlin's Jetpack compose?

I don't know what is it in Textfield's onValueChange using Jetpack compose. val usernameState = rememberSaveable { mutableStateOf(TextFieldValue())} TextField( value = usernameState.value, onValueChange =…
1
vote
1 answer

Prevent top app bar compress effect while scrolling within a Lazy lists without first item visible

I have a top bar which disappears while scrolling down and shows up while moving up within a lazy column. It is an example from android developers I was playing with the sample for a while and I added a box over the…
1
vote
1 answer

My views are overlapping one another in jetpack compose

I am very new to jetpack compose please help, I have use Surface() but my views are overlapping one another, I want separate view as first one should be TopHeader() and another one should be BillForm My code is:- class MainActivity :…
1
vote
1 answer

state.animateScrollToItem() is not working in LazyColumn

`I am trying to animate LazyColumn items with state.animateScrollItems() function. But is not not working. It is working very well with state.scrollItmes() function. I am using compose_ui_verdion 1.2.1, compose_compiler_version 1.3.2 and kotlin…
1
vote
2 answers

Jetpack compose when to create a new lambda instance in Composable?

Please see my code: @Composable fun RecomposeLambdaTest() { var state by remember { mutableStateOf("1") } val stateHolder = remember { StateHolder() } Column { Button(onClick = { state += "1" …
JeckOnly
  • 347
  • 2
  • 10
1
vote
1 answer

I do not want to upgrade jetpack compose from RC to Alpha

... but also I do not have to see that lint warning. It suggest to upgrade from 1.3 RC to 1.4 Alpha. What would you suggest to do?
Solvek
  • 5,158
  • 5
  • 41
  • 64
1
vote
1 answer

I am having a problem gradle build. Module was compiled with an incompatible version of Kotlin

Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.7.1, expected version is 1.5.1. After adding a module to my project I started getting this error message. I have tried looking it up online but the…