Add a few keyboard shortcuts
This commit is contained in:
parent
7a4b5cd065
commit
035997750e
6
fastiv.c
6
fastiv.c
|
@ -130,9 +130,15 @@ static struct key_group help_keys_view[] = {
|
||||||
{}
|
{}
|
||||||
}},
|
}},
|
||||||
{"Configuration", (struct key[]) {
|
{"Configuration", (struct key[]) {
|
||||||
|
#ifdef HAVE_LCMS2
|
||||||
|
{"c", "Toggle color management"},
|
||||||
|
#endif
|
||||||
{"x", "Toggle scale to fit if larger"},
|
{"x", "Toggle scale to fit if larger"},
|
||||||
{"i", "Toggle smooth scaling"},
|
{"i", "Toggle smooth scaling"},
|
||||||
{"t", "Toggle transparency highlighting"},
|
{"t", "Toggle transparency highlighting"},
|
||||||
|
#ifdef HAVE_JPEG_QS
|
||||||
|
{"e", "Toggle low-quality JPEG enhancement"},
|
||||||
|
#endif
|
||||||
{}
|
{}
|
||||||
}},
|
}},
|
||||||
{"Control", (struct key[]) {
|
{"Control", (struct key[]) {
|
||||||
|
|
|
@ -1060,12 +1060,16 @@ fiv_view_key_press_event(GtkWidget *widget, GdkEventKey *event)
|
||||||
case GDK_KEY_h:
|
case GDK_KEY_h:
|
||||||
return set_scale_to_fit_height(self);
|
return set_scale_to_fit_height(self);
|
||||||
|
|
||||||
|
case GDK_KEY_c:
|
||||||
|
return command(self, FIV_VIEW_COMMAND_TOGGLE_CMS);
|
||||||
case GDK_KEY_x: // Inspired by gThumb, which has more such modes.
|
case GDK_KEY_x: // Inspired by gThumb, which has more such modes.
|
||||||
return command(self, FIV_VIEW_COMMAND_TOGGLE_SCALE_TO_FIT);
|
return command(self, FIV_VIEW_COMMAND_TOGGLE_SCALE_TO_FIT);
|
||||||
case GDK_KEY_i:
|
case GDK_KEY_i:
|
||||||
return command(self, FIV_VIEW_COMMAND_TOGGLE_FILTER);
|
return command(self, FIV_VIEW_COMMAND_TOGGLE_FILTER);
|
||||||
case GDK_KEY_t:
|
case GDK_KEY_t:
|
||||||
return command(self, FIV_VIEW_COMMAND_TOGGLE_CHECKERBOARD);
|
return command(self, FIV_VIEW_COMMAND_TOGGLE_CHECKERBOARD);
|
||||||
|
case GDK_KEY_e:
|
||||||
|
return command(self, FIV_VIEW_COMMAND_TOGGLE_ENHANCE);
|
||||||
|
|
||||||
case GDK_KEY_less:
|
case GDK_KEY_less:
|
||||||
return command(self, FIV_VIEW_COMMAND_ROTATE_LEFT);
|
return command(self, FIV_VIEW_COMMAND_ROTATE_LEFT);
|
||||||
|
|
Loading…
Reference in New Issue