Stay organized with collections
Save and categorize content based on your preferences.
Allows for conditionally showing a set of text and graphical elements based on
the user's current true-or-false selection from a watch face options screen.
This element references a user configuration BooleanConfiguration element
that's defined elsewhere in the watch face file.
The BooleanConfiguration element has one required attribute, id. This is a
string that must match the id value of a previously-defined user
configuration BooleanConfiguration.
Inner elements
The BooleanConfiguration element can contain at most two BooleanOption
inner elements. Each BooleanOption contains an id value of either TRUE or
FALSE, and contains the graphical elements that should appear on the watch
face when the user selects either "true" or "false" from a watch face's options
screen, respectively.
Each BooleanOption inner element can contain one of the following elements:
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-05-20 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-20 UTC."],[],[],null,["# BooleanConfiguration\n\nWatch Face Format version Version 4 Version 3 Version 2 Version 1\n\n*** ** * ** ***\n\nAllows for conditionally showing a set of text and graphical elements based on\nthe user's current true-or-false selection from a watch face options screen.\nThis element references a [user configuration `BooleanConfiguration`](/training/wearables/wff/user-configuration/boolean-configuration) element\nthat's defined elsewhere in the watch face file.\n\nIntroduced in Wear OS 4.\n\nSyntax\n------\n\n```xml\n\u003c!-- The ID doesn't need to be \"showDate\"; this is just an example. --\u003e\n\u003cUserConfiguration\u003e\n \u003cBooleanConfiguration id=\"showDate\" /\u003e\n\u003c/UserConfiguration\u003e\n\u003c!-- ... --\u003e\n\u003cBooleanConfiguration id=\"showDate\"\u003e\n \u003cBooleanOption id=\"TRUE\"\u003e\n \u003c!-- Only the most common element is shown here --\u003e\n \u003cPartText ... /\u003e\n \u003c/BooleanOption\u003e\n \u003cBooleanOption id=\"FALSE\" ... /\u003e\n\u003c/BooleanConfiguration\u003e\n```\n\nAttributes\n----------\n\nThe `BooleanConfiguration` element has one required attribute, `id`. This is a\nstring that must match the `id` value of a previously-defined [user\nconfiguration `BooleanConfiguration`](/training/wearables/wff/user-configuration/boolean-configuration).\n\nInner elements\n--------------\n\nThe `BooleanConfiguration` element can contain at most two `BooleanOption`\ninner elements. Each `BooleanOption` contains an `id` value of either `TRUE` or\n`FALSE`, and contains the graphical elements that should appear on the watch\nface when the user selects either \"true\" or \"false\" from a watch face's options\nscreen, respectively.\n\nEach `BooleanOption` inner element can contain one of the following elements:\n\n- [`Group`](/training/wearables/wff/group/group)\n- [`PartText`](/training/wearables/wff/group/part/text/part-text)\n- [`PartImage`](/training/wearables/wff/group/part/image/part-image)\n- [`PartAnimatedImage`](/training/wearables/wff/group/part/animated-image/part-animated-image)\n- [`PartDraw`](/training/wearables/wff/group/part/draw/part-draw)\n- [`Condition`](/training/wearables/wff/common/condition)\n- [`AnalogClock`](/training/wearables/wff/clock/analog-clock)\n- [`DigitalClock`](/training/wearables/wff/clock/digital-clock)\n\nRecommended for you\n-------------------\n\n- Note: link text is displayed when JavaScript is off\n- [Group](/training/wearables/wff/group/group)\n- [ListConfiguration](/training/wearables/wff/group/configuration/list-configuration)\n- [Complication](/training/wearables/wff/complication/complication)"]]