MessageListItemStyle

data class MessageListItemStyle(@ColorInt() messageBackgroundColorMine: Int?, @ColorInt() messageBackgroundColorTheirs: Int?, @ColorInt() messageLinkTextColorMine: Int?, @ColorInt() messageLinkTextColorTheirs: Int?, @ColorInt() messageLinkBackgroundColorMine: Int, @ColorInt() messageLinkBackgroundColorTheirs: Int, linkDescriptionMaxLines: Int, textStyleMine: TextStyle, textStyleTheirs: TextStyle, textStyleUserName: TextStyle, textStyleMessageDate: TextStyle, textStyleThreadCounter: TextStyle, threadSeparatorTextStyle: TextStyle, textStyleLinkLabel: TextStyle, textStyleLinkTitle: TextStyle, textStyleLinkDescription: TextStyle, @ColorInt() dateSeparatorBackgroundColor: Int, textStyleDateSeparator: TextStyle, reactionsViewStyle: ViewReactionsViewStyle, editReactionsViewStyle: EditReactionsViewStyle, iconIndicatorSent: Drawable, iconIndicatorRead: Drawable, iconIndicatorPendingSync: Drawable, iconOnlyVisibleToYou: Drawable, textStyleMessageDeleted: TextStyle, @ColorInt() messageDeletedBackground: Int, @ColorInt() messageStrokeColorMine: Int, @Px() messageStrokeWidthMine: Float, @ColorInt() messageStrokeColorTheirs: Int, @Px() messageStrokeWidthTheirs: Float, textStyleSystemMessage: TextStyle, textStyleErrorMessage: TextStyle, pinnedMessageIndicatorTextStyle: TextStyle, pinnedMessageIndicatorIcon: Drawable, @ColorInt() pinnedMessageBackgroundColor: Int, @Px() messageStartMargin: Int, @Px() messageEndMargin: Int, messageMaxWidthFactorMine: Float, messageMaxWidthFactorTheirs: Float, showMessageDeliveryStatusIndicator: Boolean, iconFailedMessage: Drawable, iconBannedMessage: Drawable)

Style for view holders used inside MessageListView. Use this class together with TransformStyle.messageListItemStyleTransformer to change styles programmatically.

Constructors

MessageListItemStyle
Link copied to clipboard
fun MessageListItemStyle(@ColorInt() messageBackgroundColorMine: Int?, @ColorInt() messageBackgroundColorTheirs: Int?, @ColorInt() messageLinkTextColorMine: Int?, @ColorInt() messageLinkTextColorTheirs: Int?, @ColorInt() messageLinkBackgroundColorMine: Int, @ColorInt() messageLinkBackgroundColorTheirs: Int, linkDescriptionMaxLines: Int, textStyleMine: TextStyle, textStyleTheirs: TextStyle, textStyleUserName: TextStyle, textStyleMessageDate: TextStyle, textStyleThreadCounter: TextStyle, threadSeparatorTextStyle: TextStyle, textStyleLinkLabel: TextStyle, textStyleLinkTitle: TextStyle, textStyleLinkDescription: TextStyle, @ColorInt() dateSeparatorBackgroundColor: Int, textStyleDateSeparator: TextStyle, reactionsViewStyle: ViewReactionsViewStyle, editReactionsViewStyle: EditReactionsViewStyle, iconIndicatorSent: Drawable, iconIndicatorRead: Drawable, iconIndicatorPendingSync: Drawable, iconOnlyVisibleToYou: Drawable, textStyleMessageDeleted: TextStyle, @ColorInt() messageDeletedBackground: Int, @ColorInt() messageStrokeColorMine: Int, @Px() messageStrokeWidthMine: Float, @ColorInt() messageStrokeColorTheirs: Int, @Px() messageStrokeWidthTheirs: Float, textStyleSystemMessage: TextStyle, textStyleErrorMessage: TextStyle, pinnedMessageIndicatorTextStyle: TextStyle, pinnedMessageIndicatorIcon: Drawable, @ColorInt() pinnedMessageBackgroundColor: Int, @Px() messageStartMargin: Int, @Px() messageEndMargin: Int, messageMaxWidthFactorMine: Float, messageMaxWidthFactorTheirs: Float, showMessageDeliveryStatusIndicator: Boolean, iconFailedMessage: Drawable, iconBannedMessage: Drawable)

Properties

dateSeparatorBackgroundColor
Link copied to clipboard
val dateSeparatorBackgroundColor: Int
Background color for data separator.
editReactionsViewStyle
Link copied to clipboard
val editReactionsViewStyle: EditReactionsViewStyle
iconBannedMessage
Link copied to clipboard
val iconBannedMessage: Drawable
Icon for message when the current user is banned.
iconFailedMessage
Link copied to clipboard
val iconFailedMessage: Drawable
Icon for message failed status.
iconIndicatorPendingSync
Link copied to clipboard
val iconIndicatorPendingSync: Drawable
Icon for message's pending status.
iconIndicatorRead
Link copied to clipboard
val iconIndicatorRead: Drawable
Icon for message's read status.
iconIndicatorSent
Link copied to clipboard
val iconIndicatorSent: Drawable
Icon for message's sent status.
iconOnlyVisibleToYou
Link copied to clipboard
val iconOnlyVisibleToYou: Drawable
Icon for message's pending status.
linkDescriptionMaxLines
Link copied to clipboard
val linkDescriptionMaxLines: Int
Max lines for link's description.
messageBackgroundColorMine
Link copied to clipboard
val messageBackgroundColorMine: Int?
Background color for message sent by the current user.
messageBackgroundColorTheirs
Link copied to clipboard
val messageBackgroundColorTheirs: Int?
Background color for message sent by other user.
messageDeletedBackground
Link copied to clipboard
val messageDeletedBackground: Int
Background color for deleted message.
messageEndMargin
Link copied to clipboard
val messageEndMargin: Int
Margin for messages in the right side.
messageLinkBackgroundColorMine
Link copied to clipboard
val messageLinkBackgroundColorMine: Int
Background color for message with link, sent by the current user.
messageLinkBackgroundColorTheirs
Link copied to clipboard
val messageLinkBackgroundColorTheirs: Int
Background color for message with link, sent by other user.
messageLinkTextColorMine
Link copied to clipboard
val messageLinkTextColorMine: Int?
Color for links sent by the current user.
messageLinkTextColorTheirs
Link copied to clipboard
val messageLinkTextColorTheirs: Int?
Color for links sent by other user.
messageMaxWidthFactorMine
Link copied to clipboard
val messageMaxWidthFactorMine: Float
Factor used to compute max width for message sent by the current user.
messageMaxWidthFactorTheirs
Link copied to clipboard
val messageMaxWidthFactorTheirs: Float
Factor used to compute max width for message sent by other user.
messageStartMargin
Link copied to clipboard
val messageStartMargin: Int
Margin for messages in the left side.
messageStrokeColorMine
Link copied to clipboard
val messageStrokeColorMine: Int
Stroke color for message sent by the current user.
messageStrokeColorTheirs
Link copied to clipboard
val messageStrokeColorTheirs: Int
Stroke color for message sent by other user.
messageStrokeWidthMine
Link copied to clipboard
val messageStrokeWidthMine: Float
Stroke width for message sent by the current user.
messageStrokeWidthTheirs
Link copied to clipboard
val messageStrokeWidthTheirs: Float
Stroke width for message sent by other user.
pinnedMessageBackgroundColor
Link copied to clipboard
val pinnedMessageBackgroundColor: Int
pinnedMessageIndicatorIcon
Link copied to clipboard
val pinnedMessageIndicatorIcon: Drawable
pinnedMessageIndicatorTextStyle
Link copied to clipboard
val pinnedMessageIndicatorTextStyle: TextStyle
reactionsViewStyle
Link copied to clipboard
val reactionsViewStyle: ViewReactionsViewStyle
showMessageDeliveryStatusIndicator
Link copied to clipboard
val showMessageDeliveryStatusIndicator: Boolean
Flag if we need to show the delivery indicator or not.
textStyleDateSeparator
Link copied to clipboard
val textStyleDateSeparator: TextStyle
Appearance for date separator text.
textStyleErrorMessage
Link copied to clipboard
val textStyleErrorMessage: TextStyle
Appearance for error message text.
textStyleLinkDescription
Link copied to clipboard
val textStyleLinkDescription: TextStyle
Appearance for link's description text.
textStyleLinkLabel
Link copied to clipboard
val textStyleLinkLabel: TextStyle
textStyleLinkTitle
Link copied to clipboard
val textStyleLinkTitle: TextStyle
Appearance for link.
textStyleMessageDate
Link copied to clipboard
val textStyleMessageDate: TextStyle
Appearance for message date text.
textStyleMessageDeleted
Link copied to clipboard
val textStyleMessageDeleted: TextStyle
Appearance for message deleted text.
textStyleMine
Link copied to clipboard
val textStyleMine: TextStyle
Appearance for message text sent by the current user.
textStyleSystemMessage
Link copied to clipboard
val textStyleSystemMessage: TextStyle
Appearance for system message text.
textStyleTheirs
Link copied to clipboard
val textStyleTheirs: TextStyle
Appearance for message text sent by other user.
textStyleThreadCounter
Link copied to clipboard
val textStyleThreadCounter: TextStyle
Appearance for thread counter text.
textStyleUserName
Link copied to clipboard
val textStyleUserName: TextStyle
Appearance for user name text.
threadSeparatorTextStyle
Link copied to clipboard
val threadSeparatorTextStyle: TextStyle

Functions

getStyleLinkTextColor
Link copied to clipboard
fun getStyleLinkTextColor(isMine: Boolean): Int?
getStyleTextColor
Link copied to clipboard
fun getStyleTextColor(isMine: Boolean): Int?