private void SavePageBreak(CSSAttribute ai, UnsettableComboBox cbxPgBr)
        {
            string value = SavePageBreakUI(cbxPgBr);

            Debug.Assert(value != null,
                         "savePageBreakUI returned null!");

            ai.SaveAttribute(GetSelectedStyles(), value);
        }
        private string SavePageBreakUI(UnsettableComboBox cbxPgBr)
        {
            string value;

            if (cbxPgBr.IsSet())
            {
                int index = cbxPgBr.SelectedIndex;
                Debug.Assert((index >= 1) && (index < PAGEBREAK_VALUES.Length),
                             "Invalid index for page break");

                value = PAGEBREAK_VALUES[index];
            }
            else
            {
                value = "";
            }

            return(value);
        }
        private void InitPageBreakUI(CSSAttribute ai, UnsettableComboBox cbxPgBr)
        {
            Debug.Assert(IsInitMode() == true,
                         "initPageBreakUI called when page is not in init mode");

            cbxPgBr.SelectedIndex = -1;

            Debug.Assert(ai != null,
                         "Expected ai to be non-null");

            string value = ai.Value;

            if ((value != null) && (value.Length != 0))
            {
                for (int i = 1; i < PAGEBREAK_VALUES.Length; i++)
                {
                    if (PAGEBREAK_VALUES[i].Equals(value))
                    {
                        cbxPgBr.SelectedIndex = i;
                        break;
                    }
                }
            }
        }
        /// <include file='doc\DataGridGeneralPage.uex' path='docs/doc[@for="DataGridGeneralPage.InitForm"]/*' />
        /// <devdoc>
        ///   Initializes the UI of the form.
        /// </devdoc>
        private void InitForm()
        {
            GroupLabel dataGroup       = new GroupLabel();
            Label      dataSourceLabel = new Label();

            this.dataSourceCombo = new UnsettableComboBox();
            Label dataMemberLabel = new Label();

            this.dataMemberCombo = new UnsettableComboBox();
            Label dataKeyFieldLabel = new Label();

            this.dataKeyFieldCombo = new UnsettableComboBox();
            this.columnInfoLabel   = new Label();
            GroupLabel headerFooterGroup = new GroupLabel();

            this.showHeaderCheck = new CheckBox();
            this.showFooterCheck = new CheckBox();
            GroupLabel behaviorGroup = new GroupLabel();

            this.allowSortingCheck = new CheckBox();

            dataGroup.SetBounds(4, 4, 431, 16);
            dataGroup.Text     = SR.GetString(SR.DGGen_DataGroup);
            dataGroup.TabIndex = 0;
            dataGroup.TabStop  = false;

            dataSourceLabel.SetBounds(12, 24, 170, 16);
            dataSourceLabel.Text     = SR.GetString(SR.DGGen_DataSource);
            dataSourceLabel.TabStop  = false;
            dataSourceLabel.TabIndex = 1;

            dataSourceCombo.SetBounds(12, 40, 140, 64);
            dataSourceCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataSourceCombo.Sorted                = true;
            dataSourceCombo.TabIndex              = 2;
            dataSourceCombo.NotSetText            = SR.GetString(SR.DGGen_DSUnbound);
            dataSourceCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataSource);

            dataMemberLabel.SetBounds(184, 24, 170, 16);
            dataMemberLabel.Text     = SR.GetString(SR.DGGen_DataMember);
            dataMemberLabel.TabStop  = false;
            dataMemberLabel.TabIndex = 3;

            dataMemberCombo.SetBounds(184, 40, 140, 21);
            dataMemberCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataMemberCombo.Sorted                = true;
            dataMemberCombo.TabIndex              = 4;
            dataMemberCombo.NotSetText            = SR.GetString(SR.DGGen_DMNone);
            dataMemberCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataMember);

            dataKeyFieldLabel.SetBounds(12, 66, 170, 16);
            dataKeyFieldLabel.Text     = SR.GetString(SR.DGGen_DataKey);
            dataKeyFieldLabel.TabStop  = false;
            dataKeyFieldLabel.TabIndex = 5;

            dataKeyFieldCombo.SetBounds(12, 82, 140, 64);
            dataKeyFieldCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataKeyFieldCombo.Sorted                = true;
            dataKeyFieldCombo.TabIndex              = 6;
            dataKeyFieldCombo.NotSetText            = SR.GetString(SR.DGGen_DKNone);
            dataKeyFieldCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataKeyField);

            columnInfoLabel.SetBounds(8, 112, 420, 48);
            columnInfoLabel.TabStop  = false;
            columnInfoLabel.TabIndex = 7;

            headerFooterGroup.SetBounds(4, 162, 431, 16);
            headerFooterGroup.Text     = SR.GetString(SR.DGGen_HeaderFooterGroup);
            headerFooterGroup.TabIndex = 8;
            headerFooterGroup.TabStop  = false;

            showHeaderCheck.SetBounds(12, 182, 160, 16);
            showHeaderCheck.TabIndex        = 9;
            showHeaderCheck.Text            = SR.GetString(SR.DGGen_ShowHeader);
            showHeaderCheck.TextAlign       = ContentAlignment.MiddleLeft;
            showHeaderCheck.FlatStyle       = FlatStyle.System;
            showHeaderCheck.CheckedChanged += new EventHandler(this.OnCheckChangedShowHeader);

            showFooterCheck.SetBounds(12, 202, 160, 16);
            showFooterCheck.TabIndex        = 10;
            showFooterCheck.Text            = SR.GetString(SR.DGGen_ShowFooter);
            showFooterCheck.TextAlign       = ContentAlignment.MiddleLeft;
            showFooterCheck.FlatStyle       = FlatStyle.System;
            showFooterCheck.CheckedChanged += new EventHandler(this.OnCheckChangedShowFooter);

            behaviorGroup.SetBounds(4, 228, 431, 16);
            behaviorGroup.Text     = SR.GetString(SR.DGGen_BehaviorGroup);
            behaviorGroup.TabIndex = 11;
            behaviorGroup.TabStop  = false;

            allowSortingCheck.SetBounds(12, 246, 160, 16);
            allowSortingCheck.Text            = SR.GetString(SR.DGGen_AllowSorting);
            allowSortingCheck.TabIndex        = 12;
            allowSortingCheck.TextAlign       = ContentAlignment.MiddleLeft;
            allowSortingCheck.FlatStyle       = FlatStyle.System;
            allowSortingCheck.CheckedChanged += new EventHandler(this.OnCheckChangedAllowSorting);

            this.Text = SR.GetString(SR.DGGen_Text);
            this.Size = new Size(464, 272);
            this.CommitOnDeactivate = true;
            this.Icon = new Icon(this.GetType(), "DataGridGeneralPage.ico");

            Controls.Clear();
            Controls.AddRange(new Control[] {
                allowSortingCheck,
                behaviorGroup,
                showFooterCheck,
                showHeaderCheck,
                headerFooterGroup,
                columnInfoLabel,
                dataKeyFieldCombo,
                dataKeyFieldLabel,
                dataMemberCombo,
                dataMemberLabel,
                dataSourceCombo,
                dataSourceLabel,
                dataGroup
            });
        }
        protected override void InitForm()
        {
            base.InitForm();

            this._objectList = (ObjectList)Component;

            this.CommitOnDeactivate = true;
            this.Icon = new Icon(
                typeof(System.Web.UI.Design.MobileControls.MobileControlDesigner),
                "Fields.ico"
                );
            this.Size = new Size(402, 300);
            this.Text = SR.GetString(SR.ObjectListFieldsPage_Title);

            _ckbAutoGenerateFields = new CheckBox();
            _cmbDataField          = new UnsettableComboBox();
            _ckbVisible            = new CheckBox();
            _txtDataFormatString   = new TextBox();
            _txtTitle = new TextBox();

            _ckbAutoGenerateFields.SetBounds(4, 4, 396, LabelHeight);
            _ckbAutoGenerateFields.Text            = SR.GetString(SR.ObjectListFieldsPage_AutoGenerateFieldsCaption);
            _ckbAutoGenerateFields.FlatStyle       = FlatStyle.System;
            _ckbAutoGenerateFields.CheckedChanged += new EventHandler(this.OnSetPageDirty);
            _ckbAutoGenerateFields.TabIndex        = 0;

            GroupLabel grplblFieldList = new GroupLabel();

            grplblFieldList.SetBounds(4, 32, 392, LabelHeight);
            grplblFieldList.Text     = SR.GetString(SR.ObjectListFieldsPage_FieldListGroupLabel);
            grplblFieldList.TabIndex = 1;
            grplblFieldList.TabStop  = false;

            TreeList.TabIndex = 2;

            Label lblDataField = new Label();

            lblDataField.SetBounds(X, Y, ControlWidth, LabelHeight);
            lblDataField.Text     = SR.GetString(SR.ObjectListFieldsPage_DataFieldCaption);
            lblDataField.TabStop  = false;
            lblDataField.TabIndex = Index;

            Y += LabelHeight;
            _cmbDataField.SetBounds(X, Y, ControlWidth, CmbHeight);
            _cmbDataField.DropDownStyle         = ComboBoxStyle.DropDown;
            _cmbDataField.Sorted                = true;
            _cmbDataField.NotSetText            = SR.GetString(SR.ObjectListFieldsPage_NoneComboEntry);
            _cmbDataField.TextChanged          += new EventHandler(this.OnPropertyChanged);
            _cmbDataField.SelectedIndexChanged += new EventHandler(this.OnPropertyChanged);
            _cmbDataField.TabIndex              = Index + 1;

            Y += CellSpace;
            Label lblDataFormatString = new Label();

            lblDataFormatString.SetBounds(X, Y, ControlWidth, LabelHeight);
            lblDataFormatString.Text     = SR.GetString(SR.ObjectListFieldsPage_DataFormatStringCaption);
            lblDataFormatString.TabStop  = false;
            lblDataFormatString.TabIndex = Index + 2;

            Y += LabelHeight;
            _txtDataFormatString.SetBounds(X, Y, ControlWidth, CmbHeight);
            _txtDataFormatString.TextChanged += new EventHandler(this.OnPropertyChanged);
            _txtDataFormatString.TabIndex     = Index + 3;

            Y += CellSpace;
            Label lblTitle = new Label();

            lblTitle.SetBounds(X, Y, ControlWidth, LabelHeight);
            lblTitle.Text     = SR.GetString(SR.ObjectListFieldsPage_TitleCaption);
            lblTitle.TabStop  = false;
            lblTitle.TabIndex = Index + 4;

            Y += LabelHeight;
            _txtTitle.SetBounds(X, Y, ControlWidth, CmbHeight);
            _txtTitle.TextChanged += new EventHandler(this.OnPropertyChanged);
            _txtTitle.TabIndex     = Index + 5;

            Y += CellSpace;
            _ckbVisible.SetBounds(X, Y, ControlWidth, CmbHeight);
            _ckbVisible.FlatStyle       = System.Windows.Forms.FlatStyle.System;
            _ckbVisible.Text            = SR.GetString(SR.ObjectListFieldsPage_VisibleCaption);
            _ckbVisible.CheckedChanged += new EventHandler(this.OnPropertyChanged);
            _ckbVisible.TabIndex        = Index + 6;

            this.Controls.AddRange(new Control[] {
                _ckbAutoGenerateFields,
                grplblFieldList,
                lblDataField,
                _cmbDataField,
                lblDataFormatString,
                _txtDataFormatString,
                lblTitle,
                _txtTitle,
                _ckbVisible
            });
        }
Exemple #6
0
        /// <include file='doc\DataListGeneralPage.uex' path='docs/doc[@for="DataListGeneralPage.InitForm"]/*' />
        /// <devdoc>
        ///   Initializes the UI of the form.
        /// </devdoc>
        private void InitForm()
        {
            GroupLabel dataGroup       = new GroupLabel();
            Label      dataSourceLabel = new Label();

            this.dataSourceCombo = new UnsettableComboBox();
            Label dataMemberLabel = new Label();

            this.dataMemberCombo = new UnsettableComboBox();
            Label dataKeyFieldLabel = new Label();

            this.dataKeyFieldCombo = new UnsettableComboBox();
            GroupLabel headerFooterGroup = new GroupLabel();

            this.showHeaderCheck = new CheckBox();
            this.showFooterCheck = new CheckBox();
            GroupLabel repeatGroup        = new GroupLabel();
            Label      repeatColumnsLabel = new Label();

            this.repeatColumnsEdit = new NumberEdit();
            Label repeatDirectionLabel = new Label();

            this.repeatDirectionCombo = new ComboBox();
            Label repeatLayoutLabel = new Label();

            this.repeatLayoutCombo = new ComboBox();
            GroupLabel templatesGroup = new GroupLabel();

            this.extractRowsCheck = new CheckBox();

            dataGroup.SetBounds(4, 4, 360, 16);
            dataGroup.Text     = SR.GetString(SR.DLGen_DataGroup);
            dataGroup.TabIndex = 0;
            dataGroup.TabStop  = false;

            dataSourceLabel.SetBounds(8, 24, 170, 16);
            dataSourceLabel.Text     = SR.GetString(SR.DLGen_DataSource);
            dataSourceLabel.TabStop  = false;
            dataSourceLabel.TabIndex = 1;

            dataSourceCombo.SetBounds(8, 40, 140, 21);
            dataSourceCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataSourceCombo.Sorted                = true;
            dataSourceCombo.TabIndex              = 2;
            dataSourceCombo.NotSetText            = SR.GetString(SR.DLGen_DSUnbound);
            dataSourceCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataSource);

            dataMemberLabel.SetBounds(184, 24, 170, 16);
            dataMemberLabel.Text     = SR.GetString(SR.DLGen_DataMember);
            dataMemberLabel.TabStop  = false;
            dataMemberLabel.TabIndex = 3;

            dataMemberCombo.SetBounds(184, 40, 140, 21);
            dataMemberCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataMemberCombo.Sorted                = true;
            dataMemberCombo.TabIndex              = 4;
            dataMemberCombo.NotSetText            = SR.GetString(SR.DLGen_DMNone);
            dataMemberCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataMember);

            dataKeyFieldLabel.SetBounds(8, 66, 170, 16);
            dataKeyFieldLabel.Text     = SR.GetString(SR.DLGen_DataKey);
            dataKeyFieldLabel.TabStop  = false;
            dataKeyFieldLabel.TabIndex = 4;

            dataKeyFieldCombo.SetBounds(8, 82, 140, 21);
            dataKeyFieldCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            dataKeyFieldCombo.Sorted                = true;
            dataKeyFieldCombo.TabIndex              = 5;
            dataKeyFieldCombo.NotSetText            = SR.GetString(SR.DLGen_DKNone);
            dataKeyFieldCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataKeyField);

            headerFooterGroup.SetBounds(4, 108, 360, 16);
            headerFooterGroup.Text     = SR.GetString(SR.DLGen_HeaderFooterGroup);
            headerFooterGroup.TabIndex = 6;
            headerFooterGroup.TabStop  = false;

            showHeaderCheck.SetBounds(8, 128, 170, 16);
            showHeaderCheck.TabIndex        = 7;
            showHeaderCheck.Text            = SR.GetString(SR.DLGen_ShowHeader);
            showHeaderCheck.TextAlign       = ContentAlignment.MiddleLeft;
            showHeaderCheck.FlatStyle       = FlatStyle.System;
            showHeaderCheck.CheckedChanged += new EventHandler(this.OnCheckChangedShowHeader);

            showFooterCheck.SetBounds(8, 146, 170, 16);
            showFooterCheck.TabIndex        = 8;
            showFooterCheck.Text            = SR.GetString(SR.DLGen_ShowFooter);
            showFooterCheck.TextAlign       = ContentAlignment.MiddleLeft;
            showFooterCheck.FlatStyle       = FlatStyle.System;
            showFooterCheck.CheckedChanged += new EventHandler(this.OnCheckChangedShowFooter);

            repeatGroup.SetBounds(4, 172, 360, 16);
            repeatGroup.Text     = SR.GetString(SR.DLGen_RepeatLayoutGroup);
            repeatGroup.TabIndex = 9;
            repeatGroup.TabStop  = false;

            repeatColumnsLabel.SetBounds(8, 192, 106, 16);
            repeatColumnsLabel.Text     = SR.GetString(SR.DLGen_RepeatColumns);
            repeatColumnsLabel.TabStop  = false;
            repeatColumnsLabel.TabIndex = 10;

            repeatColumnsEdit.SetBounds(112, 188, 40, 21);
            repeatColumnsEdit.AllowDecimal  = false;
            repeatColumnsEdit.AllowNegative = false;
            repeatColumnsEdit.TabIndex      = 11;
            repeatColumnsEdit.TextChanged  += new EventHandler(this.OnChangedRepeatProps);

            repeatDirectionLabel.SetBounds(8, 217, 106, 16);
            repeatDirectionLabel.Text     = SR.GetString(SR.DLGen_RepeatDirection);
            repeatDirectionLabel.TabStop  = false;
            repeatDirectionLabel.TabIndex = 12;

            repeatDirectionCombo.SetBounds(112, 213, 140, 56);
            repeatDirectionCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            repeatDirectionCombo.Items.AddRange(new object[] {
                SR.GetString(SR.DLGen_RD_Horz),
                SR.GetString(SR.DLGen_RD_Vert)
            });
            repeatDirectionCombo.TabIndex              = 13;
            repeatDirectionCombo.SelectedIndexChanged += new EventHandler(this.OnChangedRepeatProps);

            repeatLayoutLabel.SetBounds(8, 242, 106, 16);
            repeatLayoutLabel.Text     = SR.GetString(SR.DLGen_RepeatLayout);
            repeatLayoutLabel.TabStop  = false;
            repeatLayoutLabel.TabIndex = 14;

            repeatLayoutCombo.SetBounds(112, 238, 140, 21);
            repeatLayoutCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            repeatLayoutCombo.Items.AddRange(new object[] {
                SR.GetString(SR.DLGen_RL_Table),
                SR.GetString(SR.DLGen_RL_Flow)
            });
            repeatLayoutCombo.TabIndex              = 15;
            repeatLayoutCombo.SelectedIndexChanged += new EventHandler(this.OnChangedRepeatProps);

            templatesGroup.SetBounds(4, 266, 360, 16);
            templatesGroup.Text     = "Templates";
            templatesGroup.TabIndex = 16;
            templatesGroup.TabStop  = false;
            templatesGroup.Visible  = false;

            extractRowsCheck.SetBounds(8, 286, 260, 16);
            extractRowsCheck.Text            = "Extract rows from Tables in template content";
            extractRowsCheck.TabIndex        = 17;
            extractRowsCheck.Visible         = false;
            extractRowsCheck.FlatStyle       = FlatStyle.System;
            extractRowsCheck.CheckedChanged += new EventHandler(this.OnCheckChangedExtractRows);

            this.Text = SR.GetString(SR.DLGen_Text);
            this.Size = new Size(368, 280);
            this.CommitOnDeactivate = true;
            this.Icon = new Icon(this.GetType(), "DataListGeneralPage.ico");

            Controls.Clear();
            Controls.AddRange(new Control[] {
                extractRowsCheck,
                templatesGroup,
                repeatLayoutCombo,
                repeatLayoutLabel,
                repeatDirectionCombo,
                repeatDirectionLabel,
                repeatColumnsEdit,
                repeatColumnsLabel,
                repeatGroup,
                showFooterCheck,
                showHeaderCheck,
                headerFooterGroup,
                dataKeyFieldCombo,
                dataKeyFieldLabel,
                dataMemberCombo,
                dataMemberLabel,
                dataSourceCombo,
                dataSourceLabel,
                dataGroup
            });
        }
Exemple #7
0
        private void InitForm()
        {
            System.Windows.Forms.Label label = new System.Windows.Forms.Label();
            this.formatTree = new System.Windows.Forms.TreeView();
            this.stylePanel = new System.Windows.Forms.Panel();
            GroupLabel label2 = new GroupLabel();

            System.Windows.Forms.Label label3 = new System.Windows.Forms.Label();
            this.foreColorCombo        = new ColorComboBox();
            this.foreColorPickerButton = new System.Windows.Forms.Button();
            System.Windows.Forms.Label label4 = new System.Windows.Forms.Label();
            this.backColorCombo        = new ColorComboBox();
            this.backColorPickerButton = new System.Windows.Forms.Button();
            System.Windows.Forms.Label label5 = new System.Windows.Forms.Label();
            this.fontNameCombo = new ComboBox();
            System.Windows.Forms.Label label6 = new System.Windows.Forms.Label();
            this.fontSizeCombo  = new UnsettableComboBox();
            this.fontSizeUnit   = new UnitControl();
            this.boldCheck      = new System.Windows.Forms.CheckBox();
            this.italicCheck    = new System.Windows.Forms.CheckBox();
            this.underlineCheck = new System.Windows.Forms.CheckBox();
            this.strikeOutCheck = new System.Windows.Forms.CheckBox();
            this.overlineCheck  = new System.Windows.Forms.CheckBox();
            GroupLabel label7 = new GroupLabel();

            System.Windows.Forms.Label label8 = new System.Windows.Forms.Label();
            this.horzAlignCombo     = new UnsettableComboBox();
            this.vertAlignLabel     = new System.Windows.Forms.Label();
            this.vertAlignCombo     = new UnsettableComboBox();
            this.allowWrappingCheck = new System.Windows.Forms.CheckBox();
            GroupLabel label9 = null;

            System.Windows.Forms.Label label10 = null;
            if (base.IsDataGridMode)
            {
                this.columnPanel = new System.Windows.Forms.Panel();
                label9           = new GroupLabel();
                label10          = new System.Windows.Forms.Label();
                this.widthUnit   = new UnitControl();
            }
            label.SetBounds(4, 4, 0x6f, 14);
            label.Text     = System.Design.SR.GetString("BDLFmt_Objects");
            label.TabStop  = false;
            label.TabIndex = 2;
            this.formatTree.SetBounds(4, 20, 0xa2, 350);
            this.formatTree.HideSelection = false;
            this.formatTree.TabIndex      = 3;
            this.formatTree.AfterSelect  += new TreeViewEventHandler(this.OnSelChangedFormatObject);
            this.stylePanel.SetBounds(0xb1, 4, 230, 370);
            this.stylePanel.TabIndex = 6;
            this.stylePanel.Visible  = false;
            label2.SetBounds(0, 2, 0xe0, 14);
            label2.Text     = System.Design.SR.GetString("BDLFmt_AppearanceGroup");
            label2.TabStop  = false;
            label2.TabIndex = 1;
            label3.SetBounds(8, 0x13, 160, 14);
            label3.Text     = System.Design.SR.GetString("BDLFmt_ForeColor");
            label3.TabStop  = false;
            label3.TabIndex = 2;
            this.foreColorCombo.SetBounds(8, 0x25, 0x66, 0x16);
            this.foreColorCombo.TabIndex              = 3;
            this.foreColorCombo.TextChanged          += new EventHandler(this.OnFormatChanged);
            this.foreColorCombo.SelectedIndexChanged += new EventHandler(this.OnFormatChanged);
            this.foreColorPickerButton.SetBounds(0x72, 0x24, 0x18, 0x16);
            this.foreColorPickerButton.TabIndex              = 4;
            this.foreColorPickerButton.Text                  = "...";
            this.foreColorPickerButton.FlatStyle             = FlatStyle.System;
            this.foreColorPickerButton.Click                += new EventHandler(this.OnClickForeColorPicker);
            this.foreColorPickerButton.AccessibleName        = System.Design.SR.GetString("BDLFmt_ChooseColorButton");
            this.foreColorPickerButton.AccessibleDescription = System.Design.SR.GetString("BDLFmt_ChooseForeColorDesc");
            label4.SetBounds(8, 0x3e, 160, 14);
            label4.Text     = System.Design.SR.GetString("BDLFmt_BackColor");
            label4.TabStop  = false;
            label4.TabIndex = 5;
            this.backColorCombo.SetBounds(8, 0x4e, 0x66, 0x16);
            this.backColorCombo.TabIndex              = 6;
            this.backColorCombo.TextChanged          += new EventHandler(this.OnFormatChanged);
            this.backColorCombo.SelectedIndexChanged += new EventHandler(this.OnFormatChanged);
            this.backColorPickerButton.SetBounds(0x72, 0x4d, 0x18, 0x16);
            this.backColorPickerButton.TabIndex              = 7;
            this.backColorPickerButton.Text                  = "...";
            this.backColorPickerButton.FlatStyle             = FlatStyle.System;
            this.backColorPickerButton.Click                += new EventHandler(this.OnClickBackColorPicker);
            this.backColorPickerButton.AccessibleName        = System.Design.SR.GetString("BDLFmt_ChooseColorButton");
            this.backColorPickerButton.AccessibleDescription = System.Design.SR.GetString("BDLFmt_ChooseBackColorDesc");
            label5.SetBounds(8, 0x68, 160, 14);
            label5.Text     = System.Design.SR.GetString("BDLFmt_FontName");
            label5.TabStop  = false;
            label5.TabIndex = 8;
            this.fontNameCombo.SetBounds(8, 120, 200, 0x16);
            this.fontNameCombo.Sorted                = true;
            this.fontNameCombo.TabIndex              = 9;
            this.fontNameCombo.SelectedIndexChanged += new EventHandler(this.OnFontNameChanged);
            this.fontNameCombo.TextChanged          += new EventHandler(this.OnFontNameChanged);
            label6.SetBounds(8, 0x92, 160, 14);
            label6.Text     = System.Design.SR.GetString("BDLFmt_FontSize");
            label6.TabStop  = false;
            label6.TabIndex = 10;
            this.fontSizeCombo.SetBounds(8, 0xa2, 100, 0x16);
            this.fontSizeCombo.TabIndex         = 11;
            this.fontSizeCombo.MaxDropDownItems = 11;
            this.fontSizeCombo.DropDownStyle    = ComboBoxStyle.DropDownList;
            this.fontSizeCombo.Items.AddRange(new object[] { System.Design.SR.GetString("BDLFmt_FS_Smaller"), System.Design.SR.GetString("BDLFmt_FS_Larger"), System.Design.SR.GetString("BDLFmt_FS_XXSmall"), System.Design.SR.GetString("BDLFmt_FS_XSmall"), System.Design.SR.GetString("BDLFmt_FS_Small"), System.Design.SR.GetString("BDLFmt_FS_Medium"), System.Design.SR.GetString("BDLFmt_FS_Large"), System.Design.SR.GetString("BDLFmt_FS_XLarge"), System.Design.SR.GetString("BDLFmt_FS_XXLarge"), System.Design.SR.GetString("BDLFmt_FS_Custom") });
            this.fontSizeCombo.SelectedIndexChanged += new EventHandler(this.OnFontSizeChanged);
            this.fontSizeUnit.SetBounds(0x70, 0xa2, 0x60, 0x16);
            this.fontSizeUnit.AllowNegativeValues        = false;
            this.fontSizeUnit.TabIndex                   = 12;
            this.fontSizeUnit.Changed                   += new EventHandler(this.OnFormatChanged);
            this.fontSizeUnit.ValueAccessibleDescription = System.Design.SR.GetString("BDLFmt_FontSizeValueDesc");
            this.fontSizeUnit.ValueAccessibleName        = System.Design.SR.GetString("BDLFmt_FontSizeValueName");
            this.fontSizeUnit.UnitAccessibleDescription  = System.Design.SR.GetString("BDLFmt_FontSizeUnitDesc");
            this.fontSizeUnit.UnitAccessibleName         = System.Design.SR.GetString("BDLFmt_FontSizeUnitName");
            this.boldCheck.SetBounds(8, 0xba, 0x6a, 20);
            this.boldCheck.Text            = System.Design.SR.GetString("BDLFmt_FontBold");
            this.boldCheck.TabIndex        = 13;
            this.boldCheck.TextAlign       = ContentAlignment.MiddleLeft;
            this.boldCheck.FlatStyle       = FlatStyle.System;
            this.boldCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            this.italicCheck.SetBounds(8, 0xcc, 0x6a, 20);
            this.italicCheck.Text            = System.Design.SR.GetString("BDLFmt_FontItalic");
            this.italicCheck.TabIndex        = 14;
            this.italicCheck.TextAlign       = ContentAlignment.MiddleLeft;
            this.italicCheck.FlatStyle       = FlatStyle.System;
            this.italicCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            this.underlineCheck.SetBounds(8, 0xde, 0x6a, 20);
            this.underlineCheck.Text            = System.Design.SR.GetString("BDLFmt_FontUnderline");
            this.underlineCheck.TabIndex        = 15;
            this.underlineCheck.TextAlign       = ContentAlignment.MiddleLeft;
            this.underlineCheck.FlatStyle       = FlatStyle.System;
            this.underlineCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            this.strikeOutCheck.SetBounds(120, 0xba, 0x6a, 20);
            this.strikeOutCheck.Text            = System.Design.SR.GetString("BDLFmt_FontStrikeout");
            this.strikeOutCheck.TabIndex        = 0x10;
            this.strikeOutCheck.TextAlign       = ContentAlignment.MiddleLeft;
            this.strikeOutCheck.FlatStyle       = FlatStyle.System;
            this.strikeOutCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            this.overlineCheck.SetBounds(120, 0xcc, 0x6a, 20);
            this.overlineCheck.Text            = System.Design.SR.GetString("BDLFmt_FontOverline");
            this.overlineCheck.TabIndex        = 0x11;
            this.overlineCheck.TextAlign       = ContentAlignment.MiddleLeft;
            this.overlineCheck.FlatStyle       = FlatStyle.System;
            this.overlineCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            label7.SetBounds(0, 0xf6, 0xe0, 14);
            label7.Text     = System.Design.SR.GetString("BDLFmt_AlignmentGroup");
            label7.TabStop  = false;
            label7.TabIndex = 0x12;
            label8.SetBounds(8, 0x108, 160, 14);
            label8.Text     = System.Design.SR.GetString("BDLFmt_HorzAlign");
            label8.TabStop  = false;
            label8.TabIndex = 0x13;
            this.horzAlignCombo.SetBounds(8, 280, 190, 0x16);
            this.horzAlignCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            this.horzAlignCombo.Items.AddRange(new object[] { System.Design.SR.GetString("BDLFmt_HA_Left"), System.Design.SR.GetString("BDLFmt_HA_Center"), System.Design.SR.GetString("BDLFmt_HA_Right"), System.Design.SR.GetString("BDLFmt_HA_Justify") });
            this.horzAlignCombo.TabIndex              = 20;
            this.horzAlignCombo.SelectedIndexChanged += new EventHandler(this.OnFormatChanged);
            this.vertAlignLabel.SetBounds(8, 0x132, 160, 14);
            this.vertAlignLabel.Text     = System.Design.SR.GetString("BDLFmt_VertAlign");
            this.vertAlignLabel.TabStop  = false;
            this.vertAlignLabel.TabIndex = 0x15;
            this.vertAlignCombo.SetBounds(8, 0x142, 190, 0x16);
            this.vertAlignCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            this.vertAlignCombo.Items.AddRange(new object[] { System.Design.SR.GetString("BDLFmt_VA_Top"), System.Design.SR.GetString("BDLFmt_VA_Middle"), System.Design.SR.GetString("BDLFmt_VA_Bottom") });
            this.vertAlignCombo.TabIndex              = 0x16;
            this.vertAlignCombo.SelectedIndexChanged += new EventHandler(this.OnFormatChanged);
            this.allowWrappingCheck.SetBounds(8, 0x15c, 200, 0x11);
            this.allowWrappingCheck.Text            = System.Design.SR.GetString("BDLFmt_AllowWrapping");
            this.allowWrappingCheck.TabIndex        = 0x18;
            this.allowWrappingCheck.FlatStyle       = FlatStyle.System;
            this.allowWrappingCheck.CheckedChanged += new EventHandler(this.OnFormatChanged);
            if (base.IsDataGridMode)
            {
                this.columnPanel.SetBounds(0xb1, 4, 0x117, 350);
                this.columnPanel.TabIndex = 7;
                this.columnPanel.Visible  = false;
                label9.SetBounds(0, 0, 0x117, 14);
                label9.Text     = System.Design.SR.GetString("BDLFmt_LayoutGroup");
                label9.TabStop  = false;
                label9.TabIndex = 0;
                label10.SetBounds(8, 20, 0x40, 14);
                label10.Text     = System.Design.SR.GetString("BDLFmt_Width");
                label10.TabStop  = false;
                label10.TabIndex = 1;
                this.widthUnit.SetBounds(80, 0x11, 0x66, 0x16);
                this.widthUnit.AllowNegativeValues        = false;
                this.widthUnit.DefaultUnit                = 0;
                this.widthUnit.TabIndex                   = 2;
                this.widthUnit.Changed                   += new EventHandler(this.OnFormatChanged);
                this.widthUnit.ValueAccessibleName        = System.Design.SR.GetString("BDLFmt_WidthValueName");
                this.widthUnit.ValueAccessibleDescription = System.Design.SR.GetString("BDLFmt_WidthValueDesc");
                this.widthUnit.UnitAccessibleName         = System.Design.SR.GetString("BDLFmt_WidthUnitName");
                this.widthUnit.UnitAccessibleDescription  = System.Design.SR.GetString("BDLFmt_WidthUnitDesc");
            }
            this.Text = System.Design.SR.GetString("BDLFmt_Text");
            base.AccessibleDescription = System.Design.SR.GetString("BDLFmt_Desc");
            base.Size = new Size(0x198, 370);
            base.CommitOnDeactivate = true;
            base.Icon = new Icon(base.GetType(), "FormatPage.ico");
            this.stylePanel.Controls.Clear();
            this.stylePanel.Controls.AddRange(new Control[] {
                this.allowWrappingCheck, this.vertAlignCombo, this.vertAlignLabel, this.horzAlignCombo, label8, label7, this.overlineCheck, this.strikeOutCheck, this.underlineCheck, this.italicCheck, this.boldCheck, this.fontSizeUnit, this.fontSizeCombo, label6, this.fontNameCombo, label5,
                this.backColorPickerButton, this.backColorCombo, label4, this.foreColorPickerButton, this.foreColorCombo, label3, label2
            });
            if (base.IsDataGridMode)
            {
                this.columnPanel.Controls.Clear();
                this.columnPanel.Controls.AddRange(new Control[] { this.widthUnit, label10, label9 });
                base.Controls.Clear();
                base.Controls.AddRange(new Control[] { this.columnPanel, this.stylePanel, this.formatTree, label });
            }
            else
            {
                base.Controls.Clear();
                base.Controls.AddRange(new Control[] { this.stylePanel, this.formatTree, label });
            }
        }
        private void InitForm()
        {
            this._cmbDataSource = new UnsettableComboBox();
            this._cmbLabelField = new UnsettableComboBox();
            this._cmbDataMember = new UnsettableComboBox();
            this._xLists        = new InterchangeableLists();

            GroupLabel grplblData = new GroupLabel();

            grplblData.SetBounds(4, 4, 392, 16);
            grplblData.Text     = SR.GetString(SR.ObjectListGeneralPage_DataGroupLabel);
            grplblData.TabIndex = 0;
            grplblData.TabStop  = false;

            Label lblDataSource = new Label();

            lblDataSource.SetBounds(12, 24, 174, 16);
            lblDataSource.Text     = SR.GetString(SR.ObjectListGeneralPage_DataSourceCaption);
            lblDataSource.TabStop  = false;
            lblDataSource.TabIndex = 1;

            _cmbDataSource.SetBounds(12, 40, 154, 64);
            _cmbDataSource.DropDownStyle         = ComboBoxStyle.DropDownList;
            _cmbDataSource.Sorted                = true;
            _cmbDataSource.TabIndex              = 2;
            _cmbDataSource.NotSetText            = SR.GetString(SR.ObjectListGeneralPage_UnboundComboEntry);
            _cmbDataSource.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataSource);

            Label lblDataMember = new Label();

            lblDataMember.SetBounds(206, 24, 174, 16);
            lblDataMember.Text     = SR.GetString(SR.ObjectListGeneralPage_DataMemberCaption);
            lblDataMember.TabStop  = false;
            lblDataMember.TabIndex = 3;

            _cmbDataMember.SetBounds(206, 40, 154, 64);
            _cmbDataMember.DropDownStyle         = ComboBoxStyle.DropDownList;
            _cmbDataMember.Sorted                = true;
            _cmbDataMember.TabIndex              = 4;
            _cmbDataMember.NotSetText            = SR.GetString(SR.ObjectListGeneralPage_NoneComboEntry);
            _cmbDataMember.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataMember);

            Label lblLabelField = new Label();

            lblLabelField.SetBounds(12, 67, 174, 16);
            lblLabelField.Text     = SR.GetString(SR.ObjectListGeneralPage_LabelFieldCaption);
            lblLabelField.TabStop  = false;
            lblLabelField.TabIndex = 5;

            _cmbLabelField.SetBounds(12, 83, 154, 64);
            _cmbLabelField.DropDownStyle         = ComboBoxStyle.DropDownList;
            _cmbLabelField.Sorted                = true;
            _cmbLabelField.TabIndex              = 6;
            _cmbLabelField.NotSetText            = SR.GetString(SR.ObjectListGeneralPage_NoneComboEntry);
            _cmbLabelField.SelectedIndexChanged += new EventHandler(this.OnSetPageDirty);
            _cmbLabelField.TextChanged          += new EventHandler(this.OnSetPageDirty);

            GroupLabel grplblTableFields = new GroupLabel();

            grplblTableFields.SetBounds(4, 118, 392, 16);
            grplblTableFields.Text     = SR.GetString(SR.ObjectListGeneralPage_TableFieldsGroupLabel);
            grplblTableFields.TabIndex = 9;
            grplblTableFields.TabStop  = false;

            _xLists.Location            = new System.Drawing.Point(4, 130);
            _xLists.TabIndex            = 10;
            _xLists.OnComponentChanged += new EventHandler(this.OnSetPageDirty);
            _xLists.TabStop             = true;
            _xLists.SetTitles(SR.GetString(SR.ObjectListGeneralPage_TableFieldsAvailableListLabel),
                              SR.GetString(SR.ObjectListGeneralPage_TableFieldsSelectedListLabel));

            GroupLabel grplblAppearance = new GroupLabel();

            grplblAppearance.SetBounds(4, 257, 392, 16);
            grplblAppearance.Text     = SR.GetString(SR.ObjectListGeneralPage_AppearanceGroupLabel);
            grplblAppearance.TabIndex = 11;
            grplblAppearance.TabStop  = false;

            Label lblBackCommandText = new Label();

            lblBackCommandText.SetBounds(12, 277, 174, 16);
            lblBackCommandText.Text     = SR.GetString(SR.ObjectListGeneralPage_BackCommandTextCaption);
            lblBackCommandText.TabStop  = false;
            lblBackCommandText.TabIndex = 12;

            _txtBackCommandText = new TextBox();
            _txtBackCommandText.SetBounds(12, 293, 154, 20);
            _txtBackCommandText.TabIndex     = 13;
            _txtBackCommandText.TextChanged += new EventHandler(this.OnSetPageDirty);

            Label lblDetailsCommandText = new Label();

            lblDetailsCommandText.SetBounds(206, 277, 174, 16);
            lblDetailsCommandText.Text     = SR.GetString(SR.ObjectListGeneralPage_DetailsCommandTextCaption);
            lblDetailsCommandText.TabStop  = false;
            lblDetailsCommandText.TabIndex = 14;

            _txtDetailsCommandText = new TextBox();
            _txtDetailsCommandText.SetBounds(206, 293, 154, 20);
            _txtDetailsCommandText.TabIndex     = 15;
            _txtDetailsCommandText.TextChanged += new EventHandler(this.OnSetPageDirty);

            Label lblMoreText = new Label();

            lblMoreText.SetBounds(12, 320, 174, 16);
            lblMoreText.Text     = SR.GetString(SR.ObjectListGeneralPage_MoreTextCaption);
            lblMoreText.TabStop  = false;
            lblMoreText.TabIndex = 16;

            _txtMoreText = new TextBox();
            _txtMoreText.SetBounds(12, 336, 154, 20);
            _txtMoreText.TabIndex     = 17;
            _txtMoreText.TextChanged += new EventHandler(this.OnSetPageDirty);

            GroupLabel pagingGroup    = new GroupLabel();
            Label      itemCountLabel = new Label();

            _txtItemCount = new TextBox();

            Label itemsPerPageLabel = new Label();

            _txtItemsPerPage = new TextBox();

            pagingGroup.SetBounds(4, 371, 392, 16);
            pagingGroup.Text     = SR.GetString(SR.ListGeneralPage_PagingGroupLabel);
            pagingGroup.TabIndex = 18;
            pagingGroup.TabStop  = false;

            itemCountLabel.SetBounds(12, 391, 174, 16);
            itemCountLabel.Text     = SR.GetString(SR.ListGeneralPage_ItemCountCaption);
            itemCountLabel.TabStop  = false;
            itemCountLabel.TabIndex = 19;

            _txtItemCount.SetBounds(12, 407, 154, 20);
            _txtItemCount.TextChanged += new EventHandler(this.OnSetPageDirty);
            _txtItemCount.KeyPress    += new KeyPressEventHandler(this.OnKeyPressNumberTextBox);
            _txtItemCount.TabIndex     = 20;

            itemsPerPageLabel.SetBounds(206, 391, 174, 16);
            itemsPerPageLabel.Text     = SR.GetString(SR.ListGeneralPage_ItemsPerPageCaption);
            itemsPerPageLabel.TabStop  = false;
            itemsPerPageLabel.TabIndex = 21;

            _txtItemsPerPage.SetBounds(206, 407, 154, 20);
            _txtItemsPerPage.TextChanged += new EventHandler(this.OnSetPageDirty);
            _txtItemsPerPage.KeyPress    += new KeyPressEventHandler(this.OnKeyPressNumberTextBox);
            _txtItemsPerPage.TabIndex     = 22;

            this.Text = SR.GetString(SR.ObjectListGeneralPage_Title);
            this.Size = new Size(402, 436);
            this.CommitOnDeactivate = true;
            this.Icon = new Icon(
                typeof(System.Web.UI.Design.MobileControls.MobileControlDesigner),
                "General.ico"
                );

            this.Controls.AddRange(new Control[]
            {
                grplblData,
                lblDataSource,
                _cmbDataSource,
                lblDataMember,
                _cmbDataMember,
                lblLabelField,
                _cmbLabelField,
                grplblTableFields,
                _xLists,
                grplblAppearance,
                lblBackCommandText,
                _txtBackCommandText,
                lblDetailsCommandText,
                _txtDetailsCommandText,
                lblMoreText,
                _txtMoreText,
                pagingGroup,
                itemCountLabel,
                _txtItemCount,
                itemsPerPageLabel,
                _txtItemsPerPage
            });
        }
Exemple #9
0
        ///////////////////////////////////////////////////////////////////////////
        // IStyleBuilderPage Implementation and StyleBuilderPage Overrides

        /// <include file='doc\PositionStylePage.uex' path='docs/doc[@for="PositionStylePage.CreateUI"]/*' />
        /// <devdoc>
        ///     Creates the UI elements within the page.
        /// </devdoc>
        protected override void CreateUI()
        {
            Label     positionLabel  = new Label();
            Label     leftLabel      = new Label();
            Label     topLabel       = new Label();
            Label     widthLabel     = new Label();
            Label     heightLabel    = new Label();
            Label     zIndexLabel    = new Label();
            ImageList positionImages = new ImageList();

            positionImages.ImageSize = new Size(34, 34);

            positionCombo   = new UnsettableComboBox();
            positionPicture = new PictureBoxEx();
            leftUnit        = new UnitControl();
            topUnit         = new UnitControl();
            widthUnit       = new UnitControl();
            heightUnit      = new UnitControl();
            zIndexEdit      = new NumberEdit();

            positionImages.Images.AddStrip(new Bitmap(typeof(PositionStylePage), "PropPosition.bmp"));
            positionPicture.Location = new Point(4, 9);
            positionPicture.Size     = new Size(36, 36);
            positionPicture.TabIndex = 0;
            positionPicture.TabStop  = false;
            positionPicture.Images   = positionImages;

            positionLabel.Location = new Point(44, 8);
            positionLabel.Size     = new Size(240, 16);
            positionLabel.TabIndex = 1;
            positionLabel.TabStop  = false;
            positionLabel.Text     = SR.GetString(SR.PosSP_PosModeLabel);

            positionCombo.Location      = new Point(44, 24);
            positionCombo.Size          = new Size(200, 21);
            positionCombo.TabIndex      = 2;
            positionCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            positionCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.PosSP_PosModeCombo_1),
                SR.GetString(SR.PosSP_PosModeCombo_2),
                SR.GetString(SR.PosSP_PosModeCombo_3)
            });
            positionCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangePosition);

            topLabel.Location = new Point(46, 61);
            topLabel.Size     = new Size(60, 16);
            topLabel.TabIndex = 3;
            topLabel.TabStop  = false;
            topLabel.Text     = SR.GetString(SR.PosSP_TopLabel);

            topUnit.Location    = new Point(108, 57);
            topUnit.Size        = new Size(88, 21);
            topUnit.TabIndex    = 4;
            topUnit.DefaultUnit = UnitControl.UNIT_PX;
            topUnit.MinValue    = -32768;
            topUnit.MaxValue    = 32767;
            topUnit.Changed    += new EventHandler(this.OnChangedTop);

            heightLabel.Location = new Point(220, 61);
            heightLabel.Size     = new Size(60, 16);
            heightLabel.TabIndex = 5;
            heightLabel.TabStop  = false;
            heightLabel.Text     = SR.GetString(SR.PosSP_HeightLabel);

            heightUnit.Location            = new Point(282, 57);
            heightUnit.Size                = new Size(88, 21);
            heightUnit.TabIndex            = 6;
            heightUnit.DefaultUnit         = UnitControl.UNIT_PX;
            heightUnit.AllowNegativeValues = false;
            heightUnit.MinValue            = -32768;
            heightUnit.MaxValue            = 32767;
            heightUnit.Changed            += new EventHandler(this.OnChangedHeight);

            leftLabel.Location = new Point(46, 84);
            leftLabel.Size     = new Size(60, 16);
            leftLabel.TabIndex = 7;
            leftLabel.TabStop  = false;
            leftLabel.Text     = SR.GetString(SR.PosSP_LeftLabel);

            leftUnit.Location    = new Point(108, 80);
            leftUnit.Size        = new Size(88, 21);
            leftUnit.TabIndex    = 8;
            leftUnit.DefaultUnit = UnitControl.UNIT_PX;
            leftUnit.MinValue    = -32768;
            leftUnit.MaxValue    = 32767;
            leftUnit.Changed    += new EventHandler(this.OnChangedLeft);

            widthLabel.Location = new Point(220, 84);
            widthLabel.Size     = new Size(60, 16);
            widthLabel.TabIndex = 9;
            widthLabel.TabStop  = false;
            widthLabel.Text     = SR.GetString(SR.PosSP_WidthLabel);

            widthUnit.Location            = new Point(282, 80);
            widthUnit.Size                = new Size(88, 21);
            widthUnit.TabIndex            = 10;
            widthUnit.DefaultUnit         = UnitControl.UNIT_PX;
            widthUnit.AllowNegativeValues = false;
            widthUnit.MinValue            = -32768;
            widthUnit.MaxValue            = 32767;
            widthUnit.Changed            += new EventHandler(this.OnChangedWidth);

            zIndexLabel.Location = new Point(46, 112);
            zIndexLabel.Size     = new Size(100, 16);
            zIndexLabel.TabIndex = 11;
            zIndexLabel.TabStop  = false;
            zIndexLabel.Text     = SR.GetString(SR.PosSP_ZIndexLabel);

            zIndexEdit.Location     = new Point(46, 130);
            zIndexEdit.Size         = new Size(60, 20);
            zIndexEdit.TabIndex     = 12;
            zIndexEdit.MaxLength    = 6;
            zIndexEdit.AllowDecimal = false;
            zIndexEdit.TextChanged += new EventHandler(this.OnChangedZIndex);

            this.Controls.Clear();
            this.Controls.AddRange(new Control[] {
                zIndexLabel,
                zIndexEdit,
                widthLabel,
                widthUnit,
                leftLabel,
                leftUnit,
                heightLabel,
                heightUnit,
                topLabel,
                topUnit,
                positionPicture,
                positionLabel,
                positionCombo
            });
        }
        ///////////////////////////////////////////////////////////////////////////
        // StyleBuilderPage Overrides

        /// <include file='doc\OtherStylePage.uex' path='docs/doc[@for="OtherStylePage.CreateUI"]/*' />
        /// <devdoc>
        ///     Creates the UI elements within the page.
        /// </devdoc>
        protected override void CreateUI()
        {
            Label     effectsLabel  = new GroupLabel();
            Label     filterLabel   = new Label();
            Label     uiLabel       = new GroupLabel();
            Label     cursorLabel   = new Label();
            Label     behaviorLabel = new GroupLabel();
            Label     urlLabel      = new Label();
            Label     tablesLabel   = new GroupLabel();
            Label     bordersLabel  = new Label();
            Label     layoutLabel   = new Label();
            ImageList cursorImages  = new ImageList();

            cursorImages.ImageSize = new Size(34, 34);
            ImageList bordersImages = new ImageList();

            bordersImages.ImageSize = new Size(34, 34);

            filterEdit      = new TextBox();
            cursorPicture   = new PictureBoxEx();
            cursorCombo     = new UnsettableComboBox();
            behaviorEdit    = new TextBox();
            urlPickerButton = new Button();
            bordersPicture  = new PictureBoxEx();
            bordersCombo    = new UnsettableComboBox();
            layoutCombo     = new UnsettableComboBox();

            uiLabel.Location = new Point(4, 4);
            uiLabel.Size     = new Size(400, 16);
            uiLabel.TabIndex = 0;
            uiLabel.TabStop  = false;
            uiLabel.Text     = SR.GetString(SR.OtherSP_UILabel);

            cursorImages.Images.AddStrip(new Bitmap(typeof(OtherStylePage), "PropCursor.bmp"));
            cursorPicture.Location = new Point(8, 25);
            cursorPicture.Size     = new Size(36, 36);
            cursorPicture.TabIndex = 1;
            cursorPicture.TabStop  = false;
            cursorPicture.Images   = cursorImages;

            cursorLabel.Location = new Point(48, 24);
            cursorLabel.Size     = new Size(160, 16);
            cursorLabel.TabIndex = 2;
            cursorLabel.TabStop  = false;
            cursorLabel.Text     = SR.GetString(SR.OtherSP_CursorLabel);

            cursorCombo.Location      = new Point(48, 40);
            cursorCombo.Size          = new Size(224, 21);
            cursorCombo.TabIndex      = 3;
            cursorCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            cursorCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.OtherSP_CursorCombo_1),
                SR.GetString(SR.OtherSP_CursorCombo_2),
                SR.GetString(SR.OtherSP_CursorCombo_3),
                SR.GetString(SR.OtherSP_CursorCombo_4),
                SR.GetString(SR.OtherSP_CursorCombo_5),
                SR.GetString(SR.OtherSP_CursorCombo_6),
                SR.GetString(SR.OtherSP_CursorCombo_7),
                SR.GetString(SR.OtherSP_CursorCombo_8),
                SR.GetString(SR.OtherSP_CursorCombo_9),
                SR.GetString(SR.OtherSP_CursorCombo_10),
                SR.GetString(SR.OtherSP_CursorCombo_11),
                SR.GetString(SR.OtherSP_CursorCombo_12),
                SR.GetString(SR.OtherSP_CursorCombo_13),
                SR.GetString(SR.OtherSP_CursorCombo_14),
                SR.GetString(SR.OtherSP_CursorCombo_15),
                SR.GetString(SR.OtherSP_CursorCombo_16)
            });
            cursorCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedCursor);

            tablesLabel.Location = new Point(4, 74);
            tablesLabel.Size     = new Size(400, 16);
            tablesLabel.TabIndex = 4;
            tablesLabel.TabStop  = false;
            tablesLabel.Text     = SR.GetString(SR.OtherSP_TablesLabel);

            bordersImages.Images.AddStrip(new Bitmap(typeof(OtherStylePage), "PropTableBorders.bmp"));
            bordersPicture.Location = new Point(8, 95);
            bordersPicture.Size     = new Size(36, 36);
            bordersPicture.TabIndex = 5;
            bordersPicture.TabStop  = false;
            bordersPicture.Images   = bordersImages;

            bordersLabel.Location = new Point(48, 94);
            bordersLabel.Size     = new Size(160, 16);
            bordersLabel.TabIndex = 6;
            bordersLabel.TabStop  = false;
            bordersLabel.Text     = SR.GetString(SR.OtherSP_BordersLabel);

            bordersCombo.Location      = new Point(48, 110);
            bordersCombo.Size          = new Size(174, 21);
            bordersCombo.TabIndex      = 7;
            bordersCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            bordersCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.OtherSP_BordersCombo_1),
                SR.GetString(SR.OtherSP_BordersCombo_2)
            });
            bordersCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedBorders);

            layoutLabel.Location = new Point(234, 94);
            layoutLabel.Size     = new Size(160, 16);
            layoutLabel.TabIndex = 8;
            layoutLabel.TabStop  = false;
            layoutLabel.Text     = SR.GetString(SR.OtherSP_LayoutLabel);

            layoutCombo.Location      = new Point(234, 110);
            layoutCombo.Size          = new Size(164, 21);
            layoutCombo.TabIndex      = 9;
            layoutCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            layoutCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.OtherSP_LayoutCombo_1),
                SR.GetString(SR.OtherSP_LayoutCombo_2)
            });
            layoutCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedLayout);

            effectsLabel.Location = new Point(4, 144);
            effectsLabel.Size     = new Size(400, 16);
            effectsLabel.TabIndex = 10;
            effectsLabel.TabStop  = false;
            effectsLabel.Text     = SR.GetString(SR.OtherSP_VisEffectsLabel);

            filterLabel.Location = new Point(8, 168);
            filterLabel.Size     = new Size(76, 16);
            filterLabel.TabIndex = 11;
            filterLabel.TabStop  = false;
            filterLabel.Text     = SR.GetString(SR.OtherSP_FilterLabel);

            filterEdit.Location     = new Point(88, 164);
            filterEdit.Size         = new Size(306, 20);
            filterEdit.TabIndex     = 12;
            filterEdit.Text         = "";
            filterEdit.TextChanged += new EventHandler(this.OnChangedFilter);

            behaviorLabel.Location = new Point(4, 196);
            behaviorLabel.Size     = new Size(400, 16);
            behaviorLabel.TabIndex = 13;
            behaviorLabel.TabStop  = false;
            behaviorLabel.Text     = SR.GetString(SR.OtherSP_BehaviorLabel);

            urlLabel.Location = new Point(8, 218);
            urlLabel.Size     = new Size(76, 16);
            urlLabel.TabIndex = 14;
            urlLabel.TabStop  = false;
            urlLabel.Text     = SR.GetString(SR.OtherSP_URLLabel);

            behaviorEdit.Location     = new Point(88, 214);
            behaviorEdit.Size         = new Size(278, 20);
            behaviorEdit.TabIndex     = 15;
            behaviorEdit.Text         = "";
            behaviorEdit.TextChanged += new EventHandler(this.OnChangedBehavior);

            urlPickerButton.Location  = new Point(370, 213);
            urlPickerButton.Size      = new Size(24, 22);
            urlPickerButton.TabIndex  = 16;
            urlPickerButton.Text      = "...";
            urlPickerButton.FlatStyle = FlatStyle.System;
            urlPickerButton.Click    += new EventHandler(this.OnClickedBehaviorUrlPicker);

            this.Controls.Clear();
            this.Controls.AddRange(new Control[] {
                behaviorLabel,
                urlLabel,
                behaviorEdit,
                urlPickerButton,
                effectsLabel,
                filterLabel,
                filterEdit,
                tablesLabel,
                layoutLabel,
                layoutCombo,
                bordersPicture,
                bordersLabel,
                bordersCombo,
                uiLabel,
                cursorPicture,
                cursorLabel,
                cursorCombo
            });
        }
Exemple #11
0
        /// <summary>
        ///   Initializes the UI of the form.
        /// </summary>
        private void InitForm()
        {
            Debug.Assert(GetBaseControl() != null);
            _isBaseControlList = (GetBaseControl() is List);   // SelectionList otherwise.

            GroupLabel dataGroup       = new GroupLabel();
            Label      dataSourceLabel = new Label();

            _dataSourceCombo = new UnsettableComboBox();
            Label dataMemberLabel = new Label();

            _dataMemberCombo = new UnsettableComboBox();
            Label dataTextFieldLabel = new Label();

            _dataTextFieldCombo = new UnsettableComboBox();
            Label dataValueFieldLabel = new Label();

            _dataValueFieldCombo = new UnsettableComboBox();

            GroupLabel appearanceGroup   = new GroupLabel();
            GroupLabel pagingGroup       = null;
            Label      itemCountLabel    = null;
            Label      itemsPerPageLabel = null;
            Label      rowsLabel         = null;
            Label      decorationLabel   = null;
            Label      selectTypeLabel   = null;

            if (_isBaseControlList)
            {
                pagingGroup          = new GroupLabel();
                itemCountLabel       = new Label();
                _itemCountTextBox    = new TextBox();
                itemsPerPageLabel    = new Label();
                _itemsPerPageTextBox = new TextBox();
                decorationLabel      = new Label();
                _decorationCombo     = new ComboBox();
            }
            else
            {
                rowsLabel        = new Label();
                _rowsTextBox     = new TextBox();
                selectTypeLabel  = new Label();
                _selectTypeCombo = new ComboBox();
            }

            dataGroup.SetBounds(4, 4, 372, 16);
            dataGroup.Text     = SR.GetString(SR.ListGeneralPage_DataGroupLabel);
            dataGroup.TabIndex = 0;
            dataGroup.TabStop  = false;

            dataSourceLabel.SetBounds(8, 24, 161, 16);
            dataSourceLabel.Text     = SR.GetString(SR.ListGeneralPage_DataSourceCaption);
            dataSourceLabel.TabStop  = false;
            dataSourceLabel.TabIndex = 1;

            _dataSourceCombo.SetBounds(8, 40, 161, 21);
            _dataSourceCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            _dataSourceCombo.Sorted                = true;
            _dataSourceCombo.TabIndex              = 2;
            _dataSourceCombo.NotSetText            = SR.GetString(SR.ListGeneralPage_UnboundComboEntry);
            _dataSourceCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataSource);

            dataMemberLabel.SetBounds(211, 24, 161, 16);
            dataMemberLabel.Text     = SR.GetString(SR.ListGeneralPage_DataMemberCaption);
            dataMemberLabel.TabStop  = false;
            dataMemberLabel.TabIndex = 3;

            _dataMemberCombo.SetBounds(211, 40, 161, 21);
            _dataMemberCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            _dataMemberCombo.Sorted                = true;
            _dataMemberCombo.TabIndex              = 4;
            _dataMemberCombo.NotSetText            = SR.GetString(SR.ListGeneralPage_NoneComboEntry);
            _dataMemberCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDataMember);

            dataTextFieldLabel.SetBounds(8, 67, 161, 16);
            dataTextFieldLabel.Text     = SR.GetString(SR.ListGeneralPage_DataTextFieldCaption);
            dataTextFieldLabel.TabStop  = false;
            dataTextFieldLabel.TabIndex = 5;

            _dataTextFieldCombo.SetBounds(8, 83, 161, 21);
            _dataTextFieldCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            _dataTextFieldCombo.Sorted                = true;
            _dataTextFieldCombo.TabIndex              = 6;
            _dataTextFieldCombo.NotSetText            = SR.GetString(SR.ListGeneralPage_NoneComboEntry);
            _dataTextFieldCombo.SelectedIndexChanged += new EventHandler(this.OnSetPageDirty);

            dataValueFieldLabel.SetBounds(211, 67, 161, 16);
            dataValueFieldLabel.Text     = SR.GetString(SR.ListGeneralPage_DataValueFieldCaption);
            dataValueFieldLabel.TabStop  = false;
            dataValueFieldLabel.TabIndex = 7;

            _dataValueFieldCombo.SetBounds(211, 83, 161, 21);
            _dataValueFieldCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
            _dataValueFieldCombo.Sorted                = true;
            _dataValueFieldCombo.TabIndex              = 8;
            _dataValueFieldCombo.NotSetText            = SR.GetString(SR.ListGeneralPage_NoneComboEntry);
            _dataValueFieldCombo.SelectedIndexChanged += new EventHandler(this.OnSetPageDirty);

            appearanceGroup.SetBounds(4, 120, 372, 16);
            appearanceGroup.Text     = SR.GetString(SR.ListGeneralPage_AppearanceGroupLabel);
            appearanceGroup.TabIndex = 9;
            appearanceGroup.TabStop  = false;

            if (_isBaseControlList)
            {
                decorationLabel.SetBounds(8, 140, 200, 16);
                decorationLabel.Text     = SR.GetString(SR.ListGeneralPage_DecorationCaption);
                decorationLabel.TabStop  = false;
                decorationLabel.TabIndex = 10;

                _decorationCombo.SetBounds(8, 156, 161, 21);
                _decorationCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
                _decorationCombo.SelectedIndexChanged += new EventHandler(this.OnSetPageDirty);
                _decorationCombo.Items.AddRange(new object[] {
                    SR.GetString(SR.ListGeneralPage_DecorationNone),
                    SR.GetString(SR.ListGeneralPage_DecorationBulleted),
                    SR.GetString(SR.ListGeneralPage_DecorationNumbered)
                });
                _decorationCombo.TabIndex = 11;

                pagingGroup.SetBounds(4, 193, 372, 16);
                pagingGroup.Text     = SR.GetString(SR.ListGeneralPage_PagingGroupLabel);
                pagingGroup.TabIndex = 12;
                pagingGroup.TabStop  = false;

                itemCountLabel.SetBounds(8, 213, 161, 16);
                itemCountLabel.Text     = SR.GetString(SR.ListGeneralPage_ItemCountCaption);
                itemCountLabel.TabStop  = false;
                itemCountLabel.TabIndex = 13;

                _itemCountTextBox.SetBounds(8, 229, 161, 20);
                _itemCountTextBox.TextChanged += new EventHandler(this.OnSetPageDirty);
                _itemCountTextBox.KeyPress    += new KeyPressEventHandler(this.OnKeyPressNumberTextBox);
                _itemCountTextBox.TabIndex     = 14;

                itemsPerPageLabel.SetBounds(211, 213, 161, 16);
                itemsPerPageLabel.Text     = SR.GetString(SR.ListGeneralPage_ItemsPerPageCaption);
                itemsPerPageLabel.TabStop  = false;
                itemsPerPageLabel.TabIndex = 15;

                _itemsPerPageTextBox.SetBounds(211, 229, 161, 20);
                _itemsPerPageTextBox.TextChanged += new EventHandler(this.OnSetPageDirty);
                _itemsPerPageTextBox.KeyPress    += new KeyPressEventHandler(this.OnKeyPressNumberTextBox);
                _itemsPerPageTextBox.TabIndex     = 16;
            }
            else
            {
                selectTypeLabel.SetBounds(8, 140, 161, 16);
                selectTypeLabel.Text     = SR.GetString(SR.ListGeneralPage_SelectTypeCaption);
                selectTypeLabel.TabStop  = false;
                selectTypeLabel.TabIndex = 10;

                _selectTypeCombo.SetBounds(8, 156, 161, 21);
                _selectTypeCombo.DropDownStyle         = ComboBoxStyle.DropDownList;
                _selectTypeCombo.SelectedIndexChanged += new EventHandler(this.OnSetPageDirty);
                _selectTypeCombo.Items.AddRange(new object[] {
                    SR.GetString(SR.ListGeneralPage_SelectTypeDropDown),
                    SR.GetString(SR.ListGeneralPage_SelectTypeListBox),
                    SR.GetString(SR.ListGeneralPage_SelectTypeRadio),
                    SR.GetString(SR.ListGeneralPage_SelectTypeMultiSelectListBox),
                    SR.GetString(SR.ListGeneralPage_SelectTypeCheckBox)
                });
                _selectTypeCombo.TabIndex = 11;

                rowsLabel.SetBounds(211, 140, 161, 16);
                rowsLabel.Text     = SR.GetString(SR.ListGeneralPage_RowsCaption);
                rowsLabel.TabStop  = false;
                rowsLabel.TabIndex = 12;

                _rowsTextBox.SetBounds(211, 156, 161, 20);
                _rowsTextBox.TextChanged += new EventHandler(this.OnSetPageDirty);
                _rowsTextBox.KeyPress    += new KeyPressEventHandler(this.OnKeyPressNumberTextBox);
                _rowsTextBox.TabIndex     = 13;
            }

            this.Text = SR.GetString(SR.ListGeneralPage_Title);
            this.Size = new Size(382, 270);
            this.CommitOnDeactivate = true;
            this.Icon = new Icon(
                typeof(System.Web.UI.Design.MobileControls.MobileControlDesigner),
                "General.ico"
                );

            this.Controls.AddRange(new Control[]
            {
                _dataTextFieldCombo,
                dataTextFieldLabel,
                _dataValueFieldCombo,
                dataValueFieldLabel,
                _dataMemberCombo,
                dataMemberLabel,
                _dataSourceCombo,
                dataSourceLabel,
                dataGroup,
                appearanceGroup
            });

            if (_isBaseControlList)
            {
                this.Controls.AddRange(new Control[]
                {
                    _itemsPerPageTextBox,
                    itemsPerPageLabel,
                    _itemCountTextBox,
                    itemCountLabel,
                    pagingGroup,
                    decorationLabel,
                    _decorationCombo
                });
            }
            else
            {
                this.Controls.AddRange(new Control[]
                {
                    _rowsTextBox,
                    rowsLabel,
                    selectTypeLabel,
                    _selectTypeCombo
                });
            }
        }
        ///////////////////////////////////////////////////////////////////////////
        // IStyleBuilderPage Implementation and StyleBuilderPage Overrides

        /// <include file='doc\LayoutStylePage.uex' path='docs/doc[@for="LayoutStylePage.CreateUI"]/*' />
        /// <devdoc>
        ///     Creates the UI elements within the page.
        /// </devdoc>
        protected override void CreateUI()
        {
            GroupBox clippingGroup        = new GroupBox();
            Label    flowControlLabel     = new GroupLabel();
            Label    visibilityLabel      = new Label();
            Label    displayLabel         = new Label();
            Label    floatLabel           = new Label();
            Label    clearLabel           = new Label();
            Label    contentLabel         = new GroupLabel();
            Label    overflowLabel        = new Label();
            Label    clipTopLabel         = new Label();
            Label    clipLeftLabel        = new Label();
            Label    clipBottomLabel      = new Label();
            Label    clipRightLabel       = new Label();
            Label    pageBreakLabel       = new GroupLabel();
            Label    pageBreakBeforeLabel = new Label();
            Label    pageBreakAfterLabel  = new Label();

            ImageList visibilityImages = new ImageList();

            visibilityImages.ImageSize = new Size(34, 34);
            ImageList displayImages = new ImageList();

            displayImages.ImageSize = new Size(34, 34);
            ImageList floatImages = new ImageList();

            floatImages.ImageSize = new Size(34, 34);
            ImageList clearImages = new ImageList();

            clearImages.ImageSize = new Size(34, 34);

            visibilityCombo      = new UnsettableComboBox();
            visibilityPicture    = new PictureBoxEx();
            displayCombo         = new UnsettableComboBox();
            displayPicture       = new PictureBoxEx();
            floatCombo           = new UnsettableComboBox();
            floatPicture         = new PictureBoxEx();
            clearCombo           = new UnsettableComboBox();
            clearPicture         = new PictureBoxEx();
            overflowCombo        = new UnsettableComboBox();
            clipTopUnit          = new UnitControl();
            clipLeftUnit         = new UnitControl();
            clipBottomUnit       = new UnitControl();
            clipRightUnit        = new UnitControl();
            pageBreakBeforeCombo = new UnsettableComboBox();
            pageBreakAfterCombo  = new UnsettableComboBox();

            flowControlLabel.Location = new Point(4, 4);
            flowControlLabel.Size     = new Size(400, 16);
            flowControlLabel.TabIndex = 0;
            flowControlLabel.TabStop  = false;
            flowControlLabel.Text     = SR.GetString(SR.LytSP_FlowControlLabel);

            visibilityImages.Images.AddStrip(new Bitmap(typeof(LayoutStylePage), "PropVisibility.bmp"));
            visibilityPicture.Location = new Point(8, 25);
            visibilityPicture.Size     = new Size(36, 36);
            visibilityPicture.TabIndex = 1;
            visibilityPicture.TabStop  = false;
            visibilityPicture.Images   = visibilityImages;

            visibilityLabel.Location = new Point(48, 24);
            visibilityLabel.Size     = new Size(132, 16);
            visibilityLabel.TabIndex = 2;
            visibilityLabel.TabStop  = false;
            visibilityLabel.Text     = SR.GetString(SR.LytSP_VisibilityLabel);

            visibilityCombo.Location      = new Point(48, 40);
            visibilityCombo.Size          = new Size(132, 21);
            visibilityCombo.TabIndex      = 3;
            visibilityCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            visibilityCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_VisibilityCombo_1),
                SR.GetString(SR.LytSP_VisibilityCombo_2)
            });
            visibilityCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedVisibility);

            floatImages.Images.AddStrip(new Bitmap(typeof(LayoutStylePage), "PropFloat.bmp"));
            floatPicture.Location = new Point(186, 25);
            floatPicture.Size     = new Size(36, 36);
            floatPicture.TabIndex = 4;
            floatPicture.TabStop  = false;
            floatPicture.Images   = floatImages;

            floatLabel.Location = new Point(226, 24);
            floatLabel.Size     = new Size(180, 16);
            floatLabel.TabIndex = 5;
            floatLabel.TabStop  = false;
            floatLabel.Text     = SR.GetString(SR.LytSP_FloatLabel);

            floatCombo.Location      = new Point(226, 40);
            floatCombo.Size          = new Size(174, 21);
            floatCombo.TabIndex      = 6;
            floatCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            floatCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_FloatCombo_1),
                SR.GetString(SR.LytSP_FloatCombo_2),
                SR.GetString(SR.LytSP_FloatCombo_3)
            });
            floatCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedFloat);

            displayImages.Images.AddStrip(new Bitmap(typeof(LayoutStylePage), "PropDisplay.bmp"));
            displayPicture.Location = new Point(8, 69);
            displayPicture.Size     = new Size(36, 36);
            displayPicture.TabIndex = 7;
            displayPicture.TabStop  = false;
            displayPicture.Images   = displayImages;

            displayLabel.Location = new Point(48, 68);
            displayLabel.Size     = new Size(132, 16);
            displayLabel.TabIndex = 8;
            displayLabel.TabStop  = false;
            displayLabel.Text     = SR.GetString(SR.LytSP_DisplayLabel);

            displayCombo.Location      = new Point(48, 84);
            displayCombo.Size          = new Size(132, 21);
            displayCombo.TabIndex      = 9;
            displayCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            displayCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_DisplayCombo_1),
                SR.GetString(SR.LytSP_DisplayCombo_2),
                SR.GetString(SR.LytSP_DisplayCombo_3)
            });
            displayCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedDisplay);

            clearImages.Images.AddStrip(new Bitmap(typeof(LayoutStylePage), "PropClear.bmp"));
            clearPicture.Location = new Point(186, 69);
            clearPicture.Size     = new Size(36, 36);
            clearPicture.TabIndex = 10;
            clearPicture.TabStop  = false;
            clearPicture.Images   = clearImages;

            clearLabel.Location = new Point(226, 68);
            clearLabel.Size     = new Size(180, 16);
            clearLabel.TabIndex = 11;
            clearLabel.TabStop  = false;
            clearLabel.Text     = SR.GetString(SR.LytSP_ClearLabel);

            clearCombo.Location      = new Point(226, 84);
            clearCombo.Size          = new Size(174, 21);
            clearCombo.TabIndex      = 12;
            clearCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            clearCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_ClearCombo_1),
                SR.GetString(SR.LytSP_ClearCombo_2),
                SR.GetString(SR.LytSP_ClearCombo_3),
                SR.GetString(SR.LytSP_ClearCombo_4)
            });
            clearCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedClear);

            contentLabel.Location = new Point(4, 114);
            contentLabel.Size     = new Size(400, 16);
            contentLabel.TabIndex = 13;
            contentLabel.TabStop  = false;
            contentLabel.Text     = SR.GetString(SR.LytSP_ContentLabel);

            overflowLabel.Location = new Point(8, 138);
            overflowLabel.Size     = new Size(108, 16);
            overflowLabel.TabIndex = 14;
            overflowLabel.TabStop  = false;
            overflowLabel.Text     = SR.GetString(SR.LytSP_OverflowLabel);

            overflowCombo.Location      = new Point(116, 134);
            overflowCombo.Size          = new Size(252, 21);
            overflowCombo.TabIndex      = 15;
            overflowCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            overflowCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_OverflowCombo_1),
                SR.GetString(SR.LytSP_OverflowCombo_2),
                SR.GetString(SR.LytSP_OverflowCombo_3),
                SR.GetString(SR.LytSP_OverflowCombo_4)
            });
            overflowCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedOverflow);

            clippingGroup.Location  = new Point(8, 162);
            clippingGroup.Size      = new Size(360, 72);
            clippingGroup.TabIndex  = 16;
            clippingGroup.TabStop   = false;
            clippingGroup.FlatStyle = FlatStyle.System;
            clippingGroup.Text      = SR.GetString(SR.LytSP_ClippingGroup);

            clipTopLabel.Location = new Point(12, 20);
            clipTopLabel.Size     = new Size(58, 16);
            clipTopLabel.TabIndex = 0;
            clipTopLabel.TabStop  = false;
            clipTopLabel.Text     = SR.GetString(SR.LytSP_ClipTopLabel);

            clipTopUnit.Location    = new Point(70, 16);
            clipTopUnit.Size        = new Size(88, 21);
            clipTopUnit.TabIndex    = 1;
            clipTopUnit.DefaultUnit = UnitControl.UNIT_PX;
            clipTopUnit.MinValue    = -32768;
            clipTopUnit.MaxValue    = 32767;
            clipTopUnit.Changed    += new EventHandler(this.OnChangedClip);

            clipLeftLabel.Location = new Point(12, 44);
            clipLeftLabel.Size     = new Size(58, 16);
            clipLeftLabel.TabIndex = 4;
            clipLeftLabel.TabStop  = false;
            clipLeftLabel.Text     = SR.GetString(SR.LytSP_ClipLeftLabel);

            clipLeftUnit.Location    = new Point(70, 40);
            clipLeftUnit.Size        = new Size(88, 21);
            clipLeftUnit.TabIndex    = 5;
            clipLeftUnit.DefaultUnit = UnitControl.UNIT_PX;
            clipLeftUnit.MinValue    = -32768;
            clipLeftUnit.MaxValue    = 32767;
            clipLeftUnit.Changed    += new EventHandler(this.OnChangedClip);

            clipBottomLabel.Location = new Point(182, 20);
            clipBottomLabel.Size     = new Size(62, 16);
            clipBottomLabel.TabIndex = 2;
            clipBottomLabel.TabStop  = false;
            clipBottomLabel.Text     = SR.GetString(SR.LytSP_ClipBottomLabel);

            clipBottomUnit.Location    = new Point(248, 16);
            clipBottomUnit.Size        = new Size(88, 21);
            clipBottomUnit.TabIndex    = 3;
            clipBottomUnit.DefaultUnit = UnitControl.UNIT_PX;
            clipBottomUnit.MinValue    = -32768;
            clipBottomUnit.MaxValue    = 32767;
            clipBottomUnit.Changed    += new EventHandler(this.OnChangedClip);

            clipRightLabel.Location = new Point(182, 44);
            clipRightLabel.Size     = new Size(62, 16);
            clipRightLabel.TabIndex = 6;
            clipRightLabel.TabStop  = false;
            clipRightLabel.Text     = SR.GetString(SR.LytSP_ClipRightLabel);

            clipRightUnit.Location    = new Point(248, 40);
            clipRightUnit.Size        = new Size(88, 21);
            clipRightUnit.TabIndex    = 7;
            clipRightUnit.DefaultUnit = UnitControl.UNIT_PX;
            clipRightUnit.MinValue    = -32768;
            clipRightUnit.MaxValue    = 32767;
            clipRightUnit.Changed    += new EventHandler(this.OnChangedClip);

            pageBreakLabel.Location = new Point(4, 244);
            pageBreakLabel.Size     = new Size(400, 16);
            pageBreakLabel.TabIndex = 17;
            pageBreakLabel.TabStop  = false;
            pageBreakLabel.Text     = SR.GetString(SR.LytSP_PageBreakGroup);

            pageBreakBeforeLabel.Location = new Point(8, 268);
            pageBreakBeforeLabel.Size     = new Size(82, 16);
            pageBreakBeforeLabel.TabIndex = 18;
            pageBreakBeforeLabel.TabStop  = false;
            pageBreakBeforeLabel.Text     = SR.GetString(SR.LytSP_PgBrBeforeLabel);

            pageBreakBeforeCombo.Location      = new Point(90, 264);
            pageBreakBeforeCombo.Size          = new Size(180, 21);
            pageBreakBeforeCombo.TabIndex      = 19;
            pageBreakBeforeCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            pageBreakBeforeCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_PgBrBeforeCombo_1),
                SR.GetString(SR.LytSP_PgBrBeforeCombo_2)
            });
            pageBreakBeforeCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedPageBreak);

            pageBreakAfterLabel.Location = new Point(8, 294);
            pageBreakAfterLabel.Size     = new Size(82, 16);
            pageBreakAfterLabel.TabIndex = 20;
            pageBreakAfterLabel.TabStop  = false;
            pageBreakAfterLabel.Text     = SR.GetString(SR.LytSP_PgBrAfterLabel);

            pageBreakAfterCombo.Location      = new Point(90, 290);
            pageBreakAfterCombo.Size          = new Size(180, 21);
            pageBreakAfterCombo.TabIndex      = 21;
            pageBreakAfterCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            pageBreakAfterCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LytSP_PgBrAfterCombo_1),
                SR.GetString(SR.LytSP_PgBrAfterCombo_2)
            });
            pageBreakAfterCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedPageBreak);

            this.Controls.Clear();
            this.Controls.AddRange(new Control[] {
                pageBreakLabel,
                pageBreakAfterLabel,
                pageBreakAfterCombo,
                pageBreakBeforeLabel,
                pageBreakBeforeCombo,
                clippingGroup,
                overflowLabel,
                overflowCombo,
                contentLabel,
                clearPicture,
                clearLabel,
                clearCombo,
                displayPicture,
                displayLabel,
                displayCombo,
                floatPicture,
                floatLabel,
                floatCombo,
                visibilityPicture,
                visibilityLabel,
                visibilityCombo,
                flowControlLabel
            });

            clippingGroup.Controls.Clear();
            clippingGroup.Controls.AddRange(new Control[] {
                clipRightLabel,
                clipRightUnit,
                clipBottomLabel,
                clipBottomUnit,
                clipLeftLabel,
                clipLeftUnit,
                clipTopLabel,
                clipTopUnit
            });
        }
Exemple #13
0
        /// <include file='doc\ListsStylePage.uex' path='docs/doc[@for="ListsStylePage.CreateUI"]/*' />
        /// <devdoc>
        ///     Creates the UI elements within the page.
        /// </devdoc>
        protected override void CreateUI()
        {
            Label listTypeLabel = new Label();
            Label bulletsLabel  = new GroupLabel();
            Label positionLabel = new Label();
            Label styleLabel    = new Label();

            listTypeCombo     = new UnsettableComboBox();
            positionCombo     = new UnsettableComboBox();
            styleCombo        = new UnsettableComboBox();
            customBulletCheck = new CheckBox();
            customImageOption = new RadioButton();
            customNoneOption  = new RadioButton();
            customImageEdit   = new TextBox();
            customImagePicker = new Button();

            listTypeLabel.Location = new Point(4, 8);
            listTypeLabel.Size     = new Size(70, 16);
            listTypeLabel.TabIndex = 0;
            listTypeLabel.TabStop  = false;
            listTypeLabel.Text     = SR.GetString(SR.LstSP_ListTypeLabel);

            listTypeCombo.Location      = new Point(76, 4);
            listTypeCombo.Size          = new Size(144, 21);
            listTypeCombo.TabIndex      = 1;
            listTypeCombo.Text          = "";
            listTypeCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            listTypeCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LstSP_ListTypeCombo_1),
                SR.GetString(SR.LstSP_ListTypeCombo_2)
            });
            listTypeCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedListType);

            bulletsLabel.Location = new Point(4, 36);
            bulletsLabel.Size     = new Size(400, 16);
            bulletsLabel.TabIndex = 2;
            bulletsLabel.TabStop  = false;
            bulletsLabel.Text     = SR.GetString(SR.LstSP_BulletsLabel);

            styleLabel.Location = new Point(8, 59);
            styleLabel.Size     = new Size(84, 16);
            styleLabel.TabIndex = 3;
            styleLabel.TabStop  = false;
            styleLabel.Text     = SR.GetString(SR.LstSP_StyleLabel);

            styleCombo.Location      = new Point(98, 55);
            styleCombo.Size          = new Size(200, 21);
            styleCombo.TabIndex      = 4;
            styleCombo.Text          = "";
            styleCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            styleCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LstSP_StyleCombo_1),
                SR.GetString(SR.LstSP_StyleCombo_2),
                SR.GetString(SR.LstSP_StyleCombo_3),
                SR.GetString(SR.LstSP_StyleCombo_4),
                SR.GetString(SR.LstSP_StyleCombo_5),
                SR.GetString(SR.LstSP_StyleCombo_6),
                SR.GetString(SR.LstSP_StyleCombo_7),
                SR.GetString(SR.LstSP_StyleCombo_8)
            });
            styleCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedStyle);

            positionLabel.Location = new Point(8, 84);
            positionLabel.Size     = new Size(84, 16);
            positionLabel.TabIndex = 5;
            positionLabel.TabStop  = false;
            positionLabel.Text     = SR.GetString(SR.LstSP_PositionLabel);

            positionCombo.Location      = new Point(98, 80);
            positionCombo.Size          = new Size(200, 21);
            positionCombo.TabIndex      = 6;
            positionCombo.Text          = "";
            positionCombo.DropDownStyle = ComboBoxStyle.DropDownList;
            positionCombo.Items.AddRange(new object[]
            {
                SR.GetString(SR.LstSP_PositionCombo_1),
                SR.GetString(SR.LstSP_PositionCombo_2)
            });
            positionCombo.SelectedIndexChanged += new EventHandler(this.OnSelChangedPosition);

            customBulletCheck.Location        = new Point(8, 112);
            customBulletCheck.Size            = new Size(260, 20);
            customBulletCheck.TabIndex        = 7;
            customBulletCheck.Text            = SR.GetString(SR.LstSP_CustomBulletCheck);
            customBulletCheck.FlatStyle       = FlatStyle.System;
            customBulletCheck.CheckedChanged += new EventHandler(this.OnChangedCustomBullet);

            customImageOption.Location        = new Point(22, 136);
            customImageOption.Size            = new Size(84, 16);
            customImageOption.TabIndex        = 8;
            customImageOption.Text            = SR.GetString(SR.LstSP_CustomImageOption);
            customImageOption.FlatStyle       = FlatStyle.System;
            customImageOption.CheckedChanged += new EventHandler(this.OnChangedCustomBulletType);

            customNoneOption.Location        = new Point(22, 156);
            customNoneOption.Size            = new Size(84, 20);
            customNoneOption.TabIndex        = 9;
            customNoneOption.Text            = SR.GetString(SR.LstSP_CustomNoneOption);
            customNoneOption.FlatStyle       = FlatStyle.System;
            customNoneOption.CheckedChanged += new EventHandler(this.OnChangedCustomBulletType);

            customImageEdit.Location       = new Point(98, 134);
            customImageEdit.Size           = new Size(226, 20);
            customImageEdit.TabIndex       = 10;
            customImageEdit.Text           = "";
            customImageEdit.AccessibleName = SR.GetString(SR.LstSP_CustomImageOption);
            customImageEdit.TextChanged   += new EventHandler(this.OnChangedCustomBulletImage);
            customImageEdit.LostFocus     += new EventHandler(this.OnLostFocusCustomBulletImage);

            customImagePicker.Location  = new Point(328, 133);
            customImagePicker.Size      = new Size(24, 22);
            customImagePicker.TabIndex  = 11;
            customImagePicker.Text      = "...";
            customImagePicker.FlatStyle = FlatStyle.System;
            customImagePicker.Click    += new EventHandler(this.OnClickCustomBulletPicker);

            this.Controls.Clear();
            this.Controls.AddRange(new Control[] {
                bulletsLabel,
                customBulletCheck,
                customImageEdit,
                customImagePicker,
                customNoneOption,
                customImageOption,
                positionLabel,
                positionCombo,
                styleLabel,
                styleCombo,
                listTypeLabel,
                listTypeCombo
            });
        }