Exemple #1
0
        public PlayHarpNoteClass CreateTakt(Control parent, AirSlotAttributesClass txt, HarpClass hc)
        {
            harpClass             = hc;
            slot                  = new PlayNoteButton();
            slot.Enabled          = true;
            slot.Parent           = parent;
            slot.BackColor        = Color.Bisque;
            slot.Font             = new Font("Consolas", 10, FontStyle.Bold);
            slot.TextAlign        = ContentAlignment.BottomLeft;
            slot.ToolTipActive    = false;
            slot.ToolTipText      = string.Empty;
            slot.Image            = null;
            slot.ImageHover       = null;
            slot.ImageAlign       = ContentAlignment.MiddleRight;
            slot.Width            = Statics.TabButtonWitdh;
            slot.Height           = Statics.PlayButtonHeight;
            slot.Text             = string.Empty;
            slot.BackColor        = Color.Gray;
            slot.BackColorHover   = slot.BackColor;
            slot.BorderColorHover = Color.Blue;
            slot.HoverStyle       = SeControlsLib.frameStyle.thickRectangle;
            slot.FlatStyle        = FlatStyle.Flat;
            slot.Tag              = txt;

            return(this);
        }
Exemple #2
0
        public PlayHarpNoteClass CreatePause(Control parent, AirSlotAttributesClass txt, Image img, HarpClass hc)
        {
            harpClass             = hc;
            slot                  = new PlayNoteButton();
            slot.Enabled          = true;
            slot.Parent           = parent;
            slot.BackColor        = Color.Bisque;
            slot.Font             = new Font("Consolas", 10, FontStyle.Bold);
            slot.TextAlign        = ContentAlignment.BottomLeft;
            slot.ToolTipActive    = true;
            slot.ToolTipText      = $@"Note:{txt.NoteStr} ({txt.DelayStr}){Environment.NewLine}Slot:{txt.Slot}";
            slot.Width            = Statics.PlayButtonWitdh;
            slot.Height           = Statics.PlayButtonHeight;
            slot.Text             = txt.Slot.ToString();
            slot.Image            = img;
            slot.ImageHover       = img;
            slot.BackColor        = Color.LightGray;
            slot.Text             = "P";
            slot.BackColorHover   = slot.BackColor;
            slot.BorderColorHover = Color.Blue;
            slot.HoverStyle       = SeControlsLib.frameStyle.thickRectangle;
            slot.FlatStyle        = FlatStyle.Flat;
            slot.Tag              = txt;

            return(this);
        }
Exemple #3
0
        public PlayHarpNoteClass CreateNote(Control parent, AirSlotAttributesClass txt, Image img, HarpClass hc)
        {
            harpClass          = hc;
            slot               = new PlayNoteButton();
            slot.Enabled       = true;
            slot.Parent        = parent;
            slot.BackColor     = Color.Bisque;
            slot.Font          = new Font("Consolas", 10, FontStyle.Bold);
            slot.TextAlign     = ContentAlignment.BottomLeft;
            slot.ToolTipActive = true;
            slot.ToolTipText   = $@"Note:{txt.NoteStr} ({txt.DelayStr}){Environment.NewLine}Slot:{txt.Slot}{Environment.NewLine}Delay:{txt.Delay}{Environment.NewLine}RefDelay:{txt.RefDelay}";
            slot.Width         = Statics.PlayButtonWitdh;
            slot.Height        = Statics.PlayButtonHeight;
            slot.Text          = txt.Slot.ToString();
            slot.Image         = img;
            slot.ImageHover    = img;

            if (txt.BreathDirection == eBreathDirection.blow)
            {
                slot.BackColor = Color.LightGreen;
            }
            else if (txt.BreathDirection == eBreathDirection.draw)
            {
                slot.BackColor = Color.LightSalmon;
            }
            else if (txt.BreathDirection == eBreathDirection.blowPushed)
            {
                slot.BackColor = Color.LightGreen;
                slot.ForeColor = Color.Yellow;
            }
            else if (txt.BreathDirection == eBreathDirection.drawPushed)
            {
                slot.BackColor = Color.LightSalmon;
                slot.ForeColor = Color.Yellow;
            }
            slot.BackColorHover   = slot.BackColor;
            slot.BorderColorHover = Color.Blue;
            slot.HoverStyle       = SeControlsLib.frameStyle.thickRectangle;
            slot.FlatStyle        = FlatStyle.Flat;
            slot.Tag        = txt;
            slot.MouseDown += Slot_MouseDown;
            slot.MouseUp   += Slot_MouseUp;
            return(this);
        }