Using java Syntax Highlighting
- setContentView(R.layout.starter);
Parsed in 0.030 seconds, using GeSHi 1.0.8.4
I'd like to manually draw to the canvas of that View or add a Button.
I don't know how to get the canvas of the view.
I did the following to get the view:
Using java Syntax Highlighting
- View viewalias = (View) this.findViewById(R.layout.starter);
Parsed in 0.030 seconds, using GeSHi 1.0.8.4
But I still need to get it's canvas - I think I'm missing something important.
I don't know the hierarchical relationships between a View and its canvas/bitmap/drawable or whatever.
I already experimented with code-completion - things like
Using java Syntax Highlighting
- Canvas mycanvas = this.getWindow().getContainer().getContext() ...
Parsed in 0.032 seconds, using GeSHi 1.0.8.4
Can somebody explain it to me or point me to a webpage that explains it?
to prevent a misunderstanding:
I know how to write a class that derives from View and then write drawing-instructions into the onDraw()-Method, but this time I want to draw from within the Activity onto the canvas of an XML-constructed view.
Is this possible?
Thanks in advance.



