/// <summary> /// Отрисовать шкалу графиков /// </summary> public void RedrawScalePanel() { bool blocked = false; try { if (drawMutex.WaitOne(500)) { if (panels != null) { ScalePanel scale = panels[1] as ScalePanel; if (scale != null) { blocked = true; using (SolidBrush brush = new SolidBrush(color)) { //scale.Drawter.Clear(color); scale.InvalidatePanel(); drawter.Present(); } } } } } finally { if (blocked) { drawMutex.ReleaseMutex(); } } }
/// <summary> /// Создать панель отображающую шкалы графиков /// </summary> /// <returns></returns> private IElement CreateScalePanel() { try { ScalePanel panel = new ScalePanel(this); panel.InitializePanel(); return(panel); } catch { return(null); } }
/// <summary> /// Создать панель отображающую шкалы графиков /// </summary> /// <returns></returns> private IElement CreateScalePanel() { try { ScalePanel panel = new ScalePanel(this); panel.InitializePanel(); return panel; } catch { return null; } }