When I do the following the mountains that I draw (a series of lines connected to one another) are covered completely by a black background. In the docs s says that the default background for drawable layouts is transparent so I thought this would allow me to draw my time string on top of my mountains.
<layout id="WatchFace">
<label id="TimeDisplay" x="center" y="50" text="00:00" font="Graphics.FONT_NUMBER_HOT" justification="Graphics.TEXT_JUSTIFY_CENTER" color="Graphics.COLOR_WHITE" />
</layout>
function onLayout(dc as Dc) as Void {
setLayout(Rez.Layouts.WatchFace(dc));
}
function onUpdate(dc as Dc) as Void {
drawMountains(dc);
dc.setColor(Graphics.COLOR_WHITE, Graphics.COLOR_TRANSPARENT);
View.onUpdate(dc);
}
When I change the order of the onUpdate function to the following the mountains are shown but they are drawn on top of my time string which is what Im trying to avoid. Does anyone know how I can achieve a transparent background using layouts?
function onUpdate(dc as Dc) as Void {
dc.setColor(Graphics.COLOR_WHITE, Graphics.COLOR_TRANSPARENT);
View.onUpdate(dc);
drawMountains(dc);
}