Пример #1
0
 public static void Write(this CodeWriter code, string name, UmlColor value)
 {
     if (!value.IsEmpty)
     {
         code.Writeln(name + " " + value.PlantUmlCode);
     }
 }
Пример #2
0
        public UmlRelationArrow WithAttribute(BaseRelationAttribute att)
        {
            if (att is null)
            {
                return(this);
            }
            if (att.ArrowDirection != UmlArrowDirections.Auto)
            {
                ArrowDirection = att.ArrowDirection;
            }
            ArrowLength = Math.Max(2, att.ArrowLength);
            if (att.LeftSign != ForceArrowEnd.NotSet)
            {
                LeftSign = (ArrowEnd)att.LeftSign;
            }
            if (att.RightSign != ForceArrowEnd.NotSet)
            {
                RightSign = (ArrowEnd)att.RightSign;
            }
            if (att.IsDotted != ChangeDecision.Auto)
            {
                IsDotted = att.IsDotted == ChangeDecision.Yes;
            }

            if (!string.IsNullOrEmpty(att.LeftSignDescription))
            {
                LeftSignDescription = att.LeftSignDescription;
            }

            if (!string.IsNullOrEmpty(att.RightSignDescription))
            {
                RightSignDescription = att.RightSignDescription;
            }

            if (!string.IsNullOrEmpty(att.Color))
            {
                Color = new UmlColor(att.Color);
            }


            return(this);
        }
Пример #3
0
 public GradientColorFill(UmlColor first, UmlColor second, GradientDirection direction)
 {
     _first     = first;
     _second    = second;
     _direction = direction;
 }
Пример #4
0
 IUmlFill INoteProvider.GetNoteBackground()
 {
     return(UmlColor.FromString(NoteBackground).ToFill());
 }
Пример #5
0
 IUmlFill IEntityBackgroundProvider.GetEntityBackground()
 {
     return(UmlColor.FromString(BackgroundColor).ToFill());
 }