imageview

JavaFX ImageView not updating

安稳与你 提交于 2020-01-14 07:01:25
问题 So I'm trying to load and save Images into an imageView where the location of the image is chosen through a file browser. I've been working on this for several days now and I'm gonna have a stroke if I can't get it fixed. I've tried everything I can think of. Thank you in advance for helping. UPDATED : Here is my main class: public class Main extends Application { private Stage primaryStage; private BorderPane rootLayout; public Main(){} @Override public void start(Stage primaryStage) throws

OnClickItem() in gridView how do I show the same image in a separate imageView

假装没事ソ 提交于 2020-01-14 06:22:09
问题 The GridView is already being populated by the contents of a specific folder called "MyDir". My layout gallery_fragment is split in half by two linearlayouts. The one on the left has the GridView which is already populated with the images from "MyDir". The layout on the right has an ImageView. The idea is that I can select an image from the GridView on the left and then it will appear on the ImageView on the right. I cannot use the res/drawables folder in this instance. I have been told I

No IMvxImageHelper registered

二次信任 提交于 2020-01-13 07:12:05
问题 I use mvvmcross and can not bind to image URL. Error: No IMvxImageHelper registered - you must provide an image helper before you can use a MvxImageView <Mvx.MvxImageView p1:id="@+id/imgArticle" p1:layout_width="49dp" p1:layout_height="49dp" p1:layout_marginLeft="5dp" p1:layout_marginTop="5dp" local:MvxBind="ImageUrl Image, Converter = Image" p1:layout_marginBottom="5dp" p1:background="#ffff0000" /> My Model: public Guid Id { get; set; } public string Name { get; set; } public string Image {

Android:set ImageView dynamically?

只愿长相守 提交于 2020-01-13 06:29:43
问题 I'm trying to download an image, and create an ImageView dynamically and add it to my layout, but it won't display the image. Here is my code: ImageView image = new ImageView(this); LinearLayout.LayoutParams vp = new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT); image.setLayoutParams(vp); image.setScaleType(ImageView.ScaleType.CENTER_CROP); image.setMaxHeight(50); image.setMaxWidth(50); image.setImageDrawable(avatar); theLayout.addView(image); maybe I need to

Selectable circular imageview like Google+

拜拜、爱过 提交于 2020-01-12 05:30:07
问题 How can I create a selectable circular ImageView like in the current Google+ app used for the profile pictures? This is what I refer to: The image above is unselected and the below is selected. I try to replicate the profile pictures 1 to 1. My work so far: loadedImage is the Bitmap which is displayed mImageView.setBackground(createStateListDrawable()); mImageView.setImageBitmap(createRoundImage(loadedImage)); The used methods: private Bitmap createRoundImage(Bitmap loadedImage) { Bitmap

Passing image to another activity

混江龙づ霸主 提交于 2020-01-12 03:53:27
问题 I figured out how to pass a String value between activites thanks to this site, however I'm having trouble passing an image. What I'm trying to to is have a user click a button that opens the gallery and allows selecting of a picture. Then I have another button that opens another activity that displays an ImageView. I want to be able to have that ImageView's image be the chosen one from the previous activity. Here is the class that has the button I'm clicking to open the gallery and retrieve

Android : ImageView getID(); returning integer

≯℡__Kan透↙ 提交于 2020-01-11 15:47:26
问题 I've set up an onTouch class to determine when one of my 40 buttons is pressed. The problem I am facing is determining which button was pressed. If I use: int ID = iv.getId(); When I click on button "widgetA1" I receive the following ID: 2131099684 I would like it to return the string ID "widgetA1" from:game.xml <ImageView android:layout_margin="1dip" android:id="@+id/widgetA1" android:src="@drawable/image" android:layout_width="wrap_content" android:layout_height="wrap_content"></ImageView>

Android : ImageView getID(); returning integer

前提是你 提交于 2020-01-11 15:47:06
问题 I've set up an onTouch class to determine when one of my 40 buttons is pressed. The problem I am facing is determining which button was pressed. If I use: int ID = iv.getId(); When I click on button "widgetA1" I receive the following ID: 2131099684 I would like it to return the string ID "widgetA1" from:game.xml <ImageView android:layout_margin="1dip" android:id="@+id/widgetA1" android:src="@drawable/image" android:layout_width="wrap_content" android:layout_height="wrap_content"></ImageView>

How to generate random image using image view in swift

会有一股神秘感。 提交于 2020-01-11 13:05:13
问题 I just followed treehouse course and create my first Fun Fact app.In that they generate a random array quotes. Needed: I have placed image view using storyboard.Already when pressing one button random array quotes will generate.But i need when that same button pressed a random image should generate.I am new to swift .! This is factbook.swift struct FactBook { // stored in arry to show all quotes let factsArray = [ "You have to dream before your dreams can come true.", "To succeed in your

Moving an image through a linearlayout

我的梦境 提交于 2020-01-11 12:03:11
问题 I'm developing an Android 2.2 application. I want to move an image from left side of the screen to the right side of the screen. How can I do that? I've read that I have to add this image to a ListView or to a GridView to setup this animation. UPDATE I've created the following files: anim/translate_right <?xml version="1.0" encoding="utf-8"?> <set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/accelerate_decelerate_interpolator"> <translate