コード例 #1
0
        public static void GenerateForm(UserControl userControl, string title, Form parentForm)
        {
            var defaultForm = new DefaultForm();

            defaultForm.Height = userControl.Height + 70;
            defaultForm.Width  = userControl.Width + 15;

            defaultForm.Controls.Add(userControl);
            defaultForm.Text = title;
            userControl.Dock = DockStyle.Fill;
            defaultForm.CustomShow(parentForm);
        }
コード例 #2
0
 /// <summary>
 /// initialize elements
 /// </summary>
 public override void InitElements()
 {
     Form                       = new DefaultForm();
     Form.Parent                = this;
     Header                     = new DefaultHeader();
     Header.Parent              = this;
     Footer                     = new DefaultFooter();
     Footer.Parent              = this;
     Detail                     = new DefaultInstructionsDetail();
     Detail.Parent              = this;
     TestResponseSummary        = new DefaultResponseSummaryForm();
     TestResponseSummary.Parent = this;
     TestList                   = new List <TestTypeForm>();
 }
コード例 #3
0
        public void LoadNode()
        {
            DefaultForm.Load();
            //  DefaultView.Load();

            //foreach (var form in SideForms.Values)
            //{
            //    form.Load();
            //}


            //foreach (var view in SideViews.Values)
            //{
            //    //view.Load();
            //}
        }
コード例 #4
0
ファイル: FileHelper.cs プロジェクト: thachgiasoft/QLDT
        public static void ShowImagePopup(Image image)
        {
            if (image == null)
            {
                return;
            }
            var imageForm   = new DefaultForm();
            var pictureEdit = new PictureEdit();

            var adjustImage = AdjustSize(image.Width, image.Height);

            pictureEdit.Image = image;
            pictureEdit.Properties.SizeMode = PictureSizeMode.Squeeze;
            pictureEdit.Dock = DockStyle.Fill;

            imageForm.Controls.Add(pictureEdit);
            imageForm.Width  = adjustImage.Key;
            imageForm.Height = adjustImage.Value;

            imageForm.Show();
        }