separate bindkey (ctrl-shift-F) to zoom full selection

This commit is contained in:
Stefan Frederik 2022-01-08 00:00:13 +01:00
parent 0eaf884039
commit ef7effab69
3 changed files with 10 additions and 4 deletions

View File

@ -133,6 +133,7 @@ shift 'F' Flip
alt 'f' Flip objects around their anchor points
ctrl 'f' Find/select by substring or regexp
- 'f' Full zoom
shift+ctrl 'F' Zoom full selected elements
shift 'G' Double snap factor
- 'g' Half snap factor
ctrl 'g' Set snap factor

View File

@ -2083,16 +2083,20 @@ int callback(const char *winpath, int event, int mx, int my, KeySym key,
tcleval("property_search");
break;
}
if(key=='F' && state == (ShiftMask | ControlMask) ) /* full zoom selection */
{
if(xctx->ui_state == SELECTION) {
zoom_full(1, 1, 3, 0.97);
}
break;
}
if(key=='f' && state == 0 ) /* full zoom */
{
if(waves_selected(event, key, state, button)) {
waves_callback(event, mx, my, key, button, aux, state);
break;
}
if(xctx->ui_state == SELECTION)
zoom_full(1, 1, 3, 0.97);
else
zoom_full(1, 0, 1, 0.97);
zoom_full(1, 0, 1, 0.97);
break;
}
if((key=='z' && state==ControlMask)) /* zoom out */

View File

@ -92,6 +92,7 @@ shift 'F' Flip
alt 'f' Flip objects around their anchor points
ctrl 'f' Find/select by substring or regexp
- 'f' Full zoom
shift+ctrl 'F' Zoom full selected elements
shift 'G' Double snap factor
- 'g' Half snap factor
ctrl 'g' Set snap factor