TDLib
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | List of all members
createTextCompositionStyle Class Referencefinal

Inherits Function.

Description

Creates a custom text composition style. May return an error with a message "TONES_SAVED_TOO_MANY" if the maximum number of added custom styles has been reached.

Returns object_ptr<TextCompositionStyle>.

Public Types

using ReturnType = object_ptr< textCompositionStyle >
 Typedef for the type returned by the function.
 

Public Member Functions

 createTextCompositionStyle ()
 
 createTextCompositionStyle (string const &title_, int64 custom_emoji_id_, string const &prompt_, bool show_creator_)
 
void store (TlStorerToString &s, const char *field_name) const final
 
- Public Member Functions inherited from TlObject
TlObject & operator= (const TlObject &)=delete
 
TlObject & operator= (TlObject &&)=default
 
virtual void store (TlStorerCalcLength &s) const
 
virtual void store (TlStorerUnsafe &s) const
 
 TlObject ()=default
 
 TlObject (const TlObject &)=delete
 
 TlObject (TlObject &&)=default
 
virtual ~TlObject ()=default
 

Public Attributes

int64 custom_emoji_id_
 Identifier of the custom emoji corresponding to the style.
 
string prompt_
 Prompt that will be used for text composition; 1-getOption("text_composition_style_prompt_length_max") characters.
 
bool show_creator_
 Pass true if the current user must be shown as the creator of the style.
 
string title_
 Title of the style; 1-getOption("text_composition_style_title_length_max") characters.
 

Static Public Attributes

static const std::int32_t ID = -1549417869
 Identifier uniquely determining a type of the object.
 

Constructor & Destructor Documentation

◆ createTextCompositionStyle() [1/2]

Default constructor for a function, which creates a custom text composition style. May return an error with a message "TONES_SAVED_TOO_MANY" if the maximum number of added custom styles has been reached.

Returns object_ptr<TextCompositionStyle>.

◆ createTextCompositionStyle() [2/2]

createTextCompositionStyle ( string const &  title_,
int64  custom_emoji_id_,
string const &  prompt_,
bool  show_creator_ 
)

Creates a function, which creates a custom text composition style. May return an error with a message "TONES_SAVED_TOO_MANY" if the maximum number of added custom styles has been reached.

Returns object_ptr<TextCompositionStyle>.

Parameters
[in]title_Title of the style; 1-getOption("text_composition_style_title_length_max") characters.
[in]custom_emoji_id_Identifier of the custom emoji corresponding to the style.
[in]prompt_Prompt that will be used for text composition; 1-getOption("text_composition_style_prompt_length_max") characters.
[in]show_creator_Pass true if the current user must be shown as the creator of the style.

Member Function Documentation

◆ store()

void store ( TlStorerToString &  s,
const char *  field_name 
) const
finalvirtual

Helper function for to_string method. Appends string representation of the object to the storer.

Parameters
[in]sStorer to which object string representation will be appended.
[in]field_nameObject field_name if applicable.

Implements TlObject.


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