aboutsummaryrefslogtreecommitdiff
path: root/commands.h
Commit message (Collapse)AuthorAgeFilesLines
* make thumbnail bindings configureable via config.h (#167)N-R-K2022-01-101-0/+6
| | | | | | | | | | | | | | this allows for configuring thumbnail mode mouse bindings similar to image mode bindings. however we can't put the thumbnails bindings into the existing buttons[] array due to fallthrough. For example M3 would switch mode and then end up selecting an image. which is why thumbnail bindings have been put into it's own array `buttons_tns[]` and `buttons[]` has been renamed to `buttons_img[]` for consistency. Closes: https://github.com/nsxiv/nsxiv/issues/131
* fix -Wstrict-prototype warningNRK2022-01-061-1/+1
| | | | looks like i missed one in ff88908
* specify func argument and related cleanup (#183)N-R-K2021-12-191-34/+34
| | | | | | | | | | | | * specifies the function argument type in commands.h compared to leaving it unspecified. all the functions in cmd_t must have arg_t as it's argument. * changes to commands.h will now trigger a rebuild - this restores old behavior prior to 12efa0e * cg_quit now uses it's argument as exit status * DestroyNotify invokes cg_quit rather than calling exit directly. * Explicitly pass EXIT_SUCCESS to cgquit in keybinding Co-authored-by: Berke Kocaoğlu <berke.kocaoglu@metu.edu.tr>
* Add ability to bind arbitrary functions.Arthur Williams2021-10-131-0/+83
| | | | | | | | | | | | | | | | | | | | | | | Before all the predated commands where kept in an array and their indexes were used in bindings. This meant that users couldn't add their own functions from the config file. Now key/mouse bindings have been changed to to store the function ptr (wrapped in a cmd_t struct to also store the mode) directly instead. General cleanup done in this commit: Defined `MODE_ALL` instead of using magic number. For example, suppose one had bindings like: { 0, XK_q, g_quit, None }, { ShitMask, XK_q, {quit_err}, None } { ControlMask, XK_q, {quit_err, .mode=MODE_IMAGE}, None } The existing binding `q` has been left unchanged and is defined the same way. However, the new hypothetical binding `Shift-q` can be used to call the custom function quit_err in any mode (default). `Ctrl-q` on the other hand will be called only on image mode. Closes #50
* One header file for type definitions and function declarationsBert Münnich2017-10-161-59/+0
|
* Simplified command argumentsBert Münnich2015-01-111-1/+1
|
* Revised command structure and key and mouse button mappingsBert Münnich2014-07-231-39/+18
|
* Use a checkerboard background for alpha layer; fixes issue #138Bert Münnich2014-04-061-1/+1
|
* Removed fit-win-to-img commandBert Münnich2014-02-041-1/+0
|
* Merged pull request #129Bert Münnich2014-01-311-0/+1
|
* Fixed handling of overloaded key mappingsBert Münnich2014-01-081-31/+37
| | | | | Issue described here: https://bbs.archlinux.org/viewtopic.php?pid=1117294#p1117294
* Slideshow mode is back, in a simplified versionBert Münnich2014-01-041-1/+2
|
* Moved external shell commands into exec/key-handler scriptBert Münnich2014-01-021-2/+0
| | | | | Gets called on all unset key mappings. Arguments are: key combo and current file. Thanks to Francesco Orsenigo (xarvh) for the idea.
* Proper support for Ctrl/Shift/Alt modifiers in key & mouse mappingsBert Münnich2014-01-021-3/+2
|
* Merge remote-tracking branch 'baskerville/reverse-marks'Bert Münnich2013-11-141-0/+1
|\
| * Add command to reverse marked imagesBastien Dejean2013-11-141-0/+1
| |
* | Add support for changing the gamma valueAndrás Mohari2013-11-131-0/+1
|/
* Added file marks; fixes issue #94Bert Münnich2013-08-101-0/+2
| | | | | | | | - Command it_toggle_image_mark (bound to 'm') toggles mark of current image - Command it_navigate_marked (bound to 'N'/'P') can be used to go to the next/previous marked image - When option -o is given, all marked files get printed
* Updated/corrected license headerBert Münnich2013-02-081-13/+13
|
* Removed old definitions from commands.hhut2013-01-271-3/+0
|
* New command: i_alternate, go to last image, issue #65Bert Münnich2012-08-161-0/+1
|
* Simplified & sped up reloading of all thumbnailsBert Münnich2012-05-131-1/+1
|
* Added a command to refresh the thumbnailsbaskerville2012-05-081-0/+1
|
* Added horizontal and vertical flip commandsbaskerville2012-05-061-0/+1
|
* Added it_toggle_bar command; default mapping: XK_bBert Münnich2012-02-151-0/+1
|
* Already in the year 2012Bert Münnich2012-02-151-1/+1
|
* Added screen-wise scrolling for thumbnail modeBert Münnich2011-10-271-3/+3
|
* Added i_reset_slideshow: set slideshow delay to number prefixBert Münnich2011-10-161-0/+1
|
* Added i_set_zoom command: set zoom to number prefixBert Münnich2011-10-161-0/+1
|
* Added support for number prefix for commandsBert Münnich2011-10-161-1/+1
|
* Updated contact informationBert Münnich2011-10-141-1/+1
|
* Added own bool typeBert2011-09-111-28/+30
|
* Added slideshow supportBert2011-09-101-0/+2
|
* Made i(t)_toggle_alpha command work in thumbnail mode tooBert2011-09-041-1/+1
|
* Reformated license headerBert2011-09-031-11/+11
|
* Added command to toggle gif animationsBert2011-08-191-0/+1
|
* Added support for multi-frame imagesBert2011-08-191-0/+1
|
* Put event handling back into main.c; events -> commandsBert2011-08-191-0/+63
|
* Merged commands.h into config.hBert2011-04-141-13/+0
|
* Use ctrl for ext cmds, disable them in config.hBert2011-03-091-5/+5
|
* Use "/bin/sh -c" for external commandsBert2011-03-031-22/+6
|
* Slightly refactored commands.hBert2011-03-011-8/+13
|
* Support for external commands like mogrify & jpegtranBert2011-03-011-0/+24