示例#1
0
        private void AreaCvToolbarSettings_Load(object sender, EventArgs e)
        {
            var enabled = _graphSummary.DocumentUIContainer.DocumentUI.Settings.PeptideSettings.Integration.PeakScoringModel.IsTrained &&
                          AreaGraphController.PointsType == PointsTypePeakArea.targets;

            if (enabled)
            {
                textQValueCutoff.Text = ValueOrEmpty(Settings.Default.AreaCVQValueCutoff);
            }

            textCvCutoff.Text          = Settings.Default.AreaCVCVCutoff.ToString(LocalizationHelper.CurrentCulture);
            checkShowCvCutoff.Checked  = Settings.Default.AreaCVShowCVCutoff;
            checkShowMedian.Checked    = Settings.Default.AreaCVShowMedianCV;
            checkBoxDecimalCvs.Checked = _showDecimals = Settings.Default.AreaCVShowDecimals;
            labelMaxCvPercent.Visible  = labelCvCutoffPercent.Visible = !Settings.Default.AreaCVShowDecimals;
            textMaxFrequency.Text      = ValueOrEmpty(Settings.Default.AreaCVMaxFrequency);
            textMaximumCv.Text         = ValueOrEmpty(Settings.Default.AreaCVMaxCV);
            textMinLog10.Text          = ValueOrEmpty(Settings.Default.AreaCVMinLog10Area);
            textMaxLog10.Text          = ValueOrEmpty(Settings.Default.AreaCVMaxLog10Area);

            GraphFontSize.PopulateCombo(comboFontSize, Settings.Default.AreaFontSize);

            var is2DHistogram = _graphSummary.Type == GraphTypeSummary.histogram2d;

            textMinLog10.Visible     = textMaxLog10.Visible = labelMinLog10.Visible = labelMaxLog10.Visible = is2DHistogram;
            textMaxFrequency.Visible = labelMaxFrequency.Visible = !is2DHistogram;

            if (is2DHistogram)
            {
                textMinLog10.Location  = new Point(textMaxFrequency.Location.X, textMinLog10.Location.Y);
                textMaxLog10.Location  = new Point(textMaxFrequency.Location.X, textMaxLog10.Location.Y);
                labelMinLog10.Location = new Point(labelMaxFrequency.Location.X, labelMinLog10.Location.Y);
                labelMaxLog10.Location = new Point(labelMaxFrequency.Location.X, labelMaxLog10.Location.Y);
            }
        }
示例#2
0
        private void DetectionToolbarProperties_Load(object sender, EventArgs e)
        {
            IntLabeledValue.PopulateCombo(cmbTargetType, Settings.TargetType);
            IntLabeledValue.PopulateCombo(cmbCountMultiple, Settings.YScaleFactor);

            txtQValueCustom.Text = Settings.QValueCutoff.ToString(LocalizationHelper.CurrentCulture);
            switch (Settings.QValueCutoff)
            {
            case 0.01f:
                rbQValue01.Select();
                break;

            default:
                rbQValueCustom.Select();
                break;
            }

            cbShowAtLeastN.Checked  = Settings.ShowAtLeastN;
            cbShowSelection.Checked = Settings.ShowSelection;
            cbShowMeanStd.Checked   = Settings.ShowMean;
            cbShowLegend.Checked    = Settings.ShowLegend;
            GraphFontSize.PopulateCombo(cmbFontSize, Settings.FontSize);

            if (_graphSummary.DocumentUIContainer.DocumentUI.IsLoaded &&
                _graphSummary.DocumentUIContainer.DocumentUI.MeasuredResults.Chromatograms.Count > 0)
            {
                tbAtLeastN.Maximum = _graphSummary.DocumentUIContainer.DocumentUI.MeasuredResults.Chromatograms.Count;
                if (Settings.RepCount < tbAtLeastN.Maximum && Settings.RepCount > tbAtLeastN.Minimum)
                {
                    tbAtLeastN.Value = Settings.RepCount;
                }
                else
                {
                    tbAtLeastN.Value = tbAtLeastN.Maximum / 2;
                }
            }
            cmbTargetType.Focus();
        }