about summary refs log tree commit diff stats
path: root/src/ui/inputwin.c
Commit message (Collapse)AuthorAgeFilesLines
* Let slashguard ignore quoted messagesMichael Vetter2022-07-041-1/+2
| | | | | | This let's us whole `/me` messages and other messages starting with `>`. Fix https://github.com/profanity-im/profanity/issues/1732
* Show return symbol for embedded newlinesPaul Fertser2022-04-121-1/+24
| | | | | | | | | When editing multi-line messages or comments everything past the first newline becomes invisible. This patch fixes it by substituting a Unicode symbol for "return" instead of printing the newline as is. On locales where it's not available single backslash is used instead.
* Handle input win redisplay via Readline hookPaul Fertser2022-04-121-3/+10
| | | | | Allow Readline to control when to redisplay the input line. This makes text entered via /editor visible after editor is closed.
* Show Readline prompt in input windowPaul Fertser2022-04-121-0/+7
| | | | | When doing an interactive search the prompt is needed to show the current state of the search to avoid confusion.
* Merge pull request #1664 from paulfertser/tab-completion-cleanupMichael Vetter2022-04-011-41/+11
|\ | | | | Tab completion code simplification
| * Tab completion code simplificationPaul Fertser2022-03-301-41/+11
| | | | | | | | | | | | Factor out common code for Tab and Shift-Tab in a separate function. No functional change.
* | Merge pull request #1667 from paulfertser/fix-screen-arrows-bindingsMichael Vetter2022-04-011-0/+3
|\ \ | | | | | | Add Alt/Ctrl-arrows combinations for GNU Screen
| * | Add Alt/Ctrl-arrows combinations for GNU ScreenPaul Fertser2022-03-301-0/+3
| |/ | | | | | | | | | | GNU Screen terminal emulator is modelled after VT100, its key bindings for "application mode" (which profanity enables on startup) can be seen with this: info screen "Input Translation".
* / Make all existing input functions bindable from configPaul Fertser2022-03-301-0/+5
|/
* Input window: handle invalid multibytePaul Fertser2022-03-291-0/+4
| | | | | | | | | | The current code enters an infinite loop if the input string happens to get an invalid utf-8 sequence somehow. For me it was reproducible by running profanity in a Screen session and pressing Alt-т (cyrillic letter). Fix it the way borrowed from 0501e49623f68aa39508e4e622924c1dd8147588 where mbrlen is used for the same purposes.
* Add quote autocompletion for previous messagesMarcoPolo-PasTonMolo2022-03-211-1/+26
| | | | | | | | | | Fixes https://github.com/profanity-im/profanity/issues/1649 Type `>` then press tab or shift tab to autocomplete previous messages, then type your reply and send message. Newlines are replaced with newline followed by `> `. A newline is added at the end so that the user can immediately type a message without manually adding a new line.
* Merge pull request #1646 from MarcoPolo-PasTonMolo/fix/nick-autocompleteMichael Vetter2022-03-211-12/+19
|\ | | | | Fix not autocompleting nicks with '/'
| * Reverse priority for nick vs cmd autocompleteMarcoPolo-PasTonMolo2022-03-211-12/+15
| |
| * Fix not autocompleting nicks with '/'MarcoPolo-PasTonMolo2022-03-031-4/+8
| | | | | | | | | | | | | | Remove check for '/' at the beginning of the line before autocompleting and make it fallback to command autocompletion if no nicks found. Fixes https://github.com/profanity-im/profanity/issues/1474
* | Alt+e is already bound, use Alt+cSteffen Jaeckel2022-03-131-1/+1
| | | | | | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* | Move get_message_from_editor to appropriate file and change its keybindingMarcoPolo-PasTonMolo2022-03-031-4/+4
| |
* | Add hotkey for sending readline text to editorMarcoPolo-PasTonMolo2022-03-031-0/+26
|/
* Format code correctlyMichael Vetter2021-10-051-4/+5
|
* Change attentionflag shortcut to alt+vMichael Vetter2021-08-311-1/+1
| | | | | | alt+f is the default readline shortcut for forward one word. Regards https://github.com/profanity-im/profanity/issues/1580
* Attention flag message ( enabled, disabled)DebXWoody2021-05-291-1/+6
| | | | | When the user enables or disabled the attention flag, a message will be displayed in the chat window.
* Attention flag - Implemented Alt+mDebXWoody2021-05-291-11/+5
|
* Attention flag for groupchatsDebXWoody2021-05-291-2/+10
| | | | Attention flag for groupchat and display the windows via "/wins attention"
* Attention flag for chat windowsDebXWoody2021-05-291-0/+22
| | | | | | | User is able to toggle a flag for chat windows. This flag should be used to mark the window for "Attention". Use Ctrl+f to mark the window.
* Set input window size to max window sizekaffeekanne2020-12-111-2/+2
| | | | Input window size was one cell off, therefore terminal themes with background color set were rendered incorrectly, fixes #1458
* Since the string from strerror should never be modified, use const.Philipp Klaus Krause2020-10-141-1/+1
|
* Avoid passing NULL pointers to curses functions.nia2020-09-041-1/+3
| | | | | | | | This allows profanity to work without segfaulting from NULL pointer dereferences when used with NetBSD libcurses. Basic functionality was tested, there may be more NULL pointer issues hiding.
* Basic support for building on NetBSD.nia2020-09-041-0/+2
| | | | | | - Add NetBSD as a recognized platform without -ldl. - Allow building with NetBSD libcurses instead of ncurses. - Portability to NetBSD sh - use POSIX '=' instead of '=='.
* Apply coding styleMichael Vetter2020-07-071-45/+44
|
* Revert "Apply coding style"Michael Vetter2020-07-071-57/+58
| | | | | | This reverts commit 9b55f2dec0ea27a9ce4856e303425e12f866cea2. Sorting the includes creates some problems.
* Apply coding styleMichael Vetter2020-07-071-58/+57
| | | | Regards https://github.com/profanity-im/profanity/issues/1396
* Define POSIX macro to have strdupMichael Vetter2020-06-121-2/+2
| | | | | | | | | | | | | | https://github.com/profanity-im/profanity/commit/98c38dc6d6d29333c63f80327774f094610d8602 sets C99 as standard. strdup() is not part of C99. For now set `-D_POSIX_C_SOURCE=200809L` macro to have strdup() in C99. Using `gnu99` instead would be another option. We should take more care to use glib functions whenever possible. Regards https://github.com/profanity-im/profanity/issues/1357
* inp_readline() Correct slashguard featureMichael Vetter2020-04-211-4/+6
| | | | Protect against invalid reads by checking the length.
* Make _inp_edited() more robustDmitry Podgorny2020-04-191-1/+8
|
* Add slashguard featureMichael Vetter2020-03-181-0/+7
| | | | | New command `/slashguard` tries to protect against typing ` /quit` by not allowing a slash in the first 4 characters.
* Add vim modelineMichael Vetter2019-11-131-0/+1
|
* Fix add_history usage in down arrow handlerMichael Vetter2019-11-051-4/+1
| | | | | | | | | | | | | | [Programming with GNU History](http://www.math.utah.edu/docs/info/hist_2.html) mentions using_history(). Chet, maintainer of readline told me about it. (Thanks Chet!) Seems like we need to call this so that the history offset is at the right end of the list. I assume it's called in the linehandler automatically. Fix https://github.com/profanity-im/profanity/issues/200
* Store current input line in historyMichael Vetter2019-11-051-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Regards https://github.com/profanity-im/profanity/issues/200 This doesn't work yet. And I have no idea why. Weird behaviour: - start profanity - type 'ASDF' - ctrl+arrow down -> text vanishes (like intended) - arrow up -> nothing happens (intended is that the last history item [ASDF] appears) - type 'ABC' - press enter - arrow up -> ABC appears - enter - type 'UUU' - ctrl+arrow down - type 'ZZZ' - enter - arrow up - ZZZ appears - arrow up - UUU appears So in the latter case we added to history and deleted from the input line and then immediately entered new text and pressed enter, to add this to the history too. When we do this the not sent text succesfully was stored in history.
* Bind key to switch to next active windowMichael Vetter2019-09-301-0/+14
| | | | | | alt-a brings one to the next window with unread messages. Regards https://github.com/profanity-im/profanity/issues/1114
* Define keybindings to switch to up to 20 windowsMichael Vetter2019-09-301-0/+100
| | | | | | | | | | alt-2 brings one ot the window. irssi supports alt + 1234567890qwertyuio to easily switch to 20 windows instead of just ten. Hardcode this too. Regards https://github.com/profanity-im/profanity/issues/1114
* Update copyright to include 2019Michael Vetter2019-01-221-1/+1
|
* Add prof_win_close (#1017)twardziejszy2019-01-101-0/+11
|
* WIP add self prefs for statusbarJames Booth2018-03-101-2/+2
|
* Clear autocompletes on line editsJames Booth2018-02-091-3/+19
|
* Update copyrightJames Booth2018-01-211-1/+1
|
* Allow previous autocompletion with shift tabJames Booth2017-04-011-2/+49
|
* Update CopyrightJames Booth2017-01-281-1/+1
|
* Allow vertical positioning of all windowsJames Booth2016-09-231-10/+4
|
* Add /inputwin top|bottom commandJames Booth2016-09-191-1/+8
| | | | closes #853
* Move all filepath handling to files.cJames Booth2016-07-241-1/+1
|
* Move xgd functionsJames Booth2016-07-241-1/+2
|