Bert Münnich
93e2a757d4
Do not print could-not-open-warnings for files found by directory traversal
10 years ago
Bert Münnich
c33f2ad355
Corrected & refactored handling of window bar content...
...
Old snprintf calls could have overflowed the buffers.
10 years ago
Bert Münnich
8db3191f04
Fixed segfault on image removal with uninitialized thumbnails; fixes issue #177
10 years ago
Bert Münnich
ddd028eb3e
Unified file count variable for image & thumbnail mode
10 years ago
Bert Münnich
b2dbd2fed3
Changed image mark in thumbnail view to small rectangle
10 years ago
Bert Münnich
5fce009b73
Refactored main loop; properly fixes startup issue
10 years ago
Bert Münnich
c1e084357c
Fixed startup in thumbnail mode with floating window
10 years ago
Bert Münnich
eaa269b6cb
Revised thumbnail loading...
...
- Only load the thumbnails that are currently visible in the window
- Unload thumbnails that are leaving the visible area
- Much less memory needed, but scrolling is now slower
- This also unintentionally fixes issue #86
10 years ago
Bert Münnich
52e56c8924
Fixed segfault caused by image removal in thumbnail mode
10 years ago
Bert Münnich
2fbc21a205
Simplified img_frame_animate
10 years ago
Bert Münnich
f478385d59
Corrected i_alternate, fixes issue #171
10 years ago
Markus Elfring
0f6cb93a09
Bug #165 : Deletion of unnecessary null pointer checks
...
The function "free" performs input parameter validation.
http://pubs.opengroup.org/onlinepubs/9699919799/functions/free.html
It is therefore not needed to check a passed pointer before this function call.
A corresponding update suggestion was generated by the software "Coccinelle"
from the following semantic patch approach.
http://coccinelle.lip6.fr/
@Remove_unnecessary_pointer_checks1@
expression x;
@@
-if (x != \(0 \| NULL\))
free(x);
@Remove_unnecessary_pointer_checks2@
expression x;
@@
-if (x != \(0 \| NULL\)) {
free(x);
x = \(0 \| NULL\);
-}
@Remove_unnecessary_pointer_checks3@
expression a, b;
@@
-if (a != \(0 \| NULL\) && b != \(0 \| NULL\))
+if (a)
free(b);
@Remove_unnecessary_pointer_checks4@
expression a, b;
@@
-if (a != \(0 \| NULL\) && b != \(0 \| NULL\)) {
+if (a) {
free(b);
b = \(0 \| NULL\);
}
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
10 years ago
Bert Münnich
fe3a1e326f
Further simplified thumbnail marks
10 years ago
Bert Münnich
50652f63d9
Full redraw when removing files during thumbnail reloading; fixes issue #164
10 years ago
Bert Münnich
e49d38d6f9
Fixed wrong thumbnail-to-file mappings caused by file deletions
10 years ago
Bert Münnich
e267dc7793
Pass marked files to external key handler in thumbnail mode; fixes issue #135
10 years ago
Bert Münnich
284be74927
Count number of marked files
10 years ago
Bert Münnich
5b01c15176
Unified file index variable for image & thumbnail mode
10 years ago
Bert Münnich
61f61cae5f
Generalized thumbnail loading, allows easier reloading of thumbnails later on
10 years ago
Bert Münnich
bb6721549b
Overhauled window drawing, yet again; fixes issue #155
...
- Buffer for window content is bigger than the window, minimizes artifacts
when window is resized
- Back to using XSetWindowBackgroundPixmap() instead of XCopyArea(),
no need to handle exposure events; X server can show gray background directly
after resize event before sxiv redraws the window contents
10 years ago
Bert Münnich
9c92de8584
Added support for multiple commands per key/button mapping; elegant fix for issue #150
10 years ago
Bert Münnich
06164c29b7
Revised command structure and key and mouse button mappings
10 years ago
Bert Münnich
5d0679b855
Show key handler status in bar while it is running
10 years ago
Miroslav Koskar
4cbc7346ff
Timeout initial redraw
11 years ago
Bert Münnich
6d7acac3d1
Use real path of all files internally, requires _XOPEN_SOURCE>=500, fixes issue #137
11 years ago
Bert Münnich
653a6ee83b
Warn once when external key combo is used and key-handler not installed
11 years ago
Bert Münnich
e2fa49ecfe
Unified X atom initialization
11 years ago
Bert Münnich
f6510b0a04
Merged pull request #129
11 years ago
András Mohari
54d7b7f20f
Use a prefix key to execute the key handler
...
The default prefix key is C-x, and can be changed in config.def.h. The
first key pressed after the prefix key will be passed the external key
handler, unless the key is Escape, which is used to cancel the prefix.
11 years ago
Bert Münnich
ed69b483ed
Double click on thumbnail to open image
11 years ago
Bert Münnich
304fd382db
Adhere to XDG Base Directory Specification; fixes issue #124
11 years ago
Bert Münnich
48954a163a
Allow config.h to use multimedia keys (XF86_XK_*); fixes issue #123
11 years ago
Bert Münnich
e82397db15
Fixed handling of overloaded key mappings
...
Issue described here:
https://bbs.archlinux.org/viewtopic.php?pid=1117294#p1117294
11 years ago
Bert Münnich
9632dd88b9
Fixup for 9574150
11 years ago
Bert Münnich
9574150f2d
Check file modification time after key handler
11 years ago
Bert Münnich
cd34aa2a6b
Fixed slideshow delay corruption after GIF animation
11 years ago
Bert Münnich
6a0fa2507c
Slideshow mode is back, in a simplified version
11 years ago
Bert Münnich
f2e0c492bd
Moved external shell commands into exec/key-handler script
...
Gets called on all unset key mappings. Arguments are: key combo and
current file. Thanks to Francesco Orsenigo (xarvh) for the idea.
11 years ago
Bert Münnich
b2eae528ed
Proper support for Ctrl/Shift/Alt modifiers in key & mouse mappings
11 years ago
Bastien Dejean
4780ec5463
Close info file descriptor after reading
11 years ago
Bert Münnich
cc479ca5ac
Fixed segfault when removing first image from file list, fixes issue #112
11 years ago
Bert Münnich
50f9ad14de
Refactored remote changes
11 years ago
Bert Münnich
2737fc8b81
Merge remote-tracking branch 'ariand/gamma'
11 years ago
Bert Münnich
38bc23405d
Highlight edges of marked images in thumbnail mode
11 years ago
András Mohari
0353e6eea2
Add support for changing the gamma value
11 years ago
Bert Münnich
450c1ed9b5
Fixed inconsistencies in navigation when removing invalid files
11 years ago
Bert Münnich
7d878bd16d
Added file marks; fixes issue #94
...
- 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
11 years ago
Bert Münnich
98972e98f9
Fixed segfault caused by FD_ISSET() on negative fd
...
Reported by Kris Siwiec
12 years ago
Bert Münnich
6f05e77728
New options: -[io], read/write files from/to stdin/out
...
Fixes issue #84
12 years ago
Bert Münnich
825c52c33f
Made bar fields more distinguishable
12 years ago
Bert Münnich
38ecea3b4d
Polished info script execution
12 years ago
Bert Münnich
30802cec0f
Spawn info script & update bar contents only when needed
12 years ago
Bert Münnich
f3298400e6
Spawn and read from info script without blocking
12 years ago
Bert Münnich
bf41012493
Merge remote-tracking branch '4z3/set-user-specified-sizehints' into sizehints
...
Conflicts:
window.c
12 years ago
Bert Münnich
08ae25da22
Refactored function definitions to use dangling brace
12 years ago
Bert Münnich
6d3bbc6d5e
Updated/corrected license header
12 years ago
tv
3f25b907bd
When using -g hint the WM that we've got user specified geometry
...
Without this some window managers (e.g. fvwm) will ignore the initial
window position and place it according to it's own rules.
12 years ago
muennich
d6a475e4b1
Simplified status bar, filled by user script
12 years ago
Bert Münnich
cd929eabfe
Fixed issue #73
12 years ago
muennich
5106472d8b
Fixed issue #72
12 years ago
Bert Münnich
0155223a1a
Merge branch 'newdraw'
12 years ago
Bert Münnich
1ae06ffd09
Next try to fix issue #71
12 years ago
Bert Münnich
4a5d5d26aa
Overhauled window drawing
...
- Draw onto pixmap as before, but use the same size for the pixmap as
for the window, allocate new pixmap after configure requests
- Use XCopyArea() instead of XSetWindowBackgroundPixmap(), which now
requires handling of Expose events
12 years ago
Bert Münnich
fd519ffc40
Disregard obsolete events, fixed issue #64
12 years ago
Bert Münnich
f2a3d73212
New command: i_alternate, go to last image, issue #65
12 years ago
Bert Münnich
d7ff54bb6e
Optimized redraw timeout after window resize for tiling window managers; related to issue #44
13 years ago
Bert Münnich
751ebb3b29
Fixed issue #39 : missing include of <sys/select.h>
13 years ago
Bert Münnich
ed2c9f7caa
Display full name in info bar, if there is enough space
13 years ago
Bert Münnich
a329615c68
Show info message in bar while loading thumbnails
13 years ago
Bert Münnich
d407dd65d5
Already in the year 2012
13 years ago
Bert Münnich
b752d5c594
Added symbol BAR_SEPARATOR
13 years ago
Bert Münnich
b8458271fb
Added text bar on bottom of window
13 years ago
Bert Münnich
8fc7cb73b3
Nicer window title
13 years ago
Bert Münnich
c3c95ab218
Removed slideshow support
13 years ago
Bert Münnich
71a7940d74
Better fix for issue #25
13 years ago
Bert Münnich
1cdbeb972a
Added screen-wise scrolling for thumbnail mode
13 years ago
Bert Münnich
867940ea85
Pan by pixel count, if number prefix given
13 years ago
Bert Münnich
dc727b8dce
Added support for number prefix for commands
13 years ago
Bert Münnich
36177fb180
Updated contact information
13 years ago
Bert Münnich
4383a651c7
Strictly adhere to ANSI-C standard
13 years ago
Bert Münnich
a09b20c5e6
Use void for empty argument lists
13 years ago
Bert Münnich
8dcf682de9
Made all conditionals more precise
13 years ago
Bert Münnich
22d4e991d5
Transformed function macros in util.h to inline functions
13 years ago
Bert Münnich
d08408e942
Make use of EXIT_* macros (2)
13 years ago
rck
3a81af41ac
make use of EXIT_ macros
13 years ago
Bert Münnich
515e410451
Use win_t member in img_t & tns_t instead of parameters
13 years ago
Bert
b2a2a62b7b
Added own bool type
13 years ago
Bert
510512714d
Added slideshow support
13 years ago
Bert
6e575b0f72
Strict conformance to IEEE Std 1003.1-2001
13 years ago
Bert
8f34b7e95c
Load as much of a corrupted gif file as possible
13 years ago
Bert
711494ad36
Avoid conflicting macros
13 years ago
Bert
2bbdd2f5b9
Fixed title-update in thumb mode
13 years ago
Bert
d585b86354
Reformated license header
13 years ago
Bert
c2320a2f49
Fixed remove_file()
13 years ago
Bert
a7a849761f
Simplified cursor resetting
13 years ago
Bert
abb5feeb78
Corrected timeout handling
13 years ago
Bert
dcd04e526d
Corrected thumbnail loading and timeout handling
13 years ago
Bert
1e84773276
Data driven timeout handling
13 years ago
Bert
bb577d274d
Added command to toggle gif animations
13 years ago
Bert
8b3ae5027e
Added support for gif animation
13 years ago
Bert
79bd86defb
Refactored img_load_gif()
...
- Corrected handling of transparency settings for individual frames
- Corrected handling of different frame dimensions & offsets
13 years ago
Bert
86a6f00112
Added support for multi-frame images
13 years ago
Bert
1d749382f0
Put event handling back into main.c; events -> commands
13 years ago
Bert
1d7849efc1
Added force parameter to tns_load() to disregard cache
13 years ago
Bert
421f012022
Renamed application modes
13 years ago
Bert
8763f6930f
Corrected FSF address in license headers
13 years ago
Bert
ff013dd009
Revised handling of file names & paths
13 years ago
Bert
b8ff1677b1
Major code refactoring
...
- Configurable key and mouse mappings in config.h
- Put event handling code from main.c into events.[ch]
13 years ago
Bert
a271e16744
Reduced usage of preprocessor macros
13 years ago
Bert
dde2d9d023
Support XK_KP_{Add,Subtract} for zooming
13 years ago
Bert
bd87ae9346
All timeouts in milliseconds
13 years ago
Bert
f52603b31a
Small refactoring
13 years ago
Bert
a6100373c1
New mappings: ctrl-[hjkl], pan image one window width/height
14 years ago
Bert
ea23115af4
Use getline instead of readline
14 years ago
Bert
2252a0148d
New option: -n, start at given picture
14 years ago
Bert
00e6cd2bd1
Show image dimension in window title
14 years ago
Bert
485e6c863a
H/J/K/L mappings to pan to edges
14 years ago
Bert
d54e64faae
Fixed background color for non-EWMH-compliant WMs
14 years ago
Bert
ba293b09df
Center zoomed area
14 years ago
Bert
548b383f0b
Fixed mouse cursor
14 years ago
Bert
c58307ba38
Merged commands.h into config.h
14 years ago
Bert
5f8201110e
Slightly changed introductory text
14 years ago
Bert
d15264ea32
Remove invalid images when loading them; refactorings
14 years ago
Bert
5cb6d12a94
Refactored main.c
14 years ago
Bert
bac610ddc4
Merge branch 'tcache'
...
Conflicts:
main.c
14 years ago
Bert
dc54981a68
New option: -C, clean thumbnail cache
14 years ago
Bert
a90bd1c833
Refactored recursive directory util functions
14 years ago
Bert
e9996882cb
Moved read_dir_rec into util.c
14 years ago
Bert
b2f1b997ed
Disable support for external commands by default
14 years ago
Bert
d7c1f0a85d
Removed escape key mapping
14 years ago
Bert
fa81707540
New key mapping: D, remove image from file list
14 years ago
Bert
facd7e3b42
New option: -a, do not filter out unsupported files
14 years ago
Bert
426edfb349
Readded file-type check at startup
14 years ago
Bert
8d4e3a57ab
Do not check file-type at startup
14 years ago
Bert
87a9828417
Filename cosmetics
14 years ago
Bert
3672c0bc63
Toggle image transparency with A-key
14 years ago
Bert
a82c45431b
Use ctrl for ext cmds, disable them in config.h
14 years ago
Bert
00d4b0f7cf
Use "/bin/sh -c" for external commands
14 years ago
Bert
c05fd44bdd
Support for external commands like mogrify & jpegtran
14 years ago
Bert
955c39a5c5
Shorter typedefs
14 years ago
Bert
9b24f82404
Small refactorings, removed over-ambitious todo
14 years ago
Bert
7334bdfa51
Revert "Save rotated png-files with S-key"
...
This reverts commit 090ee5405b
.
14 years ago
Bert
090ee5405b
Save rotated png-files with S-key
14 years ago
Bert
c5f6b2c0d5
Sort directory entries when using -r
14 years ago
Bert
dafe7eac74
Refactored imlib context handling
14 years ago
Bert
4cfb8a204a
Correct timeout handling, more complex
14 years ago
Bert
88b5c5f2e4
Fixed cursor hiding after switching to thumb mode
14 years ago
Bert
fde9f5bf85
Hide cursor on redraw or after 1.5s mouse inactivity
14 years ago
Bert
ea80c73520
Fixed title for thumbnail mode
14 years ago
Bert
f2b8a75f6c
Always support thumbs; start thumb-mode with single -t
14 years ago