SetChatBackground class
Sets the background in a specific chat. Supported only in private and secret chats with non-deleted users, and in chats with a sufficient boost level and can_change_info administrator right Returns Ok
- Inheritance
-
- Object
- TdFunction
- SetChatBackground
- Available extensions
- Annotations
-
- @immutable
Constructors
- SetChatBackground({required int chatId, InputBackground? background, BackgroundType? type, required int darkThemeDimming, required bool onlyForSelf})
-
const
Properties
- background → InputBackground?
-
background The input background to use; pass null to create a new filled
or chat theme background
final
- chatId → int
-
chatId Chat identifier
final
- darkThemeDimming → int
-
darkThemeDimming Dimming of the background in dark themes, as a
percentage; 0-100. Applied only to Wallpaper and Fill types of background
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- onlyForSelf → bool
-
onlyForSelf Pass true to set the background only for self; pass false to
set the background for all chat users. Always false for backgrounds set in
boosted chats. The background can be set for both users only by Telegram
Premium users and if the set background isn't of the type
inputBackgroundPrevious
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- type → BackgroundType?
-
type Background type; pass null to use the default background type for
the chosen background; backgroundTypeChatTheme isn't supported for private
and secret chats. Use chatBoostLevelFeatures.chat_theme_background_count
and chatBoostLevelFeatures.can_set_custom_background to check whether the
background type can be set in the boosted chat
final
Methods
-
copyWith(
{int? chatId, InputBackground? background, BackgroundType? type, int? darkThemeDimming, bool? onlyForSelf}) → SetChatBackground -
Available on SetChatBackground, provided by the SetChatBackgroundExtensions extension
-
getConstructor(
) → String -
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Constants
- constructor → const String