Use zoom steps instead of hard-coding levels (#92)

Co-authored-by: NRK <nrk@disroot.org>
Co-authored-by: Berke Kocaoğlu <berke.kocaoglu@metu.edu.tr>
This commit is contained in:
Lu Xu
2021-09-25 08:10:29 +03:00
committed by NRK
parent 696f68753f
commit a2339e70fd
4 changed files with 22 additions and 63 deletions

View File

@ -39,6 +39,9 @@
#ifndef MAX
#define MAX(a,b) ((a) > (b) ? (a) : (b))
#endif
#ifndef ABS
#define ABS(a) ((a) > 0 ? (a) : -(a))
#endif
#define ARRLEN(a) (sizeof(a) / sizeof((a)[0]))
@ -246,9 +249,8 @@ bool img_load(img_t*, const fileinfo_t*);
CLEANUP void img_close(img_t*, bool);
void img_render(img_t*);
bool img_fit_win(img_t*, scalemode_t);
bool img_zoom(img_t*, float);
bool img_zoom_in(img_t*);
bool img_zoom_out(img_t*);
bool img_zoom(img_t*, int);
bool img_zoom_to(img_t*, float);
bool img_pos(img_t*, float, float);
bool img_move(img_t*, float, float);
bool img_pan(img_t*, direction_t, int);