Function deltachat::tools::truncate_msg_text
source · pub(crate) async fn truncate_msg_text(
context: &Context,
text: String,
) -> Result<(String, bool)>
Expand description
Shortens a message text if necessary according to the configuration. Adds “[…]” to the end of the shortened text.
Returns the resulting text and a bool telling whether a truncation was done.