3,998 questions
0
votes
0
answers
47
views
NavGraph & viewmodel gets reset on each config change
I’m using a single activity app, where you have a Splash screen using the new splash screen api, keepsplashscreen is used to keep showing the splash screen till the check if the user is logged in or ...
1
vote
1
answer
93
views
How to change TextView color depending on the color behind it?
I have a TextView drawn on a LinearProgressIndicator.
Part of the LinearProgressIndicator is blue and part of it is light blue.
I want the TextView color to be lighter on the blue part and darker on ...
0
votes
0
answers
53
views
Deactivate slider from user click
I want to deactivate my slider so the user won't be able to touch it. I found the isClickable, but it works only for buttons. What is the equivalent of a slider?
My XML:
<Button
android:id=&...
2
votes
1
answer
39
views
Showing Full Screen View in Activity in Xiomi Note 12s Android device
I have run an Android app on different devices. It shows the full-screen view on Xiaomi devices, which leads to an overlap of the activity's top and bottom areas, while it works fine on other devices ...
1
vote
1
answer
183
views
AppBar loads with delay when using AndroidView with WebView in Jetpack Compose
I'm building a Jetpack Compose screen that has an AppBar at the top and a WebView below it using AndroidView.
The problem is that the AppBar takes a noticeable moment to appear when the screen loads.
...
0
votes
0
answers
55
views
Is View.onDetachedFromWindow always after View.onAttachedToWindow
For a long time, I've always thought that View.onAttachedToWindow(alias it ATTACH) and View.onDetachedFromWindow(alias DETACH) come in pairs, eg: ATTACH - DETACH - ATTACH - DETACH。 But today I found ...
0
votes
0
answers
49
views
I directly want to navigate the WhatsApp profile section from my Android app
This is my code for open the whatsApp .
void openWhatsApp() async {
try {
final Uri url = Uri.parse("https://chat.whatsapp.com/");
final intent = AndroidIntent(
...
0
votes
2
answers
60
views
How to fix the missing required view with ID in the custom View
I want to create a custom view based on com.google.android.material.slider.RangeSlider. It works on a physical device, but fails in the XML preview from Android Studio. I've tried rebuilding, clearing ...
0
votes
0
answers
84
views
Android Compose: NullPointerException during AndroidView cleanup
I'm experiencing crashes in my Compose-based app when cleaning up AndroidView components that contain third-party ad views. The crash occurs during view detachment:
Fatal Exception: java.lang....
1
vote
2
answers
178
views
The bottom navigation view is a little high in Android
While I am taking Bottom Nav example from android studio new project templet, the view is perfect.
But if I create new project with 'Empty View Activity' and implementing Bottom Nav manually, the view ...
-1
votes
1
answer
64
views
How to set text color of DatePicker to White?
I'm using a previous question on Stackoverflow for implementing Wheel Date picker using DatePicker of View library in jetpack compose.
The result i have before navigating to next page.
After i ...
0
votes
1
answer
104
views
How to make children of a view screen-reader optional on Android
I've got a page on android that has a list of carousels. Each carousel has a header. When Talkback is enabled, currently the user has to go from the title of the carousel, navigate over every carousel ...
3
votes
0
answers
66
views
CameraX is recomposing and making the screen glitch when text is updated
I have a camera screen in Jetpack Compose. It has another ImageView(SubcomposeAsyncImage) that gets updated with the image count when I take an image.
Issue:
The camera preview is not opening ...
0
votes
0
answers
41
views
Login button is invisible on Samsung Galaxy A52 5G
I'm experiencing an issue with the login page of my Android application. The problem occurs only on Samsung Galaxy A52 5G devices. Users have reported that the login button is not visible when they ...
0
votes
1
answer
48
views
PreferenceFragment Activity toolbar
In a Compose application, I implemented the Settings screen as a new AppCompatActivity containing my PreferenceFragment.
In order to navigate between screens in Compose and the Preference Activity, I ...
1
vote
1
answer
2k
views
Finding android.R.id.content view in jetpack compose activities
This is probably a stupid question but i have to ask it anyway.
In activities that are created solely by composables, is it still possible to use activity.findViewById(android.R.id.content) to find ...
0
votes
0
answers
248
views
Make image overlap its parent view in Jetpack Compose
what i want is to make image overlap top edge of its parent view. without fixating any of view sizes
image 1 expected
i tried to use Box with image inside set to .wrapContentHeight(align = Alignment....
3
votes
1
answer
69
views
Click a PopupMenu button with Espresso?
Is there a way to click an item in an inflated PopupMenu anchored to a ListView item?
I have a PopupMenu that is created by clicking a button inside a ListView. I need to click an item inside the ...
0
votes
1
answer
203
views
Android Views in Jetpack Compose
var adRequested by remember { mutableStateOf(false) }
if (AdEventManager.isInternetAvailable() && !adRequested &&
isNativeAdVisible && !App.isAppPremium) {
...
0
votes
1
answer
89
views
Positioning an Overlaying or floating View Above another view in Layout
In an Android application, I have a layout containing a TextView at the top and two elements beneath it: an icon and another TextView. The second TextView displays a numerical value that undergoes a ...
0
votes
1
answer
333
views
Android WebView with transparent Overlay in Compose
I have a BottomSheet non-Modal with a WebView in Compose using an AndroidView.
The WebView shows the Google Map Site and I use parameters to show a Location that I obtain using ...
0
votes
1
answer
48
views
How to create TabItem indicator with bottom padding
I want to implement a Tab Indicator with bottom margin
<com.google.android.material.tabs.TabLayout android:id="@+id/tabs" android:layout_width="match_parent" android:...
4
votes
0
answers
705
views
Scrim not overlaying a status bar while showing a modal bottom sheet
I have an issue on a device with android 13, where the status bar is not overlaid by the scrim when a modal bottom sheet is showing. Now, the same app works as expected in an emulator with android 7.1....
1
vote
1
answer
684
views
Jetpack Compose ComposeView always return 0 width and height
So I'm trying to convert a composable to view with this approach
val composeView = ComposeView(LocalContext.current)
composeView.setContent { //My Composable }
But the problem is why when I get the ...
2
votes
0
answers
441
views
How to know the current Translation, Rotation and Scale that are currently applied to a Compose (or View) Canvas?
Suppose I have the following Canvas on my compose screen:
Canvas(modifier = Modifier.fillMaxSize()) {
withTransform(
{
transform(matrix = SOME_TRANSFORMATION_MATRIX_HERE)
...