private void btnOk_Click(object sender, EventArgs e) { var x = new TextDataParser(txtInput.Text); var cleanOutput = x.CleanDataOutput(); Sprite.SetBytes(cleanOutput); DialogResult = DialogResult.OK; }
private void btnPreview_Click(object sender, EventArgs e) { var x = new TextDataParser(txtInput.Text); var cleanOutput = x.CleanDataOutput(); var s = new StringBuilder(); foreach (var b in cleanOutput) { s.Append(b.Value.ToString()); if (b != cleanOutput.Last()) { s.Append(", "); } } txtCleanDataOutput.Text = s.ToString(); Sprite.SetBytes(cleanOutput); picPreview.Invalidate(); }