Merged PR 308: #8224/#7571 Margins cotation and Colors

Related work items: #8224
This commit is contained in:
Carl Fuchs 2023-01-30 14:59:55 +00:00
parent 4e8f465405
commit a7feebdcd1
18 changed files with 425 additions and 150 deletions

View file

@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Runtime.Serialization;
namespace SVGLDLibs.Models
@ -112,26 +112,10 @@ namespace SVGLDLibs.Models
[DataMember(EmitDefaultValue = false)]
public bool? HideChildrenInTreeview { get; set; }
/** if true, show the dimension of the container */
[DataMember(EmitDefaultValue = false)]
public Position[] ShowSelfDimensions { get; set; }
/** if true show the overall dimensions of its children */
[DataMember(EmitDefaultValue = false)]
public Position[] ShowChildrenDimensions { get; set; }
public Dimensions DimensionOptions { get; set; }
/**
* if true, allows a parent dimension borrower to uses its x coordinate for as a reference point for a dimension
*/
[DataMember(EmitDefaultValue = false)]
public Orientation[] MarkPosition { get; set; }
/**
* if true, show a dimension from the edge of the container to end
* and insert dimensions mark
*/
[DataMember(EmitDefaultValue = false)]
public Position[] ShowDimensionWithMarks { get; set; }
/**
* if true, hide the entry in the sidebar (default: false)

View file

@ -0,0 +1,28 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;
namespace SVGLDLibs.Models
{
[DataContract]
public class DimensionOptions
{
/** positions of the dimension */
[DataMember(EmitDefaultValue = false)]
public Position[] positions;
/** color */
[DataMember(EmitDefaultValue = false)]
public string color;
}
}

View file

@ -9,11 +9,14 @@ namespace SVGLDLibs.Models
/** if true, show the dimension of the container */
[DataMember(EmitDefaultValue = false)]
public Position[] showSelfDimensions;
public DimensionOptions selfDimensions;
[DataMember(EmitDefaultValue = false)]
public DimensionOptions selfMarginsDimensions;
/** if true show the overall dimensions of its children */
[DataMember(EmitDefaultValue = false)]
public Position[] showChildrenDimensions;
public DimensionOptions childrenDimensions;
/**
* if true, allows a parent dimension borrower to borrow its x coordinate
@ -27,6 +30,6 @@ namespace SVGLDLibs.Models
* and insert dimensions marks at lift up children (see liftDimensionToBorrower)
*/
[DataMember(EmitDefaultValue = false)]
public Position[] showDimensionWithMarks;
public DimensionOptions dimensionWithMarks;
}
}