1 // Copyright (c) 2021 Samsung Electronics Co., Ltd.
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
7 // http://www.apache.org/licenses/LICENSE-2.0
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
16 using System.ComponentModel;
17 using System.Diagnostics.CodeAnalysis;
19 namespace Tizen.NUI.Text
22 /// A struct to pass data of InputFilter PropertyMap. <br />
25 /// InputFilter filters input based on regular expressions. <br />
26 /// Users can set the Accepted or Rejected regular expression set, or both. <br />
27 /// If both are used, Rejected has higher priority. <br />
28 /// The character set must follow the regular expression rules. <br />
29 /// Behaviour can not be guaranteed for incorrect grammars. <br />
30 /// Refer the link below for detailed rules. <br />
31 /// The functions in std::regex library use the ECMAScript grammar: <br />
32 /// http://cplusplus.com/reference/regex/ECMAScript/ <br />
33 /// The InputFilter struct is used as an argument to SetInputFilter and GetInputFilter methods. <br />
34 /// See <see cref="Tizen.NUI.BaseComponents.TextField.SetInputFilter"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetInputFilter"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetInputFilter"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetInputFilter"/>. <br />
36 /// <since_tizen> 9 </since_tizen>
37 public struct InputFilter : IEquatable<InputFilter>
40 /// A regular expression in the set of characters to be accepted by the inputFilter.
42 public string Accepted { get; set; }
45 /// A regular expression in the set of characters to be rejected by the inputFilter.
47 public string Rejected { get; set; }
50 /// Determines whether the specified object is equal to the current object.
52 /// <param name="obj">The object to compare with the current object.</param>
53 /// <returns>true if equal InputFilter, else false.</returns>
54 [EditorBrowsable(EditorBrowsableState.Never)]
55 public override bool Equals(object obj) => obj is InputFilter other && this.Equals(other);
58 /// Determines whether the specified object is equal to the current object.
60 /// <param name="other">The InputFilter to compare with the current InputFilter.</param>
61 /// <returns>true if equal InputFilter, else false.</returns>
62 [EditorBrowsable(EditorBrowsableState.Never)]
63 public bool Equals(InputFilter other) => Accepted == other.Accepted && Rejected == other.Rejected;
68 /// <param name="lhsInputFilter">InputFilter to compare</param>
69 /// <param name="rhsInputFilter">InputFilter to be compared</param>
70 /// <returns>true if InputFilters are equal</returns>
71 [EditorBrowsable(EditorBrowsableState.Never)]
72 public static bool operator ==(InputFilter lhsInputFilter, InputFilter rhsInputFilter) => lhsInputFilter.Equals(rhsInputFilter);
77 /// <param name="lhsInputFilter">InputFilter to compare</param>
78 /// <param name="rhsInputFilter">InputFilter to be compared</param>
79 /// <returns>true if InputFilters are not equal</returns>
80 [EditorBrowsable(EditorBrowsableState.Never)]
81 public static bool operator !=(InputFilter lhsInputFilter, InputFilter rhsInputFilter) => !lhsInputFilter.Equals(rhsInputFilter);
84 /// Gets the hash code of this InputFilter.
86 /// <returns>The hash code.</returns>
87 [EditorBrowsable(EditorBrowsableState.Never)]
88 public override int GetHashCode() => (Accepted, Rejected).GetHashCode();
92 /// A struct to pass data of Strikethrough PropertyMap. <br />
95 /// The Strikethrough struct is used as an argument to SetStrikethrough and GetStrikethrough methods. <br />
96 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetStrikethrough"/>, <see cref="Tizen.NUI.BaseComponents.TextLabel.GetStrikethrough"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetStrikethrough"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetStrikethrough"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetStrikethrough"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetStrikethrough"/>. <br />
98 [EditorBrowsable(EditorBrowsableState.Never)]
99 public struct Strikethrough : IEquatable<Strikethrough>
102 /// Whether the strikethrough is enabled (the default value is false).
104 [EditorBrowsable(EditorBrowsableState.Never)]
105 public bool Enable { get; set; }
108 /// The color of the strikethrough (if not provided then the color of the text is used).
110 [EditorBrowsable(EditorBrowsableState.Never)]
111 public Color Color { get; set; }
114 /// The height in pixels of the strikethrough (if null, the default value is 1.0f).
116 [EditorBrowsable(EditorBrowsableState.Never)]
117 public float? Height { get; set; }
120 /// Determines whether the specified object is equal to the current object.
122 /// <param name="obj">The object to compare with the current object.</param>
123 /// <returns>true if equal Strikethrough, else false.</returns>
124 [EditorBrowsable(EditorBrowsableState.Never)]
125 public override bool Equals(object obj) => obj is Strikethrough other && this.Equals(other);
128 /// Determines whether the specified object is equal to the current object.
130 /// <param name="other">The Strikethrough to compare with the current Strikethrough.</param>
131 /// <returns>true if equal Strikethrough, else false.</returns>
132 [EditorBrowsable(EditorBrowsableState.Never)]
133 public bool Equals(Strikethrough other) => Enable == other.Enable && Color == other.Color && Height == other.Height;
138 /// <param name="lhsStrikethrough">Strikethrough to compare</param>
139 /// <param name="rhsStrikethrough">Strikethrough to be compared</param>
140 /// <returns>true if Strikethroughs are equal</returns>
141 [EditorBrowsable(EditorBrowsableState.Never)]
142 public static bool operator ==(Strikethrough lhsStrikethrough, Strikethrough rhsStrikethrough) => lhsStrikethrough.Equals(rhsStrikethrough);
147 /// <param name="lhsStrikethrough">Strikethrough to compare</param>
148 /// <param name="rhsStrikethrough">Strikethrough to be compared</param>
149 /// <returns>true if Strikethroughs are not equal</returns>
150 [EditorBrowsable(EditorBrowsableState.Never)]
151 public static bool operator !=(Strikethrough lhsStrikethrough, Strikethrough rhsStrikethrough) => !lhsStrikethrough.Equals(rhsStrikethrough);
154 /// Gets the hash code of this Strikethrough.
156 /// <returns>The hash code.</returns>
157 [EditorBrowsable(EditorBrowsableState.Never)]
158 public override int GetHashCode() => (Enable, Color, Height).GetHashCode();
162 /// A struct to pass data of FontStyle PropertyMap. <br />
165 /// The FontStyle struct is used as an argument to SetFontStyle and GetFontStyle methods. <br />
166 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetFontStyle"/>, <see cref="Tizen.NUI.BaseComponents.TextLabel.GetFontStyle"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetFontStyle"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetFontStyle"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetFontStyle"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetFontStyle"/>. <br />
168 [EditorBrowsable(EditorBrowsableState.Never)]
169 public struct FontStyle : IEquatable<FontStyle>
172 /// The Width defines occupied by each glyph.
174 [EditorBrowsable(EditorBrowsableState.Never)]
175 public FontWidthType Width { get; set; }
178 /// The Weight defines the thickness or darkness of the glyphs.
180 [EditorBrowsable(EditorBrowsableState.Never)]
181 public FontWeightType Weight { get; set; }
184 /// The Slant defines whether to use italics.
186 [EditorBrowsable(EditorBrowsableState.Never)]
187 public FontSlantType Slant { get; set; }
190 /// Determines whether the specified object is equal to the current object.
192 /// <param name="obj">The object to compare with the current object.</param>
193 /// <returns>true if equal FontStyle, else false.</returns>
194 [EditorBrowsable(EditorBrowsableState.Never)]
195 public override bool Equals(object obj) => obj is FontStyle other && this.Equals(other);
198 /// Determines whether the specified object is equal to the current object.
200 /// <param name="other">The FontStyle to compare with the current FontStyle.</param>
201 /// <returns>true if equal FontStyle, else false.</returns>
202 [EditorBrowsable(EditorBrowsableState.Never)]
203 public bool Equals(FontStyle other) => Width == other.Width && Weight == other.Weight && Slant == other.Slant;
208 /// <param name="lhsFontStyle">FontStyle to compare</param>
209 /// <param name="rhsFontStyle">FontStyle to be compared</param>
210 /// <returns>true if FontStyles are equal</returns>
211 [EditorBrowsable(EditorBrowsableState.Never)]
212 public static bool operator ==(FontStyle lhsFontStyle, FontStyle rhsFontStyle) => lhsFontStyle.Equals(rhsFontStyle);
217 /// <param name="lhsFontStyle">FontStyle to compare</param>
218 /// <param name="rhsFontStyle">FontStyle to be compared</param>
219 /// <returns>true if FontStyles are not equal</returns>
220 [EditorBrowsable(EditorBrowsableState.Never)]
221 public static bool operator !=(FontStyle lhsFontStyle, FontStyle rhsFontStyle) => !lhsFontStyle.Equals(rhsFontStyle);
224 /// Gets the hash code of this FontStyle.
226 /// <returns>The hash code.</returns>
227 [EditorBrowsable(EditorBrowsableState.Never)]
228 public override int GetHashCode() => (Width, Weight, Slant).GetHashCode();
232 /// A struct to pass data of Underline PropertyMap. <br />
235 /// The Underline struct is used as an argument to SetUnderline and GetUnderline methods. <br />
236 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetUnderline"/>, <see cref="Tizen.NUI.BaseComponents.TextLabel.GetUnderline"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetUnderline"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetUnderline"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetUnderline"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetUnderline"/>. <br />
238 [EditorBrowsable(EditorBrowsableState.Never)]
239 public struct Underline : IEquatable<Underline>
242 /// Whether the underline is enabled (the default value is false).
244 [EditorBrowsable(EditorBrowsableState.Never)]
245 public bool Enable { get; set; }
248 /// The type of the underline (the default type is Solid).
250 [EditorBrowsable(EditorBrowsableState.Never)]
251 public UnderlineType Type { get; set; }
254 /// The color of the underline (if not provided then the color of the text is used).
256 [EditorBrowsable(EditorBrowsableState.Never)]
257 public Color Color { get; set; }
260 /// The height in pixels of the underline (if null, the default value is 1.0f).
262 [EditorBrowsable(EditorBrowsableState.Never)]
263 public float? Height { get; set; }
266 /// The width of the dashes of the dashed underline (if null, the default value is 2.0f). <br />
267 /// Only valid when "UnderlineType.Dashed" type is used.
269 [EditorBrowsable(EditorBrowsableState.Never)]
270 public float? DashWidth { get; set; }
273 /// The gap between the dashes of the dashed underline (if null, the default value is 1.0f). <br />
274 /// Only valid when "UnderlineType.Dashed" type is used.
276 [EditorBrowsable(EditorBrowsableState.Never)]
277 public float? DashGap { get; set; }
280 /// Determines whether the specified object is equal to the current object.
282 /// <param name="obj">The object to compare with the current object.</param>
283 /// <returns>true if equal Underline, else false.</returns>
284 [EditorBrowsable(EditorBrowsableState.Never)]
285 public override bool Equals(object obj) => obj is Underline other && this.Equals(other);
288 /// Determines whether the specified object is equal to the current object.
290 /// <param name="other">The Underline to compare with the current Underline.</param>
291 /// <returns>true if equal Underline, else false.</returns>
292 [EditorBrowsable(EditorBrowsableState.Never)]
293 public bool Equals(Underline other) => Enable == other.Enable && Type == other.Type && Color == other.Color &&
294 Height == other.Height && DashWidth == other.DashWidth && DashGap == other.DashGap;
299 /// <param name="lhsUnderline">Underline to compare</param>
300 /// <param name="rhsUnderline">Underline to be compared</param>
301 /// <returns>true if Underlines are equal</returns>
302 [EditorBrowsable(EditorBrowsableState.Never)]
303 public static bool operator ==(Underline lhsUnderline, Underline rhsUnderline) => lhsUnderline.Equals(rhsUnderline);
308 /// <param name="lhsUnderline">Underline to compare</param>
309 /// <param name="rhsUnderline">Underline to be compared</param>
310 /// <returns>true if Underlines are not equal</returns>
311 [EditorBrowsable(EditorBrowsableState.Never)]
312 public static bool operator !=(Underline lhsUnderline, Underline rhsUnderline) => !lhsUnderline.Equals(rhsUnderline);
315 /// Gets the hash code of this Underline.
317 /// <returns>The hash code.</returns>
318 [EditorBrowsable(EditorBrowsableState.Never)]
319 public override int GetHashCode() => (Enable, Type, Color, Height, DashWidth, DashGap).GetHashCode();
323 /// A struct to pass data of Shadow PropertyMap. <br />
326 /// The Shadow struct is used as an argument to SetShadow and GetShadow methods. <br />
327 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetShadow"/>, <see cref="Tizen.NUI.BaseComponents.TextLabel.GetShadow"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetShadow"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetShadow"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetShadow"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetShadow"/>. <br />
329 [EditorBrowsable(EditorBrowsableState.Never)]
330 public struct Shadow : IEquatable<Shadow>
333 /// The color of the shadow (the default color is Color.Black).
335 [EditorBrowsable(EditorBrowsableState.Never)]
336 public Color Color { get; set; }
339 /// The offset in pixels of the shadow (if null, the default value is 0, 0). <br />
340 /// If not provided then the shadow is not enabled. <br />
343 [EditorBrowsable(EditorBrowsableState.Never)]
344 public Vector2 Offset { get; set; }
347 /// The radius of the Gaussian blur for the soft shadow (if null, the default value is 0.0f). <br />
348 /// If not provided then the soft shadow is not enabled. <br />
350 [EditorBrowsable(EditorBrowsableState.Never)]
351 public float? BlurRadius { get; set; }
354 /// Determines whether the specified object is equal to the current object.
356 /// <param name="obj">The object to compare with the current object.</param>
357 /// <returns>true if equal Shadow, else false.</returns>
358 [EditorBrowsable(EditorBrowsableState.Never)]
359 public override bool Equals(object obj) => obj is Shadow other && this.Equals(other);
362 /// Determines whether the specified object is equal to the current object.
364 /// <param name="other">The Shadow to compare with the current Shadow.</param>
365 /// <returns>true if equal Shadow, else false.</returns>
366 [EditorBrowsable(EditorBrowsableState.Never)]
367 public bool Equals(Shadow other) => Color == other.Color && Offset == other.Offset && BlurRadius == other.BlurRadius;
372 /// <param name="lhsShadow">Shadow to compare</param>
373 /// <param name="rhsShadow">Shadow to be compared</param>
374 /// <returns>true if Shadows are equal</returns>
375 [EditorBrowsable(EditorBrowsableState.Never)]
376 public static bool operator ==(Shadow lhsShadow, Shadow rhsShadow) => lhsShadow.Equals(rhsShadow);
381 /// <param name="lhsShadow">Shadow to compare</param>
382 /// <param name="rhsShadow">Shadow to be compared</param>
383 /// <returns>true if Shadows are not equal</returns>
384 [EditorBrowsable(EditorBrowsableState.Never)]
385 public static bool operator !=(Shadow lhsShadow, Shadow rhsShadow) => !lhsShadow.Equals(rhsShadow);
388 /// Gets the hash code of this Shadow.
390 /// <returns>The hash code.</returns>
391 [EditorBrowsable(EditorBrowsableState.Never)]
392 public override int GetHashCode() => (Color, Offset, BlurRadius).GetHashCode();
396 /// A struct to pass data of Outline PropertyMap. <br />
399 /// The Outline struct is used as an argument to SetOutline and GetOutline methods. <br />
400 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetOutline"/>, <see cref="Tizen.NUI.BaseComponents.TextLabel.GetOutline"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetOutline"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetOutline"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetOutline"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetOutline"/>. <br />
402 [EditorBrowsable(EditorBrowsableState.Never)]
403 public struct Outline : IEquatable<Outline>
406 /// The color of the outline (the default color is Color.White).
408 [EditorBrowsable(EditorBrowsableState.Never)]
409 public Color Color { get; set; }
412 /// The width in pixels of the outline (if null, the default value is 0.0f). <br />
413 /// If not provided then the outline is not enabled. <br />
415 [EditorBrowsable(EditorBrowsableState.Never)]
416 public float? Width { get; set; }
419 /// Determines whether the specified object is equal to the current object.
421 /// <param name="obj">The object to compare with the current object.</param>
422 /// <returns>true if equal Outline, else false.</returns>
423 [EditorBrowsable(EditorBrowsableState.Never)]
424 public override bool Equals(object obj) => obj is Outline other && this.Equals(other);
427 /// Determines whether the specified object is equal to the current object.
429 /// <param name="other">The Outline to compare with the current Outline.</param>
430 /// <returns>true if equal Outline, else false.</returns>
431 [EditorBrowsable(EditorBrowsableState.Never)]
432 public bool Equals(Outline other) => Color == other.Color && Width == other.Width;
437 /// <param name="lhsOutline">Outline to compare</param>
438 /// <param name="rhsOutline">Outline to be compared</param>
439 /// <returns>true if Outlines are equal</returns>
440 [EditorBrowsable(EditorBrowsableState.Never)]
441 public static bool operator ==(Outline lhsOutline, Outline rhsOutline) => lhsOutline.Equals(rhsOutline);
446 /// <param name="lhsOutline">Outline to compare</param>
447 /// <param name="rhsOutline">Outline to be compared</param>
448 /// <returns>true if Outlines are not equal</returns>
449 [EditorBrowsable(EditorBrowsableState.Never)]
450 public static bool operator !=(Outline lhsOutline, Outline rhsOutline) => !lhsOutline.Equals(rhsOutline);
453 /// Gets the hash code of this Outline.
455 /// <returns>The hash code.</returns>
456 [EditorBrowsable(EditorBrowsableState.Never)]
457 public override int GetHashCode() => (Color, Width).GetHashCode();
461 /// A struct to pass data of TextFit PropertyMap. <br />
464 /// The TextFit struct is used as an argument to SetTextFit and GetTextFit methods. <br />
465 /// See <see cref="Tizen.NUI.BaseComponents.TextLabel.SetTextFit"/> and <see cref="Tizen.NUI.BaseComponents.TextLabel.GetTextFit"/>. <br />
467 [EditorBrowsable(EditorBrowsableState.Never)]
468 public struct TextFit : IEquatable<TextFit>
471 /// True to enable the text fit or false to disable (the default value is false).
473 [EditorBrowsable(EditorBrowsableState.Never)]
474 public bool Enable { get; set; }
477 /// Minimum Size for text fit (if null, the default value is 10.0f).
479 [EditorBrowsable(EditorBrowsableState.Never)]
480 public float? MinSize { get; set; }
483 /// Maximum Size for text fit (if null, the default value is 100.0f).
485 [EditorBrowsable(EditorBrowsableState.Never)]
486 public float? MaxSize { get; set; }
489 /// Step Size for font increase (if null, the default value is 1.0f).
491 [EditorBrowsable(EditorBrowsableState.Never)]
492 public float? StepSize { get; set; }
495 /// The size type of font, PointSize or PixelSize (the default value is PointSize).
497 [EditorBrowsable(EditorBrowsableState.Never)]
498 public FontSizeType FontSizeType { get; set; }
501 /// Font Size for text fit
503 [EditorBrowsable(EditorBrowsableState.Never)]
504 public float? FontSize { get; set; }
507 /// Determines whether the specified object is equal to the current object.
509 /// <param name="obj">The object to compare with the current object.</param>
510 /// <returns>true if equal TextFit, else false.</returns>
511 [EditorBrowsable(EditorBrowsableState.Never)]
512 public override bool Equals(object obj) => obj is TextFit other && this.Equals(other);
515 /// Determines whether the specified object is equal to the current object.
517 /// <param name="other">The TextFit to compare with the current TextFit.</param>
518 /// <returns>true if equal TextFit, else false.</returns>
519 [EditorBrowsable(EditorBrowsableState.Never)]
520 public bool Equals(TextFit other) => Enable == other.Enable && MinSize == other.MinSize && MaxSize == other.MaxSize &&
521 StepSize == other.StepSize && FontSizeType == other.FontSizeType && FontSize == other.FontSize;
526 /// <param name="lhsTextFit">TextFit to compare</param>
527 /// <param name="rhsTextFit">TextFit to be compared</param>
528 /// <returns>true if TextFits are equal</returns>
529 [EditorBrowsable(EditorBrowsableState.Never)]
530 public static bool operator ==(TextFit lhsTextFit, TextFit rhsTextFit) => lhsTextFit.Equals(rhsTextFit);
535 /// <param name="lhsTextFit">TextFit to compare</param>
536 /// <param name="rhsTextFit">TextFit to be compared</param>
537 /// <returns>true if TextFits are not equal</returns>
538 [EditorBrowsable(EditorBrowsableState.Never)]
539 public static bool operator !=(TextFit lhsTextFit, TextFit rhsTextFit) => !lhsTextFit.Equals(rhsTextFit);
542 /// Gets the hash code of this TextFit.
544 /// <returns>The hash code.</returns>
545 [EditorBrowsable(EditorBrowsableState.Never)]
546 public override int GetHashCode() => (Enable, MinSize, MaxSize, StepSize, FontSizeType, FontSize).GetHashCode();
550 /// A struct to pass data of Placeholder PropertyMap. <br />
553 /// The Placeholder struct is used as an argument to SetPlaceholder and GetPlaceholder methods. <br />
554 /// See <see cref="Tizen.NUI.BaseComponents.TextField.SetPlaceholder"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetPlaceholder"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetPlaceholder"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.SetPlaceholder"/>. <br />
556 [EditorBrowsable(EditorBrowsableState.Never)]
557 public struct Placeholder : IEquatable<Placeholder>
560 /// The text to display when the TextField is empty and inactive.
562 [EditorBrowsable(EditorBrowsableState.Never)]
563 public string Text { get; set; }
566 /// The text to display when the placeholder has focus.
568 [EditorBrowsable(EditorBrowsableState.Never)]
569 public string TextFocused { get; set; }
572 /// The color of the placeholder text.
574 [EditorBrowsable(EditorBrowsableState.Never)]
575 public Color Color { get; set; }
578 /// The FontFamily of the placeholder text.
580 [EditorBrowsable(EditorBrowsableState.Never)]
581 public string FontFamily { get; set; }
584 /// The FontStyle of the placeholder text (if null, the text control FontStyle is used).
586 [EditorBrowsable(EditorBrowsableState.Never)]
587 public FontStyle? FontStyle { get; set; }
590 /// The PointSize of the placeholder text. <br />
591 /// Not required if PixelSize provided. <br />
592 /// If both provided or neither provided then the text control point size is used. <br />
594 [EditorBrowsable(EditorBrowsableState.Never)]
595 public float? PointSize { get; set; }
598 /// The PiexSize of the placeholder text.
599 /// Not required if PointSize provided. <br />
600 /// If both provided or neither provided then the text control point size is used. <br />
602 [EditorBrowsable(EditorBrowsableState.Never)]
603 public float? PixelSize { get; set; }
606 /// The ellipsis of the placeholder text (the default value is false).
608 [EditorBrowsable(EditorBrowsableState.Never)]
609 public bool Ellipsis { get; set; }
612 /// Determines whether the specified object is equal to the current object.
614 /// <param name="obj">The object to compare with the current object.</param>
615 /// <returns>true if equal Placeholder, else false.</returns>
616 [EditorBrowsable(EditorBrowsableState.Never)]
617 public override bool Equals(object obj) => obj is Placeholder other && this.Equals(other);
620 /// Determines whether the specified object is equal to the current object.
622 /// <param name="other">The Placeholder to compare with the current Placeholder.</param>
623 /// <returns>true if equal Placeholder, else false.</returns>
624 [EditorBrowsable(EditorBrowsableState.Never)]
625 public bool Equals(Placeholder other) =>
626 Text == other.Text && TextFocused == other.TextFocused && Color == other.Color && FontFamily == other.FontFamily &&
627 FontStyle == other.FontStyle && PointSize == other.PointSize && PixelSize == other.PixelSize && Ellipsis == other.Ellipsis;
632 /// <param name="lhsPlaceholder">Placeholder to compare</param>
633 /// <param name="rhsPlaceholder">Placeholder to be compared</param>
634 /// <returns>true if Placeholders are equal</returns>
635 [EditorBrowsable(EditorBrowsableState.Never)]
636 public static bool operator ==(Placeholder lhsPlaceholder, Placeholder rhsPlaceholder) => lhsPlaceholder.Equals(rhsPlaceholder);
641 /// <param name="lhsPlaceholder">Placeholder to compare</param>
642 /// <param name="rhsPlaceholder">Placeholder to be compared</param>
643 /// <returns>true if Placeholders are not equal</returns>
644 [EditorBrowsable(EditorBrowsableState.Never)]
645 public static bool operator !=(Placeholder lhsPlaceholder, Placeholder rhsPlaceholder) => !lhsPlaceholder.Equals(rhsPlaceholder);
648 /// Gets the hash code of this Placeholder.
650 /// <returns>The hash code.</returns>
651 [EditorBrowsable(EditorBrowsableState.Never)]
652 public override int GetHashCode() => (Text, TextFocused, Color, FontFamily, FontStyle, PointSize, PixelSize, Ellipsis).GetHashCode();
656 /// A struct to pass data of HiddenInputSettings PropertyMap. <br />
659 /// The HiddenInput struct is used as an argument to SetHiddenInput and GetHiddenInput methods. <br />
660 /// See <see cref="Tizen.NUI.BaseComponents.TextField.SetHiddenInput"/> and <see cref="Tizen.NUI.BaseComponents.TextField.GetHiddenInput"/>. <br />
662 [EditorBrowsable(EditorBrowsableState.Never)]
663 public struct HiddenInput : IEquatable<HiddenInput>
666 /// The mode for input text display. <br />
668 [EditorBrowsable(EditorBrowsableState.Never)]
669 public HiddenInputModeType Mode { get; set; }
672 /// All input characters are substituted by this character (if null, the default value is '*'). <br />
674 [EditorBrowsable(EditorBrowsableState.Never)]
675 public char? SubstituteCharacter { get; set; }
678 /// Length of text to show or hide, available when HideCount/ShowCount mode is used (if null, the default value is 0). <br />
680 [EditorBrowsable(EditorBrowsableState.Never)]
681 public int? SubstituteCount { get; set; }
684 /// Hide last character after this duration, available when ShowLastCharacter mode (if null, the default value is 1000). <br />
686 [EditorBrowsable(EditorBrowsableState.Never)]
687 public int? ShowLastCharacterDuration { get; set; }
690 /// Determines whether the specified object is equal to the current object.
692 /// <param name="obj">The object to compare with the current object.</param>
693 /// <returns>true if equal HiddenInput, else false.</returns>
694 [EditorBrowsable(EditorBrowsableState.Never)]
695 public override bool Equals(object obj) => obj is HiddenInput other && this.Equals(other);
698 /// Determines whether the specified object is equal to the current object.
700 /// <param name="other">The HiddenInput to compare with the current HiddenInput.</param>
701 /// <returns>true if equal HiddenInput, else false.</returns>
702 [EditorBrowsable(EditorBrowsableState.Never)]
703 public bool Equals(HiddenInput other) => Mode == other.Mode && SubstituteCharacter == other.SubstituteCharacter &&
704 SubstituteCount == other.SubstituteCount && ShowLastCharacterDuration == other.ShowLastCharacterDuration;
709 /// <param name="lhsHiddenInput">HiddenInput to compare</param>
710 /// <param name="rhsHiddenInput">HiddenInput to be compared</param>
711 /// <returns>true if HiddenInputs are equal</returns>
712 [EditorBrowsable(EditorBrowsableState.Never)]
713 public static bool operator ==(HiddenInput lhsHiddenInput, HiddenInput rhsHiddenInput) => lhsHiddenInput.Equals(rhsHiddenInput);
718 /// <param name="lhsHiddenInput">HiddenInput to compare</param>
719 /// <param name="rhsHiddenInput">HiddenInput to be compared</param>
720 /// <returns>true if HiddenInputs are not equal</returns>
721 [EditorBrowsable(EditorBrowsableState.Never)]
722 public static bool operator !=(HiddenInput lhsHiddenInput, HiddenInput rhsHiddenInput) => !lhsHiddenInput.Equals(rhsHiddenInput);
725 /// Gets the hash code of this HiddenInput.
727 /// <returns>The hash code.</returns>
728 [EditorBrowsable(EditorBrowsableState.Never)]
729 public override int GetHashCode() => (Mode, SubstituteCharacter, SubstituteCount, ShowLastCharacterDuration).GetHashCode();
733 /// A struct to pass data of SelectionHandleImageLeft, SelectionHandleImageRight, SelectionHandlePressedImageLeft, SelectionHandlePressedImageRight, SelectionHandleMarkerImageLeft and SelectionHandleMarkerImageRight PropertyMap. <br />
736 /// The SelectionHandleImage struct is used as an argument to SetSelectionHandleImage, GetSelectionHandleImage methods, SetSelectionHandlePressedImage, GetSelectionHandlePressedImage, SetSelectionHandleMarkerImage and GetSelectionHandleMarkerImage. <br />
737 /// See <see cref="Tizen.NUI.BaseComponents.TextField.SetSelectionHandleImage"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetSelectionHandleImage"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetSelectionHandlePressedImage"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetSelectionHandlePressedImage"/>, <see cref="Tizen.NUI.BaseComponents.TextField.SetSelectionHandleMarkerImage"/>, <see cref="Tizen.NUI.BaseComponents.TextField.GetSelectionHandleMarkerImage"/>, <br />
738 /// <see cref="Tizen.NUI.BaseComponents.TextEditor.SetSelectionHandleImage"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.GetSelectionHandleImage"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetSelectionHandlePressedImage"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.GetSelectionHandlePressedImage"/>, <see cref="Tizen.NUI.BaseComponents.TextEditor.SetSelectionHandleMarkerImage"/> and <see cref="Tizen.NUI.BaseComponents.TextEditor.GetSelectionHandleMarkerImage"/>. <br />
740 [EditorBrowsable(EditorBrowsableState.Never)]
741 public struct SelectionHandleImage : IEquatable<SelectionHandleImage>
744 /// The image path to display for the left selection handle. <br />
745 /// It means the handle in the bottom-left. <br />
746 /// If the handle needs to be displayed in the top-left, this image will be vertically flipped. <br />
747 /// If null or empty string, it doesn't change the property. <br />
749 [EditorBrowsable(EditorBrowsableState.Never)]
750 public string LeftImageUrl { get; set; }
753 /// The image path to display for the right selection handle. <br />
754 /// It means the handle in the bottom-right. <br />
755 /// If the handle needs to be displayed in the top-right, this image will be vertically flipped. <br />
756 /// If null or empty string, it doesn't change the property. <br />
758 [EditorBrowsable(EditorBrowsableState.Never)]
759 public string RightImageUrl { get; set; }
762 /// Determines whether the specified object is equal to the current object.
764 /// <param name="obj">The object to compare with the current object.</param>
765 /// <returns>true if equal SelectionHandleImage, else false.</returns>
766 [EditorBrowsable(EditorBrowsableState.Never)]
767 public override bool Equals(object obj) => obj is SelectionHandleImage other && this.Equals(other);
770 /// Determines whether the specified object is equal to the current object.
772 /// <param name="other">The SelectionHandleImage to compare with the current SelectionHandleImage.</param>
773 /// <returns>true if equal SelectionHandleImage, else false.</returns>
774 [EditorBrowsable(EditorBrowsableState.Never)]
775 public bool Equals(SelectionHandleImage other) => LeftImageUrl == other.LeftImageUrl && RightImageUrl == other.RightImageUrl;
780 /// <param name="lhsSelectionHandleImage">SelectionHandleImage to compare</param>
781 /// <param name="rhsSelectionHandleImage">SelectionHandleImage to be compared</param>
782 /// <returns>true if SelectionHandleImages are equal</returns>
783 [EditorBrowsable(EditorBrowsableState.Never)]
784 public static bool operator ==(SelectionHandleImage lhsSelectionHandleImage, SelectionHandleImage rhsSelectionHandleImage)
785 => lhsSelectionHandleImage.Equals(rhsSelectionHandleImage);
790 /// <param name="lhsSelectionHandleImage">SelectionHandleImage to compare</param>
791 /// <param name="rhsSelectionHandleImage">SelectionHandleImage to be compared</param>
792 /// <returns>true if SelectionHandleImages are not equal</returns>
793 [EditorBrowsable(EditorBrowsableState.Never)]
794 public static bool operator !=(SelectionHandleImage lhsSelectionHandleImage, SelectionHandleImage rhsSelectionHandleImage)
795 => !lhsSelectionHandleImage.Equals(rhsSelectionHandleImage);
798 /// Gets the hash code of this SelectionHandleImage.
800 /// <returns>The hash code.</returns>
801 [EditorBrowsable(EditorBrowsableState.Never)]
802 public override int GetHashCode() => (LeftImageUrl, RightImageUrl).GetHashCode();
806 /// A struct to pass data of FontInfo PropertyMap.
808 [EditorBrowsable(EditorBrowsableState.Never)]
809 public struct FontInfo : IEquatable<FontInfo>
812 /// The FontFamily of the font.
814 [EditorBrowsable(EditorBrowsableState.Never)]
815 public string Family { get; set; }
818 /// The FontPath of the font.
820 [EditorBrowsable(EditorBrowsableState.Never)]
821 public string Path { get; set; }
824 /// The FontStyle of the font.
826 [EditorBrowsable(EditorBrowsableState.Never)]
827 public FontStyle Style { get; set; }
830 /// Determines whether the specified object is equal to the current object.
832 /// <param name="obj">The object to compare with the current object.</param>
833 /// <returns>true if equal FontInfo, else false.</returns>
834 [EditorBrowsable(EditorBrowsableState.Never)]
835 public override bool Equals(object obj) => obj is FontInfo other && this.Equals(other);
838 /// Determines whether the specified object is equal to the current object.
840 /// <param name="other">The FontInfo to compare with the current FontInfo.</param>
841 /// <returns>true if equal FontInfo, else false.</returns>
842 [EditorBrowsable(EditorBrowsableState.Never)]
843 public bool Equals(FontInfo other) => Family == other.Family && Path == other.Path && Style == other.Style;
848 /// <param name="lhsFontInfo">FontInfo to compare</param>
849 /// <param name="rhsFontInfo">FontInfo to be compared</param>
850 /// <returns>true if FontInfos are equal</returns>
851 [EditorBrowsable(EditorBrowsableState.Never)]
852 public static bool operator ==(FontInfo lhsFontInfo, FontInfo rhsFontInfo) => lhsFontInfo.Equals(rhsFontInfo);
857 /// <param name="lhsFontInfo">FontInfo to compare</param>
858 /// <param name="rhsFontInfo">FontInfo to be compared</param>
859 /// <returns>true if FontInfos are not equal</returns>
860 [EditorBrowsable(EditorBrowsableState.Never)]
861 public static bool operator !=(FontInfo lhsFontInfo, FontInfo rhsFontInfo) => !lhsFontInfo.Equals(rhsFontInfo);
864 /// Gets the hash code of this FontInfo.
866 /// <returns>The hash code.</returns>
867 [EditorBrowsable(EditorBrowsableState.Never)]
868 public override int GetHashCode() => (Family, Path, Style).GetHashCode();