/// <summary> /// 设置清洗颜色 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void m_ButtonStartClean_Click(object sender, EventArgs e) { m_ButtonSet_Click(null, null); byte color = 0;//(byte) (m_ComboBoxColorIndex.SelectedIndex + 1); byte?level = null; color = 0xff; EpsonLCD.SetManualCleanCmd(color, level); }
/// <summary> /// 设置清洗颜色 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void m_ButtonStartClean_Click(object sender, EventArgs e) { byte color = 0;//(byte) (m_ComboBoxColorIndex.SelectedIndex + 1); for (int i = 0; i < panelColorMask.Controls.Count; i++) { if (bColorJet) { if (panelColorMask.Controls[i] is RadioButton) { if (((RadioButton)panelColorMask.Controls[i]).Checked) { color = (byte)(i); } } } else { if (panelColorMask.Controls[i] is CheckBox) { if (((CheckBox)panelColorMask.Controls[i]).Checked) { color |= (byte)(1 << i); } } } } byte?level = (byte)(comboBoxLevel.SelectedIndex + 1); if (level < 0) { level = 0; } if (bColorJet) { level = null; } if (checkBoxAll.Checked) { color = 0xff; } EpsonLCD.SetManualCleanCmd(color, level); }