tgbotxx 1.1.9.2
Telegram Bot C++ Library
Loading...
Searching...
No Matches
tgbotxx::BackgroundTypePattern Struct Reference

The background is a PNG or TGV pattern combined with a fill. https://core.telegram.org/bots/api#backgroundtypepattern. More...

#include <BackgroundType.hpp>

Inheritance diagram for tgbotxx::BackgroundTypePattern:
tgbotxx::BackgroundType

Public Member Functions

 BackgroundTypePattern ()
 
 BackgroundTypePattern (const nl::json &json)
 
nl::json toJson () const override
 
void fromJson (const nl::json &json) override
 
- Public Member Functions inherited from tgbotxx::BackgroundType
 BackgroundType ()=default
 
 BackgroundType (const nl::json &json)
 
virtual ~BackgroundType ()=default
 

Public Attributes

Ptr< Documentdocument
 Document with the pattern.
 
Ptr< BackgroundFillfill
 The background fill that is combined with the pattern.
 
std::int32_t intensity {}
 Intensity of the pattern when it is shown above the filled background; 0-100.
 
bool isInverted {}
 Optional. True, if the background fill must be applied only to the pattern itself. All other pixels are black in this case. For dark themes only.
 
bool isMoving {}
 Optional. True, if the background moves slightly when the device is tilted.
 
- Public Attributes inherited from tgbotxx::BackgroundType
std::string type
 Type of the background, one of "fill", "wallpaper", "pattern", "chat_theme".
 

Detailed Description

The background is a PNG or TGV pattern combined with a fill. https://core.telegram.org/bots/api#backgroundtypepattern.

Definition at line 112 of file BackgroundType.hpp.

Constructor & Destructor Documentation

◆ BackgroundTypePattern() [1/2]

tgbotxx::BackgroundTypePattern::BackgroundTypePattern ( )
inline

Definition at line 113 of file BackgroundType.hpp.

◆ BackgroundTypePattern() [2/2]

tgbotxx::BackgroundTypePattern::BackgroundTypePattern ( const nl::json &  json)
inlineexplicit

Definition at line 116 of file BackgroundType.hpp.

Member Function Documentation

◆ fromJson()

void tgbotxx::BackgroundTypePattern::fromJson ( const nl::json &  json)
inlineoverridevirtual

Reimplemented from tgbotxx::BackgroundType.

Definition at line 145 of file BackgroundType.hpp.

◆ toJson()

nl::json tgbotxx::BackgroundTypePattern::toJson ( ) const
inlineoverridevirtual

Reimplemented from tgbotxx::BackgroundType.

Definition at line 135 of file BackgroundType.hpp.

Member Data Documentation

◆ document

Ptr<Document> tgbotxx::BackgroundTypePattern::document

Document with the pattern.

Definition at line 121 of file BackgroundType.hpp.

◆ fill

Ptr<BackgroundFill> tgbotxx::BackgroundTypePattern::fill

The background fill that is combined with the pattern.

Definition at line 124 of file BackgroundType.hpp.

◆ intensity

std::int32_t tgbotxx::BackgroundTypePattern::intensity {}

Intensity of the pattern when it is shown above the filled background; 0-100.

Definition at line 127 of file BackgroundType.hpp.

◆ isInverted

bool tgbotxx::BackgroundTypePattern::isInverted {}

Optional. True, if the background fill must be applied only to the pattern itself. All other pixels are black in this case. For dark themes only.

Definition at line 130 of file BackgroundType.hpp.

◆ isMoving

bool tgbotxx::BackgroundTypePattern::isMoving {}

Optional. True, if the background moves slightly when the device is tilted.

Definition at line 133 of file BackgroundType.hpp.


The documentation for this struct was generated from the following file: