From 83791d57176ff0dc7f3c3a0bd270349e9f39789a Mon Sep 17 00:00:00 2001
From: tjc <tjc@ee4ac58c-ac51-4696-9907-e4b3aa274f04>
Date: Mon, 16 Mar 2009 15:41:37 +0000
Subject: [PATCH] strip out uniprot DE line categories

git-svn-id: svn+ssh://svn.internal.sanger.ac.uk/repos/svn/pathsoft/artemis/trunk@10122 ee4ac58c-ac51-4696-9907-e4b3aa274f04
---
 uk/ac/sanger/artemis/editor/DataCollectionPane.java | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/uk/ac/sanger/artemis/editor/DataCollectionPane.java b/uk/ac/sanger/artemis/editor/DataCollectionPane.java
index 4b564230a..4668eda80 100644
--- a/uk/ac/sanger/artemis/editor/DataCollectionPane.java
+++ b/uk/ac/sanger/artemis/editor/DataCollectionPane.java
@@ -825,9 +825,17 @@ public class DataCollectionPane extends JScrollPane
 
       if(product != null && !product.equals(""))
       {
-        if(product.endsWith("."))
+        if(product.endsWith(".") ||
+           product.endsWith(";"))
           product = product.substring(0,product.length()-1);
-
+    
+        int ind;
+        if((product.startsWith("RecName:") || 
+            product.startsWith("SubName:") ||
+            product.startsWith("AltName:")) &&
+            (ind = product.indexOf("="))>0)
+          product = product.substring(ind+1);
+        
         orthoText.append("\n<br>\n/product=\""+product.toLowerCase()+"\"");
       }
     }
-- 
GitLab