imageview

Ripple effect in pressed state + transparency in normal state

六月ゝ 毕业季﹏ 提交于 2019-12-06 07:05:15
问题 I would like the ImageView in the ViewGroup, when pressed, draws the ripple and this is working ! But when the ViewGroup is pressed, the ImageView inside it, should remain transparent otherwise the ImageView background is visible: (that color alpha-orange, you actually see, is the ripple when pressed). This happens only with devices API 21+. With devices API <21 I use a selector and the image background remains transparent as wanted when the ViewGroup is pressed. layout.xml <LinearLayout

How to fill different color on same area of imageview (Color over another Color on same area of imageview)?

徘徊边缘 提交于 2019-12-06 06:46:55
I have one imageview and i set image for filling the different colors. But when i fill color then other color is not fill on same area on imageview which previous color is filled. I use color pallet button for getting different color for fill on imageview. Below is my code and image description. public class Play_Screen extends Activity implements OnTouchListener, OnClickListener { private Thread thread; private boolean running = false; // DrawImageView iv; // ImageView imageView; private Context context = this; private int paintAlpha = 255; // initial color private int paintColor; MediaPlayer

Android: How do you scale multiple views together?

∥☆過路亽.° 提交于 2019-12-06 05:19:29
问题 I'm trying to layer graphics one top of each other, like an icon over a background, with the second layer (icon) at a certain pixel offset from the top left corner of first layer (background). Since each layer will eventually have its own animation, I'm placing each in its own View. For my implementation I have two ImageViews, one for each layer, inside a RelativeLayout, which in turn is inside a ScrollView. ImageViews are positioned using layout_margin relative to the top left corner (0,0).

how to make the animation clickable in android [duplicate]

≡放荡痞女 提交于 2019-12-06 05:05:00
This question already has an answer here : image is playing an animation and the image is clickable (1 answer) Closed 6 years ago . I've made a simple animation for an image and I set the event OnClick on the image to make a toast. The problem is that I made the image started doing the animation on the onCreate and I made set the image to be clicked and fire the toast but the problem is that the image isn't clickable, but if I press on the original position of the image, the toast is started (the image is not moving with the animation) thx for your help this is the animation code in anim

Full size image in ImageView

走远了吗. 提交于 2019-12-06 04:59:49
问题 I'm trying to draw an image in an ImageView, but i want it to be unscaled, with scrollbars as necessary. How can I accomplish this? Right now I just have a drawable set as the android:src of the ImageView in the XML. This autoscales the image to fit the screen width. I read that this might be because of the compatibility mode (developing for 1.5, testing on 2.1), but then I added <uses-sdk android:minSdkVersion="3" android:targetSdkVersion="4" /> to my manifest, and nothing changed. Any clues

Image out of bounds after transformation on view

一曲冷凌霜 提交于 2019-12-06 04:54:33
问题 I'm having a problem with displaying my image. I have an Image I want to display full screen. So I have this Imageview with match_parent and 20dp padding. It looks good but when I apply rotation on it, it seems that the bounds of the view doesn't change and the image can get clipped out of the screen ! Totally don't want that to happen! How do I rescale the image so that the image also fits in the ImageView when its 90 degrees rotated. This is my XML WITH rotation in it. EDIT: How to fix the

how to send image from one activity to other?

喜你入骨 提交于 2019-12-06 04:23:15
问题 I need send a imageview like i send the string "title", but i can't, how can i send a imageview (R.drawable.image) from mainactivity to secondactivity? THANKS MAIN ACTIVITY public void NewActivity(View view){ Intent intent = new Intent(this, SecondActivity.class); intent.putExtra("title", getString(R.string.title)); startActivity(intent); } SECOND ACTIVITY @Override public void onCreate(Bundle bundle) { super.onCreate(bundle); setContentView(R.layout.pantalla); Bundle extras = getIntent()

UIImageView.image bigger than UIImageView

偶尔善良 提交于 2019-12-06 03:11:47
I have a UIImageView in a custom tableview cell. When I set the UIimageview property, the uiimageview.image is bigger than the uiimageview. Why? Here is the code: cell.imageView.image=[UIImage imageNamed:@"BlueMooseLogo.png"]; And here is a link to what the cell looks like. The blue square is the background of the imageview, and the blue moose is the image. https://docs.google.com/document/d/1G7BYCriYbSGYHryP5OI7XHuVpqRKiNcBrxdY14wDgoA/edit?usp=sharing If it's relevant, within interface builder, after I select the uiimageview, I have the view set to scale to fill. I've faced the same problem,

Image browse button in android activity

≡放荡痞女 提交于 2019-12-06 02:51:22
问题 currently I'm developing an application which requires a browse button in my activity. When I press the browse button I should be able to browse the image files in my sdcard as well as in the phone memory. Upon tapping the image file it should be selected and the path of the image file (that is, where that selected image file is located) should be displayed in the activity in a textview. Also the selected image should be displayed in a imageview. How to do this? Can someone please help me out

Custom Splash Screen - Android

余生颓废 提交于 2019-12-06 02:13:34
Currently my android application shows a black screen with a loading wheel as it processes the user's request i:e as it gets content from the server. I would like to modify this screen to include an icon (image) that fades in and out continuously instead of the loading wheel. Is there any possible way to do it? Yes, you'll use an Alpha Animation See here and here and lastly here for a good tutorial on Animations with some nice code. In order to "chain" your animations so that one starts after the other you'll use an Animation listener and start the other one from the onAnimationEnd method