Esempio n. 1
0
        protected void Calque()
        {
            try
            {
                Groupe G;

                G = _Calque.AjouterGroupe("Fichier");

                _Texte_RefFichier = G.AjouterTexteBox("Référence du fichier :", "la référence est ajoutée au début du nom de chaque fichier généré");

                _Texte_RefFichier.Text         = MdlBase.eRefFichierComplet();
                _Texte_RefFichier.LectureSeule = false;

                // S'il n'y a pas de reference, on met le texte en rouge
                if (String.IsNullOrWhiteSpace(_Texte_RefFichier.Text))
                {
                    _Texte_RefFichier.BackgroundColor(Color.Red, true);
                }

                _TextBox_Campagne = G.AjouterTexteBox("Campagne :", "");
                _TextBox_Campagne.LectureSeule = true;

                _CheckBox_MettreAjourCampagne = G.AjouterCheckBox("Mettre à jour la campagne");

                G = _Calque.AjouterGroupe("Quantité :");

                _Texte_Quantite               = G.AjouterTexteBox("Multiplier par quantité :", "Multiplier les quantités par");
                _Texte_Quantite.Text          = MdlBase.pQuantite();
                _Texte_Quantite.ValiderTexte += ValiderTextIsInteger;

                G = _Calque.AjouterGroupe("Materiaux :");

                _TextListBox_Materiaux = G.AjouterTextListBox();
                _TextListBox_Materiaux.TouteHauteur      = true;
                _TextListBox_Materiaux.Height            = 50;
                _TextListBox_Materiaux.SelectionMultiple = true;

                G = _Calque.AjouterGroupe("Ep :");

                _TextListBox_Ep = G.AjouterTextListBox();
                _TextListBox_Ep.TouteHauteur      = true;
                _TextListBox_Ep.Height            = 50;
                _TextListBox_Ep.SelectionMultiple = true;

                G = _Calque.AjouterGroupe("Options");

                _CheckBox_AfficherLignePliage = G.AjouterCheckBox(AfficherLignePliage);
                _CheckBox_AfficherNotePliage  = G.AjouterCheckBox(AfficherNotePliage);
                _CheckBox_AfficherNotePliage.StdIndent();

                _CheckBox_AfficherLignePliage.OnUnCheck += _CheckBox_AfficherNotePliage.UnCheck;
                _CheckBox_AfficherLignePliage.OnIsCheck += _CheckBox_AfficherNotePliage.IsEnable;

                // Pour eviter d'ecraser le parametre de "AfficherNotePliage", le met à jour seulement si
                if (!_CheckBox_AfficherLignePliage.IsChecked)
                {
                    _CheckBox_AfficherNotePliage.IsChecked = _CheckBox_AfficherLignePliage.IsChecked;
                    _CheckBox_AfficherNotePliage.IsEnabled = _CheckBox_AfficherLignePliage.IsChecked;
                }

                _CheckBox_InscrireNomTole              = G.AjouterCheckBox(InscrireNomTole);
                _Texte_TailleInscription               = G.AjouterTexteBox(TailleInscription, false);
                _Texte_TailleInscription.ValiderTexte += ValiderTextIsInteger;
                _Texte_TailleInscription.StdIndent();

                _CheckBox_InscrireNomTole.OnIsCheck += _Texte_TailleInscription.IsEnable;
                _Texte_TailleInscription.IsEnabled   = _CheckBox_InscrireNomTole.IsChecked;

                _CheckBox_OrienterDvp        = G.AjouterCheckBox(OrienterDvp);
                _EnumComboBox_OrientationDvp = G.AjouterEnumComboBox <eOrientation, Intitule>(OrientationDvp);
                _EnumComboBox_OrientationDvp.StdIndent();

                _CheckBox_OrienterDvp.OnIsCheck       += _EnumComboBox_OrientationDvp.IsEnable;
                _EnumComboBox_OrientationDvp.IsEnabled = _CheckBox_OrienterDvp.IsChecked;
            }
            catch (Exception e)
            { this.LogMethode(new Object[] { e }); }
        }
Esempio n. 2
0
        protected void Calque()
        {
            try
            {
                Groupe G;

                G = _Calque.AjouterGroupe("Fichier");

                _Texte_RefFichier = G.AjouterTexteBox("Référence du fichier :", "la référence est ajoutée au début du nom de chaque fichier généré");

                String Ref = MdlBase.eRefFichier();
                _Texte_RefFichier.Text         = Ref;
                _Texte_RefFichier.LectureSeule = false;

                // S'il n'y a pas de reference, on met le texte en rouge
                if (String.IsNullOrWhiteSpace(Ref))
                {
                    _Texte_RefFichier.BackgroundColor(Color.Red, true);
                }

                _Texte_Quantite               = G.AjouterTexteBox("Quantité :", "Multiplier les quantités par");
                _Texte_Quantite.Text          = Quantite();
                _Texte_Quantite.ValiderTexte += ValiderTextIsInteger;

                _CheckBox_ComposantsExterne = G.AjouterCheckBox(ComposantsExterne);

                G = _Calque.AjouterGroupe("Materiaux :");

                _TextListBox_Materiaux = G.AjouterTextListBox();
                _TextListBox_Materiaux.TouteHauteur      = true;
                _TextListBox_Materiaux.Height            = 50;
                _TextListBox_Materiaux.SelectionMultiple = true;

                _CheckBox_ForcerMateriau                         = G.AjouterCheckBox("Forcer le materiau");
                _TextComboBox_ForcerMateriau                     = G.AjouterTextComboBox();
                _TextComboBox_ForcerMateriau.Editable            = true;
                _TextComboBox_ForcerMateriau.LectureSeule        = false;
                _TextComboBox_ForcerMateriau.NotifieSurSelection = false;
                _TextComboBox_ForcerMateriau.IsEnabled           = false;
                _CheckBox_ForcerMateriau.OnIsCheck              += _TextComboBox_ForcerMateriau.IsEnable;

                G = _Calque.AjouterGroupe("Ep :");

                _TextListBox_Ep = G.AjouterTextListBox();
                _TextListBox_Ep.TouteHauteur      = true;
                _TextListBox_Ep.Height            = 50;
                _TextListBox_Ep.SelectionMultiple = true;

                G = _Calque.AjouterGroupe("Options");

                _CheckBox_AfficherLignePliage = G.AjouterCheckBox(AfficherLignePliage);
                _CheckBox_AfficherNotePliage  = G.AjouterCheckBox(AfficherNotePliage);
                _CheckBox_AfficherNotePliage.StdIndent();

                _CheckBox_AfficherLignePliage.OnUnCheck += _CheckBox_AfficherNotePliage.UnCheck;
                _CheckBox_AfficherLignePliage.OnIsCheck += _CheckBox_AfficherNotePliage.IsEnable;

                // Pour eviter d'ecraser le parametre de "AfficherNotePliage", le met à jour seulement si
                if (!_CheckBox_AfficherLignePliage.IsChecked)
                {
                    _CheckBox_AfficherNotePliage.IsChecked = _CheckBox_AfficherLignePliage.IsChecked;
                    _CheckBox_AfficherNotePliage.IsEnabled = _CheckBox_AfficherLignePliage.IsChecked;
                }

                _CheckBox_InscrireNomTole              = G.AjouterCheckBox(InscrireNomTole);
                _Texte_TailleInscription               = G.AjouterTexteBox(TailleInscription, false);
                _Texte_TailleInscription.ValiderTexte += ValiderTextIsInteger;
                _Texte_TailleInscription.StdIndent();

                _CheckBox_InscrireNomTole.OnIsCheck += _Texte_TailleInscription.IsEnable;
                _Texte_TailleInscription.IsEnabled   = _CheckBox_InscrireNomTole.IsChecked;


                _CheckBox_OrienterDvp        = G.AjouterCheckBox(OrienterDvp);
                _EnumComboBox_OrientationDvp = G.AjouterEnumComboBox <eOrientation, Intitule>(OrientationDvp);
                _EnumComboBox_OrientationDvp.StdIndent();

                _CheckBox_OrienterDvp.OnIsCheck       += _EnumComboBox_OrientationDvp.IsEnable;
                _EnumComboBox_OrientationDvp.IsEnabled = _CheckBox_OrienterDvp.IsChecked;

                _CheckBox_FermerPlan         = G.AjouterCheckBox(FermerPlan);
                _CheckBox_MajPlans           = G.AjouterCheckBox("Mettre à jour les dvps existant");
                _CheckBox_MajPlans.IsChecked = false;

                G          = _Calque.AjouterGroupe("Fichiers volumineux");
                G.Expanded = true;

                _CheckBox_ConvertirEsquisse = G.AjouterCheckBox(ConvertirEsquisse);
            }
            catch (Exception e)
            { this.LogMethode(new Object[] { e }); }
        }