Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Documentation for styles in android resources

I tried to add a documentation to some styles in my code. The issue is, that android studio doesn't link the documentation directly to a usage of the style.

I mean, the simple <!-- Docu --> comment doesn't create my desired documentation for the style.

<!-- Documentation -->
<style name="graph" parent="font_graph_base"/>

Here is what i want, as an example for a view attribute: View attribute example

This is what i get, if i use the simple <!-- --> comment, what i want is to fill this documentation. Current state...

Is there a way to get this working?

like image 987
Kenny Seyffarth Avatar asked May 22 '15 09:05

Kenny Seyffarth


1 Answers

Okay, I did a lot of searching for this but I'm gonna have to disappoint you. I don't think there is a way to do this. Even the styles used by Android don't have documentation. I think the only thing you can do is put comments above and just navigate to the style to see your comment.

However you can use comments as documentation with attributes (attr). If you have attributes you just put a normal comment <!-- --> above it and it would appear as documentation. You even have ways to suppress that comment using <eat-comment/>.

like image 177
Kevin van Mierlo Avatar answered Oct 14 '22 09:10

Kevin van Mierlo