Class VisualView

    Definition

    Namespace:
    Tizen.NUI.BaseComponents
    Assembly:
    Tizen.NUI.dll

    A visual view control if a user adds any visual to it.

    public class VisualView : CustomView, INotifyPropertyChanged, IDisposable
    Inheritance
    object
    Tizen.NUI.Binding.BindableObject
    Tizen.NUI.Binding.Element
    BaseHandle
    Animatable
    Container
    View
    ViewWrapper
    CustomView
    VisualView
    Implements
    System.ComponentModel.INotifyPropertyChanged
    System.IDisposable
    Examples

    Example:

    VisualView _visualView = new VisualView();
    ImageVisualMap imageVisualMap1 = new ImageVisualMap();
    imageVisualMap1.URL = "./NUISample/res/images/image-1.jpg";
    imageVisualMap1.VisualSize = new Vector2( 300.0f, 300.0f );
    imageVisualMap1.Offset = new Vector2( 50.0f, 50.0f );
    imageVisualMap1.OffsetSizeMode = new Vector4( 1.0f, 1.0f, 1.0f, 1.0f );
    imageVisualMap1.Origin = AlignType.TOP_BEGIN;
    imageVisualMap1.AnchorPoint = AlignType.TOP_BEGIN;
    _visualView.AddVisual("imageVisual1", imageVisualMap1);

    Constructors

    View Source

    VisualView()

    Constructor.

    Declaration
    public VisualView()

    Properties

    View Source

    NumberOfVisuals

    Gets the total number of visuals which are added by users.

    Declaration
    public int NumberOfVisuals { get; }
    Property Value
    Type Description
    int

    Methods

    View Source

    AddVisual(string, VisualMap)

    Adds or updates a visual to visual view.

    Declaration
    public void AddVisual(string visualName, VisualMap visualMap)
    Parameters
    Type Name Description
    string visualName

    The name of a visual to add. If a name is added to an existing visual name, the visual will be replaced.

    VisualMap visualMap

    The property map of a visual to create.

    View Source

    AnimateVisual(VisualMap, string, object, int, int, BuiltinFunctions?, object)

    Creates a visual animation (transition) with the input parameters.

    Declaration
    public Animation AnimateVisual(VisualMap target, string property, object destinationValue, int startTime, int endTime, AlphaFunction.BuiltinFunctions? alphaFunction = null, object initialValue = null)
    Parameters
    Type Name Description
    VisualMap target

    The visual map to animation.

    string property

    The property of visual to animation.

    object destinationValue

    The destination value of property after animation.

    int startTime

    The start time of visual animation.

    int endTime

    The end time of visual animation.

    AlphaFunction.BuiltinFunctions? alphaFunction

    The alpha function of visual animation.

    object initialValue

    The initial property value of visual animation.

    Returns
    Type Description
    Animation

    Animation instance

    View Source

    AnimateVisualAdd(VisualMap, string, object, int, int, BuiltinFunctions?, object)

    Adds a group visual animation (transition) map with the input parameters.

    Declaration
    public void AnimateVisualAdd(VisualMap target, string property, object destinationValue, int startTime, int endTime, AlphaFunction.BuiltinFunctions? alphaFunction = null, object initialValue = null)
    Parameters
    Type Name Description
    VisualMap target

    The visual map to animation.

    string property

    The property of visual to animation.

    object destinationValue

    The destination value of property after animation.

    int startTime

    The start time of visual animation.

    int endTime

    The end time of visual animation.

    AlphaFunction.BuiltinFunctions? alphaFunction

    The alpha function of visual animation.

    object initialValue

    The initial property value of visual animation.

    View Source

    AnimateVisualAddFinish()

    Finishes to add a visual animation (transition) map and creates a transition animation.

    Declaration
    public Animation AnimateVisualAddFinish()
    Returns
    Type Description
    Animation

    Animation instance.

    View Source

    OnInitialize()

    Overrides the parent method.

    Declaration
    public override void OnInitialize()
    Overrides
    CustomView.OnInitialize()
    View Source

    OnRelayout(Vector2, RelayoutContainer)

    Overrides the method of OnRelayout() for CustomView class.
    Called after the size negotiation has been finished for this control.
    The control is expected to assign this given size to itself or its children.
    Should be overridden by derived classes if they need to layout actors differently after certain operations like add or remove actors, resize, or after changing specific properties.

    Declaration
    public override void OnRelayout(Vector2 size, RelayoutContainer container)
    Parameters
    Type Name Description
    Vector2 size

    The allocated size.

    RelayoutContainer container

    The control should add actors to this container that it is not able to allocate a size for.

    Overrides
    CustomView.OnRelayout(Vector2, RelayoutContainer)
    Remarks

    As this function is called from inside the size negotiation algorithm, you cannot call RequestRelayout (the call would just be ignored).

    View Source

    RemoveAll()

    Removes all visuals of the visual view.

    Declaration
    public void RemoveAll()
    View Source

    RemoveVisual(string)

    Removes a visual by name.

    Declaration
    public void RemoveVisual(string visualName)
    Parameters
    Type Name Description
    string visualName

    The name of a visual to remove.

    View Source

    VisualAnimate(VisualAnimator)

    temporary fix to pass TCT.

    Declaration
    public Animation VisualAnimate(VisualAnimator visualMap)
    Parameters
    Type Name Description
    VisualAnimator visualMap
    Returns
    Type Description
    Animation

    Implements

    System.ComponentModel.INotifyPropertyChanged
    System.IDisposable
    • View Source
    Back to top Copyright © 2016-2024 Samsung
    Generated by DocFX