← All components

<button>

InteractiveWallpaperWidget

Tappable button with a text label. Runs a tap action on widgets; wallpapers draw it without interaction.

Example

<button action="refresh" style="filled">Refresh</button>

Attributes

NameTypeDefaultDescription
actionString
openAppopenActivityintentopenUrlsearchopenAlarmsopenTimerssetAlarmsetTimeropenCalendarnewEventdialsmsemailopenMapnavigateopenSettingscameraassistantshareopenAardflexopenWallpaperPickerrefreshtoggleswitchPage
—Tap action. Parameters are extra attributes named by the action.
styleString
filledoutlinedtext
filledButton style.
colorColor—Button container color
textColorColor—Label color
allDayBoolean—All-day event (for newEvent)
appString—Package name, e.g. com.google.android.deskclock (for openApp)
beginString—Start: ISO date-time or epoch millis (for newEvent)
bodyString—Message text (for sms, email)
categoryString—Intent category (for intent)
componentString—Component, e.g. com.example/.MainActivity (for openActivity)
dataString—Data URI (for intent)
dateString—today | yyyy-MM-dd | epoch millis (for openCalendar)
endString—End: ISO date-time or epoch millis (for newEvent)
extrasString—Intent extras: key=value;key=value (for openActivity, intent)
hourInt—Hour 0–23 (for setAlarm)
intentActionString—Intent action, e.g. android.intent.action.VIEW (for intent)
latFloat—Latitude (for openMap)
lonFloat—Longitude (for openMap)
messageString—Alarm label (for setAlarm, setTimer)
mimeTypeString—MIME type (for intent)
minuteInt—Minute 0–59 (for setAlarm)
numberString—Phone number (for dial, sms)
packageString—Restrict to this package (for intent)
pageString
nextprev<index>
—Page index, next or prev (for switchPage)
queryString—Search terms (for search, openMap)
screenString
homewallpaperswidgetslibrarysettingswallpaper:<id>widget:<id>editor:<id>
—Target screen (for openAardflex)
secondsInt—Timer length in seconds (for setTimer)
sectionString
wifibluetoothbatterydisplaysoundlocationdateTimewallpapernotificationsappInfohome
—Settings section (for openSettings)
skipUiBoolean—Create silently without showing the clock app (for setAlarm, setTimer)
subjectString—Subject (for email, share)
textString—Text to share (for share)
titleString—Event title (for newEvent)
toString—Recipient address (for email, navigate)
urlString—http(s) URL (for openUrl)
varString—Variable name (for toggle)
overlayVisibleBooleanfalseKeep this element visible when the widget renders in overlay mode (default: hidden, the wallpaper draws it)