Watch Face Format version <button value="5" default="">Version 5</button> <button value="4">Version 4</button> <button value="3">Version 3</button> <button value="2">Version 2</button> <button value="1">Version 1</button>

*** ** * ** ***

An analog clock is a container for `AnalogHands` inner elements, which display
a series of clock hands that rotate around a watch face.

Introduced in Wear OS 4.

## Syntax

```xml
<AnalogClock x="integer" y="integer" width="integer" height="integer"
             pivotX="float" pivotY="float" angle="float-degrees" alpha="integer"
             scaleX="float" scaleY="float"
             renderMode="[SOURCE | MASK | ALL]"
             tintColor="argb-color | rgb-color">
    <!-- This is the maximum number of hands that you can define. -->
    <HourHand ... />
    <HourHand ... />
    <MinuteHand ... />
    <MinuteHand ... />
    <SecondHand ... />
    <SecondHand ... />
</AnalogClock>
```

## Attributes

The `AnalogClock` element has the following attributes:

### Required attributes

The following attributes are required:

`x`, `y`, `width`, `height`
:   A collection of integers that specify the element's size and position.

### Optional attributes

The following attributes are optional:

`pivotX`, `pivotY`
:   A two-dimensional pivot point about which the element rotates. Both values
    are floating-point numbers that are scaled to fit in the range $ \[0, 1\] $.

`angle`
:   A number of degrees, clockwise, that the element should be rotated about its
    pivot point.

`alpha`
:   Set the level of transparency that this element should have. A value of `0`
    indicates that the element should be completely transparent. A value of `255`
    indicates that the element should be completely opaque.

`scaleX`
:   The horizontal scaling factor to apply to this element.

`scaleY`
:   The vertical scaling factor to apply to this element.

`renderMode`
:   The element's render mode type. Possible values are: `SOURCE` (default),
    `MASK`, or `ALL`.

`tintColor`
:   Apply a tint color filter to the element. You must specify the color using
    either the ARGB format (`#ff000000` = opaque black) or the RGB format
    (`#000000` = black).

## Inner elements

The `AnalogClock` element can contain the following inner elements:

[`HourHand`](https://developer.android.com/training/wearables/wff/clock/hour-hand)
[`MinuteHand`](https://developer.android.com/training/wearables/wff/clock/minute-hand)
[`SecondHand`](https://developer.android.com/training/wearables/wff/clock/second-hand)
:   Elements that represent the hour, minute, and second hands, respectively, that
    rotate around the watch face. `AnalogClock` can contain at most 2 hour hands, 2
    minute hands, and 2 second hands.

`Localization`
:   Provides a hint for the locale to use when rendering the time. More
    information is available in the [`Localization`](https://developer.android.com/training/wearables/wff/common/localization) reference.

An `AnalogClock` element can contain at most one `Localization` element.

`Variant`
:   Allows for changing attributes of this element when the Wear OS device is in
    ambient mode. More information is available in the [`Variant`](https://developer.android.com/training/wearables/wff/common/variant/variant) reference.

## Recommended for you

- Note: link text is displayed when JavaScript is off
- [Group](https://developer.android.com/training/wearables/wff/group/group)
- [DigitalClock](https://developer.android.com/training/wearables/wff/clock/digital-clock)
- [PartImage](https://developer.android.com/training/wearables/wff/group/part/image/part-image)