Commit 91ca50aecb

91ca50aecb369b4556a1b827b0c1252682a09218

parent: 949100bdc7

Unregistered key

Ethan Reynolds <1653607+reynoldsme@users.noreply.github.com> · 2024-04-13 22:47 UTC
committer: <noreply@github.com>

Fix image preview placement when messages are preceded by a date in the timeline (#257)

Layout: unified · split

src/message/mod.rs +2
@@ -961,6 +961,8 @@ impl Message {
961961 let proto = proto.map(|p| {
962962 let y_off = text.lines.len() as u16;
963963 let x_off = fmt.cols.user_gutter_width(settings);
964 // Adjust y_off by 1 if a date was printed before the message to account for the extra line.
965 let y_off = if fmt.date.is_some() { y_off + 1 } else { y_off };
964966 (p, x_off, y_off)
965967 });
966968