mirror of
https://github.com/matrix-org/matrix-rust-sdk.git
synced 2026-05-03 13:37:56 -04:00
Now that there is some support for [MSC2530](https://github.com/matrix-org/matrix-spec-proposals/pull/2530), I gave adding sending captions a try. ( This is my first time with Rust 😄 ) I tried it on Element X with a hardcoded caption and it seems to work well  (It even got forwarded through mautrix-whatsapp and the caption was visible on the Whatsapp side) --- * ffi: Expose filename and formatted body fields for media captions In relevance to MSC2530 * MSC2530: added the ability to send media with captions Signed-off-by: Marco Antonio Alvarez <surakin@gmail.com> * signoff Signed-off-by: Marco Antonio Alvarez <surakin@gmail.com> * fixing the import messup * fix missing parameters in documentation * fix formatting * move optional parameters to the end * more formatting fixes * more formatting fixes * rename url parameter to filename in send_attachment and helpers * fix send_attachment documentation example * move caption and formatted_caption into attachmentconfig * fix formatting * fix formatting * fix formatting (hopefully the last one) * updated stale comments * simplify attachment message comments --------- Signed-off-by: Marco Antonio Alvarez <surakin@gmail.com> Co-authored-by: SpiritCroc <dev@spiritcroc.de>
Matrix SDK Examples
In this folder you find examples for using the matrix-sdk (and its various components) to implement specific common features, each as a separate crate. You can run each of them from the root of the repository, mind you that _ becomes - and the crate names are prefixed with example-. So to run the image bot example you can do cargo run -p example-image-bot.