From 4f43dd4be9aa25f1f82a1e9dedc2e4c12abb98ce Mon Sep 17 00:00:00 2001 From: miettinen Date: Fri, 25 Oct 2013 08:28:09 +0000 Subject: [PATCH] Bugfix to whitespace replacement in Sysdyn (refs #2930). git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@28119 ac1ea38d-2e2b-0410-8846-a27921b304fc --- .../org/simantics/sysdyn/representation/utils/FormatUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org.simantics.sysdyn/src/org/simantics/sysdyn/representation/utils/FormatUtils.java b/org.simantics.sysdyn/src/org/simantics/sysdyn/representation/utils/FormatUtils.java index 19fadc7b..d05d9546 100644 --- a/org.simantics.sysdyn/src/org/simantics/sysdyn/representation/utils/FormatUtils.java +++ b/org.simantics.sysdyn/src/org/simantics/sysdyn/representation/utils/FormatUtils.java @@ -146,7 +146,7 @@ public class FormatUtils { // Replace whitespace sequences with underscore characters for (String reference : allReferences) { - String regex = reference.replaceAll(" ", "\\\\s+"); + String regex = reference.replaceAll(" ", "(_|\\\\s+)"); String replacement = reference.replaceAll(" ", "_"); modifiedEquation = modifiedEquation.replaceAll(regex, replacement); } -- 2.47.1