boxdot / gurk-rs

Signal Messenger client for terminal
GNU Affero General Public License v3.0
479 stars 36 forks source link

New visual style for receipts #135

Closed boxdot closed 2 years ago

boxdot commented 2 years ago

Show ○ (sent), ◉ (received), ● (delivered) unicode icons next to own messages. This can be disabled by adding show_receipts = false to the config file.

Also optimize the receipts handling code.

Sup3Legacy commented 2 years ago

Now that's a nice slick UI! Also the optimization was probably well deserved

Sup3Legacy commented 2 years ago

I just noticed the internal names for the different message delivery status have been mismatched, it's supposed to be Sent, Delivered, Read and not Sent, Received, Delivered. Seems I made the mistake a while back, can you fix it?

Sup3Legacy commented 2 years ago

Just thought that we assume in the receipt handling code that messages are stored in order of increasing timestamp even though this might not be the case on some occasions (because the timestamp is set by the sender, there is some jitter). This means we might not handle receipts correctly in these edge cases.

boxdot commented 2 years ago

Very good observation. Either we need to sort then and maintain the order, or maintain a lookup table.