Skip to content
Snippets Groups Projects
Commit 6eda7ed1 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

export of z index for reactions added

parent a096aa33
No related branches found
No related tags found
1 merge request!990Gpml prototype
Pipeline #15907 passed
...@@ -269,7 +269,7 @@ public class ModelToGPML { ...@@ -269,7 +269,7 @@ public class ModelToGPML {
/** /**
* This function transform Compartments into Shapes (Oval or Rectangle) from * This function transform Compartments into Shapes (Oval or Rectangle) from
* PathVisio. * PathVisio.
* *
* @param model * @param model
* model where compartments are placed * model where compartments are placed
...@@ -338,7 +338,10 @@ public class ModelToGPML { ...@@ -338,7 +338,10 @@ public class ModelToGPML {
interaction.append(" <Interaction GraphId=\"" + getNewId() + "\">\n"); interaction.append(" <Interaction GraphId=\"" + getNewId() + "\">\n");
interaction.append(" <Attribute Key=\"org.pathvisio.core.ds\" Value=\"\"/>\n"); interaction.append(" <Attribute Key=\"org.pathvisio.core.ds\" Value=\"\"/>\n");
interaction.append(" <Attribute Key=\"org.pathvisio.core.id\" Value=\"\"/>\n"); interaction.append(" <Attribute Key=\"org.pathvisio.core.id\" Value=\"\"/>\n");
interaction.append(" <Graphics ConnectorType=\"Segmented\" ZOrder=\"32827\" LineThickness=\"1.0\">\n"); interaction.append(" <Graphics "
+ "ConnectorType=\"Segmented\" "
+ "ZOrder=\"" + rn.getReaction().getZ() + "\" "
+ "LineThickness=\"" + rn.getLine().getWidth() + "\">\n");
if (rn instanceof Reactant) { if (rn instanceof Reactant) {
for (Point2D p2d : line.getPoints()) { for (Point2D p2d : line.getPoints()) {
...@@ -514,11 +517,10 @@ public class ModelToGPML { ...@@ -514,11 +517,10 @@ public class ModelToGPML {
interactions.append(" <Interaction GraphId=\"" + reaction.getIdReaction() + "\">\n"); interactions.append(" <Interaction GraphId=\"" + reaction.getIdReaction() + "\">\n");
interactions.append(biopaxParser.toReferenceXml(reaction.getMiriamData())); interactions.append(biopaxParser.toReferenceXml(reaction.getMiriamData()));
// interactions.append(" <Attribute Key=\"org.pathvisio.core.ds\" interactions.append(" <Graphics "
// Value=\"\"/>\n"); + "ConnectorType=\"Segmented\" "
// interactions.append(" <Attribute Key=\"org.pathvisio.core.id\" + "ZOrder=\"" + reaction.getZ() + "\" "
// Value=\"\"/>\n"); + "LineThickness=\"" + reaction.getLine().getWidth() + "\">\n");
interactions.append(" <Graphics ConnectorType=\"Segmented\" ZOrder=\"32827\" LineThickness=\"1.0\">\n");
/** Start and End **/ /** Start and End **/
Reactant start = reaction.getReactants().get(0); Reactant start = reaction.getReactants().get(0);
...@@ -608,7 +610,7 @@ public class ModelToGPML { ...@@ -608,7 +610,7 @@ public class ModelToGPML {
return gpml.toString(); return gpml.toString();
} }
private String colorToString(Color color) { private String colorToString(Color color) {
return colorParser.colorToHtml(color).substring(1); return colorParser.colorToHtml(color).substring(1);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment