canvas_scale_global()

The window size is defined as

  • window_size = image_size * global_scale

  • a = b * c

  • which is equal to

  • a/b = (b * c)/b

  • a/b = c (simplified)

  • So window_width / image_size = global scale

  • Then the question becomes how to set it relative to other elements.

  • (That's what the extra little number is for)

  • Note that "_setting" is the automatic or user set number,

  • where as with out that suffix it's the "internal" system used value.

  • Context here is that it's not a "zoom".

  • magic_nav_spacer is rough space between actual pane size and padding on either side of image. The goal of calculation is to make it relative to left and right panel