AdwAvatar

A widget displaying an image, with a generated fallback.

<picture> <source srcset="avatar-dark.png" media="(prefers-color-scheme: dark)"> <img src="avatar.png" alt="avatar"> </picture>

adw.avatar.Avatar is a widget that shows a round avatar.

adw.avatar.Avatar generates an avatar with the initials of the property@Avatar:text on top of a colored background.

The color is picked based on the hash of the property@Avatar:text.

If property@Avatar:show-initials is set to FALSE, property@Avatar:icon-name or avatar-default-symbolic is shown instead of the initials.

Use property@Avatar:custom-image to set a custom image.

CSS nodes

adw.avatar.Avatar has a single CSS node with name avatar.

struct AdwAvatar