summaryrefslogtreecommitdiff
path: root/gui/glabel.c
diff options
context:
space:
mode:
authorWerner Almesberger <werner@almesberger.net>2016-08-22 06:41:03 -0300
committerWerner Almesberger <werner@almesberger.net>2016-08-22 06:41:03 -0300
commit86bbde6852de4406e080337042b697fa58e50f30 (patch)
tree71f26135c5ccc5bd477eb883480ab4bc6bac37e0 /gui/glabel.c
parent8e572113b8289a6d5b66f66e0b2e77af8d71874b (diff)
downloadeeshow-86bbde6852de4406e080337042b697fa58e50f30.tar.gz
eeshow-86bbde6852de4406e080337042b697fa58e50f30.tar.bz2
eeshow-86bbde6852de4406e080337042b697fa58e50f30.zip
eeshow/gui/: change zoom system to use float; reduce step from 2 to 2^(1/3)
Diffstat (limited to 'gui/glabel.c')
-rw-r--r--gui/glabel.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gui/glabel.c b/gui/glabel.c
index 8d7586b..fba5e04 100644
--- a/gui/glabel.c
+++ b/gui/glabel.c
@@ -49,8 +49,8 @@ static void eeschema_coord(const struct gui_ctx *ctx,
GtkAllocation alloc;
gtk_widget_get_allocation(ctx->da, &alloc);
- *rx = ((x - ctx->x) >> ctx->zoom) + alloc.width / 2;
- *ry = ((y - ctx->y) >> ctx->zoom) + alloc.height / 2;
+ *rx = ((x - ctx->x) * ctx->scale) + alloc.width / 2;
+ *ry = ((y - ctx->y) * ctx->scale) + alloc.height / 2;
}