ScalingMethod

Since: BlackBerry 10.0.0

#include <bb/cascades/ScalingMethod>

A set of methods that specify how an image should be scaled.

Scaling methods are used when displaying an image within an ImageView.

  • AspectFit: fits the image inside assigned area while keeping the correct aspect ratio.

  • AspectFill: stretches and crops the image to fill the entire assigned area while keeping the aspect ratio.

  • Fill: stretches the image to fit assigned area.

  • None: scale is unmodified and content is either cropped or centered.

The assigned area of the ImageView is determined by its size parameters.


Overview

Public Types Index

enum Type

AspectFit = 0, AspectFill = 1, Fill = 2, None = 3

Public Types

Type

Definitions of the scaling methods.

Since:

BlackBerry 10.0.0

AspectFit = 0

Fit the image inside assigned area while keeping the correct aspect ratio.

Since:

BlackBerry 10.0.0

AspectFill = 1

Stretch and crop the image to fill the entire assigned area while keeping the aspect ratio.

Since:

BlackBerry 10.0.0

Fill = 2

Stretch the image to fit assigned area.

Since:

BlackBerry 10.0.0

None = 3

Scale is 1.0f and content is either cropped or centered.

Since:

BlackBerry 10.0.0

Last modified: 2014-03-13

comments powered by Disqus