From 5b78966d21dd4b17a158cd90bc175378d63e62d6 Mon Sep 17 00:00:00 2001 From: Kevin Winata Date: Tue, 23 Apr 2024 14:29:40 +0700 Subject: [PATCH] [NUI] TextLabel BindableProperty refactor (#6094) --- .../src/public/BaseComponents/TextLabel.cs | 912 +++++++++++++++++++-- .../BaseComponents/TextLabelBindableProperty.cs | 415 ++++++---- 2 files changed, 1068 insertions(+), 259 deletions(-) diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs index 035f02d..7967f7c 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs @@ -82,7 +82,140 @@ namespace Tizen.NUI.BaseComponents } } - static TextLabel() { } + static TextLabel() + { + if (NUIApplication.IsUsingXaml) + { + TranslatableTextProperty = BindableProperty.Create(nameof(TranslatableText), typeof(string), typeof(TextLabel), string.Empty, + propertyChanged: SetInternalTranslatableTextProperty, defaultValueCreator: GetInternalTranslatableTextProperty); + + TextProperty = BindableProperty.Create(nameof(Text), typeof(string), typeof(TextLabel), string.Empty, + propertyChanged: SetInternalTextProperty, defaultValueCreator: GetInternalTextProperty); + + FontFamilyProperty = BindableProperty.Create(nameof(FontFamily), typeof(string), typeof(TextLabel), string.Empty, + propertyChanged: SetInternalFontFamilyProperty, defaultValueCreator: GetInternalFontFamilyProperty); + + FontStyleProperty = BindableProperty.Create(nameof(FontStyle), typeof(PropertyMap), typeof(TextLabel), null, + propertyChanged: SetInternalFontStyleProperty, defaultValueCreator: GetInternalFontStyleProperty); + + PointSizeProperty = BindableProperty.Create(nameof(PointSize), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalPointSizeProperty, defaultValueCreator: GetInternalPointSizeProperty); + + MultiLineProperty = BindableProperty.Create(nameof(MultiLine), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalMultiLineProperty, defaultValueCreator: GetInternalMultiLineProperty); + + HorizontalAlignmentProperty = BindableProperty.Create(nameof(HorizontalAlignment), typeof(HorizontalAlignment), typeof(TextLabel), HorizontalAlignment.Begin, + propertyChanged: SetInternalHorizontalAlignmentProperty, defaultValueCreator: GetInternalHorizontalAlignmentProperty); + + VerticalAlignmentProperty = BindableProperty.Create(nameof(VerticalAlignment), typeof(VerticalAlignment), typeof(TextLabel), VerticalAlignment.Bottom, + propertyChanged: SetInternalVerticalAlignmentProperty, defaultValueCreator: GetInternalVerticalAlignmentProperty); + + TextColorProperty = BindableProperty.Create(nameof(TextColor), typeof(Color), typeof(TextLabel), null, + propertyChanged: SetInternalTextColorProperty, defaultValueCreator: GetInternalTextColorProperty); + + AnchorColorProperty = BindableProperty.Create(nameof(TextLabel.AnchorColor), typeof(Color), typeof(TextLabel), null, + propertyChanged: SetInternalAnchorColorProperty, defaultValueCreator: GetInternalAnchorColorProperty); + + AnchorClickedColorProperty = BindableProperty.Create(nameof(TextLabel.AnchorClickedColor), typeof(Color), typeof(TextLabel), null, + propertyChanged: SetInternalAnchorClickedColorProperty, defaultValueCreator: GetInternalAnchorClickedColorProperty); + + RemoveFrontInsetProperty = BindableProperty.Create(nameof(RemoveFrontInset), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalRemoveFrontInsetProperty, defaultValueCreator: GetInternalRemoveFrontInsetProperty); + + RemoveBackInsetProperty = BindableProperty.Create(nameof(RemoveBackInset), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalRemoveBackInsetProperty, defaultValueCreator: GetInternalRemoveBackInsetProperty); + + EnableMarkupProperty = BindableProperty.Create(nameof(EnableMarkup), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalEnableMarkupProperty, defaultValueCreator: GetInternalEnableMarkupProperty); + + EnableAutoScrollProperty = BindableProperty.Create(nameof(EnableAutoScroll), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalEnableAutoScrollProperty, defaultValueCreator: GetInternalEnableAutoScrollProperty); + + AutoScrollSpeedProperty = BindableProperty.Create(nameof(AutoScrollSpeed), typeof(int), typeof(TextLabel), default(int), + propertyChanged: SetInternalAutoScrollSpeedProperty, defaultValueCreator: GetInternalAutoScrollSpeedProperty); + + AutoScrollLoopCountProperty = BindableProperty.Create(nameof(AutoScrollLoopCount), typeof(int), typeof(TextLabel), default(int), + propertyChanged: SetInternalAutoScrollLoopCountProperty, defaultValueCreator: GetInternalAutoScrollLoopCountProperty); + + AutoScrollGapProperty = BindableProperty.Create(nameof(AutoScrollGap), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalAutoScrollGapProperty, defaultValueCreator: GetInternalAutoScrollGapProperty); + + LineSpacingProperty = BindableProperty.Create(nameof(LineSpacing), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalLineSpacingProperty, defaultValueCreator: GetInternalLineSpacingProperty); + + RelativeLineHeightProperty = BindableProperty.Create(nameof(RelativeLineHeight), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalRelativeLineHeightProperty, defaultValueCreator: GetInternalRelativeLineHeightProperty); + + UnderlineProperty = BindableProperty.Create(nameof(Underline), typeof(PropertyMap), typeof(TextLabel), null, + propertyChanged: SetInternalUnderlineProperty, defaultValueCreator: GetInternalUnderlineProperty); + + ShadowProperty = BindableProperty.Create(nameof(Shadow), typeof(PropertyMap), typeof(TextLabel), null, + propertyChanged: SetInternalShadowProperty, defaultValueCreator: GetInternalShadowProperty); + + TextShadowProperty = BindableProperty.Create(nameof(TextShadow), typeof(TextShadow), typeof(TextLabel), null, + propertyChanged: SetInternalTextShadowProperty, defaultValueCreator: GetInternalTextShadowProperty); + + EmbossProperty = BindableProperty.Create(nameof(Emboss), typeof(string), typeof(TextLabel), string.Empty, + propertyChanged: SetInternalEmbossProperty, defaultValueCreator: GetInternalEmbossProperty); + + OutlineProperty = BindableProperty.Create(nameof(Outline), typeof(PropertyMap), typeof(TextLabel), null, + propertyChanged: SetInternalOutlineProperty, defaultValueCreator: GetInternalOutlineProperty); + + PixelSizeProperty = BindableProperty.Create(nameof(PixelSize), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalPixelSizeProperty, defaultValueCreator: GetInternalPixelSizeProperty); + + EllipsisProperty = BindableProperty.Create(nameof(Ellipsis), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalEllipsisProperty, defaultValueCreator: GetInternalEllipsisProperty); + + EllipsisPositionProperty = BindableProperty.Create(nameof(EllipsisPosition), typeof(EllipsisPosition), typeof(TextLabel), EllipsisPosition.End, + propertyChanged: SetInternalEllipsisPositionProperty, defaultValueCreator: GetInternalEllipsisPositionProperty); + + AutoScrollLoopDelayProperty = BindableProperty.Create(nameof(AutoScrollLoopDelay), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalAutoScrollLoopDelayProperty, defaultValueCreator: GetInternalAutoScrollLoopDelayProperty); + + AutoScrollStopModeProperty = BindableProperty.Create(nameof(AutoScrollStopMode), typeof(AutoScrollStopMode), typeof(TextLabel), AutoScrollStopMode.FinishLoop, + propertyChanged: SetInternalAutoScrollStopModeProperty, defaultValueCreator: GetInternalAutoScrollStopModeProperty); + + LineWrapModeProperty = BindableProperty.Create(nameof(LineWrapMode), typeof(LineWrapMode), typeof(TextLabel), LineWrapMode.Word, + propertyChanged: SetInternalLineWrapModeProperty, defaultValueCreator: GetInternalLineWrapModeProperty); + + VerticalLineAlignmentProperty = BindableProperty.Create(nameof(VerticalLineAlignment), typeof(VerticalLineAlignment), typeof(TextLabel), VerticalLineAlignment.Bottom, + propertyChanged: SetInternalVerticalLineAlignmentProperty, defaultValueCreator: GetInternalVerticalLineAlignmentProperty); + + MatchSystemLanguageDirectionProperty = BindableProperty.Create(nameof(MatchSystemLanguageDirection), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalMatchSystemLanguageDirectionProperty, defaultValueCreator: GetInternalMatchSystemLanguageDirectionProperty); + + CharacterSpacingProperty = BindableProperty.Create(nameof(CharacterSpacing), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalCharacterSpacingProperty, defaultValueCreator: GetInternalCharacterSpacingProperty); + + TextFitProperty = BindableProperty.Create(nameof(TextFit), typeof(PropertyMap), typeof(TextLabel), null, + propertyChanged: SetInternalTextFitProperty, defaultValueCreator: GetInternalTextFitProperty); + + MinLineSizeProperty = BindableProperty.Create(nameof(MinLineSize), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalMinLineSizeProperty, defaultValueCreator: GetInternalMinLineSizeProperty); + + FontSizeScaleProperty = BindableProperty.Create(nameof(FontSizeScale), typeof(float), typeof(TextLabel), default(float), + propertyChanged: SetInternalFontSizeScaleProperty, defaultValueCreator: GetInternalFontSizeScaleProperty); + + EnableFontSizeScaleProperty = BindableProperty.Create(nameof(EnableFontSizeScale), typeof(bool), typeof(TextLabel), default(bool), + propertyChanged: SetInternalEnableFontSizeScaleProperty, defaultValueCreator: GetInternalEnableFontSizeScaleProperty); + + ShadowOffsetProperty = BindableProperty.Create(nameof(ShadowOffset), typeof(Tizen.NUI.Vector2), typeof(TextLabel), null, + propertyChanged: SetInternalShadowOffsetProperty, defaultValueCreator: GetInternalShadowOffsetProperty); + + ShadowColorProperty = BindableProperty.Create(nameof(ShadowColor), typeof(Tizen.NUI.Vector4), typeof(TextLabel), null, + propertyChanged: SetInternalShadowColorProperty, defaultValueCreator: GetInternalShadowColorProperty); + + UnderlineEnabledProperty = BindableProperty.Create(nameof(UnderlineEnabled), typeof(bool), typeof(TextLabel), false, + propertyChanged: SetInternalUnderlineEnabledProperty, defaultValueCreator: GetInternalUnderlineEnabledProperty); + + UnderlineColorProperty = BindableProperty.Create(nameof(UnderlineColor), typeof(Tizen.NUI.Vector4), typeof(TextLabel), null, + propertyChanged: SetInternalUnderlineColorProperty, defaultValueCreator: GetInternalUnderlineColorProperty); + + UnderlineHeightProperty = BindableProperty.Create(nameof(UnderlineHeight), typeof(float), typeof(TextLabel), 0.0f, + propertyChanged: SetInternalUnderlineHeightProperty, defaultValueCreator: GetInternalUnderlineHeightProperty); + } + } static internal new void Preload() { @@ -196,11 +329,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (string)GetValue(TranslatableTextProperty); + if (NUIApplication.IsUsingXaml) + { + return (string)GetValue(TranslatableTextProperty); + } + else + { + return (string)GetInternalTranslatableTextProperty(this); + } } set { - SetValue(TranslatableTextProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(TranslatableTextProperty, value); + } + else + { + SetInternalTranslatableTextProperty(this, null, value); + } } } private string translatableText @@ -244,11 +391,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (string)GetValue(TextProperty); + if (NUIApplication.IsUsingXaml) + { + return (string)GetValue(TextProperty); + } + else + { + return (string)GetInternalTextProperty(this); + } } set { - SetValue(TextProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(TextProperty, value); + } + else + { + SetInternalTextProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -262,11 +423,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (string)GetValue(FontFamilyProperty); + if (NUIApplication.IsUsingXaml) + { + return (string)GetValue(FontFamilyProperty); + } + else + { + return (string)GetInternalFontFamilyProperty(this); + } } set { - SetValue(FontFamilyProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(FontFamilyProperty, value); + } + else + { + SetInternalFontFamilyProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -332,11 +507,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (PropertyMap)GetValue(FontStyleProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(FontStyleProperty); + } + else + { + return (PropertyMap)GetInternalFontStyleProperty(this); + } } set { - SetValue(FontStyleProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(FontStyleProperty, value); + } + else + { + SetInternalFontStyleProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -395,11 +584,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(PointSizeProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(PointSizeProperty); + } + else + { + return (float)GetInternalPointSizeProperty(this); + } } set { - SetValue(PointSizeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(PointSizeProperty, value); + } + else + { + SetInternalPointSizeProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -413,11 +616,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(MultiLineProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(MultiLineProperty); + } + else + { + return (bool)GetInternalMultiLineProperty(this); + } } set { - SetValue(MultiLineProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(MultiLineProperty, value); + } + else + { + SetInternalMultiLineProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -431,11 +648,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (HorizontalAlignment)GetValue(HorizontalAlignmentProperty); + if (NUIApplication.IsUsingXaml) + { + return (HorizontalAlignment)GetValue(HorizontalAlignmentProperty); + } + else + { + return (HorizontalAlignment)GetInternalHorizontalAlignmentProperty(this); + } } set { - SetValue(HorizontalAlignmentProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(HorizontalAlignmentProperty, value); + } + else + { + SetInternalHorizontalAlignmentProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -449,11 +680,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (VerticalAlignment)GetValue(VerticalAlignmentProperty); + if (NUIApplication.IsUsingXaml) + { + return (VerticalAlignment)GetValue(VerticalAlignmentProperty); + } + else + { + return (VerticalAlignment)GetInternalVerticalAlignmentProperty(this); + } } set { - SetValue(VerticalAlignmentProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(VerticalAlignmentProperty, value); + } + else + { + SetInternalVerticalAlignmentProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -472,12 +717,27 @@ namespace Tizen.NUI.BaseComponents { get { - Color temp = (Color)GetValue(TextColorProperty); + Color temp; + if (NUIApplication.IsUsingXaml) + { + temp = (Color)GetValue(TextColorProperty); + } + else + { + temp = (Color)GetInternalTextColorProperty(this); + } return new Color(OnTextColorChanged, temp.R, temp.G, temp.B, temp.A); } set { - SetValue(TextColorProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(TextColorProperty, value); + } + else + { + SetInternalTextColorProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -496,11 +756,25 @@ namespace Tizen.NUI.BaseComponents { get { - return GetValue(ShadowOffsetProperty) as Vector2; + if (NUIApplication.IsUsingXaml) + { + return GetValue(ShadowOffsetProperty) as Vector2; + } + else + { + return GetInternalShadowOffsetProperty(this) as Vector2; + } } set { - SetValue(ShadowOffsetProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ShadowOffsetProperty, value); + } + else + { + SetInternalShadowOffsetProperty(this, null, value); + } } } @@ -550,11 +824,25 @@ namespace Tizen.NUI.BaseComponents { get { - return GetValue(ShadowColorProperty) as Vector4; + if (NUIApplication.IsUsingXaml) + { + return GetValue(ShadowColorProperty) as Vector4; + } + else + { + return GetInternalShadowColorProperty(this) as Vector4; + } } set { - SetValue(ShadowColorProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ShadowColorProperty, value); + } + else + { + SetInternalShadowColorProperty(this, null, value); + } } } @@ -603,11 +891,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(UnderlineEnabledProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(UnderlineEnabledProperty); + } + else + { + return (bool)GetInternalUnderlineEnabledProperty(this); + } } set { - SetValue(UnderlineEnabledProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(UnderlineEnabledProperty, value); + } + else + { + SetInternalUnderlineEnabledProperty(this, null, value); + } } } @@ -652,11 +954,25 @@ namespace Tizen.NUI.BaseComponents { get { - return GetValue(UnderlineColorProperty) as Vector4; + if (NUIApplication.IsUsingXaml) + { + return GetValue(UnderlineColorProperty) as Vector4; + } + else + { + return GetInternalUnderlineColorProperty(this) as Vector4; + } } set { - SetValue(UnderlineColorProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(UnderlineColorProperty, value); + } + else + { + SetInternalUnderlineColorProperty(this, null, value); + } } } @@ -705,11 +1021,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(UnderlineHeightProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(UnderlineHeightProperty); + } + else + { + return (float)GetInternalUnderlineHeightProperty(this); + } } set { - SetValue(UnderlineHeightProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(UnderlineHeightProperty, value); + } + else + { + SetInternalUnderlineHeightProperty(this, null, value); + } } } @@ -749,11 +1079,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(EnableMarkupProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(EnableMarkupProperty); + } + else + { + return (bool)GetInternalEnableMarkupProperty(this); + } } set { - SetValue(EnableMarkupProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EnableMarkupProperty, value); + } + else + { + SetInternalEnableMarkupProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -767,11 +1111,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(EnableAutoScrollProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(EnableAutoScrollProperty); + } + else + { + return (bool)GetInternalEnableAutoScrollProperty(this); + } } set { - SetValue(EnableAutoScrollProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EnableAutoScrollProperty, value); + } + else + { + SetInternalEnableAutoScrollProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -785,11 +1143,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (int)GetValue(AutoScrollSpeedProperty); + if (NUIApplication.IsUsingXaml) + { + return (int)GetValue(AutoScrollSpeedProperty); + } + else + { + return (int)GetInternalAutoScrollSpeedProperty(this); + } } set { - SetValue(AutoScrollSpeedProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AutoScrollSpeedProperty, value); + } + else + { + SetInternalAutoScrollSpeedProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -803,11 +1175,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (int)GetValue(AutoScrollLoopCountProperty); + if (NUIApplication.IsUsingXaml) + { + return (int)GetValue(AutoScrollLoopCountProperty); + } + else + { + return (int)GetInternalAutoScrollLoopCountProperty(this); + } } set { - SetValue(AutoScrollLoopCountProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AutoScrollLoopCountProperty, value); + } + else + { + SetInternalAutoScrollLoopCountProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -821,11 +1207,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(AutoScrollGapProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(AutoScrollGapProperty); + } + else + { + return (float)GetInternalAutoScrollGapProperty(this); + } } set { - SetValue(AutoScrollGapProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AutoScrollGapProperty, value); + } + else + { + SetInternalAutoScrollGapProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -839,11 +1239,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(LineSpacingProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(LineSpacingProperty); + } + else + { + return (float)GetInternalLineSpacingProperty(this); + } } set { - SetValue(LineSpacingProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(LineSpacingProperty, value); + } + else + { + SetInternalLineSpacingProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -857,11 +1271,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(RelativeLineHeightProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(RelativeLineHeightProperty); + } + else + { + return (float)GetInternalRelativeLineHeightProperty(this); + } } set { - SetValue(RelativeLineHeightProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(RelativeLineHeightProperty, value); + } + else + { + SetInternalRelativeLineHeightProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -882,11 +1310,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (PropertyMap)GetValue(UnderlineProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(UnderlineProperty); + } + else + { + return (PropertyMap)GetInternalUnderlineProperty(this); + } } set { - SetValue(UnderlineProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(UnderlineProperty, value); + } + else + { + SetInternalUnderlineProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -951,11 +1393,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (PropertyMap)GetValue(ShadowProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(ShadowProperty); + } + else + { + return (PropertyMap)GetInternalShadowProperty(this); + } } set { - SetValue(ShadowProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ShadowProperty, value); + } + else + { + SetInternalShadowProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1013,11 +1469,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (TextShadow)GetValue(TextShadowProperty); + if (NUIApplication.IsUsingXaml) + { + return (TextShadow)GetValue(TextShadowProperty); + } + else + { + return (TextShadow)GetInternalTextShadowProperty(this); + } } set { - SetValue(TextShadowProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(TextShadowProperty, value); + } + else + { + SetInternalTextShadowProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1031,11 +1501,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (string)GetValue(EmbossProperty); + if (NUIApplication.IsUsingXaml) + { + return (string)GetValue(EmbossProperty); + } + else + { + return (string)GetInternalEmbossProperty(this); + } } set { - SetValue(EmbossProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EmbossProperty, value); + } + else + { + SetInternalEmbossProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1055,11 +1539,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (PropertyMap)GetValue(OutlineProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(OutlineProperty); + } + else + { + return (PropertyMap)GetInternalOutlineProperty(this); + } } set { - SetValue(OutlineProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(OutlineProperty, value); + } + else + { + SetInternalOutlineProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1164,11 +1662,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(PixelSizeProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(PixelSizeProperty); + } + else + { + return (float)GetInternalPixelSizeProperty(this); + } } set { - SetValue(PixelSizeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(PixelSizeProperty, value); + } + else + { + SetInternalPixelSizeProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1182,11 +1694,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(EllipsisProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(EllipsisProperty); + } + else + { + return (bool)GetInternalEllipsisProperty(this); + } } set { - SetValue(EllipsisProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EllipsisProperty, value); + } + else + { + SetInternalEllipsisProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1200,11 +1726,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (EllipsisPosition)GetValue(EllipsisPositionProperty); + if (NUIApplication.IsUsingXaml) + { + return (EllipsisPosition)GetValue(EllipsisPositionProperty); + } + else + { + return (EllipsisPosition)GetInternalEllipsisPositionProperty(this); + } } set { - SetValue(EllipsisPositionProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EllipsisPositionProperty, value); + } + else + { + SetInternalEllipsisPositionProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1218,11 +1758,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(AutoScrollLoopDelayProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(AutoScrollLoopDelayProperty); + } + else + { + return (float)GetInternalAutoScrollLoopDelayProperty(this); + } } set { - SetValue(AutoScrollLoopDelayProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AutoScrollLoopDelayProperty, value); + } + else + { + SetInternalAutoScrollLoopDelayProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1237,11 +1791,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (AutoScrollStopMode)GetValue(AutoScrollStopModeProperty); + if (NUIApplication.IsUsingXaml) + { + return (AutoScrollStopMode)GetValue(AutoScrollStopModeProperty); + } + else + { + return (AutoScrollStopMode)GetInternalAutoScrollStopModeProperty(this); + } } set { - SetValue(AutoScrollStopModeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AutoScrollStopModeProperty, value); + } + else + { + SetInternalAutoScrollStopModeProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1272,11 +1840,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (LineWrapMode)GetValue(LineWrapModeProperty); + if (NUIApplication.IsUsingXaml) + { + return (LineWrapMode)GetValue(LineWrapModeProperty); + } + else + { + return (LineWrapMode)GetInternalLineWrapModeProperty(this); + } } set { - SetValue(LineWrapModeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(LineWrapModeProperty, value); + } + else + { + SetInternalLineWrapModeProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1308,11 +1890,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (VerticalLineAlignment)GetValue(VerticalLineAlignmentProperty); + if (NUIApplication.IsUsingXaml) + { + return (VerticalLineAlignment)GetValue(VerticalLineAlignmentProperty); + } + else + { + return (VerticalLineAlignment)GetInternalVerticalLineAlignmentProperty(this); + } } set { - SetValue(VerticalLineAlignmentProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(VerticalLineAlignmentProperty, value); + } + else + { + SetInternalVerticalLineAlignmentProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1325,11 +1921,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(MatchSystemLanguageDirectionProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(MatchSystemLanguageDirectionProperty); + } + else + { + return (bool)GetInternalMatchSystemLanguageDirectionProperty(this); + } } set { - SetValue(MatchSystemLanguageDirectionProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(MatchSystemLanguageDirectionProperty, value); + } + else + { + SetInternalMatchSystemLanguageDirectionProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1352,11 +1962,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (PropertyMap)GetValue(TextFitProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(TextFitProperty); + } + else + { + return (PropertyMap)GetInternalTextFitProperty(this); + } } set { - SetValue(TextFitProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(TextFitProperty, value); + } + else + { + SetInternalTextFitProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1519,11 +2143,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(MinLineSizeProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(MinLineSizeProperty); + } + else + { + return (float)GetInternalMinLineSizeProperty(this); + } } set { - SetValue(MinLineSizeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(MinLineSizeProperty, value); + } + else + { + SetInternalMinLineSizeProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1540,11 +2178,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(CharacterSpacingProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(CharacterSpacingProperty); + } + else + { + return (float)GetInternalCharacterSpacingProperty(this); + } } set { - SetValue(CharacterSpacingProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(CharacterSpacingProperty, value); + } + else + { + SetInternalCharacterSpacingProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1563,12 +2215,27 @@ namespace Tizen.NUI.BaseComponents { get { - Color color = (Color)GetValue(AnchorColorProperty); + Color color; + if (NUIApplication.IsUsingXaml) + { + color = (Color)GetValue(AnchorColorProperty); + } + else + { + color = (Color)GetInternalAnchorColorProperty(this); + } return new Color(OnAnchorColorChanged, color.R, color.G, color.B, color.A); } set { - SetValue(AnchorColorProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AnchorColorProperty, value); + } + else + { + SetInternalAnchorColorProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1587,12 +2254,27 @@ namespace Tizen.NUI.BaseComponents { get { - Color color = (Color)GetValue(AnchorClickedColorProperty); + Color color; + if (NUIApplication.IsUsingXaml) + { + color = (Color)GetValue(AnchorClickedColorProperty); + } + else + { + color = (Color)GetInternalAnchorClickedColorProperty(this); + } return new Color(OnAnchorClickedColorChanged, color.R, color.G, color.B, color.A); } set { - SetValue(AnchorClickedColorProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AnchorClickedColorProperty, value); + } + else + { + SetInternalAnchorClickedColorProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1609,11 +2291,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(RemoveFrontInsetProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(RemoveFrontInsetProperty); + } + else + { + return (bool)GetInternalRemoveFrontInsetProperty(this); + } } set { - SetValue(RemoveFrontInsetProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(RemoveFrontInsetProperty, value); + } + else + { + SetInternalRemoveFrontInsetProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1630,11 +2326,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(RemoveBackInsetProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(RemoveBackInsetProperty); + } + else + { + return (bool)GetInternalRemoveBackInsetProperty(this); + } } set { - SetValue(RemoveBackInsetProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(RemoveBackInsetProperty, value); + } + else + { + SetInternalRemoveBackInsetProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1650,11 +2360,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (float)GetValue(FontSizeScaleProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(FontSizeScaleProperty); + } + else + { + return (float)GetInternalFontSizeScaleProperty(this); + } } set { - SetValue(FontSizeScaleProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(FontSizeScaleProperty, value); + } + else + { + SetInternalFontSizeScaleProperty(this, null, value); + } NotifyPropertyChanged(); } } @@ -1714,11 +2438,25 @@ namespace Tizen.NUI.BaseComponents { get { - return (bool)GetValue(EnableFontSizeScaleProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(EnableFontSizeScaleProperty); + } + else + { + return (bool)GetInternalEnableFontSizeScaleProperty(this); + } } set { - SetValue(EnableFontSizeScaleProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(EnableFontSizeScaleProperty, value); + } + else + { + SetInternalEnableFontSizeScaleProperty(this, null, value); + } NotifyPropertyChanged(); } } diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextLabelBindableProperty.cs b/src/Tizen.NUI/src/public/BaseComponents/TextLabelBindableProperty.cs index e559a1f..072079d 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextLabelBindableProperty.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextLabelBindableProperty.cs @@ -32,7 +32,8 @@ namespace Tizen.NUI.BaseComponents /// StyleNameProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty TranslatableTextProperty = BindableProperty.Create(nameof(TranslatableText), typeof(string), typeof(TextLabel), string.Empty, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty TranslatableTextProperty = null; + internal static void SetInternalTranslatableTextProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -45,15 +46,17 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.TranslatableText?.Reset(textLabel); textLabel.SetTranslatableText((string)newValue); } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalTranslatableTextProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return textLabel.translatableText; - }); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty TextProperty = BindableProperty.Create(nameof(Text), typeof(string), typeof(TextLabel), string.Empty, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty TextProperty = null; + internal static void SetInternalTextProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -66,17 +69,19 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.Text?.Reset(textLabel); textLabel.SetText((string)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalTextProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; // Do not try to get string if we know that previous text was empty. return textLabel.textIsEmpty ? "" : Object.InternalGetPropertyString(textLabel.SwigCPtr, TextLabel.Property.TEXT); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty FontFamilyProperty = BindableProperty.Create(nameof(FontFamily), typeof(string), typeof(TextLabel), string.Empty, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty FontFamilyProperty = null; + internal static void SetInternalFontFamilyProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -89,15 +94,17 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.FontFamily?.Reset(textLabel); textLabel.SetFontFamily((string)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalFontFamilyProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return textLabel.InternalFontFamily; - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty FontStyleProperty = BindableProperty.Create(nameof(FontStyle), typeof(PropertyMap), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty FontStyleProperty = null; + internal static void SetInternalFontStyleProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -105,17 +112,19 @@ namespace Tizen.NUI.BaseComponents Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.FontStyle, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); textLabel.RequestLayout(); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalFontStyleProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.FontStyle).Get(temp); return temp; - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty PointSizeProperty = BindableProperty.Create(nameof(PointSize), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty PointSizeProperty = null; + internal static void SetInternalPointSizeProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -128,16 +137,18 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.PointSize?.Reset(textLabel); textLabel.SetPointSize((float?)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalPointSizeProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.PointSize); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty MultiLineProperty = BindableProperty.Create(nameof(MultiLine), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty MultiLineProperty = null; + internal static void SetInternalMultiLineProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -146,16 +157,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.MultiLine, (bool)newValue); textLabel.RequestLayout(); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalMultiLineProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.MultiLine); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty HorizontalAlignmentProperty = BindableProperty.Create(nameof(HorizontalAlignment), typeof(HorizontalAlignment), typeof(TextLabel), HorizontalAlignment.Begin, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty HorizontalAlignmentProperty = null; + internal static void SetInternalHorizontalAlignmentProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -163,8 +176,8 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.HorizontalAlignment, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalHorizontalAlignmentProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; string temp; @@ -187,10 +200,12 @@ namespace Tizen.NUI.BaseComponents { return HorizontalAlignment.End; } - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty VerticalAlignmentProperty = BindableProperty.Create(nameof(VerticalAlignment), typeof(VerticalAlignment), typeof(TextLabel), VerticalAlignment.Bottom, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty VerticalAlignmentProperty = null; + internal static void SetInternalVerticalAlignmentProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -198,8 +213,8 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.VerticalAlignment, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalVerticalAlignmentProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; string temp; @@ -222,10 +237,12 @@ namespace Tizen.NUI.BaseComponents { return VerticalAlignment.Bottom; } - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty TextColorProperty = BindableProperty.Create(nameof(TextColor), typeof(Color), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty TextColorProperty = null; + internal static void SetInternalTextColorProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -238,8 +255,8 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.TextColor?.Reset(textLabel); textLabel.SetTextColor((Color)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalTextColorProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; @@ -249,18 +266,19 @@ namespace Tizen.NUI.BaseComponents } Object.InternalRetrievingPropertyVector4(textLabel.SwigCPtr, TextLabel.Property.TextColor, textLabel.internalTextColor.SwigCPtr); return textLabel.internalTextColor; - })); + } [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AnchorColorProperty = BindableProperty.Create(nameof(TextLabel.AnchorColor), typeof(Color), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AnchorColorProperty = null; + internal static void SetInternalAnchorColorProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Object.InternalSetPropertyVector4(textLabel.SwigCPtr, TextLabel.Property.AnchorColor, ((Color)newValue).SwigCPtr); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAnchorColorProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; @@ -270,18 +288,19 @@ namespace Tizen.NUI.BaseComponents } Object.InternalRetrievingPropertyVector4(textLabel.SwigCPtr, TextLabel.Property.TextColor, textLabel.internalAnchorColor.SwigCPtr); return textLabel.internalAnchorColor; - })); + } [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AnchorClickedColorProperty = BindableProperty.Create(nameof(TextLabel.AnchorClickedColor), typeof(Color), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AnchorClickedColorProperty = null; + internal static void SetInternalAnchorClickedColorProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Object.InternalSetPropertyVector4(textLabel.SwigCPtr, TextLabel.Property.AnchorClickedColor, ((Color)newValue).SwigCPtr); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAnchorClickedColorProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; @@ -291,49 +310,52 @@ namespace Tizen.NUI.BaseComponents } Object.InternalRetrievingPropertyVector4(textLabel.SwigCPtr, TextLabel.Property.TextColor, textLabel.internalAnchorClickedColor.SwigCPtr); return textLabel.internalAnchorClickedColor; - })); + } /// /// RemoveFrontInsetProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty RemoveFrontInsetProperty = BindableProperty.Create(nameof(RemoveFrontInset), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty RemoveFrontInsetProperty = null; + internal static void SetInternalRemoveFrontInsetProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.RemoveFrontInset, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalRemoveFrontInsetProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.RemoveFrontInset); - })); + } /// /// RemoveBackInsetProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty RemoveBackInsetProperty = BindableProperty.Create(nameof(RemoveBackInset), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty RemoveBackInsetProperty = null; + internal static void SetInternalRemoveBackInsetProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.RemoveBackInset, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalRemoveBackInsetProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.RemoveBackInset); - })); + } /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EnableMarkupProperty = BindableProperty.Create(nameof(EnableMarkup), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EnableMarkupProperty = null; + internal static void SetInternalEnableMarkupProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -341,16 +363,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableMarkup, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEnableMarkupProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableMarkup); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EnableAutoScrollProperty = BindableProperty.Create(nameof(EnableAutoScroll), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EnableAutoScrollProperty = null; + internal static void SetInternalEnableAutoScrollProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -358,16 +382,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableAutoScroll, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEnableAutoScrollProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableAutoScroll); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AutoScrollSpeedProperty = BindableProperty.Create(nameof(AutoScrollSpeed), typeof(int), typeof(TextLabel), default(int), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AutoScrollSpeedProperty = null; + internal static void SetInternalAutoScrollSpeedProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -375,16 +401,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.AutoScrollSpeed, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAutoScrollSpeedProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.AutoScrollSpeed); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AutoScrollLoopCountProperty = BindableProperty.Create(nameof(AutoScrollLoopCount), typeof(int), typeof(TextLabel), default(int), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AutoScrollLoopCountProperty = null; + internal static void SetInternalAutoScrollLoopCountProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -392,16 +420,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.AutoScrollLoopCount, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAutoScrollLoopCountProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.AutoScrollLoopCount); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AutoScrollGapProperty = BindableProperty.Create(nameof(AutoScrollGap), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AutoScrollGapProperty = null; + internal static void SetInternalAutoScrollGapProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -409,16 +439,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.AutoScrollGap, (float)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAutoScrollGapProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.AutoScrollGap); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty LineSpacingProperty = BindableProperty.Create(nameof(LineSpacing), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty LineSpacingProperty = null; + internal static void SetInternalLineSpacingProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -427,15 +459,17 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.LineSpacing, (float)newValue); textLabel.RequestLayout(); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalLineSpacingProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.LineSpacing); - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty RelativeLineHeightProperty = BindableProperty.Create(nameof(RelativeLineHeight), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty RelativeLineHeightProperty = null; + internal static void SetInternalRelativeLineHeightProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -443,51 +477,56 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.RelativeLineHeight, (float)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalRelativeLineHeightProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.RelativeLineHeight); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty UnderlineProperty = BindableProperty.Create(nameof(Underline), typeof(PropertyMap), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty UnderlineProperty = null; + internal static void SetInternalUnderlineProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.UNDERLINE, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalUnderlineProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.UNDERLINE).Get(temp); return temp; - })); + } /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ShadowProperty = BindableProperty.Create(nameof(Shadow), typeof(PropertyMap), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ShadowProperty = null; + internal static void SetInternalShadowProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.SHADOW, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalShadowProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.SHADOW).Get(temp); return temp; - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty TextShadowProperty = BindableProperty.Create(nameof(TextShadow), typeof(TextShadow), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty TextShadowProperty = null; + internal static void SetInternalTextShadowProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -500,17 +539,19 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.TextShadow?.Reset(textLabel); textLabel.SetTextShadow((TextShadow)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalTextShadowProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.SHADOW).Get(temp); return temp.Empty() ? null : new TextShadow(temp); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EmbossProperty = BindableProperty.Create(nameof(Emboss), typeof(string), typeof(TextLabel), string.Empty, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EmbossProperty = null; + internal static void SetInternalEmbossProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -518,33 +559,37 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyString(textLabel.SwigCPtr, TextLabel.Property.EMBOSS, (string)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEmbossProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyString(textLabel.SwigCPtr, TextLabel.Property.EMBOSS); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty OutlineProperty = BindableProperty.Create(nameof(Outline), typeof(PropertyMap), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty OutlineProperty = null; + internal static void SetInternalOutlineProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.OUTLINE, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalOutlineProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.OUTLINE).Get(temp); return temp; - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty PixelSizeProperty = BindableProperty.Create(nameof(PixelSize), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty PixelSizeProperty = null; + internal static void SetInternalPixelSizeProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; @@ -557,16 +602,18 @@ namespace Tizen.NUI.BaseComponents textLabel.selectorData?.PixelSize?.Reset(textLabel); textLabel.SetPixelSize((float?)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalPixelSizeProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.PixelSize); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EllipsisProperty = BindableProperty.Create(nameof(Ellipsis), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EllipsisProperty = null; + internal static void SetInternalEllipsisProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -574,16 +621,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.ELLIPSIS, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEllipsisProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.ELLIPSIS); - })); + } + /// This will be public opened in tizen_6.5 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EllipsisPositionProperty = BindableProperty.Create(nameof(EllipsisPosition), typeof(EllipsisPosition), typeof(TextLabel), EllipsisPosition.End, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EllipsisPositionProperty = null; + internal static void SetInternalEllipsisPositionProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -591,16 +640,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.EllipsisPosition, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEllipsisPositionProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return (EllipsisPosition)Object.InternalGetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.EllipsisPosition); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AutoScrollLoopDelayProperty = BindableProperty.Create(nameof(AutoScrollLoopDelay), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AutoScrollLoopDelayProperty = null; + internal static void SetInternalAutoScrollLoopDelayProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -608,16 +659,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.AutoScrollLoopDelay, (float)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAutoScrollLoopDelayProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.AutoScrollLoopDelay); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AutoScrollStopModeProperty = BindableProperty.Create(nameof(AutoScrollStopMode), typeof(AutoScrollStopMode), typeof(TextLabel), AutoScrollStopMode.FinishLoop, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AutoScrollStopModeProperty = null; + internal static void SetInternalAutoScrollStopModeProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -625,18 +678,20 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.AutoScrollStopMode, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalAutoScrollStopModeProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; string temp; temp = Object.InternalGetPropertyString(textLabel.SwigCPtr, TextLabel.Property.AutoScrollStopMode); return temp.GetValueByDescription(); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty LineWrapModeProperty = BindableProperty.Create(nameof(LineWrapMode), typeof(LineWrapMode), typeof(TextLabel), LineWrapMode.Word, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty LineWrapModeProperty = null; + internal static void SetInternalLineWrapModeProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -644,16 +699,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.LineWrapMode, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalLineWrapModeProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return (LineWrapMode)Object.InternalGetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.LineWrapMode); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty VerticalLineAlignmentProperty = BindableProperty.Create(nameof(VerticalLineAlignment), typeof(VerticalLineAlignment), typeof(TextLabel), VerticalLineAlignment.Bottom, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty VerticalLineAlignmentProperty = null; + internal static void SetInternalVerticalLineAlignmentProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -661,16 +718,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.VerticalLineAlignment, (int)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalVerticalLineAlignmentProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return (VerticalLineAlignment)Object.InternalGetPropertyInt(textLabel.SwigCPtr, TextLabel.Property.VerticalLineAlignment); - })); + } + /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty MatchSystemLanguageDirectionProperty = BindableProperty.Create(nameof(MatchSystemLanguageDirection), typeof(bool), typeof(TextLabel), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty MatchSystemLanguageDirectionProperty = null; + internal static void SetInternalMatchSystemLanguageDirectionProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -678,16 +737,18 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.MatchSystemLanguageDirection, (bool)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalMatchSystemLanguageDirectionProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.MatchSystemLanguageDirection); - })); + } + /// This will be public opened in tizen_6.5 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty CharacterSpacingProperty = BindableProperty.Create(nameof(CharacterSpacing), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty CharacterSpacingProperty = null; + internal static void SetInternalCharacterSpacingProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -695,34 +756,37 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.CharacterSpacing, (float)newValue); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalCharacterSpacingProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.CharacterSpacing); - })); + } + /// Only for XAML. No need of public API. Make hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty TextFitProperty = BindableProperty.Create(nameof(TextFit), typeof(PropertyMap), typeof(TextLabel), null, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty TextFitProperty = null; + internal static void SetInternalTextFitProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.TextFit, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalTextFitProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; PropertyMap temp = new PropertyMap(); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)textLabel.SwigCPtr, TextLabel.Property.TextFit).Get(temp); return temp; - })); + } /// Only for XAML. No need of public API. Make hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty MinLineSizeProperty = BindableProperty.Create(nameof(MinLineSize), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty MinLineSizeProperty = null; + internal static void SetInternalMinLineSizeProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -731,31 +795,33 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.MinLineSize, (float)newValue); textLabel.RequestLayout(); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalMinLineSizeProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyFloat(textLabel.SwigCPtr, TextLabel.Property.MinLineSize); - })); + } [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty FontSizeScaleProperty = BindableProperty.Create(nameof(FontSizeScale), typeof(float), typeof(TextLabel), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty FontSizeScaleProperty = null; + internal static void SetInternalFontSizeScaleProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) { textLabel.InternalFontSizeScale = (float)newValue; } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalFontSizeScaleProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return textLabel.InternalFontSizeScale; - })); + } [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty EnableFontSizeScaleProperty = BindableProperty.Create(nameof(EnableFontSizeScale), typeof(bool), typeof(TextLabel), default(bool), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty EnableFontSizeScaleProperty = null; + internal static void SetInternalEnableFontSizeScaleProperty(BindableObject bindable, object oldValue, object newValue) { var textLabel = (TextLabel)bindable; if (newValue != null) @@ -764,103 +830,108 @@ namespace Tizen.NUI.BaseComponents Object.InternalSetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableFontSizeScale, (bool)newValue); textLabel.RequestLayout(); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + internal static object GetInternalEnableFontSizeScaleProperty(BindableObject bindable) { var textLabel = (TextLabel)bindable; return Object.InternalGetPropertyBool(textLabel.SwigCPtr, TextLabel.Property.EnableFontSizeScale); - })); + } /// /// ShadowOffsetProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ShadowOffsetProperty = BindableProperty.Create(nameof(ShadowOffset), typeof(Tizen.NUI.Vector2), typeof(TextLabel), null, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty ShadowOffsetProperty = null; + internal static void SetInternalShadowOffsetProperty(BindableObject bindable, object oldValue, object newValue) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; if (newValue != null) { instance.InternalShadowOffset = (Tizen.NUI.Vector2)newValue; } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalShadowOffsetProperty(BindableObject bindable) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; return instance.InternalShadowOffset; - }); + } /// /// ShadowColorProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ShadowColorProperty = BindableProperty.Create(nameof(ShadowColor), typeof(Tizen.NUI.Vector4), typeof(TextLabel), null, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty ShadowColorProperty = null; + internal static void SetInternalShadowColorProperty(BindableObject bindable, object oldValue, object newValue) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; if (newValue != null) { instance.InternalShadowColor = (Tizen.NUI.Vector4)newValue; } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalShadowColorProperty(BindableObject bindable) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; return instance.InternalShadowColor; - }); + } /// /// UnderlineEnabledProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty UnderlineEnabledProperty = BindableProperty.Create(nameof(UnderlineEnabled), typeof(bool), typeof(TextLabel), false, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty UnderlineEnabledProperty = null; + internal static void SetInternalUnderlineEnabledProperty(BindableObject bindable, object oldValue, object newValue) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; if (newValue != null) { instance.InternalUnderlineEnabled = (bool)newValue; } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalUnderlineEnabledProperty(BindableObject bindable) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; return instance.InternalUnderlineEnabled; - }); + } /// /// UnderlineColorProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty UnderlineColorProperty = BindableProperty.Create(nameof(UnderlineColor), typeof(Tizen.NUI.Vector4), typeof(TextLabel), null, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty UnderlineColorProperty = null; + internal static void SetInternalUnderlineColorProperty(BindableObject bindable, object oldValue, object newValue) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; if (newValue != null) { instance.InternalUnderlineColor = (Tizen.NUI.Vector4)newValue; } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalUnderlineColorProperty(BindableObject bindable) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; return instance.InternalUnderlineColor; - }); + } /// /// UnderlineHeightProperty /// [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty UnderlineHeightProperty = BindableProperty.Create(nameof(UnderlineHeight), typeof(float), typeof(TextLabel), 0.0f, propertyChanged: (bindable, oldValue, newValue) => + public static readonly BindableProperty UnderlineHeightProperty = null; + internal static void SetInternalUnderlineHeightProperty(BindableObject bindable, object oldValue, object newValue) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; if (newValue != null) { instance.InternalUnderlineHeight = (float)newValue; } - }, - defaultValueCreator: (bindable) => + } + internal static object GetInternalUnderlineHeightProperty(BindableObject bindable) { var instance = (Tizen.NUI.BaseComponents.TextLabel)bindable; return instance.InternalUnderlineHeight; - }); + } internal Selector TranslatableTextSelector { -- 2.7.4