protected AbstractMeasure(string id, string scoreId, int staffCount, double width, AbstractMeasureContent content)
 {
     if (String.IsNullOrEmpty(id))
     {
         throw new ArgumentException("Id cannot be null or empty");
     }
     if (staffCount < 1)
     {
         throw new ArgumentException("Staff count cannot be lower than 1");
     }
     this.id         = id;
     this.staffCount = staffCount;
     this.scoreId    = scoreId;
     visualsHost     = new Canvas();
     this.width      = width;
     this.content    = content;
 }
Beispiel #2
0
 protected MultiStaffMeasure(string id, string scoreId, IList <AbstractStaff> staffs, double width, AbstractMeasureContent content)
     : base(id, scoreId, staffs?.Count ?? 0, width, content)
 {
     this.staffs = staffs;
 }
Beispiel #3
0
 protected MultiStaffMeasure(string id, string scoreId, int staffCount, double width, AbstractMeasureContent content) : base(id, scoreId, staffCount, width, content)
 {
 }
Beispiel #4
0
 public StandardMeasure(string id, string scoreId, AbstractStaff staff, double width, AbstractMeasureContent content) : base(id, scoreId, 1, width, content)
 {
     this.staff = staff;
     width      = staff.DesiredWidth;
     height     = staff.DesiredHeight;
     GetVisualControl().Children.Add(staff.GetVisualsContainer());
     foreach (var item in content.GetVisualHostContainers())
     {
         GetVisualControl().Children.Add(item.GetVisualControl());
     }
 }