android-view Questions
2
I need to use the emoji2-emojipicker from androidx which is made like so with XML views:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width=...
Archdiocese asked 22/6, 2023 at 10:11
4
Solved
I have this function in my main activity which doesn't display a badge:
private fun setFindShiftBadge(state: HomeState) {
val findShiftsBadge = BadgeDrawable.create(this)
home_framelayout.foreg...
Lynnett asked 31/1, 2020 at 18:44
4
I get this warning (from the question title) in a custom Android view I am developing.
Why do I get warned? What's the logic behind it i.e. why is it a good
practice to also override performClick ...
Centner asked 13/12, 2014 at 18:54
4
Solved
My problem is simple. How to Clear Focus of all the elements in a View that may have focus (like EditText -or- TextView whose textIsSelectable="true" and the text is selected in it at occurrence of...
Orian asked 26/2, 2017 at 19:51
16
Solved
In Eclipse, when you hover your mouse over a method, a window would appear with a description of what the method does, what the parameters mean and what it returns. Is there a way to get Android St...
Yachting asked 18/5, 2013 at 0:49
2
I'm trying to replicate some View-based selected text behavior with Jetpack Compose. In both of these cases, I've long-tapped on the middle of the URL.
View based:
<TextView ... android:textIsSe...
Creuse asked 30/1, 2022 at 20:38
2
In Android, can you create a Listener for catching changes in a View's properties (width / height / margin / position relative to top of the screen)?
I want to trigger an event when layout_marginT...
Entrain asked 8/10, 2013 at 13:10
14
Solved
I am trying to apply an animation to a view in my Android app after my activity is created. To do this, I need to determine the current size of the view, and then set up an animation to scale from ...
Groundsill asked 23/9, 2010 at 14:2
8
After updating from compose alpha-11 to alpha-12(or beta-01) I am getting this crash whenever I open an activity or fragment that has compose views.
I am using AppCompatActivity which implements Li...
Fornicate asked 26/2, 2021 at 8:30
7
Solved
Is there any way to place an images half is on top of another image using only constraint layout. I know it can be done using relative and frame layouts but in the case of constraint layout is ther...
Creedon asked 16/3, 2018 at 11:22
34
Solved
First of all: yes, I read all the other threads on this topic. And not only those from this site... (you see, I'm a little frustrated)
Most of them come with the advice to use android:id instead o...
Niobe asked 16/7, 2010 at 12:2
2
I want to retrieve height and width of video, I am using MediaMetadataRetriever class for this. It is working correct for most of the case, but for few case height and width are interchanged.
I t...
Element asked 25/8, 2017 at 10:55
11
Solved
I'd like to round the corners of a view and also change the color of the view based on the contents at runtime.
TextView v = new TextView(context);
v.setText(tagsList.get(i));
if(i%2 == 0){
v.set...
Creationism asked 22/8, 2013 at 22:29
9
Solved
I have an Activity with 3 EditTexts and a custom view which acts a specialised keyboard to add information into the EditTexts.
Currently I'm passing the Activity into the view so that I can get t...
Pacify asked 26/11, 2011 at 5:58
12
Solved
java.lang.IllegalArgumentException: Wrong state class, expecting View State but received class android.widget.CompoundButton$SavedState instead. This usually happens when two views of different typ...
Hiroshima asked 9/5, 2016 at 10:8
7
I want to check if a View within a ScrollView is currently visible in Android. I am not checking if it is focused on yet but if it is currently being displayed on screen. Is there a method in View ...
Ivett asked 26/12, 2012 at 10:43
6
Solved
I have a fragment added using
transaction.add(R.id.content, fragment, null);
and I need to start new fragment from this one. But to do this I need to know first fragment's container view id (R.i...
Shamikashamma asked 3/8, 2011 at 11:47
14
I'm using really naive code to show a bottom sheet dialog fragment:
class LogoutBottomSheetFragment : BottomSheetDialogFragment() {
override fun onCreateView(inflater: LayoutInflater, container:...
Yurev asked 29/11, 2017 at 13:25
10
Solved
I need help with ConstraintSet. My goal is to change view's constraints in code, but I cant figure out how to do this right.
I have 4 TextViews and one ImageView. I need to set ImageView constrain...
Jemmy asked 23/7, 2017 at 8:41
6
I need to draw three circles in my fragment ,the circles differ in size, I refer this link
The result i obtained is this
This is my XML Code : UPDATED
<?xml version="1.0" encoding="utf-8"?...
Racine asked 17/1, 2014 at 4:57
3
Solved
If foo is a view, what is the difference between foo.setVisibility(View.GONE) and fooParent.removeView(foo)? I am particularly interested in memory consumption of the view, before and after both st...
Snotty asked 1/10, 2012 at 12:11
3
I have views as follows :
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/global_legal_gap"
android:clipToPadding="t...
Inefficiency asked 14/6, 2018 at 8:54
1
Solved
I want to open my app and see something from it (for example a widget) that will be available everywhere, not only when the app is opened
Example:
Note that I am on the desktop page, and app is no...
Saree asked 14/11, 2022 at 15:6
2
Is there an existing View in Android for a banner? Or do I need to build one myself using the specs?
To be clear, this is not for ads but for the Material-Design concept of Banner.
Firestone asked 30/10, 2018 at 19:54
15
What's the best way to disable the touch events for all the views?
Rottweiler asked 24/3, 2011 at 11:38
1 Next >
© 2022 - 2024 — McMap. All rights reserved.