tags:

views:

213

answers:

2

I'm building a jar so that other developers can use the view I create in their Android applications. I'm wondering if it is possible to use a layout resource in my jar so I can build the layout of my view or if I need to build up my view programmatically. Similarly, can I include image resources in my jar file?

+1  A: 

No, not currently. Because of the way Android packages resources in an apk, you can't include them in a jar. However, you can still share the jar with the other developers - they'll just have to manually pull in the layout files.

Erich Douglass
A: 

NO you cannot you will have to specify the layout parameters within your code for the jar to be of use.

Fred Grott