0

Hi I want to start creating my app but need some guidance. I have several images that i have designed and would like to layer these images. lets say I have image A, B and C. i want to layer image B ontop of image A and then image C on top of image B. How do i go about do this?The language is java, I am programming for an android tablet

shaz
  • 11
  • I am not sure what your question is, you just have to place them on top of each other, and adjust transparency if needed. – Oscar Gomez Jan 04 '12 at 20:36
  • Yes i just have to place them on top of each other but what the plan is that according to the data that is input a specific layer will be added. Like clock arms. I will save 12 different images for each hour and then i want this to change depending on data input. so a different picture will appear as foreground each time. – shaz Jan 06 '12 at 01:23

2 Answers2

0

You can place the ImageViews in an AbsoluteLayout and position them according to how you'd like them. Keep in mind that AbsoluteLayout is depreciated, but still fully functions. It's just harder to maintain.

Jason Robinson
  • 31,005
  • 19
  • 77
  • 131
  • Thanks so much for the advice. I am now using the images in an Absolutelayout. I have another question. I have the images saved in a xml file atm, what I want to do is put conditions on what is shown. As in i want if statements to show specific images. For example if x=1 then just show the image of an apple, whereas if x=2 then show the image of an orange. how can i go about putting in conditions like this? – shaz Jan 09 '12 at 23:01
0

You can do this either in XML or directly in Java - see this answer.

Community
  • 1
  • 1
Marvin Pinto
  • 30,138
  • 7
  • 37
  • 54