hiding multiplicity for cconnectors using CSS [message #1784410] |
Tue, 27 March 2018 13:52  |
Eclipse User |
|
|
|
I'm working on a SysML Model using Papyrus .
On an IBD, there are multiple flowports connecting the outside of the block to various parts where the transformations and routing occur.
By design, all ports, and therefore all connectors, have a multiplicity of 1.
I can easily use CSS to remove the multiplicity on ports:
Port {
maskLabel: name;
However, I can't seem to find the right css to get rid of all the connector ends; multiplicity...
I tried:
Connector {
sourceDecoration: none;
targetDecoration: none;
} /* did not really expect this to work...
Port {
maskLabel: name;
}
ConnectorEnd {
maskLabel: none;
}
Would anyone have a suggestion to resolve this?
TIA
|
|
|
Re: hiding multiplicity for cconnectors using CSS [message #1784449 is a reply to message #1784410] |
Wed, 28 March 2018 03:04   |
Eclipse User |
|
|
|
Hi Charles,
The Mask Label is used to define the text of configurable labels (Such as Port or Property, where a single label displays the Name/Type/Multiplicity/etc)
For Connectors, you're actually manipulating 3 different label elements: one for the name, and two for the multiplicities (This is actually similar to Associations). So what you want to do is actually hide these extra two labels, and only keep the Name one. So maskLabel is not the correct. source/target decoration won't help either, as they are used to remove the arrow-ends of connectors (But CompositeDiagram Connectors already don't have such decorations, so there is nothing to remove)
So what you need to do is to actually 1) Identify the Multiplicity Labels of the Connector, and 2) Set their visible property to false:
Connector > Label[kind=SourceMultiplicity],
Connector > Label[kind=TargetMultiplicity] {
visible: false;
}
In general, you can find the "kind" of Labels by selecting a Connector (Or any other edge, e.g. Association) in a Diagram, then select Filter > Show/Hide Labels. The "kind" of the label is the value in the "Label Role" column
HTH,
Camille
|
|
|
|
Re: hiding multiplicity for cconnectors using CSS [message #1784535 is a reply to message #1784506] |
Thu, 29 March 2018 03:22   |
Eclipse User |
|
|
|
Hi Charles,
I've tested that in the CompositeDiagram only; it's quite possible that the IBD doesn't fully support CSS (Although, since SysML1.4, they should now be pure Papyrus/UML Diagrams, and should thus have the same set of supported features)
Also note that user actions take precedence over CSS Customization, so if, for an existing diagram, you have already used the manual Show/Hide Label feature, then CSS will no longer be taken into account. I'll have a deeper look to CSS in SysML Diagrams later today
Cheers,
Camille
|
|
|
|
|
|
|
Re: hiding multiplicity for cconnectors using CSS [message #1802798 is a reply to message #1784410] |
Sat, 16 February 2019 05:19  |
Eclipse User |
|
|
|
To hide the scrollbar use -webkit- because it is supported by major browsers (Google Chrome, Safari or newer versions of Opera). There are many other options for the other browsers liteblue which are listed below:
-webkit- (Chrome, Safari, newer versions of Opera):
.element::-webkit-scrollbar { width: 0 !important }
-moz- (Firefox):
.element { overflow: -moz-scrollbars-none; }
-ms- (Internet Explorer +10):
.element { -ms-overflow-style: none; }
[Updated on: Tue, 19 February 2019 23:40] by Moderator
|
|
|
Powered by
FUDForum. Page generated in 0.04957 seconds