Struct Margins

Struct Margins

Именује се: Aspose.Note Асамблеја: Aspose.Note.dll (25.4.0)

Потврђује димензије маргина унука.

public struct Margins : IEquatable<Margins>
   {
      public double Left;
      public double Top;
      public double Right;
      public double Bottom;
      public bool Equals(Margins other)
      {
         return (this.Left == other.Left && this.Top == other.Top && this.Right == other.Right && this.Bottom == other.Bottom);
      }
   }

Implements

IEquatable

Наслеђени чланови

object.GetType() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()

Constructors

Маргине (плава, пловидбе, флота и флате)

Иницијалише нову инстанцију Aspose.Note.Маргине струкса одређеним левим, десним, врхунским и доњим маргинима.

public Margins(float left, float right, float top, float bottom)
   {
      Left = left;
      Right = right;
      Top = top;
      Bottom = bottom;
   }

Parameters

left float

Лева маржа ширине.

right float

Права ширина маргина.

top float

Врх маргиналне ширине.

bottom float

Доњег маргина ширине.

Fields

Empty

Празни маргини су.

public static readonly Margins Empty = new Margins();
In this case, no changes were made because the given code already follows standard C# conventions. When dealing with more complex scenarios, additional adjustments such as line wrapping at appropriate indentation levels and consistent spacing between keywords and operands may be necessary.

Пољска вредност

Margins

Properties

Bottom

Добија или поставља дно маргине ширине.

public readonly float Bottom
   {
      get;
      set;
   }

Вредност имовине

float

Left

Добија или поставља леву маргиналну ширину.

public float Left
   {
      get => this.Left;
      set => this.Left = value;
   }

Вредност имовине

float

Right

Добија или поставља праву маргиналну ширину.

public float Right
    {
       get => this.Right;
       set => this.Right = value;
    }

Вредност имовине

float

Top

Добија или поставља врхунску маргиналну ширину.

public float Top
   {
      get => this._top;
      set => this._top = value;
   }
   private float _top;

Вредност имовине

float

Methods

Еквивалент ( Маргинс )

Тестирајте да ли су две маргиналне структуре једнаке.

public bool Equals(Margins other)
   {
      return (this.Left == other.Left)
             && (this.Top == other.Top)
             && (this.Right == other.Right)
             && (this.Bottom == other.Bottom);
   }

Parameters

other Margins

Структура маргина.

Returns

bool

Систем је боолеан.

Објект ( Object )

Тестирајте да ли су две маргиналне структуре једнаке.

public override bool Equals(object obj)
   {
      if (obj is null || !(obj is MyClass)) // Changed line break to improve readability
         return false;
      var other = (MyClass)obj; // Casting variable declaration on the same line for better readability
      return this.Property1 == other.Property1 && this.Property2 == other.Property2; // Aligned conditions for better readability
   }

Parameters

obj object

било који објекат.

Returns

bool

Систем је боолеан.

КСНУМКС (

Служи као хасх функција за тип.

public override int GetHashCode()
   {
   }

Returns

int

Систем.инт32.

Operators

оператор = = (Маргинс и Маргин)

Тестирајте да ли су две маргиналне структуре једнаке.

public static bool operator==(Margins lhs, Margins rhs)
   {
      return (lhs.Left == rhs.Left) &&
             (lhs.Right == rhs.Right) &&
             (lhs.Top == rhs.Top) &&
             (lhs.Bottom == rhs.Bottom);
   }

Parameters

lhs Margins

Структура маргина.

rhs Margins

Структура маргина треба упоредити са.

Returns

bool

Систем је боолеан.

Оператор! = (Маргинс и Маргин)

Тестирајте да ли су две маргине структуре неједнаке.

public static bool operator !=(Margins lhs, Margins rhs)
   {
       return !(lhs.Left == rhs.Left &&
                 lhs.Right == rhs.Right &&
                 lhs.Top == rhs.Top &&
                 lhs.Bottom == rhs.Bottom);
   }

Parameters

lhs Margins

Структура маргина.

rhs Margins

Структура маргина треба упоредити са.

Returns

bool

Систем је боолеан.

 Српски