summaryrefslogtreecommitdiff
path: root/src/gui/gui-buffer.c
AgeCommit message (Collapse)Author
2017-01-01core: update copyright datesSébastien Helleu
2016-10-08core: fix integer overflow in calls to realloc (issue #809)Sébastien Helleu
2016-08-13core: fix NULL pointer derefence in case of memory error in ↵Sébastien Helleu
gui_buffer_input_buffer_init()
2016-03-21core: add pointer in some callbacks (closes #406)Sébastien Helleu
This pointer is the first argument received by callbacks, and the existing argument "data" is now automatically freed by WeeChat when the object containing the callback is removed. With this new pointer, the linked list of callbacks in scripts has been removed. This will improve speed of scripts (using a lot of hooks), reduce memory used by scripts and reduce time to unload scripts. Following functions are affected in the C API: * exec_on_files * config_new * config_new_section * config_new_option * hook_command * hook_command_run * hook_timer * hook_fd * hook_process * hook_process_hashtable * hook_connect * hook_print * hook_signal * hook_hsignal * hook_config * hook_completion * hook_modifier * hook_info * hook_info_hashtable * hook_infolist * hook_hdata * hook_focus * unhook_all_plugin * buffer_new * bar_item_new * upgrade_new * upgrade_read
2016-02-28core: check that pointers received in arguments are not NULL in buffers and ↵Sébastien Helleu
windows functions
2016-01-01core: update copyright datesSébastien Helleu
2015-06-22core: fix bar item "scroll" after /buffer clear (closes #448)Sébastien Helleu
2015-01-01core: update copyright datesSébastien Helleu
2014-09-24core: fix crash on buffer close when option weechat.look.hotlist_remove is ↵Sébastien Helleu
set to "merged" (closes #199)
2014-05-24relay: fix crash when closing relay buffers (closes #57, closes #78)Sébastien Helleu
A flag "closing" has been added in buffers. It is set to 1 when the buffer is closing, and then no more printf is allowed in the buffer (a message printed on relay buffer was causing a crash when it is closed).
2014-05-24api: add argument "flags" in function hdata_new_listSébastien Helleu
2014-04-05core: add option -all for command /buffer hide|unhideSébastien Helleu
2014-04-05core: add hidden buffers, add options hide/unhide in command /bufferSébastien Helleu
2014-04-03core: add "hotlist" in completion of command "/buffer set"Sébastien Helleu
2014-04-03api: allow value "-1" for property "hotlist" in function buffer_set (to ↵Sébastien Helleu
remove a buffer from hotlist)
2014-04-01core: add default key alt-'-' to toggle filters in current buffer (closes #17)Sébastien Helleu
2014-03-31core: add non-active merged buffers with activity in hotlist (if another ↵Sébastien Helleu
merged buffer is zoomed) (task #12845) There was a bug with "num_displayed" in buffers when they are merged and that one buffer is zoomed: now the num_displayed is > 0 for the active buffer, and it is set to 0 for all merged non-active buffers (only in case of zoom). A variable "zoomed" has been added in buffers to know if a buffer with this number is zoomed or not (possibly another buffer).
2014-03-25core: add buffer property "clear"Sebastien Helleu
2014-03-11api: add support of case insensitive search and search by buffer full name ↵Sebastien Helleu
in function buffer_search (bug #34318)
2014-02-10api: add integer return code for functions hook_{signal|hsignal}_sendSebastien Helleu
2014-02-07core: fix apply of layout when buffers that are not in layout are before ↵Sebastien Helleu
some buffers in layout Now when a layout is applied, the buffers in layout are inserted/sorted first in the new list. Then the other buffers (not in layout) are added after this loop, and then they are added after all layout buffers.
2014-02-06core: fix hotlist problems after apply of a layout (bug #41481)Sebastien Helleu
This commit fixes a problem when computing the value of "num_displayed" in all buffers. For merged buffers (with same number), the num_displayed of each merged buffer must be incremented (and not only the current active buffer).
2014-01-01core: update copyright datesSebastien Helleu
2013-12-31core: fix unneeded shift of buffer numbers when a buffer with layout is ↵Sebastien Helleu
created and merged
2013-12-15core: add buffer property "highlight_tags_restrict", rename option ↵Sebastien Helleu
irc.look.highlight_tags to irc.look.highlight_tags_restrict The buffer property "highlight_tags" is renamed to "highlight_tags_restrict". New behavior for buffer property "highlight_tags": force highlight on tags. Option irc.look.highlight_tags is renamed to irc.look.highlight_tags_restrict.
2013-12-14core: add logical "and" between tags in filters, weechat.look.highlight_tags ↵Sebastien Helleu
and buffer property "highlight_tags" The logical "and" is made with the separator "+". Example: "irc_notice+nick_toto,nick_test" will match a notice from nick "toto" or any message from nick "test".
2013-12-11Merge branch 'buffer-auto-renumber'Sebastien Helleu
2013-12-08core: add signal "buffer_cleared"Sebastien Helleu
2013-12-07core: use first gap for new buffer only if the buffer has no layout numberSebastien Helleu
2013-12-07core: add option weechat.look.buffer_positionSebastien Helleu
The value of option can be: - "end": buffer is added after the end of list (number = last number + 1) - "first_gap": buffer is added at first number available in the list (after the end of list if no number is available)
2013-12-04core: add buffer property "day_change" to hide messages for the day change ↵Sebastien Helleu
in specific buffers
2013-12-01core: fix random crash when closing a bufferSebastien Helleu
The problem happened because we used a pointer to a "struct t_gui_buffer_visited" for the switch to another buffer, when the buffer is closed. This is executed in all windows displaying the buffer, but on each switch to buffer, the visited buffers are updated and therefore the address can change. The pointer becomes invalid, and WeeChat still uses it on next windows for the buffer switch. It happened rarely because the visited buffer is freed and allocated immediately after, so the address is often the same in memory. Thanks to silverd for the tests on OS X to track the problem.
2013-11-30core: add limits for buffers (max 10000 buffers opened, number of a buffer: ↵Sebastien Helleu
between 1 and INT_MAX - 10000)
2013-11-30core: fix crash when moving buffer with only one buffer (core buffer)Sebastien Helleu
2013-11-30core: add variable "gui_buffers_count", use it in bar item "buffer_count"Sebastien Helleu
Now the bar item "buffer_count" displays the number of opened buffers (each merged buffer counts 1).
2013-11-30core: add option weechat.look.buffer_auto_renumberSebastien Helleu
New option: weechat.look.buffer_auto_renumber, boolean which is on by default, so the behavior is the same: no gap is allowed in numbers, they start at number 1 and they are auto-renumbered after each command like /buffer move, /buffer merge, ... A new option "renumber" has been added in command /buffer, to renumber a range of buffers (or all). Changes when the option weechat.look.buffer_auto_renumber is off: - command "/buffer move": - the current number will be left free for use, and the target number can be any number >= 1 (possibly higher than the current last buffer number) - the value can be "-" (which moves the buffer to number 1) or "+" (which moves the buffer to the end, ie last number + 1) - command "/buffer swap": - now the buffers are swapped in the list without being "moved" - comand "/buffer [+/-]N": - it is now working with gaps in buffer numbers - command "/buffer merge": - it can now merge a group of merged buffers into another buffer (or buffers merged themselves) - layout can restore buffer numbers with gaps in numbers
2013-11-28core: revert check of layout when switching to a buffer using value "auto" ↵Sebastien Helleu
in buffer_set This reverts commits 14cf7bd20fb3f00b18343464c175a0c4e3556149 and 262dff4b87ebf14a11fe83899fe168bc5a72ffe6. The initial fix was for a problem with irc autojoin and layout: the current window has not appropriate buffer (as defined in layout) if it is not the latest channel in "autojoin" option. So the way to fix this problem is to set the value of option irc.look.buffer_switch_autojoin to off.
2013-10-27core: fix auto-apply of window layout in current window when option ↵Sebastien Helleu
irc.look.buffer_switch_autojoin is on
2013-08-17core: add search of regular expression in buffer, don't reset search type on ↵Sebastien Helleu
a new search, select where to search (messages/prefixes) Key changed in search context: - ctrl+"r": switch search type: string/regex New keys in search context: - alt+"c": case (in)sensitive search - tab: search in messages/prefixes/both
2013-08-10core: optimize the removal of lines in buffers (a lot faster to clear/close ↵Sebastien Helleu
buffers with lot of lines) The update of variables "buffer_max_length" and "prefix_max_length" in struct t_gui_lines is now delayed and made during the main refresh (in main loop). For a buffer with 50K lines, it is up to 3300 times faster to clear/close it. For a buffer with 4096 lines (default limit), it is up to 120 times faster.
2013-04-18api: add property "completion_freeze" for function buffer_set: do not stop ↵Sebastien Helleu
completion when command line is updated
2013-03-17core: fix refresh of item "completion" (bug #38214) (patch from Nils Görs)Sebastien Helleu
The item is now cleared after any action that is changing content of command line and after switch of buffer.
2013-03-17core: fix typos in many comments and some stringsSebastien Helleu
2013-03-17core: add support of multiple layouts (task #11274)Sebastien Helleu
2013-03-03core: add count for groups, nicks, and total in nicklistSebastien Helleu
2013-02-07core: fix structures before buffer data when a buffer is closedSebastien Helleu
This was causing a bug in relay plugin (weechat protocol): when a buffer was closed, local variables were removed after buffer name, and when signal is sent to client, the buffer name was wrong (already freed).
2013-01-26core: use size of 32 for hashtables (instead of 4, 8 or 16)Sebastien Helleu
A size of 32 will use a little more memory but will reduce collisions in key hashs, and then length of linked lists inside hash structure (faster search in hashtable).
2013-01-01core: update copyright datesSebastien Helleu
2012-12-15core: move comments with description of C file to top of filesSebastien Helleu
2012-12-13core: reformat comments for functionsSebastien Helleu