def zoom_out(self):
self.widget_canvas_image.delete("image")
self.image_photo = ImageTk.PhotoImage(self.image_open.resize(
(self.image_photo.width() - self.original_width, self.image_photo.height() - self.original_height)))
self.widget_canvas_image.configure(scrollregion=(self.check_scrollregion()))
self.widget_canvas_image.configure(width=self.check_size()[0], height=self.check_size()[1])
# self.drawn_image = self.widget_canvas_image.create_image(0, 0, anchor="nw", image=self.image_photo, tags="image")
self.zoom_current -= 1
# print(self.zoom_current)
self.zoom_width = self.image_photo.width()
self.zoom_height = self.image_photo.height()
self.draw_tiles()
self.draw_background()
self.check_zoom()
评论列表
文章目录