Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Tue, 28 Apr 2009 10:10:19 GMT


Sponsored Links
 Hello.

I need to put 3 shapes (circles) on a drawable. I will create various
drawables with different colors and use it on an Animation, the
problem is I cant find a way to (programatically or XML) add various
shapes to a single drawable.\

Any possible solution is welcome.

-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by nEx.Software » Tue, 28 Apr 2009 10:30:38 GMT


 I'm not positive but I believe the way to do this in XML is to use a
layer-list tag. I'll check it but in the meantime you want to look
into that. In code I believe this equates to a layerdrawable?

On Apr 27, 7:10pm, Jose de Paula Eufrasio Junior


--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Tue, 28 Apr 2009 10:32:18 GMT


 On Mon, Apr 27, 2009 at 11:30 PM, nEx.Software



Tried a LayerDrawable without much luck. Unless I am doing something
really stupid with it. The lack of code samples get to my nerves
sometimes :)


-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by Dianne Hackborn » Tue, 28 Apr 2009 11:01:42 GMT


 How about just writing your own Drawable subclass?

On Mon, Apr 27, 2009 at 7:32 PM, Jose de Paula Eufrasio Junior <






-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Tue, 28 Apr 2009 11:10:20 GMT


 


Erm... What? :P
Sorry I am kinda green on some java stuff. I will check out how I can
do that. Thanks.

-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Wed, 29 Apr 2009 02:10:05 GMT


 Ok I almost got it. I tried this code:  http://pastebin.com/m72209427 
but my red_circle overlap, so I got only one when I run the Activity.
I also tried this XML:  http://pastebin.com/m43a2c42d but I got one 
circle stretching, one normal. I tried to set android:bottom and that
did not work.

Soo, what the catch I am missing? :)


-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Wed, 29 Apr 2009 23:57:12 GMT


 aFTER more testinmg: and not getting to show one drawable lowe then
other I am thinking that the LayerDrawable does not allow it. Am I
right?

Like:

------------> Layer
Draw1
Draw2
Draw3
-------------> end layerr

and not

-------------> Layer
Draw1, Draw2, Draw3
-------------->

-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Multiple shapes on one Drawable

by Jose de Paula Eufrasio Junior » Thu, 30 Apr 2009 01:43:07 GMT


 Woot!

Hey Dianne, thanks for the tip. I created a Custom drawable class with
a for loop and using canvas.drawcircle. It's fast and very easy to
use.

Not bad for a python programmer that started writing java/android apps
last friday :)

-- 
Jos de Paula Eufrsio Jnior (coredump)
MCSO, GRC Professional
 http://core.eti.br 

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. gears porting for X86 in Android

Hi all,
Has anyone do gears porting for X86 in Adnroid?

--~--~---------~--~----~------------~-------~--~----~
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: 

2. Error reading jdwp list: EO

hello im trying to execute the application it will showing like this
"[2009-06-15 23:43:18 - DeviceMonitor]Error reading jdwp list: EOF"
what is the problem pls help me .

thanks& Regarding

siva.

--~--~---------~--~----~------------~-------~--~----~

3. using Pmem in skia image decoding

4. how can I retrieve the list from the PHP DataBase

5. "Apple iPhone Developers Mostly Do n鈥檛 Make Much Money"

6. help with MultiAutoCompleteTextView.

7. Animated window transitions in Android 1.5