summaryrefslogtreecommitdiff
path: root/app.go (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Show connected messages in the current buffer as welldelthas2022-12-231-1/+1
|
* Backoff from 0 seconds to 1 minute on reconnectdelthas2022-12-231-21/+23
| | | | Resets on successful connection.
* Show MOTD in server buffer onlydelthas2022-12-231-1/+9
| | | | Also hide MOTD start and end messages.
* Add a 10s timeout to connect + TLS handshakedelthas2022-11-041-6/+11
|
* Clear highlights from MARKREAD when only NotifyNone lines are leftdelthas2022-10-181-19/+24
| | | | | | | | | | | | | | | | | Previously, we did not clear buffers highlight statuses on MARKREAD if there was any unread line after it. This meant that if we received a plain message, than a join message, and some other device sent us a read marker for the plain message, we would still highlight the buffer. But we should not: a join message should not highlight the buffer. This is a recurrent use case because some clients do not display join mesasges and therefore do not send read markers for it. This updates the logic to actually store the notify level (in the line) and uses it to reset the highlight status when only NotifyNone messages (or no messages) are left.
* Prevnet highlighting on notices, drop unknown CTCPdelthas2022-10-041-9/+23
|
* Make the last opened channel visible in the horizontal listdelthas2022-09-141-0/+1
| | | | | | | | When starting senpai, we jump to the last opened buffer. Offset the horizontal target list to make the buffer visible, as if scrolled to with CTRL+N. Fixes: https://todo.sr.ht/~taiite/senpai/100
* Highlight only on word boundariesdelthas2022-08-191-2/+29
| | | | | | | | | | | | | | | | | | | Preivously, we highlighted the user for any message that contained the nick, even in the middle of a word. Now, we only send a highlight if the user was mentioned in a single word, by detecting word boundaries around the mention of the user. For example, considering user "foo": Previously, we would highlight on "foo" and "foolish". Now, we highlight only on "foo". This was inspired/copied from soju's handling [1]. [1]: https://git.sr.ht/~emersion/soju/tree/5e56cc30c538eb88c21cce732e2e357e80098164/item/irc.go#L473 Fixes: https://todo.sr.ht/~taiite/senpai/97
* Revert to using base colors by default, making extended configurabledelthas2022-08-151-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In a previous commit, the color scheme for displaying nicks was changed to use more colors (30 rather than 14), using extended colors from the 256 colors set. The issue with this is that most terminal emulators customize the colors of the first 16 colors to make them more readable (eg, a terminal emulator with a light theme will make colors darker, and one with a dark theme will make colors lighter). So the 14 colors used before were usually not the default color codes from the original xterm/X11 spec, but specific colors chosen by the terminal emulator to be particularly readable. In a way, changing the behavior to use colors from the 256 colors set, which is usually not overriden, made them much less readable. Which is why we need a configuration option for this. I conversatively chose to make the default color scheme the previous one, with only the base 16 colors. The 256 colors scheme can be enable by adding to the configuration file: colors { nicks extended }
* Color nicks in the member list the same as in the timelinedelthas2022-08-101-4/+4
| | | | | | | | Also, change the color scheme to use more colors. Now 30 instead of 15, and with the consistent color codes offered by the extended XTerm 256 color scheme. Fixes: https://todo.sr.ht/~taiite/senpai/90
* Add support for soju.im/bouncer-networks-notifydelthas2022-08-101-7/+51
| | | | | | This enables dynamic discovery of new and deleted networks. Fixes: https://todo.sr.ht/~taiite/senpai/71
* Add a config option to beep on highlightKirill Chibisov2022-08-011-0/+4
| | | | | This will allow to bring user attention when you are getting highlighted.
* Add pane-widths { text } to limit the max line widthdelthas2022-07-251-0/+1
| | | | Fixes: https://todo.sr.ht/~taiite/senpai/87
* Scroll to the channel when changing the horizontal channelNomeji2022-07-221-0/+2
| | | | | | | | | | | | | Previously, when running CTRL+N or CTRL+P to go to the next or previous channel, with the horizontal channel mode, the selected channel could appear offscreen. This patch ensures that we scroll just enough to make the newly selected chan visible. Thanks to Nomeji for his hard work on this. Adapted slightly to refactor existing code to use the newly created width computation routine.
* Fix horizontal channel buffer clicks on negative positionsdelthas2022-05-101-1/+1
|
* Fetch the chat history of the last opened buffer firstdelthas2022-04-201-8/+23
| | | | This will slightly speed up startup time.
* Fix default highlight command path not being usedGalen Abell2022-04-201-3/+3
|
* Add a config option for unread buffer text colorTim Culverhouse2022-04-201-0/+3
| | | | | | | This patch adds the ability to set a config option for changing the foreground text color of unread buffers (This was refactored slightly by delthas.)
* Enable clicking on a horizontal buffer to switch to itdelthas2022-04-201-0/+6
| | | | | | | This is inspired by a patch from mooff. This keeps the same click & drag behavior as for the vertical channel list.
* Scroll horizontal channel list with the mouse wheeldelthas2022-04-201-3/+3
| | | | | | This is inspired by a patch by mooff. The horizontal channel list can now be scrolled with the mouse wheel.
* Show/hide the channel & member list with F7/F8delthas2022-04-201-11/+17
| | | | | | | This patch is inspired and modified from a patch by mooff. Also this switches the default configuration to *display* the channel & member list by default.
* Delete word on Alt+Backspacedelthas2022-04-151-1/+6
| | | | This is a standard shortcut.
* Batch events by time period rather than by fixed sizedelthas2022-04-151-19/+27
| | | | | | | | | | Previously, we would render every 64 events (at most). Now that we have many more events, with history & read, batch events by period rather than static size. Waiting up to 200ms before refreshing is a good compromise between responsiveness and performance.
* Only send READ for messages received from a channeldelthas2022-04-151-0/+9
| | | | i.e. don't enter an infinite loop when printing disconnection errors :-)
* Implement SEARCHdelthas2022-04-121-0/+16
| | | | | | Also refactor ui/ to support overlays, temporary anonmyous buffers. See: https://github.com/emersion/soju/pull/39
* Add a 15s keepalive to connectionsdelthas2022-04-081-0/+5
| | | | | My DSL line is awful atm, I'd like to know ASAP when I'm disconnected so that I don't write paragraphs into the void.
* Drain the events channel when closingdelthas2022-02-261-0/+5
| | | | | This avoids rare cases where we try to send messages to the event channel, but it is full and blocks the Close routine.
* Add support for the ALL_PROXY, NO_PROXY environment variablesdelthas2022-02-181-1/+3
| | | | | | | | | | | | This adds support for SOCKS5 proxy support through standard environement variables. To connect to the SOCKS5 proxy at host:port with credentials user:pass, run: export ALL_PROXY=socks5://user:pass@host:port Co-authored-by: the-y <the-y@riseup.net>
* Enable clicking on channel members to open a query with themdelthas2022-02-131-2/+25
|
* Make CTRL+C alternatively clear the input and set '/quit' in itdelthas2022-02-131-0/+2
|
* Fix event collapsingdelthas2022-02-111-72/+92
|
* Add support for the soju.im/read capability and READ commanddelthas2022-02-111-0/+10
| | | | See: https://github.com/emersion/soju/blob/c7f0634ec8ee94425547b159bc36705582151012/doc/read.md
* ui: add commands completionKalyan Sriram2022-02-101-0/+1
|
* MONITOR user with whom we have an open bufferdelthas2022-02-101-0/+13
|
* Take NICKs into account when reducing join/part linesHubert Hirtz2021-12-091-8/+12
| | | | | | | | | | | | | | | | So that 1/ redundant events are removed even if people change nick in the mean time and 2/ events that are actually not redundant are not removed, e.g. +val val->jw +dan dan->val -val should be reduced to +val val->jw instead of val->jw +dan dan->val
* Allow selecting buffers with Alt+{1..9}Leon Henrik Plickat2021-12-061-0/+2
|
* Bump history batch limitsHubert Hirtz2021-12-061-5/+5
| | | | | | Initial history request: 200 -> 500 Infinite scroll request: 100 -> 200 Reconnect request: 200 -> 1000
* Do not mark the buffer as unread on MODEHubert Hirtz2021-12-061-1/+1
|
* Merge redundant eventsHubert Hirtz2021-12-061-1/+87
|
* Use second precision for bound computationHubert Hirtz2021-11-291-8/+10
| | | | | Should solve duplicates on servers that don't store message stamps with the full millisecond precision offered by the time tag (e.g. soju)
* Fetch history for queriesHubert Hirtz2021-11-291-2/+6
|
* Merge MODE messagesdelthas2021-11-241-1/+2
| | | | | Also, fix an issue where mode strings only displayed the first parameter.
* Add support for draft/event-playbackdelthas2021-11-241-76/+110
| | | | | | | | | | - Refactor formatting lines into a function - Store event times in the event - Refactor merging lines into a function - Always merge lines from the history, now that we will add mergeable lines with CHATHISTORY Successfully tested locally.
* Show the current channel topic at the top of the timelinedelthas2021-11-241-1/+3
|
* config: replace YAML with scfg config formatKalyan Sriram2021-11-231-17/+31
| | | | | | | | | | | | | | | | This patch replaces the YAML configuration format with scfg (https://git.sr.ht/~emersion/scfg). Additionally, a few things about configuration are cleaned up: * abbreviated names are expanded (addr -> address, nick -> nickname) * negative bools switched to positive (no-tls -> tls) * independent column widths are grouped under the "pane-width" directive * implementation of default configuration values is improved * password-cmd is executed directly (with scfg field parsing) instead of with "sh -c". * on-highlight is now a file, $XDG_CONFIG_HOME/senpai/highlight by default, which can be changed with the on-highlight-path directive
* Add support for CHATHISTORY TARGETSdelthas2021-11-191-0/+34
|
* Handle tcell error events by closingdelthas2021-11-181-2/+8
| | | | | This is namely useful when the terminal is closing: these events are sent, and we should close when that happens (instead of panicking).
* Add support for user buffersdelthas2021-11-161-6/+7
|
* Fix part-ing a channel with duplicate name in other networksdelthas2021-11-161-1/+1
| | | | | If there are multiple channels with the same name in several networks, we should part from the one from the correct network.
* Allow App.Close() and App.Run() to be run concurrentlyHubert Hirtz2021-11-161-13/+21
|