public DayPanel() { InitializeComponent(); _items = new List<IScheduleItem>(); _blocks = new List<ItemBlock>(); _layoutEngine = new BlockLayoutEngine(); SetStyle(ControlStyles.AllPaintingInWmPaint, true); SetStyle(ControlStyles.UserPaint, true); SetStyle(ControlStyles.DoubleBuffer, true); SetStyle(ControlStyles.ResizeRedraw, true); BackColor = Color.FromArgb(255, 255, 213); AutoScrollMinSize = new Size(Width, HalfHourHeight * 48); }
public DayPanel() { InitializeComponent(); _items = new List <IScheduleItem>(); _blocks = new List <ItemBlock>(); _layoutEngine = new BlockLayoutEngine(); SetStyle(ControlStyles.AllPaintingInWmPaint, true); SetStyle(ControlStyles.UserPaint, true); SetStyle(ControlStyles.DoubleBuffer, true); SetStyle(ControlStyles.ResizeRedraw, true); BackColor = Color.FromArgb(255, 255, 213); AutoScrollMinSize = new Size(Width, HalfHourHeight * 48); }
public bool IntersectsWith(BlockLayoutEngine.IBlockLayoutAdapter block) { return _rectangle.IntersectsWith(new Rectangle(block.Left, block.Top, block.Width, block.Height)); }