コード例 #1
0
        public ShortAnswerQuestionPanel(CustomFonts customFonts) : base(customFonts)
        {
            this.Size = new Size(645, 147);

            Type = 1;

            answerPanel          = new ShortAnswerPanel(customFonts);
            answerPanel.Location = new Point(300, 120);
            this.Controls.Add(answerPanel);

            QuestionTextBox.Size       = new System.Drawing.Size(500, 100);
            QuestionTextBox.LostFocus += questionTextBox_LostFocus_1;

            QuestionLabel.MaximumSize = new System.Drawing.Size(500, 0);
            QuestionLabel.Click      += questionLabel_Click_1;

            ExamScorePanel.Location = new Point(520, (this.Height - ExamScorePanel.Height) / 2);

            DeleteButton.Location = new Point(605, (this.Height - DeleteButton.Height) / 2);
        }
コード例 #2
0
        public ExamShortAnswerQuestionPanel(CustomFonts customFonts, string question, int score) : base(customFonts, question, score)
        {
            int height;

            this.Size   = new Size(725, 147);
            this.Click += Click_1;

            Type = 1;

            answerPanel = new ShortAnswerPanel(customFonts);
            this.Controls.Add(answerPanel);

            QuestionLabel.MaximumSize = new System.Drawing.Size(500, 0);

            QuestionLabel.Location = new Point(0, 10);
            answerPanel.Location   = new Point(300, QuestionLabel.Location.Y + QuestionLabel.Height + 20);
            height                     = answerPanel.Location.Y + answerPanel.Height;
            this.Height                = height;
            ExamScorePanel.Location    = new Point(520, (height - ExamScorePanel.Height) / 2);
            StudentScorePanel.Location = new Point(600, (height - StudentScorePanel.Height) / 2);
        }