Adam Porter
b00fb58673
Change: (ement-room--format-m.image) Relief, margin, pointer
...
This looks a bit nicer, and it conveys that the image is clickable.
2022-05-02 06:40:08 -05:00
Adam Porter
be5d68cd2c
Add/Change: (ement-room-send-file)
...
Also, move most logic from ement-room-send-image to it.
2022-05-02 06:40:08 -05:00
Adam Porter
6dc47f683c
Add: Format m.file events
2022-05-02 06:37:08 -05:00
Adam Porter
478091be38
Add: (ement-room--format-m.image) Linkify image URLs
...
When not showing images (when ement-room-images is nil), linkify the
URL to the image.
Thanks to @Wibjarm:matrix.org for reporting.
2022-05-02 06:36:54 -05:00
Adam Porter
c827e96d62
Fix: (room-defevent "m.room.message") Replaced messages
...
When reopening closed room buffers that contain retro-loaded messages
that include events that have been replaced by later edits, the
original messages were inserted alongside the edits, because the edit
events were inserted before the original events, so the original
events were not replaced by the edits.
This happened because the edits were processed before the originals,
because the events were stored out-of-order in the timeline. Now,
this shouldn't have been the case, because when retro-loading
messages, we store them at the beginning of the timeline, before the
newer events. But, for some reason, this isn't always working. The
Matrix spec says that the definition of "chronological order" is
up to the server, so maybe it's not always returning them in the order
we would expect.
So this is a mildly hacky workaround: if the event's unsigned data
indicates it's been replaced, we just don't insert it. Theoretically,
we should already have any such replacing event.
If we wanted to be extra careful, we could look up the replacing event
in the hash table to ensure we've got it, but we can add that later if
necessary; for now, let's not.
2022-05-02 04:54:12 -05:00
Adam Porter
8651e480ee
Tidy: Declare function
2022-05-02 04:01:38 -05:00
Adam Porter
7e9eb20980
Fix: (ement-room-mode-map) ement-room-occur binding
2022-05-02 04:01:13 -05:00
Adam Porter
fcf9ad92b4
Add: (ement-room-occur) et al.
2022-04-29 16:04:27 -05:00
Adam Porter
1a6b77ec51
Fix: (ement-room-find-event) Use event ID
...
For some reason, e.g. membership events in the EWOC are not always
`eq', so just compare IDs.
2022-04-29 15:58:16 -05:00
Adam Porter
a16db0ce6b
Tidy: (ement-room-retro-to) Declare indentation
2022-04-29 14:34:15 -05:00
Adam Porter
7a6390537f
Add: Go to events in matrix.to URLs when possible
2022-04-29 14:33:31 -05:00
Adam Porter
80ae7dc83e
Tidy: Docstrings
2022-04-29 13:45:03 -05:00
Adam Porter
7f118498f4
Fix: Compilation warning
2022-04-29 13:38:26 -05:00
Adam Porter
255ffbf052
Change/Fix: (ement-room--insert-event) Refactor and fix name headers
...
Ideally we would just call ement-room--insert-sender-headers for the
proper nodes, but at the moment this seems to work properly, so let's
just use this. We can refactor this into that again later.
2022-04-28 08:03:28 -05:00
Adam Porter
e047677fa0
Change/Fix: (ement-room--insert-sender-headers) Refactor and fix
...
Now works with read markers, is clearer, etc.
2022-04-28 07:20:16 -05:00
Adam Porter
a929af9fa3
Fix: (ement-room-set-message-format) Set margins in buffer
...
Not just with set-window-margins.
2022-04-28 05:56:07 -05:00
Adam Porter
d9fef46f1b
Fix: (ement-room--insert-event) Elemental-style message format
2022-04-27 11:52:42 -05:00
Adam Porter
5bddd9282e
Add/Fix: (ement--xml-escape-string, ement-room--format-body-mentions)
...
Escape non-XML(/HTML?) characters in HTML-formatted mentions.
2022-04-27 11:31:55 -05:00
Adam Porter
d4020544f1
Add: Linkify mentions in outgoing messages
2022-04-26 08:08:30 -05:00
Adam Porter
01d6bd612a
Tidy: (ement-room-leave)
2022-04-26 07:56:42 -05:00
Adam Porter
aebf61de4a
Fix: (ement-room-goto-prev) When at point-max
2022-04-26 07:49:03 -05:00
Adam Porter
e54ad99b38
Add: (ement-room-warn-for-already-seen-messages)
2022-04-22 11:13:10 -05:00
Adam Porter
68c1d36a40
Add: (ement-room-shr-use-fonts)
2022-04-22 10:27:55 -05:00
Adam Porter
4ad7e03112
Fix: (ement-room-mwheel-scroll) Use window-start
...
It seems that `mwheel-scroll' no longer signals an error at
beginning-of-buffer, so to detect whether that is the case, we'll have
to compare window-start.
2022-04-15 16:25:53 -05:00
Adam Porter
8e9031b368
Change: Require Emacs 27.1+
...
I'm not even testing it on Emacs 26.3 anymore, and this will let me
eliminate the last byte-compilation warning.
2022-04-15 10:33:15 -05:00
Adam Porter
8430e1c813
Add/Change: (ement-complete-room) Complete in room list buffers
...
And use keyword args.
2022-04-15 10:30:13 -05:00
Adam Porter
163d26243e
Fix: (ement-room--buffer) Invited rooms
...
Changed the slot used to track status.
2022-04-15 09:43:01 -05:00
Adam Porter
97ad5fe226
Add: (ement-taxy) Generated avatars using svg-lib
...
Thanks to @rougier for his great work on svg-lib.el!
2022-04-14 16:08:21 -05:00
Adam Porter
f46f4a222e
Fix: (ement-room--format-message-body) Format of m.replace messages
2022-04-14 02:56:22 -05:00
Adam Porter
f39cf31d21
Change: (ement-room-scroll-up-mark-read) Keep rooms window visible
...
...when it's already visible. This is useful when the rooms list is
in a side window.
2022-04-13 10:50:41 -05:00
Adam Porter
be412426e4
Fix: (ement-room-images) Only warn on image-capable display
2022-04-11 06:59:21 -05:00
Adam Porter
2a63e83192
Tidy: (ement-room--org-html-src-block) Use string-trim
...
Instead of org-trim.
2022-04-11 06:51:30 -05:00
Adam Porter
2fda057516
Tidy: Rename ement-room--handle-event(s) to --process-event(s)
2022-04-11 06:20:09 -05:00
Adam Porter
2c5bf38d79
Tidy: declare-function
2022-04-09 17:19:58 -05:00
Adam Porter
c7c7d98d16
Change/Fix: (ement-room--buffer) Process state/timeline events chronologically
2022-04-09 13:17:09 -05:00
Adam Porter
755e62db11
Fix: (ement-room-defevent "m.reaction") Find correct event
2022-04-09 13:15:32 -05:00
Adam Porter
e91ebf1789
Change: (ement-room-view-event) Include local slot
2022-04-09 13:15:01 -05:00
Adam Porter
e941816bc7
Add/Change: --events-equal-p and --event-replaces-p, and use
...
In (ement-room-defevent "m.reaction") and (ement-room-defevent "m.typing").
2022-04-09 12:36:04 -05:00
Adam Porter
5ca29de7ba
Fix: (ement-room--format-message) Edited message bodies
2022-04-09 12:36:04 -05:00
Adam Porter
1481714f9e
Fix: (ement-room-mark-read) Interactive spec
2022-04-07 10:59:25 -05:00
Adam Porter
f778c4cbc7
Change/Fix: (ement--process-event, ement-room--handle-events) Demote errors
...
It seems that various types of events may be accepted and forwarded by
servers despite being malformed. We don't want any malformed event to
prevent other events from being processed, or to prevent further
syncing. So we demote all errors encountered while running event
handlers. Ement's users seem attentive, so it's likely that they will
still report any that they encounter regularly, even though they'll
only be reported as messages.
Closes #61 . Thanks to @jfmcbrayer for reporting.
2022-04-07 10:57:29 -05:00
Adam Porter
95262e8571
Change: (ement-room-mark-read) Ensure proper major mode
...
See #59 .
2022-04-04 04:22:55 -05:00
Adam Porter
5fa7b8fa1d
Tidy: (declare-function ement--format-room)
2022-03-29 10:53:09 -05:00
Adam Porter
789da61000
Fix: (ement-room-leave) Use --format-room
2022-03-29 08:37:19 -05:00
Adam Porter
62da76173d
Change: (room-defevent "m.room.tombstone") Improve message
2022-03-29 08:25:30 -05:00
Adam Porter
b4d9b4fe26
Fix: (ement-room--buffer) Set header/footer before events
...
e.g. tombstone events would set the header while processing events,
which would then be overridden, leaving tombstoned rooms without a
warning.
2022-03-29 08:24:53 -05:00
Adam Porter
d70e3a04b3
WIP: Process read receipts
...
Not much used yet, except for trying to determine whether a room is
unread.
2022-03-29 06:44:17 -05:00
Adam Porter
03eea1570f
WIP: (ement-room-scroll-up-mark-read) ement-taxy-room-list-mode
2022-03-29 03:38:01 -05:00
Adam Porter
713efc0d59
Fix: (ement-room-mark-read)
...
Fixes #59 . Thanks to @fleimgruber for reporting.
2022-03-25 23:33:02 -05:00
Adam Porter
8c7030a95d
Change: Remove debug message
...
This shouldn't be needed anymore, and it can interfere with feedback
from the new send-direct-message command.
2022-03-25 22:59:19 -05:00