I am making a program where pictures are displayed to the user. Some of these pictures are, however, too long and run off the canvas. The canvas is a set size(width=600, height=150). I am wondering if there is anything to make sure the longer pictures do not exceed this width and are shrunk down when they do so they fit.
The images are in .gif format.
I have tried using subsample() and zoom() but these seem to shrink the images even when they already fit on the canvas making them too small.
subsample and zoom are the only way to resize images with the tkinter PhotoImage objects. Whey you call them, they will always shrink or grow the image. It is up to you to determine which one to call, and what arguments that will give you the closest approximation to the desired size.
Is there a way, without PIL, to have an images put onto a Canvas to always be resized to fit in?