Пример #1
0
        public UmlNote AddNote(NoteLocation location, string noteText, IUmlFill background = null)
        {
            noteText = noteText?.Trim();
            if (string.IsNullOrEmpty(noteText))
            {
                return(null);
            }
            var note = GetOrCreateNote(location);

            if (background != null)
            {
                note.Background = background;
            }
            note.Text += "\n" + noteText;
            return(note);
        }
Пример #2
0
 public static bool IsEmpty(this IUmlFill fill)
 {
     return(string.IsNullOrEmpty(fill?.GetCode()));
 }
Пример #3
0
        public static string GetCodeWithSpace(this IUmlFill fill, bool convertToRgb = false)
        {
            var code = fill?.GetCode(convertToRgb);

            return(string.IsNullOrEmpty(code) ? string.Empty : " " + code);
        }