Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
feh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
derf
feh
Commits
d03fc61a
Commit
d03fc61a
authored
7 years ago
by
Birte Kristina Friesel
Browse files
Options
Downloads
Patches
Plain Diff
Add toggle_auto_zoom key binding, defaulting to Z
Closes #218
parent
81656da7
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
man/feh.pre
+4
-0
4 additions, 0 deletions
man/feh.pre
src/keyevents.c
+5
-0
5 additions, 0 deletions
src/keyevents.c
src/options.h
+1
-0
1 addition, 0 deletions
src/options.h
with
10 additions
and
0 deletions
man/feh.pre
+
4
−
0
View file @
d03fc61a
...
...
@@ -1376,6 +1376,10 @@ Close current window
.
Jump to a random position in the current filelist
.
.It Z Bq toggle_auto_zoom
.
Toggle auto-zoom.
.
.It \&[, \&] Bq prev_dir, next_dir
.
Jump to the first image of the previous or next sequence of images sharing
...
...
This diff is collapsed.
Click to expand it.
src/keyevents.c
+
5
−
0
View file @
d03fc61a
...
...
@@ -185,6 +185,7 @@ void init_keyevents(void) {
feh_set_kb
(
"render"
,
0
,
XK_KP_Begin
,
0
,
XK_R
,
0
,
0
);
feh_set_kb
(
"toggle_actions"
,
0
,
XK_a
,
0
,
0
,
0
,
0
);
feh_set_kb
(
"toggle_aliasing"
,
0
,
XK_A
,
0
,
0
,
0
,
0
);
feh_set_kb
(
"toggle_auto_zoom"
,
0
,
XK_Z
,
0
,
0
,
0
,
0
);
#ifdef HAVE_LIBEXIF
feh_set_kb
(
"toggle_exif"
,
0
,
XK_e
,
0
,
0
,
0
,
0
);
#endif
...
...
@@ -637,6 +638,10 @@ void feh_event_handle_generic(winwidget winwid, unsigned int state, KeySym keysy
winwid
->
force_aliasing
=
!
winwid
->
force_aliasing
;
winwidget_render_image
(
winwid
,
0
,
0
);
}
else
if
(
feh_is_kp
(
EVENT_toggle_auto_zoom
,
state
,
keysym
,
button
))
{
opt
.
zoom_mode
=
(
opt
.
zoom_mode
==
0
?
ZOOM_MODE_MAX
:
0
);
winwidget_rerender_all
(
1
);
}
else
if
(
feh_is_kp
(
EVENT_toggle_filenames
,
state
,
keysym
,
button
))
{
opt
.
draw_filename
=
!
opt
.
draw_filename
;
winwidget_rerender_all
(
0
);
...
...
This diff is collapsed.
Click to expand it.
src/options.h
+
1
−
0
View file @
d03fc61a
...
...
@@ -189,6 +189,7 @@ enum key_action {
EVENT_render
,
EVENT_toggle_actions
,
EVENT_toggle_aliasing
,
EVENT_toggle_auto_zoom
,
#ifdef HAVE_LIBEXIF
EVENT_toggle_exif
,
#endif
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment