问题
Is it normal that Tkinter's Canvas' create_text
's font size doesn't change when I change the Canvas' scale with canvas.scale
?
I thought that, as it is a high level GUI management system, I wouldn't have to resize manually the text done with create_text
after a zooming. Isn't this strange, or am I wrong ?
回答1:
It's normal, even if not entirely what you want. The scale
method just changes the coordinate lists, but text
items only have one of those so they just get (optionally) translated.
This also applies to image
and bitmap
items. And features of other items like the line width; they're not scaled.
来源:https://stackoverflow.com/questions/20689760/tkinter-canvas-create-text-and-zooming