Beispiel #1
0
 /// <summary>
 /// Прорисовка элемента управления
 /// </summary>
 public virtual void Draw(SpriteBatch spriteBatch)
 {
     if (Visible)
     {
         image.Draw(spriteBatch);
     }
 }
Beispiel #2
0
 /// <summary>
 /// Визуализация элемента в текущем кадре
 /// </summary>
 public override void Draw(SpriteBatch spriteBatch)
 {
     if (Visible)
     {
         base.Draw(spriteBatch);
         currentListNumberText.Draw(spriteBatch);
         image2.Draw(spriteBatch);
         foreach (var prev in list[currentListNumber])                   //MAYBE TODO корректная работа при удалении всех превов в рантайме (приводит к удалению всех измерений)
         {
             prev.Draw(spriteBatch);
         }
     }
 }
Beispiel #3
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            base.Draw(spriteBatch);
            if (Visible)
            {
                count = 0;
                foreach (var item in list)
                {
                    spriteBatch.DrawString(font, (count + 1).ToString() + ") " + item.ToString(), new Vector2(Position.X + Bounds.Width / 1000f * 100, Position.Y + start + step * count++), Color.White);
                }
                if (selectedItem != null)
                {
                    mesh.Draw(spriteBatch);
                }
                //for (int i = 0; i < items.Length; i++) {
                //    if (items[i] == null)
                //        continue;

                //}
            }
        }