This page describes the structure of watch faces that use the Watch Face Format, as well as how to build and deploy them.
The structure of WFF watch faces
Watch Face Format watch faces are submitted to the Play Store as AABs or APKs just
like any other app. While they therefore share many of the common attributes of
other apps, such as a need for an AndroidManifest.xml
file, they have a specific
structure.
- All the content of the watch face is in the resources folder, namely
res/
- All the watch face definitions are in
res/raw/
, includingres/raw/watchface.xml
for the simple case and any other XML definitions that represent support for different device sizes. - All resources needed by the watch face are in the appropriate resources
folder, just as for regular applications, for example:
/res/font
for fonts/res/drawable
for image and animation assets/res/values/strings.xml
for any string resources
Build the watch face using Gradle
The easiest way to see the process of how to use Gradle to build the watch face is to take a look at the samples on GitHub.
As well as building the watch face, the Gradle scripts in these projects check the watch face XML for validity using the validator tools.
Check the watch face prior to submission to Google Play
Once you have created your watch face and familiarized yourself with the build process, perform pre-submission checks on your watch face AAB before submitting to Play.
Play performs very similar checks, so ensuring that you're passing these pre-submission checks saves you considerable time in the submission and review process.
An example of running the pre-submission checks:
These checks no only inspect how much memory the watch face is using, but also identify other issues, such as missing resources, as well as validating the XML.
For details on how to obtain and build the tool, see the Memory Footprint Evaluator.