How do I make a photo finger-zoomable on a android device? Is there a simple way, or is it complicated? But I dont want zoom buttons. I want it like a phonebrowser, when you take your fingers and drag them from each other on the phone, it will zoom in. How do I do?? I have searched everywhere. If there no way, can I just have two buttons, - and +. If I click one, the "imageview" change size?
How do I make a photo finger-zoomable on a android device? Is there a simple way, or is it complicated? But I dont want zoom buttons. I want it like a phonebrowser, when you take your fingers and drag them from each other on the phone, it will zoom in. How do I do?? I have searched everywhere. If there no way, can I just have two buttons, - and +. If I click one, the "imageview" change size?
Check out this tutorial: http://www.zdnet.com/blog/burnette/how-to-use-multi-touch-in-android-2-part-6-implementing-the-pinch-zoom-gesture/1847
The simplest way is to load your image on a WebView and let it do all the work
webView.loadUrl("file://...")
Related
I have been asked to design an app that allows the user to take an image. At the top of the image there should be data such as imageNo and workOrder.
At the minute, I have two TextViews at the top of my activity, an ImageView below and then a green button at the end like so:
ImageScreenshot
When I click the green button I would like to send this full screen, textviews and image all as one file/image to a destination - like a screenshot.
Is there any libraries out there or does anyone know how I could achieve this?
Thanks!
https://www.youtube.com/watch?v=sPvCEsGm8us
check out this tutorial, I think it covers the basics of the question you asked. I automatically thought of this reference as I read your query.
As written in the topic, I have an android App, which has a design - that design is being shown differently on my Phone than in the XML-Preview.
Screenshots:
As you can see on my device, the button at the bottom is far more in the top than it should be. Any fixes?
This is because of the screen size. If you are just stacking the views in a LinearLayout they will take up whatever room they need and the the bottom will be blank. If you want you can make the button be pushed to the bottom by using layout_weight=1 on whichever view you want to take up the remaining space.
i'm developing an application for android that is already done for IOS, is not big problem.
the thing is that my boss want it to be exactly the same, but one of the menus is the problem, is like a slide menu but with zoom and a background image, anyone have any idea how can i do this, i already google it but no results :(, a library would help.
here is a picture with the menu for IOS.
I don't think if it would be an effective solution but you can use a RelativeLayout.
Put the selection part behind in a LinearLayout then put a framelayout front to contain list fragments. This way you shouldn't use an action bar to have absolutely same looking with iOs version.
When someone clicks open button apply an animation to your framelayout. scale it by %75 and move it 25% in y coordinate and move it %50 in x coordinate. When buttons in your LinearLayout apply a reverse animation to your FrameLayout. If swap button clicked change your fragment with new one. You can also aply a transaction animation to your fragments.
I hope you know how to handle this stuff. If no I can do my best to code an example.
EDIT:
Don't forget to set your flame layout unclickable when you move it to right side.
https://github.com/SpecialCyCi/AndroidResideMenu
I think I found your answer. I came across this in a list of libraries it is 3.8 on the list https://github.com/Trinea/android-open-project/tree/master/English%20Version
Cheers!
I would like to develop a Dialog which is composed of 3 steps to guide the user when he launches the app for the first time.
The following image is an example of what I would like to achieve:
1- I would like to know how to add a mark to close the dialog at the top-right corner?
2- How can I implement the small circles at the bottom of the screen that indicates the current step? Can they be created programmatically?
3-Only to be sure, I decided to navigate between the Dialog steps using a ViewFlipper. Is this the right approach?
Thanks in advance.
I would like to know how to add a mark to close the dialog at the
upper right corner?
Don't do that. That looks like it was a straight port from an iphone app. Use the native android dialog containers/buttons.
How can I implement the small dots at the bottom of the screen that
indicates the current step?
What have you tried? There's a million ways of doing this depending on the rest of the workflow.
Only to be sure, I decided to navigate between the dialog steps using
a ViewFlipper. Is this the right approach?
Maybe. It depends what you're displaying. If you're only displaying a single image or something simple, then that might be the best approach. I would create different dialog fragments ( you are using fragments, right?) for the different steps. That way you can automatically push them to the back stack as you move through the workflow.
one of the ways to implement the "little dots on the bottom" is :
include the dots in every image you are creating.
draw one of the dots highlighted in every image
flip through the images in order of the highlighted dots. (or highlight the dots in the order you want to show your images)
but this would make your dots disappear during the images are flipped.
if you want to avoid that :
create two different image views , one acts as a container for the main image, the other as a container for the dots, place the 1st image view above the other.
create a no of images containing just a no of dots, each with one of the dots highlighted
flip through both the imageViews in synchronization
use a "flip animation" in the upper image view
use no animation, or a minimal animation for the dots.
This will produce the desired effect. Hope this helps :-)
My vision is this-- I have an image of a human body(like an anatomy chart), and I want the user to be able to click a certain part of it and be able to communicate the body part they have clicked on, as in translating it to text... I wonder if this could be possible, and how? Any sample code/redirection to a tutorial would be helpful, or maybe just a practical idea...
A very simple approach is just to add an ImageView to you layout.
Override onTouchEvent in the activity to capture touches and then translate the coordinates to texts.