# ComplicationHighlightRenderer

# ComplicationHighlightRenderer

Artifact:[androidx.wear.watchface:watchface-complications-rendering](https://developer.android.com/jetpack/androidx/releases/wear-watchface)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer.kt+class:androidx.wear.watchface.complications.rendering.ComplicationHighlightRenderer)  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0)  
Deprecated in[1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer "View this page in Java")

<br />

```
class ComplicationHighlightRenderer
```

<br />

*** ** * ** ***

| **This class is deprecated.**   
| AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

Helper for rendering a thick outline around a complication to highlight it.

use Watch Face Format instead

## Summary

|                                                                                                                                                                                                                                                                                                                                                  ### Public constructors                                                                                                                                                                                                                                                                                                                                                   |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ~~[ComplicationHighlightRenderer](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer#ComplicationHighlightRenderer(kotlin.Float,kotlin.Float))~~`(` ` outlineExpansion: @`[Px](https://developer.android.com/reference/kotlin/androidx/annotation/Px)` `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)`,` ` outlineStrokeWidth: @`[Px](https://developer.android.com/reference/kotlin/androidx/annotation/Px)` `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html) `)` **This function is deprecated.**AndroidX watchface libraries are deprecated, use Watch Face Format instead. |

|                             ### Public functions                              |
|-------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Unit](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html) | ~~[drawComplicationHighlight](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer#drawComplicationHighlight(android.graphics.Canvas,android.graphics.Rect,kotlin.Int))~~`(canvas: `[Canvas](https://developer.android.com/reference/android/graphics/Canvas.html)`, bounds: `[Rect](https://developer.android.com/reference/android/graphics/Rect.html)`, color: @`[ColorInt](https://developer.android.com/reference/kotlin/androidx/annotation/ColorInt)` `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`)` **This function is deprecated.**AndroidX watchface libraries are deprecated, use Watch Face Format instead. |

## Public constructors

### ComplicationHighlightRenderer

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0)  
Deprecated in[1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)  

```
[ComplicationHighlightRenderer](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer#ComplicationHighlightRenderer(kotlin.Float,kotlin.Float))(
    outlineExpansion: @Px Float,
    outlineStrokeWidth: @Px Float
)
```
| **This function is deprecated.**   
AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff  

## Public functions

### drawComplicationHighlight

Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0)  
Deprecated in[1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)  

```
fun [drawComplicationHighlight](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer#drawComplicationHighlight(android.graphics.Canvas,android.graphics.Rect,kotlin.Int))(canvas: Canvas, bounds: Rect, color: @ColorInt Int): Unit
```
| **This function is deprecated.**   
| AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

Intended for use by[CanvasComplicationDrawable.drawHighlight](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/CanvasComplicationDrawable#drawHighlight(android.graphics.Canvas,android.graphics.Rect,kotlin.Int,java.time.ZonedDateTime,kotlin.Int)). Draws a thick line around the complication with[color](https://developer.android.com/reference/kotlin/androidx/wear/watchface/complications/rendering/ComplicationHighlightRenderer#drawComplicationHighlight(android.graphics.Canvas,android.graphics.Rect,kotlin.Int))and with the given bounds. Fills the center of the complication with transparent white. When composited on top of the underlying watchface the complication's original pixels will be preserved with their original brightness.