[global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_PixelBuffer_Resize")]
public static extern void PixelBuffer_Resize(global::System.Runtime.InteropServices.HandleRef jarg1, ushort jarg2, ushort jarg3);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_PixelBuffer_Rotate")]
+ public static extern bool PixelBuffer_Rotate(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
}
}
}
\ No newline at end of file
--- /dev/null
+using System;
+using System.Collections.Generic;
+using System.Runtime.InteropServices;
+using System.Text;
+
+namespace Tizen.NUI
+{
+ internal static partial class Interop
+ {
+ internal static partial class RendererParameters
+ {
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_new_RendererParameters_0")]
+ public static extern global::System.IntPtr new_RendererParameters__SWIG_0();
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_text_set")]
+ public static extern void RendererParameters_text_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_text_get")]
+ public static extern string RendererParameters_text_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_horizontalAlignment_set")]
+ public static extern void RendererParameters_horizontalAlignment_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_horizontalAlignment_get")]
+ public static extern string RendererParameters_horizontalAlignment_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_verticalAlignment_set")]
+ public static extern void RendererParameters_verticalAlignment_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_verticalAlignment_get")]
+ public static extern string RendererParameters_verticalAlignment_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontFamily_set")]
+ public static extern void RendererParameters_fontFamily_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontFamily_get")]
+ public static extern string RendererParameters_fontFamily_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontWeight_set")]
+ public static extern void RendererParameters_fontWeight_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontWeight_get")]
+ public static extern string RendererParameters_fontWeight_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontWidth_set")]
+ public static extern void RendererParameters_fontWidth_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontWidth_get")]
+ public static extern string RendererParameters_fontWidth_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontSlant_set")]
+ public static extern void RendererParameters_fontSlant_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontSlant_get")]
+ public static extern string RendererParameters_fontSlant_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_layout_set")]
+ public static extern void RendererParameters_layout_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_layout_get")]
+ public static extern string RendererParameters_layout_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_circularAlignment_set")]
+ public static extern void RendererParameters_circularAlignment_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_circularAlignment_get")]
+ public static extern string RendererParameters_circularAlignment_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textColor_set")]
+ public static extern void RendererParameters_textColor_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textColor_get")]
+ public static extern global::System.IntPtr RendererParameters_textColor_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontSize_set")]
+ public static extern void RendererParameters_fontSize_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_fontSize_get")]
+ public static extern float RendererParameters_fontSize_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textWidth_set")]
+ public static extern void RendererParameters_textWidth_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textWidth_get")]
+ public static extern uint RendererParameters_textWidth_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textHeight_set")]
+ public static extern void RendererParameters_textHeight_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_textHeight_get")]
+ public static extern uint RendererParameters_textHeight_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_radius_set")]
+ public static extern void RendererParameters_radius_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_radius_get")]
+ public static extern uint RendererParameters_radius_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_beginAngle_set")]
+ public static extern void RendererParameters_beginAngle_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_beginAngle_get")]
+ public static extern float RendererParameters_beginAngle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_incrementAngle_set")]
+ public static extern void RendererParameters_incrementAngle_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_incrementAngle_get")]
+ public static extern float RendererParameters_incrementAngle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_ellipsisEnabled_set")]
+ public static extern void RendererParameters_ellipsisEnabled_set(global::System.Runtime.InteropServices.HandleRef jarg1, bool jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_ellipsisEnabled_get")]
+ public static extern bool RendererParameters_ellipsisEnabled_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_markupEnabled_set")]
+ public static extern void RendererParameters_markupEnabled_set(global::System.Runtime.InteropServices.HandleRef jarg1, bool jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_markupEnabled_get")]
+ public static extern bool RendererParameters_markupEnabled_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_isTextColorSet_set")]
+ public static extern void RendererParameters_isTextColorSet_set(global::System.Runtime.InteropServices.HandleRef jarg1, bool jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_RendererParameters_isTextColorSet_get")]
+ public static extern bool RendererParameters_isTextColorSet_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_delete_RendererParameters")]
+ public static extern void delete_RendererParameters(global::System.Runtime.InteropServices.HandleRef jarg1);
+ }
+
+ internal static partial class EmbeddedItemInfo
+ {
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_new_EmbeddedItemInfo_0")]
+ public static extern global::System.IntPtr new_EmbeddedItemInfo__SWIG_0();
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_delete_EmbeddedItemInfo")]
+ public static extern void delete_EmbeddedItemInfo(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_characterIndex_set")]
+ public static extern void EmbeddedItemInfo_characterIndex_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_characterIndex_get")]
+ public static extern uint EmbeddedItemInfo_characterIndex_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_glyphIndex_set")]
+ public static extern void EmbeddedItemInfo_glyphIndex_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_glyphIndex_get")]
+ public static extern uint EmbeddedItemInfo_glyphIndex_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_position_set")]
+ public static extern void EmbeddedItemInfo_position_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_position_get")]
+ public static extern global::System.IntPtr EmbeddedItemInfo_position_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_size_set")]
+ public static extern void EmbeddedItemInfo_size_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_size_get")]
+ public static extern global::System.IntPtr EmbeddedItemInfo_size_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_rotatedSize_set")]
+ public static extern void EmbeddedItemInfo_rotatedSize_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_rotatedSize_get")]
+ public static extern global::System.IntPtr EmbeddedItemInfo_rotatedSize_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_angle_set")]
+ public static extern void EmbeddedItemInfo_angle_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_angle_get")]
+ public static extern global::System.IntPtr EmbeddedItemInfo_angle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_colorBlendingMode_set")]
+ public static extern void EmbeddedItemInfo_colorBlendingMode_set(global::System.Runtime.InteropServices.HandleRef jarg1, Tizen.NUI.ColorBlendingMode jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_EmbeddedItemInfo_colorBlendingMode_get")]
+ public static extern Tizen.NUI.ColorBlendingMode EmbeddedItemInfo_colorBlendingMode_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+ }
+
+ internal static partial class ShadowParameters
+ {
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_new_ShadowParameters_0")]
+ public static extern global::System.IntPtr new_ShadowParameters__SWIG_0();
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_delete_ShadowParameters")]
+ public static extern void delete_ShadowParameters(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_input_set")]
+ public static extern void ShadowParameters_input_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_input_get")]
+ public static extern global::System.IntPtr ShadowParameters_input_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_textColor_set")]
+ public static extern void ShadowParameters_textColor_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_textColor_get")]
+ public static extern global::System.IntPtr ShadowParameters_textColor_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_color_set")]
+ public static extern void ShadowParameters_color_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_color_get")]
+ public static extern global::System.IntPtr ShadowParameters_color_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_offset_set")]
+ public static extern void ShadowParameters_offset_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_offset_get")]
+ public static extern global::System.IntPtr ShadowParameters_offset_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_blendShadow_set")]
+ public static extern void ShadowParameters_blendShadow_set(global::System.Runtime.InteropServices.HandleRef jarg1, bool jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_ShadowParameters_blendShadow_get")]
+ public static extern bool ShadowParameters_blendShadow_get(global::System.Runtime.InteropServices.HandleRef jarg1);
+ }
+
+ internal static partial class TextUtils
+ {
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_TextUtils_Render")]
+ public static extern global::System.IntPtr TextUtils_Render(global::System.Runtime.InteropServices.HandleRef jarg1, ref global::System.IntPtr jarg2, ref int count, ref int length);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_TextUtils_CreateShadow")]
+ public static extern global::System.IntPtr TextUtils_CreateShadow(global::System.Runtime.InteropServices.HandleRef jarg1);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_TextUtils_ConvertToRgba8888")]
+ public static extern global::System.IntPtr TextUtils_ConvertToRgba8888(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, bool jarg3);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_TextUtils_UpdateBuffer")]
+ public static extern void TextUtils_UpdateBuffer(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, uint jarg3, uint jarg4, bool jarg5);
+
+ }
+ }
+}
\ No newline at end of file
--- /dev/null
+/*
+ * Copyright(c) 2020 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+using System;
+using System.ComponentModel;
+using System.Collections.Generic;
+using Tizen.NUI.Binding;
+
+namespace Tizen.NUI.BaseComponents
+{
+ /// <summary>
+ /// Class with the text and style parameters to be rendered into a pixel buffer.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public class RendererParameters : Disposable
+ {
+ internal RendererParameters(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn)
+ {
+ }
+
+ internal static global::System.Runtime.InteropServices.HandleRef getCPtr(RendererParameters obj)
+ {
+ return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ }
+
+ protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
+ {
+ Interop.RendererParameters.delete_RendererParameters(swigCPtr);
+ }
+
+ /// <summary>
+ /// Construct RendererParameters
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public RendererParameters() : this(Interop.RendererParameters.new_RendererParameters__SWIG_0(), true)
+ {
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ /// <summary>
+ /// The text to be rendered
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public string Text
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_text_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_text_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The horizontal alignment: one of HorizontalAlignment.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public HorizontalAlignment HorizontalAlignment
+ {
+ set
+ {
+ string alignment = "begin";
+ switch(value)
+ {
+ case HorizontalAlignment.Begin: {
+ alignment = "begin";
+ break;
+ }
+ case HorizontalAlignment.Center: {
+ alignment = "center";
+ break;
+ }
+ case HorizontalAlignment.End: {
+ alignment = "end";
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ Interop.RendererParameters.RendererParameters_horizontalAlignment_set(swigCPtr, alignment);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_horizontalAlignment_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ HorizontalAlignment alignment = HorizontalAlignment.Begin;
+ switch(ret)
+ {
+ case "begin": {
+ alignment = HorizontalAlignment.Begin;
+ break;
+ }
+ case "center": {
+ alignment = HorizontalAlignment.Center;
+ break;
+ }
+ case "end": {
+ alignment = HorizontalAlignment.End;
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ return alignment;
+ }
+ }
+
+ /// <summary>
+ /// The vertical alignment: one of VerticalAlignment.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public VerticalAlignment VerticalAlignment
+ {
+ set
+ {
+ string alignment = "top";
+ switch(value)
+ {
+ case VerticalAlignment.Top: {
+ alignment = "top";
+ break;
+ }
+ case VerticalAlignment.Center: {
+ alignment = "center";
+ break;
+ }
+ case VerticalAlignment.Bottom: {
+ alignment = "bottom";
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ Interop.RendererParameters.RendererParameters_verticalAlignment_set(swigCPtr, alignment);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_verticalAlignment_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ VerticalAlignment alignment = VerticalAlignment.Top;
+ switch(ret)
+ {
+ case "top": {
+ alignment = VerticalAlignment.Top;
+ break;
+ }
+ case "center": {
+ alignment = VerticalAlignment.Center;
+ break;
+ }
+ case "bottom": {
+ alignment = VerticalAlignment.Bottom;
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ return alignment;
+ }
+ }
+
+ /// <summary>
+ /// The font's family.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public string FontFamily
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_fontFamily_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_fontFamily_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The font's weight: one of {"thin", "ultraLight", "extraLight", "light", "demiLight", "semiLight", "book", "normal", "regular", "medium", "demiBold", "semiBold", "bold", "ultraBold", "extraBold", "black", "heavy", "extraBlack"}.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public string FontWeight
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_fontWeight_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_fontWeight_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The font's width: one of {"ultraCondensed", "extraCondensed", "condensed", "semiCondensed", "normal", "semiExpanded", "expanded", "extraExpanded", "ultraExpanded"}.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public string FontWidth
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_fontWidth_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_fontWidth_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The font's slant. one of {"normal", "roman", "italic", "oblique"}
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public string FontSlant
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_fontSlant_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_fontSlant_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The type of layout: one of TextLayout {"singleLine", "multiLine", "circular"}
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public TextLayout Layout
+ {
+ set
+ {
+ string textLayout = "singleLine";
+ switch(value)
+ {
+ case TextLayout.SingleLine: {
+ textLayout = "singleLine";
+ break;
+ }
+ case TextLayout.MultiLine: {
+ textLayout = "multiLine";
+ break;
+ }
+ case TextLayout.Circular: {
+ textLayout = "circular";
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ Interop.RendererParameters.RendererParameters_layout_set(swigCPtr, textLayout);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_layout_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ TextLayout textLayout = TextLayout.SingleLine;
+ switch(ret)
+ {
+ case "singleLine": {
+ textLayout = TextLayout.SingleLine;
+ break;
+ }
+ case "multiLine": {
+ textLayout = TextLayout.MultiLine;
+ break;
+ }
+ case "circular": {
+ textLayout = TextLayout.Circular;
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ return textLayout;
+ }
+ }
+
+ /// <summary>
+ /// The text alignment within the arc: one of CircularAlignment. The @p horizontalAlignment and @p verticalAlignment can be used to align the text within the text area.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public CircularAlignment CircularAlignment
+ {
+ set
+ {
+ string alignment = "begin";
+ switch(value)
+ {
+ case CircularAlignment.Begin: {
+ alignment = "begin";
+ break;
+ }
+ case CircularAlignment.Center: {
+ alignment = "center";
+ break;
+ }
+ case CircularAlignment.End: {
+ alignment = "end";
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ Interop.RendererParameters.RendererParameters_circularAlignment_set(swigCPtr, alignment);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ string ret = Interop.RendererParameters.RendererParameters_circularAlignment_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ CircularAlignment alignment = CircularAlignment.Begin;
+ switch(ret)
+ {
+ case "begin": {
+ alignment = CircularAlignment.Begin;
+ break;
+ }
+ case "center": {
+ alignment = CircularAlignment.Center;
+ break;
+ }
+ case "end": {
+ alignment = CircularAlignment.End;
+ break;
+ }
+ default : {
+ break;
+ }
+ }
+ return alignment;
+ }
+ }
+
+ /// <summary>
+ /// The default text's color. Default is white.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Vector4 TextColor
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_textColor_set(swigCPtr, Vector4.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Vector4 ret = new Vector4(Interop.RendererParameters.RendererParameters_textColor_get(swigCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The font's size (in points).
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public float FontSize
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_fontSize_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ float ret = Interop.RendererParameters.RendererParameters_fontSize_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The width in pixels of the boundaries where the text is going to be laid-out.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public uint TextWidth
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_textWidth_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ uint ret = Interop.RendererParameters.RendererParameters_textWidth_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The height in pixels of the boundaries where the text is going to be laid-out.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public uint TextHeight
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_textHeight_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ uint ret = Interop.RendererParameters.RendererParameters_textHeight_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The radius in pixels of the circular text.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public uint Radius
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_radius_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ uint ret = Interop.RendererParameters.RendererParameters_radius_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The begin angle in degrees of the text area on the circle. The top of the circle is 0°, the right side 90°, the bottom 180° and the left 270°.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public float BeginAngle
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_beginAngle_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ float ret = Interop.RendererParameters.RendererParameters_beginAngle_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The increment angle in degrees of the text area on the circle. The @p incrementAngle defines a direction. If positive, the text will be laid out clockwise.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public float IncrementAngle
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_incrementAngle_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ float ret = Interop.RendererParameters.RendererParameters_incrementAngle_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Whether the ellipsis layout option is enabled.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool EllipsisEnabled
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_ellipsisEnabled_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ bool ret = Interop.RendererParameters.RendererParameters_ellipsisEnabled_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Whether the mark-up processor is enabled.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool MarkupEnabled
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_markupEnabled_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ bool ret = Interop.RendererParameters.RendererParameters_markupEnabled_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Whether a default color has been set.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool IsTextColorSet
+ {
+ set
+ {
+ Interop.RendererParameters.RendererParameters_isTextColorSet_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ bool ret = Interop.RendererParameters.RendererParameters_isTextColorSet_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ }
+
+ /// <summary>
+ /// Class with info of the embedded items layout.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public class EmbeddedItemInfo : Disposable
+ {
+
+ internal EmbeddedItemInfo(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn)
+ {
+ }
+
+ internal static global::System.Runtime.InteropServices.HandleRef getCPtr(EmbeddedItemInfo obj)
+ {
+ return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ }
+
+ protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
+ {
+ Interop.EmbeddedItemInfo.delete_EmbeddedItemInfo(swigCPtr);
+ }
+
+ /// <summary>
+ /// Construct EmbeddedItemInfo
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public EmbeddedItemInfo() : this(Interop.EmbeddedItemInfo.new_EmbeddedItemInfo__SWIG_0(), true)
+ {
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ /// <summary>
+ /// Index to the character within the string.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public uint CharacterIndex
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_characterIndex_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ uint ret = Interop.EmbeddedItemInfo.EmbeddedItemInfo_characterIndex_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Index to the glyph
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public uint GlyphIndex
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_glyphIndex_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ uint ret = Interop.EmbeddedItemInfo.EmbeddedItemInfo_glyphIndex_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The layout position within the buffer (top, left corner).
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Vector2 Position
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_position_set(swigCPtr, Vector2.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Vector2 ret = new Vector2(Interop.EmbeddedItemInfo.EmbeddedItemInfo_position_get(swigCPtr), swigCMemOwn);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The size within the buffer of the embedded item.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Size Size
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_size_set(swigCPtr, Size.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Size ret = new Size(Interop.EmbeddedItemInfo.EmbeddedItemInfo_size_get(swigCPtr), swigCMemOwn);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The rotated size within the buffer of the embedded item.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Size RotatedSize
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_rotatedSize_set(swigCPtr, Size.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Size ret = new Size(Interop.EmbeddedItemInfo.EmbeddedItemInfo_rotatedSize_get(swigCPtr), swigCMemOwn);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Rotation angle of the pixel buffer in degrees.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Degree Angle
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_angle_set(swigCPtr, Degree.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Degree ret = new Degree(Interop.EmbeddedItemInfo.EmbeddedItemInfo_angle_get(swigCPtr), swigCMemOwn);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Whether the color of the image is multiplied by the color of the text.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Tizen.NUI.ColorBlendingMode ColorBlendingMode
+ {
+ set
+ {
+ Interop.EmbeddedItemInfo.EmbeddedItemInfo_colorBlendingMode_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Tizen.NUI.ColorBlendingMode ret = Interop.EmbeddedItemInfo.EmbeddedItemInfo_colorBlendingMode_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+ }
+
+ /// <summary>
+ /// Class with the parameters needed to build a shadow for the given pixel buffer.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public class ShadowParameters : Disposable
+ {
+
+ internal ShadowParameters(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn)
+ {
+ }
+
+ internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ShadowParameters obj)
+ {
+ return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ }
+
+ protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
+ {
+ Interop.ShadowParameters.delete_ShadowParameters(swigCPtr);
+ }
+
+ /// <summary>
+ /// Construct ShadowParameters
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public ShadowParameters() : this(Interop.ShadowParameters.new_ShadowParameters__SWIG_0(), true)
+ {
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ /// <summary>
+ /// The input pixel buffer used to create the shadow.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public PixelBuffer Input
+ {
+ set
+ {
+ Interop.ShadowParameters.ShadowParameters_input_set(swigCPtr, PixelBuffer.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ PixelBuffer ret = new PixelBuffer(Interop.ShadowParameters.ShadowParameters_input_get(swigCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The color of the text.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Vector4 TextColor
+ {
+ set
+ {
+ Interop.ShadowParameters.ShadowParameters_textColor_set(swigCPtr, Vector4.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Vector4 ret = new Vector4(Interop.ShadowParameters.ShadowParameters_textColor_get(swigCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The color of the shadow.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Vector4 Color
+ {
+ set
+ {
+ Interop.ShadowParameters.ShadowParameters_color_set(swigCPtr, Vector4.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Vector4 ret = new Vector4(Interop.ShadowParameters.ShadowParameters_color_get(swigCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// The offset of the shadow.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public Vector2 Offset
+ {
+ set
+ {
+ Interop.ShadowParameters.ShadowParameters_offset_set(swigCPtr, Vector2.getCPtr(value));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ Vector2 ret = new Vector2(Interop.ShadowParameters.ShadowParameters_offset_get(swigCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ /// <summary>
+ /// Whether to blend the shadow.
+ /// </summary>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool blendShadow
+ {
+ set
+ {
+ Interop.ShadowParameters.ShadowParameters_blendShadow_set(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ bool ret = Interop.ShadowParameters.ShadowParameters_blendShadow_get(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+ }
+
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public static partial class TextUtils
+ {
+ /// <summary>
+ /// Renders text into a pixel buffer.
+ /// @note: Can process a mark-up string.
+ /// @note: It does the font selection, RTL reordering, shaping and layouting.
+ /// @note: The width of the pixel buffer may be different to the given @e textWidth
+ /// due to some padding pixels added.
+ ///
+ /// The text is laid-out for the given size @e (textWidth,textHeight).
+ /// If the @e multiLineEnabled option is enabled, the text will wrap in lines.
+ /// If the @e ellipsisEnabled option is enabled, the text will be ellided if
+ /// there is no more space for new lines.
+ ///
+ /// It won't be rendered the parts of the text exceeding the boundaries of
+ /// the given width and height.
+ ///
+ /// If the given @e textHeight is zero, a big enough pixel buffer will be created
+ /// to render the full text.
+ ///
+ /// If the given @e textWidth is zero, the 'natural size' of the text will be
+ /// used to create the pixel buffer to render the full text.
+ ///
+ /// If the radius is not zero, the text will be laid-out following a circular path.
+ /// In that case the text is laid-out in a single line.
+ ///
+ /// If the mark-up string contains embedded items, the @p embeddedItemLayout vector
+ /// contains the layout info of each embedded item.
+ /// </summary>
+ /// <param name="textParameters">The text and style options.</param>
+ /// <param name="embeddedItemLayout">The layout info of the embedded items</param>
+ /// <returns>A pixel buffer with the text rendered on it.</returns>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public static PixelBuffer Render(RendererParameters textParameters, ref EmbeddedItemInfo[] embeddedItemLayout)
+ {
+ int count = 0;
+ int length = 0;
+ global::System.IntPtr returnItem = IntPtr.Zero;
+ PixelBuffer ret = new PixelBuffer(Interop.TextUtils.TextUtils_Render(RendererParameters.getCPtr(textParameters), ref returnItem, ref count, ref length), true);
+
+ embeddedItemLayout = new EmbeddedItemInfo[count];
+ for(int i=0; i< count; i++) {
+ IntPtr p = new IntPtr((returnItem.ToInt32() + i * length));
+ embeddedItemLayout[i] = new EmbeddedItemInfo(p, false);
+ }
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ /// <summary>
+ /// Creates a shadow for the text given in the input pixel buffer.
+ /// The function returns a RGBA8888 pixel buffer with the text and its shadow rendered on it.
+ ///
+ /// The pixel format of the @e input pixel buffer could be an A8 or an RGBA8888. If it's
+ /// an A8 pixel buffer, it uses the given @e textColor to give color to the text. Otherwise
+ /// it uses the color of the @e input pixel buffer.
+ /// </summary>
+ /// <param name="shadowParameters">The parameters needed to create the text's shadow.</param>
+ /// <returns>A pixel buffer with the text and the shadow rendered on it.</returns>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public static PixelBuffer CreateShadow(ShadowParameters shadowParameters)
+ {
+ PixelBuffer ret = new PixelBuffer(Interop.TextUtils.TextUtils_CreateShadow(ShadowParameters.getCPtr(shadowParameters)), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ /// <summary>
+ /// Converts a @p pixelBuffer with pixel format A8 to RGBA8888 using the given @p color.
+ /// @note Does nothing if the @p pixelBuffer is not A8.
+ /// </summary>
+ /// <param name="pixelBuffer">The pixel buffer with pixel format A8</param>
+ /// <param name="color">The color used to convert to RGBA8888</param>
+ /// <param name="multiplyByAlpha">multiplyByAlpha Whether to multiply the @p color with the alpha value of the @p pixel @p buffer.</param>
+ /// <returns>The pixel buffer converted to RGBA8888.</returns>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public static PixelBuffer ConvertToRgba8888(PixelBuffer pixelBuffer, Vector4 color, bool multiplyByAlpha)
+ {
+ PixelBuffer ret = new PixelBuffer(Interop.TextUtils.TextUtils_ConvertToRgba8888(PixelBuffer.getCPtr(pixelBuffer), Vector4.getCPtr(color), multiplyByAlpha), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ /// <summary>
+ /// Updates the @p dst pixel buffer with the data from @p src pixel buffer.
+ /// @note Both pixel buffers must have the same pixel format. Does nothing if both pixel format are different.
+ /// @note The function does nothing if the @p src pixel buffer doesn't fit into the @p dst pixel buffer.
+ ///
+ /// The @p src pixel buffer could be blended with the @p dst pixel buffer if @p blend is set to @e true.
+ /// </summary>
+ /// <param name="src">The pixel buffer from where the data is read.</param>
+ /// <param name="dst">The pixel buffer where the data is written.</param>
+ /// <param name="x">The top left corner's X within the destination pixel buffer.</param>
+ /// <param name="y">The top left corner's y within the destination pixel buffer.</param>
+ /// <param name="blend">Whether to blend the source pixel buffer with the destination pixel buffer as background.</param>
+ // This will be public opened after ACR done. (Before ACR, need to be hidden as Inhouse API)
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public static void UpdateBuffer(PixelBuffer src, PixelBuffer dst, uint x, uint y, bool blend)
+ {
+ Interop.TextUtils.TextUtils_UpdateBuffer(PixelBuffer.getCPtr(src), PixelBuffer.getCPtr(dst), x, y, blend);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ }
+
+}
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PixelBuffer obj)
+ /// <summary>
+ /// Rotate the buffer by the given angle.
+ /// </summary>
+ /// <param name="angle">The angle in degrees.</param>
+ /// <since_tizen> 8 </since_tizen>
+ /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool Rotate(Degree angle)
{
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ bool ret = Interop.PixelBuffer.PixelBuffer_Rotate(swigCPtr, Degree.getCPtr(angle));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
}
- internal PixelBuffer Assign(PixelBuffer rhs)
+ /// <summary>
+ /// Gets the pixel buffer
+ /// </summary>
+ /// <since_tizen> 8 </since_tizen>
+ /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public global::System.IntPtr GetBuffer()
{
- PixelBuffer ret = new PixelBuffer(Interop.PixelBuffer.PixelBuffer_Assign(swigCPtr, PixelBuffer.getCPtr(rhs)), false);
+ global::System.IntPtr ret = Interop.PixelBuffer.PixelBuffer_GetBuffer(swigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- internal SWIGTYPE_p_unsigned_char GetBuffer()
+ internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PixelBuffer obj)
{
- global::System.IntPtr cPtr = Interop.PixelBuffer.PixelBuffer_GetBuffer(swigCPtr);
- SWIGTYPE_p_unsigned_char ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_unsigned_char(cPtr, false);
+ return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ }
+
+ internal PixelBuffer Assign(PixelBuffer rhs)
+ {
+ PixelBuffer ret = new PixelBuffer(Interop.PixelBuffer.PixelBuffer_Assign(swigCPtr, PixelBuffer.getCPtr(rhs)), false);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
/// <summary>
/// @brief The looping mode the AnimatedVectorImageVisual will use.
- /// @details Name "loopingMode", Type LoopingMode::Type (Property::INTEGER)
+ /// @details Name "loopingMode", Type LoopingMode::Type (Property::INTEGER)
/// @note Default value is LoopingMode::RESTART.
/// </summary>
/// <remarks>
/// <since_tizen> 3 </since_tizen>
public static readonly int Border = NDalic.IMAGE_VISUAL_WRAP_MODE_V + 1;
}
+
+ /// <summary>
+ /// This specifies properties of the ArcVisual.
+ /// </summary>
+ internal struct ArcVisualProperty
+ {
+ /// <summary>
+ /// The thickness of the arc.
+ /// </summary>
+ /// <remarks>The value is float type.</remarks>
+ /// <remarks>This is mandatory property.</remarks>
+ internal static readonly int Thickness = NDalic.IMAGE_VISUAL_URL;
+
+ /// <summary>
+ /// The start angle where the arc begins in degrees.
+ /// </summary>
+ /// <remarks>The value is float type.</remarks>
+ /// <remarks>The property of optional. The default value is 0.</remarks>
+ internal static readonly int StartAngle = Thickness + 1;
+
+ /// <summary>
+ /// The sweep angle of the arc in degrees.
+ /// </summary>
+ /// <remarks>The value is float type.</remarks>
+ /// <remarks>The property of optional. The default value is 360.</remarks>
+ internal static readonly int SweepAngle = Thickness + 2;
+
+ /// <summary>
+ /// The cap style of the arc.
+ /// </summary>
+ /// <remarks>
+ /// The value is integer type.
+ /// The value 0 means butt, the arc does not extend beyond its two endpoints.
+ /// The value 1 means round, the arc will be extended by a half circle with the center at the end.
+ /// </remarks>
+ /// <remarks>The property of optional. The default value is 0 (butt).</remarks>
+ internal static readonly int Cap = Thickness + 3;
+ }
+
+ /// Enumeration for Circular alignment.
+ /// The @p horizontalAlignment and @p verticalAlignment can be used to align the text within the text area.
+ /// </summary>
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public enum CircularAlignment
+ {
+ /// <summary>
+ /// Texts place at the begin of Circular direction.
+ /// </summary>
+ [Description("BEGIN")]
+ Begin,
+ /// <summary>
+ /// Texts place at the center of Circular direction.
+ /// </summary>
+ [Description("CENTER")]
+ Center,
+ /// <summary>
+ /// Texts place at the end of Circular direction.
+ /// </summary>
+ [Description("END")]
+ End
+ }
+
+ /// <summary>
+ /// Enumeration for Text Layout.
+ /// </summary>
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public enum TextLayout
+ {
+ /// <summary>
+ /// SingleLine.
+ /// </summary>
+ [Description("singleLine")]
+ SingleLine,
+ /// <summary>
+ /// MultiLine.
+ /// </summary>
+ [Description("multiLine")]
+ MultiLine,
+ /// <summary>
+ /// Circular.
+ /// </summary>
+ [Description("circular")]
+ Circular
+ }
+
+ /// <summary>
+ /// Defines how a color is blended.
+ /// </summary>
+ /// This will be public opened after ACR done. Before ACR, need to be hidden as inhouse API.
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public enum ColorBlendingMode
+ {
+ /// <summary>
+ /// No blend.
+ /// </summary>
+ None,
+ /// <summary>
+ /// The color is multiplied by another one.
+ /// </summary>
+ Multiply
+ };
}
--- /dev/null
+using System;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.Runtime.InteropServices;
+using Tizen.NUI;
+using Tizen.NUI.BaseComponents;
+using Tizen.NUI.Components;
+
+namespace Tizen.NUI.Samples
+{
+ public class CircularText : IExample
+ {
+ private string VERSION_3_ES = "#version 300 es\n";
+
+ private static readonly string VERTEX_SHADER =
+ "precision mediump float;\n"+
+ "in vec2 aPosition;\n"+
+ "in vec2 aTexCoord;\n"+
+ "out vec2 vUV;\n"+
+ "uniform vec3 uSize;\n"+
+ "uniform mat4 uMvpMatrix;\n"+
+ "void main()\n"+
+ "{\n"+
+ " vec4 vertexPosition = vec4(aPosition, 0.0, 1.0);\n"+
+ " vertexPosition.xyz *= uSize;\n"+
+ " gl_Position = uMvpMatrix * vertexPosition;\n"+
+ " vUV = aTexCoord;\n"+
+ "}\n";
+
+ private static readonly string FRAGMENT_SHADER =
+ "precision mediump float;\n"+
+ "in vec2 vUV;\n"+
+ "out vec4 FragColor;\n"+
+ "uniform sampler2D sAlbedo;\n"+
+ "uniform vec4 uColor;\n"+
+ "void main()\n"+
+ "{\n"+
+ " vec4 color = texture( sAlbedo, vUV );\n"+
+ " FragColor = vec4( color.rgb, uColor.a * color.a );\n"+
+ "}\n";
+
+ public struct Vec2
+ {
+ float x;
+ float y;
+ public Vec2(float xIn, float yIn)
+ {
+ x = xIn;
+ y = yIn;
+ }
+ }
+
+ private struct TexturedQuadVertex
+ {
+ public Vec2 position;
+ public Vec2 texCoord;
+ };
+
+ private Renderer CreateRenderer()
+ {
+ TexturedQuadVertex vertex1 = new TexturedQuadVertex();
+ TexturedQuadVertex vertex2 = new TexturedQuadVertex();
+ TexturedQuadVertex vertex3 = new TexturedQuadVertex();
+ TexturedQuadVertex vertex4 = new TexturedQuadVertex();
+ vertex1.position = new Vec2(-0.5f, -0.5f);
+ vertex2.position = new Vec2( 0.5f, -0.5f);
+ vertex3.position = new Vec2(-0.5f, 0.5f);
+ vertex4.position = new Vec2( 0.5f, 0.5f);
+ vertex1.texCoord = new Vec2( 0.0f, 0.0f);
+ vertex2.texCoord = new Vec2( 1.0f, 0.0f);
+ vertex3.texCoord = new Vec2( 0.0f, 1.0f);
+ vertex4.texCoord = new Vec2( 1.0f, 1.0f);
+
+ TexturedQuadVertex[] texturedQuadVertexData = new TexturedQuadVertex[4] { vertex1, vertex2, vertex3, vertex4 };
+
+ PropertyMap property = new PropertyMap();
+ property.Add("aPosition", new PropertyValue((int)PropertyType.Vector2));
+ property.Add("aTexCoord", new PropertyValue((int)PropertyType.Vector2));
+ PropertyBuffer vertexBuffer = new PropertyBuffer(property);
+
+ const int vertexCount = 4;
+ unsafe
+ {
+ float* pc = (float*)Marshal.UnsafeAddrOfPinnedArrayElement(texturedQuadVertexData, 0);
+ IntPtr pA = new IntPtr(pc);
+ vertexBuffer.SetData(pA, vertexCount);
+ }
+
+ Geometry geometry = new Geometry();
+ geometry.AddVertexBuffer(vertexBuffer);
+ geometry.SetType(Geometry.Type.TRIANGLE_STRIP);
+
+ // Create the shader
+ Shader shader = new Shader( VERSION_3_ES + VERTEX_SHADER, VERSION_3_ES + FRAGMENT_SHADER );
+
+ // Create the renderer
+ Renderer renderer = new Renderer( geometry, shader );
+
+ return renderer;
+ }
+
+ private uint GetBytesPerPixel(PixelFormat pixelFormat)
+ {
+ switch (pixelFormat)
+ {
+ case PixelFormat.L8:
+ case PixelFormat.A8:
+ {
+ return 1;
+ }
+
+ case PixelFormat.LA88:
+ case PixelFormat.RGB565:
+ case PixelFormat.RGBA4444:
+ case PixelFormat.RGBA5551:
+ case PixelFormat.BGR565:
+ case PixelFormat.BGRA4444:
+ case PixelFormat.BGRA5551:
+ {
+ return 2;
+ }
+
+ case PixelFormat.RGB888:
+ {
+ return 3;
+ }
+
+ case PixelFormat.RGB8888:
+ case PixelFormat.BGR8888:
+ case PixelFormat.RGBA8888:
+ case PixelFormat.BGRA8888:
+ {
+ return 4;
+ }
+ default:
+ return 4;
+ }
+ return 0;
+ }
+
+ TextureSet CreateTextureSet( RendererParameters textParameters, List<string> embeddedItems )
+ {
+ EmbeddedItemInfo[] embeddedItemLayout = new EmbeddedItemInfo[0];
+ PixelBuffer pixelBuffer = TextUtils.Render( textParameters, ref embeddedItemLayout );
+
+ uint dstWidth = pixelBuffer.GetWidth();
+ uint dstHeight = pixelBuffer.GetHeight();
+
+ int index = 0;
+ int length = embeddedItemLayout.Length;
+ for(int i = 0; i < length; i++)
+ {
+ EmbeddedItemInfo itemLayout = embeddedItemLayout[i];
+ int width = (int)itemLayout.Size.Width;
+ int height = (int)itemLayout.Size.Height;
+
+ int x = (int)itemLayout.Position.X;
+ int y = (int)itemLayout.Position.Y;
+
+ PixelBuffer itemPixelBuffer = ImageLoading.LoadImageFromFile(embeddedItems[index++]);
+
+ if( itemPixelBuffer == null ) continue;
+
+ itemPixelBuffer.Resize( (ushort)width, (ushort)height );
+ itemPixelBuffer.Rotate( itemLayout.Angle );
+
+
+ width = (int)itemPixelBuffer.GetWidth();
+ height = (int)itemPixelBuffer.GetHeight();
+
+ PixelFormat itemPixelFormat = itemPixelBuffer.GetPixelFormat();
+
+ // Check if the item is out of the buffer.
+ if( ( x + width < 0 ) ||
+ ( x > dstWidth ) ||
+ ( y < 0 ) ||
+ ( y - height > dstHeight ) )
+ {
+ // The embedded item is completely out of the buffer.
+ continue;
+ }
+
+ // Crop if it exceeds the boundaries of the destination buffer.
+ int layoutX = 0;
+ int layoutY = 0;
+ int cropX = 0;
+ int cropY = 0;
+ int newWidth = width;
+ int newHeight = height;
+
+ bool crop = false;
+
+ if( 0 > x )
+ {
+ newWidth += x;
+ cropX = Math.Abs( x );
+ crop = true;
+ }
+ else
+ {
+ layoutX = x;
+ }
+
+ if( cropX + newWidth > dstWidth )
+ {
+ crop = true;
+ newWidth -= (int)( ( cropX + newWidth ) - dstWidth );
+ }
+
+ layoutY = y;
+ if( 0 > layoutY )
+ {
+ newHeight += layoutY;
+ cropY = Math.Abs(layoutY);
+ crop = true;
+ }
+
+ if( cropY + newHeight > dstHeight )
+ {
+ crop = true;
+ newHeight -= (int)( ( cropY + newHeight ) - dstHeight );
+ }
+
+ int uiCropX = cropX;
+ int uiCropY = cropY;
+ int uiNewWidth = newWidth;
+ int uiNewHeight = newHeight;
+
+ if( crop )
+ {
+ itemPixelBuffer.Crop( (ushort)uiCropX, (ushort)uiCropY, (ushort)uiNewWidth, (ushort)uiNewHeight );
+ }
+
+ // Blend the item pixel buffer with the text's color according its blending mode.
+ if( ColorBlendingMode.Multiply == itemLayout.ColorBlendingMode )
+ {
+ PixelBuffer buffer = new PixelBuffer( (uint)uiNewWidth, (uint)uiNewHeight, itemPixelFormat );
+
+ IntPtr bufferIntPtr = buffer.GetBuffer();
+ IntPtr itemBufferIntPtr = itemPixelBuffer.GetBuffer();
+
+ uint bytesPerPixel = GetBytesPerPixel(itemPixelFormat);
+ uint size = (uint)(uiNewWidth * uiNewHeight * bytesPerPixel);
+
+
+ unsafe {
+ byte *bufferPtr = (byte *)bufferIntPtr.ToPointer();
+ byte *itemBufferPtr = (byte *)itemBufferIntPtr.ToPointer();
+
+ for (uint j = 0; j < size; j += bytesPerPixel)
+ {
+ *(bufferPtr + 0) = (byte)( ( *(itemBufferPtr + 0u) ) * textParameters.TextColor.R );
+ *(bufferPtr + 1) = (byte)( ( *(itemBufferPtr + 1u) ) * textParameters.TextColor.G );
+ *(bufferPtr + 2) = (byte)( ( *(itemBufferPtr + 2u) ) * textParameters.TextColor.B );
+ *(bufferPtr + 3) = (byte)( ( *(itemBufferPtr + 3u) ) * textParameters.TextColor.A );
+
+ itemBufferPtr += bytesPerPixel;
+ bufferPtr += bytesPerPixel;
+ }
+ }
+
+ itemPixelBuffer = buffer;
+ }
+
+ TextUtils.UpdateBuffer(itemPixelBuffer, pixelBuffer, (uint)layoutX, (uint)layoutY, true);
+ }
+
+ PixelData pixelData = PixelBuffer.Convert( pixelBuffer );
+
+ Texture texture = new Texture( TextureType.TEXTURE_2D,
+ pixelData.GetPixelFormat(),
+ pixelData.GetWidth(),
+ pixelData.GetHeight() );
+ texture.Upload(pixelData);
+
+ TextureSet textureSet = new TextureSet();
+ textureSet.SetTexture( 0u, texture );
+
+ return textureSet;
+
+ }
+
+
+
+ private View root;
+ static string DEMO_IMAGE_DIR = CommonResource.GetDaliResourcePath() + "DaliDemo/";
+ static string IMAGE1 = DEMO_IMAGE_DIR + "application-icon-1.png";
+ static string IMAGE2 = DEMO_IMAGE_DIR + "application-icon-6.png";
+
+ public void Activate()
+ {
+ Window window = NUIApplication.GetDefaultWindow();
+
+ root = new View()
+ {
+ Size = window.Size,
+ BackgroundColor = Color.Yellow,
+ ParentOrigin = ParentOrigin.TopLeft,
+ PivotPoint = PivotPoint.TopLeft,
+ PositionUsesPivotPoint = true,
+ };
+ window.Add(root);
+
+ string image1 = "<item 'width'=26 'height'=26 'url'='" + IMAGE1 + "'/>";
+ string image2 = "<item 'width'=26 'height'=26/>";
+
+ RendererParameters textParameters = new RendererParameters();
+ textParameters.Text = "Hello " + image1 + " world " + image2 + " this " + image1 + " is " + image2 + " a " + image1 + " demo " + image2 + " of " + image1 + " circular " + image2 + " text " + image1 + " width " + image2 + " icons.";
+ textParameters.HorizontalAlignment = HorizontalAlignment.Center;
+ textParameters.VerticalAlignment = VerticalAlignment.Center;
+ textParameters.CircularAlignment = CircularAlignment.Center;
+ textParameters.FontFamily = "SamsungUI";
+ textParameters.FontWeight = "";
+ textParameters.FontWidth = "";
+ textParameters.FontSlant = "";
+ textParameters.Layout = TextLayout.Circular;
+ textParameters.TextColor = Color.Black;
+ textParameters.FontSize = 25;
+ textParameters.TextWidth = 360u;
+ textParameters.TextHeight = 360u;
+ textParameters.Radius = 180u;
+ textParameters.BeginAngle = 15;
+ textParameters.IncrementAngle = 360;
+ textParameters.EllipsisEnabled = true;
+ textParameters.MarkupEnabled = true;
+
+ List<string> embeddedItems = new List<string>();
+ embeddedItems.Add(IMAGE2);
+ embeddedItems.Add(IMAGE2);
+ embeddedItems.Add(IMAGE2);
+ embeddedItems.Add(IMAGE2);
+ embeddedItems.Add(IMAGE2);
+
+ TextureSet textureSet = CreateTextureSet( textParameters, embeddedItems );
+ Renderer renderer = CreateRenderer();
+ renderer.SetTextures( textureSet );
+
+ View actor = new View();
+ actor.PivotPoint = PivotPoint.TopLeft;
+ actor.ParentOrigin = ParentOrigin.TopLeft;
+ actor.Position = new Position(0, 0, 0);
+ actor.Size = new Size( 360, 360 );
+ actor.Color = Color.White;
+
+ actor.AddRenderer( renderer );
+ root.Add(actor);
+ }
+
+
+ public void Deactivate()
+ {
+ if (root != null)
+ {
+ NUIApplication.GetDefaultWindow().Remove(root);
+ root.Dispose();
+ }
+ }
+ }
+}
\ No newline at end of file