Skip to content

Commit bc17b5d

Browse files
adaussyAxelRICHARD
authored andcommitted
[1007] Improve direct edit on Feature with ":=" and "default" symbols
Bug: #1007 Signed-off-by: Arthur Daussy <arthur.daussy@obeo.fr>
1 parent 8474afb commit bc17b5d

File tree

21 files changed

+2025
-1713
lines changed

21 files changed

+2025
-1713
lines changed

CHANGELOG.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414

1515
=== Improvements
1616

17-
-https://github.com/eclipse-syson/syson/issues/1061[#1061] [general-view] Add ellipsis on `Packages` label, to provide visual feedback on name overflow.
17+
- https://github.com/eclipse-syson/syson/issues/1061[#1061] [general-view] Add ellipsis on `Packages` label, to provide visual feedback on name overflow.
18+
- https://github.com/eclipse-syson/syson/issues/1007[#1007] Improve direct edit on Feature elements to be able to set the `isDefault` and `isInitial` properties
1819

1920
=== New features
2021

backend/application/syson-sysml-export/src/main/java/org/eclipse/syson/sysml/export/SysMLElementSerializer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1210,7 +1210,7 @@ private void appendValuePart(Appender builder, Usage usage) {
12101210
builder.appendWithSpaceIfNeeded(LabelConstants.DEFAULT);
12111211
}
12121212
if (feature.isIsInitial()) {
1213-
builder.appendWithSpaceIfNeeded(":=");
1213+
builder.appendWithSpaceIfNeeded(LabelConstants.COLON_EQUAL);
12141214
} else {
12151215
builder.appendWithSpaceIfNeeded(LabelConstants.EQUAL);
12161216
}

backend/metamodel/syson-sysml-metamodel/src/main/java/org/eclipse/syson/sysml/helper/LabelConstants.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ public class LabelConstants {
4141

4242
public static final String EQUAL = "=";
4343

44+
public static final String COLON_EQUAL = ":=";
45+
4446
public static final String GREATER_THAN = ">";
4547

4648
public static final String IN = "in";

backend/services/syson-direct-edit-grammar/src/main/java/org/eclipse/syson/services/grammars/DirectEdit.interp

Lines changed: 6 additions & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)