Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [android-jetpack-compose-animation]

The tag has no usage guidance.

android-jetpack-compose-animation
0 votes
0 answers
18 views

In Android Studio's Compose Animation Preview screen, how can I save the initial and target preview values of an animation?

Android Studio's Compose Animation Preview lets you visualize how an animation will look in a timeline. I'm using animateFloatAsState in this example and my usage will go from -1.0f to 1.0f. The thing ...
JaviCasa's user avatar
  • 728
0 votes
0 answers
12 views

ScrollableTabRow maxValue incorrect cannot scroll to the tab I need

I don't think this problem has a solution but if anyone else is experiencing this please let me know what I can do! Here is the relevant code. The maxValue of the scrollState is 1125; which I assume ...
user1743524's user avatar
0 votes
0 answers
44 views

Shared Element Transition using Jetpack Compose with Navigation, doesn't work in back navigation popBackStack

In our project We are using the compose animation (beta01) which includes the shared transition (sharedElement), with Navigation, as mentioned here: https://developer.android.com/develop/ui/compose/...
Monster Brain's user avatar
1 vote
1 answer
95 views

Compose project crash when adding the compose animation library with shared element transition

I'm using compose version compose-bom 2023.03.00 and when I try to add the latest compose animation module (1.7.0-alpha07) with shared elements update, the app crashes on launch with error showing ...
Monster Brain's user avatar
0 votes
0 answers
19 views

AnimatedVisibility reversed animation issue

I encountered a problem that if there is AnimatedVisibility and the state changes immediately from true to false (in time when the animation is played), then the animation is reversed. I Googled, used ...
Дмитрий's user avatar
0 votes
1 answer
40 views

i have a lazy row which contains "n" number of boxes. On clicking any box, that box should expand & other box should disappear using smooth animation

Need UI and animation in jetpack compose: i have a lazy row which contains "n" number of boxes. On clicking any box, that box should expand & other box should disappear using smooth ...
Heleena Joy's user avatar
0 votes
1 answer
117 views

Jetpack compose. Animation duration is incorrect on some devices

I'm using Animatable to implement linear progress animation. Here is my code: val progress = remember(currStory) { Animatable(0f) } progress.animateTo( targetValue = 1f, ...
testivanivan's user avatar
  • 1,328
0 votes
1 answer
233 views

Infinite color animation sequentially in Jetpack Compose

I've just learned how to animate a color from an initial value to a target value indefinitely. Now I want that animation to go through more colors. This is what I've got so far: @Preview(heightDp = 30,...
rslemos's user avatar
  • 2,653
0 votes
1 answer
73 views

Simulating vintage blinking cursor in Jetpack Compose

I'm developing a WearOS application, and for a specific piece of data I decided — I'm toying with the idea — that the most compact display would be a matrix of dots. Each dot can be: OFF (almost black,...
rslemos's user avatar
  • 2,653
0 votes
0 answers
28 views

How reset detectHorizontalDragGestures

I use code for listen swipe Card( modifier = Modifier .offset { IntOffset(offset.roundToInt(), 0) } .pointerInput(Unit) { ...
Pavlo Kravchenko's user avatar
0 votes
0 answers
111 views

Jetpack Compose Texts maxLine with animateContentSize Modifier is not good for exit animation

so i made a basic expandable card compose where you click the card to expand and click again to un expand the texts maxLine property changes b/w Int.MAX_VALUE and unexpandedMaxLines but the problem ...
Jaimin Vashi's user avatar
0 votes
2 answers
175 views

AnimatedVisibility is not working with weights

Here is a simple example to reproduce the issue I'm having: @Composable fun AnimatedVisibilityEx(modifier: Modifier = Modifier) { var visible by remember { mutableStateOf(true) } Box(modifier ...
frangulyan's user avatar
  • 3,788
1 vote
1 answer
225 views

Applying Brush Effect to Whole Word While Animating Each Letter Individually in Jetpack Compose

I am trying to create a text effect in Jetpack Compose where the text uses a brush that looks like a set of colors smoothly changing diagonally. The individual letters in the text should move up and ...
Oleksandr Myronchuk's user avatar
4 votes
1 answer
271 views

How can I determine whether a 2D Point is within a Polygon or Complex Path with Jetpack Compose?

This is a share your knowledge, Q&A-style to explain how to detect whether a polygon or a complex shapes such as some section of path is touched as in gif below. Also it contains how to animate ...
Thracian's user avatar
  • 59.2k
2 votes
2 answers
464 views

How can I achieve before-after animation in Jetpack Compose?

I have used weight or changed width with infinite animation, but it is not the effect showed in the below gif. How can I achieve it in Jetpack Compose?
Abdullah's user avatar
  • 384

15 30 50 per page