Skip to content

Commit

Permalink
Allow '-' in the TMT sample name.
Browse files Browse the repository at this point in the history
Also unify the pattern for the sample name and reference tag.
  • Loading branch information
fcyu committed Jan 13, 2023
1 parent dec9f54 commit b2ce3ee
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

public class QuantLabelAnnotation {

private static Pattern disallowedPattern = Pattern.compile("[^0-9a-zA-Z_]");
public static final Pattern disallowedPattern = Pattern.compile("[^0-9a-zA-Z_-]");

private String label;
private String sample;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

package com.dmtavt.fragpipe.tools.tmtintegrator;

import static com.dmtavt.fragpipe.tools.tmtintegrator.QuantLabelAnnotation.disallowedPattern;
import static com.dmtavt.fragpipe.tools.tmtintegrator.QuantLabelAnnotation.unifyAnnotationSampleName;

import com.dmtavt.fragpipe.api.Bus;
Expand Down Expand Up @@ -313,7 +314,7 @@ private JPanel createPanelOptsBasic() {
uiSpinnerTolerance = UiUtils.spinnerInt(20, 1, 9999, 1).create();
FormEntry feTolerance = fe("tolerance", "Mass tolerance (ppm)", uiSpinnerTolerance, "Reporter ions mass tolerance in PPM");

UiText uiTextRefTag = UiUtils.uiTextBuilder().cols(10).filter("[^0-9a-zA-Z_]").text("Bridge").create();
UiText uiTextRefTag = UiUtils.uiTextBuilder().cols(10).filter(disallowedPattern.toString()).text("Bridge").create();
FormEntry feRefTag = fe(TmtiConfProps.PROP_ref_tag,
"Ref sample tag", uiTextRefTag,
"<html>Unique tag to identify reference (bridge) channels");
Expand Down

0 comments on commit b2ce3ee

Please sign in to comment.