/// <summary> /// Repaints the HALCON window 'window' /// </summary> private void repaint(HalconDotNet.HWindow window) { int count = HObjList.Count; if (count > 0) { HObjectEntry entry; HSystem.SetSystem("flush_graphic", "false"); window.ClearWindow(); mGC.stateOfSettings.Clear(); for (int i = 0; i < count; i++) { entry = ((HObjectEntry)HObjList[i]); if (entry.colorShow.Length > 0) { window.SetColor(entry.colorShow); } mGC.applyContext(window, entry.gContext); window.DispObj(entry.HObj); } if (roiManager != null) { roiManager.paintData(window); } HSystem.SetSystem("flush_graphic", "true"); window.DispLine(-100.0, -100.0, -101.0, -101.0); } count = StrList.Count; if (count > 0) { foreach (StringX strX in StrList) { window.SetFont("-Consolas-" + strX.size.ToString() + "-*-" + (strX.bold ? "1" : "0") + "-*-*-" + (strX.slant ? "1" : "0") + "-"); window.SetColor(strX.color.Name.ToLower()); window.SetTposition(strX.row, strX.column); window.WriteString(strX.str); } } }