The width / height of the window drawn: a host's (from resize), or of the window's own, as it is now.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(WindowProxy), | intent(in) | :: | self |
real(wp) function aspect_ratio(self) class(WindowProxy), intent(in) :: self integer(c_int) :: width, height aspect_ratio = real(self%width_, wp) / real(self%height_, wp) if (self%hosted .or. .not. c_associated(self%viewer_)) return if (vkf_viewer_size(self%viewer_, width, height) /= 0) return if (width > 0 .and. height > 0) aspect_ratio = real(width, wp) / real(height, wp) end function aspect_ratio