Closed welandx closed 1 year ago
Searching is done by Telegram server, not by telega.el
and Telegram server does not support regexps as I know. Use https://bugs.telegram.org/ to report this searching issue
JFYI: You can search messages inplace, using C-c C-r binding in the chatbuf
Searching is done by Telegram server, not by
telega.el
and Telegram server does not support regexps as I know. Use https://bugs.telegram.org/ to report this searching issue
Thank you for your suggestion. I found this: https://bugs.telegram.org/c/724. So I'm looking for a temporary alternative method.
JFYI: You can search messages inplace, using C-c C-r binding in the chatbuf
Is there any difference with this search? I found that it behaves the same as telega-chatbuf-filter-search
.
My current idea is to use telega-button-backward
and apply the logic similar to my/match-at-point-msg
to each message. Store each matched message, then telega-msg-goto
.
Is this approach feasible? If you could provide some advice, I would greatly appreciate it.
Searching is done by Telegram server, not by
telega.el
and Telegram server does not support regexps as I know. Use https://bugs.telegram.org/ to report this searching issueThank you for your suggestion. I found this: https://bugs.telegram.org/c/724. So I'm looking for a temporary alternative method.
JFYI: You can search messages inplace, using C-c C-r binding in the chatbuf
Is there any difference with this search? I found that it behaves the same as
telega-chatbuf-filter-search
.
telega-chatbuf-filter-search
filters messages, i.e. shows only messages matching search query. Inplace searching searches for the query without filtering messages, so you can see context surrounding the message matching your query.
My current idea is to use
telega-button-backward
and apply the logic similar tomy/match-at-point-msg
to each message. Store each matched message, thentelega-msg-goto
. Is this approach feasible? If you could provide some advice, I would greatly appreciate it.
This could be done, however, in a general way this will be very slow and will give inconsistent results.
What you can do is to match newly incoming messages for some keyword of your interest and then display messages list. Something similar to custom value for telega-notifications-msg-temex
and M-x telega-notifications-history RET
command to display messages matching telega-notifications-msg-temex
telega-chatbuf-filter-search
filters messages, i.e. shows only messages matching search query. Inplace searching searches for the query without filtering messages, so you can see context surrounding the message matching your query.
I see.
This could be done, however, in a general way this will be very slow and will give inconsistent results.
Thanks, but this feature is quite important to me personally, so I will implement it temporarily to solve the problem.
What you can do is to match newly incoming messages for some keyword of your interest and then display messages list. Something similar to custom value for
telega-notifications-msg-temex
andM-x telega-notifications-history RET
command to display messages matchingtelega-notifications-msg-temex
This is also helpful.
Current Behavior
I found that the function
telega-chatbuf-filter-search
cannot search for Chinese words within the sentence. For example, msg list:If I want to search "推荐", I can get the first sentence, but I cannot search for the second one.
Possible Solution
I try to match some words with
telega-msg-match-p
:But I don't know how to get as many messages as possible and display the matching messages just like
filter
. Is it possible to implement atelega-chatbuf-filter-search
using regex or some other way to achieve better searching of Chinese characters? Sorry, I have limited knowledge of Emacs Lisp.