getVerticalSize function

double getVerticalSize(
  1. double px
)

This method is used to set padding/margin (for the top and bottom side) & height of the screen or widget according to the Viewport height.

Implementation

double getVerticalSize(double px) {
  return ((px * height) / (FIGMA_DESIGN_HEIGHT - FIGMA_DESIGN_STATUS_BAR));
}