コード例 #1
0
ファイル: Business.cs プロジェクト: luizptm/TestCorrection
 public void TesteImagem()
 {
     ImageLib imageLib = new ImageLib();
     string   name     = "Candidate " + 1;
     string   question = "Question " + 1;
     Bitmap   image    = imageLib.DrawTextInImage(question, name);
 }
コード例 #2
0
ファイル: ImageWorker.cs プロジェクト: luizptm/TestCorrection
        private void CreateSaveImageCandidate(Object s = null)
        {
            //SomeState state = (SomeState)s;
            //int i = (int)state.Cookie;
            string    candidateName = "Candidate " + i;
            Candidate c             = new Candidate()
            {
                Name = candidateName
            };

            candidateLib.SaveCandidate(c);

            Question q = new Question {
                Id = questionId, Type = "discursiva", Number = i, Descripton = "Question " + questionId
            };
            Bitmap image = imageLib.DrawTextInImage("Question " + questionId, candidateName);

            imageLib.Save(q, c, image); //saving ImageCandidate
        }