Book a Demo

Author Topic: "DASHDOT" == "DASH"  in ShapeScripts  (Read 14230 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
"DASHDOT" == "DASH"  in ShapeScripts
« on: July 24, 2008, 02:21:31 pm »
Are my ancient (but still 20/20) eyes deceiving me or does a:

setlinestyle("DASHDOT");

in a ShapeScript draw exactly the same as a

setlinestyle("DASH");  ?

setlinestyle("DASHDOTDOT");

(and the others) seems to work fine!

If it's a common problem I'll file a report...

Paolo
7.1 (831)



Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

mrf

  • EA User
  • **
  • Posts: 311
  • Karma: +0/-0
    • View Profile
Re: "DASHDOT" == "DASH"
« Reply #1 on: July 24, 2008, 02:55:48 pm »
Paolo,

Just had a brief look over the code and there is an annotation that the "DASHDOT" style is interpreted as a long dash. If you try changing it back and forwards from DASH and DASHDOT in the shape script editor window you can see the length of the dash get bigger and smaller.

I'll talk to Roy about clarifying the style definition in the help file.
« Last Edit: July 24, 2008, 02:58:05 pm by mfraser »
Best Regards,

Michael

[email protected]
"It is more complicated than you think." - RFC 1925, Section 2.8

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" == "DASH"
« Reply #2 on: July 24, 2008, 05:41:07 pm »
Quote
Paolo,

Just had a brief look over the code and there is an annotation that the "DASHDOT" style is interpreted as a long dash. If you try changing it back and forwards from DASH and DASHDOT in the shape script editor window you can see the length of the dash get bigger and smaller.

I'll talk to Roy about clarifying the style definition in the help file.
Thanks for that Mike,

Any chance we could get both?

(FWIW: on the diagram that prompted the post, there's only one style of dashed line, so you can't see the distinction - which you CAN see by doing as Mike suggests)

Paolo
(I'll even submit a feature request... :) )
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #3 on: July 24, 2008, 10:14:21 pm »
Yes, please do Paolo.

The extent we can use shape scripts for distinct connectors is very important. Any help there is welcome. The 'real' dash-dot pattern is common in other drawing paradigms (even outside of UML) so should be supported. Having different lengths of dashes available would also be nice.

Of course if both were kept it would be nice if the names (or at least the dash-dot name) corresponded with the correct line styles.

David
No, you can't have it!

Thomas Mercer-Hursh

  • EA User
  • **
  • Posts: 386
  • Karma: +0/-0
  • Computing Integrity
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #4 on: July 25, 2008, 02:20:08 am »
All of the line styles (except solid! :) ) are dicey.  It they are drawn at just the right angle with just the right line weight, then you can tell what they are, but use the wrong line weight or put them at the wrong angle and they could be anything at all, except solid.

Try playing a little with weights 1 and 2 and 3 one a connector and moving the end points around and you will see what I mean.

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #5 on: July 25, 2008, 01:56:40 pm »
Feature request submitted -(with link back to here for ongoing discussion).

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #6 on: July 25, 2008, 03:44:51 pm »
Quote
The extent we can use shape scripts for distinct connectors is very important. Any help there is welcome. The 'real' dash-dot pattern is common in other drawing paradigms (even outside of UML) so should be supported. Having different lengths of dashes available would also be nice.
IF Sparx are going to add the LONGDASH as a separate literals, perhaps we could suggest a set of literals that should implement at the same time.

Plus, from my viewpoint, I'd like to see a consistent UI for line specification.  I think there are three different technologies (from memory) for line/borders.

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #7 on: July 25, 2008, 09:41:27 pm »
But of course we've got to respect all that legacy [=inconsistent] code out there. Sigh...
No, you can't have it!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #8 on: July 27, 2008, 03:57:04 pm »
Quote
But of course we've got to respect all that legacy [=inconsistent] code out there. Sigh...
To be handled by a repository specific behaviour switch...

If Sparx jump on it quick, there won't be that much legacy code as Shape scripts are still relatively new and many people (perhaps like me) avoided DASHDOT because it wasn't...

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #9 on: July 28, 2008, 07:19:25 am »
What he said!
No, you can't have it!

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" /= "DASH"  in Sh
« Reply #10 on: February 20, 2009, 11:26:05 am »
Quote
If Sparx jump on it quick, there won't be that much legacy code as Shape scripts are still relatively new and many people (perhaps like me) avoided DASHDOT because it wasn't...
It would seem that the new 7.5 rendering engine makes DASHDOT generate a DASH and DOT!  Hooray!

BUT, how do I get a LONG DASH?  The Help still insists that DASHDOT will generate a LONG DASH.  Can a Sparxian supply the set of literals the new engine supports, please?

TIA,
Paolo
« Last Edit: February 20, 2009, 11:26:46 am by PaoloFCantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

mrf

  • EA User
  • **
  • Posts: 311
  • Karma: +0/-0
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #11 on: February 20, 2009, 12:46:10 pm »
LONGDASH is not an official shapescript line style. If you'd like to see it added then please feel free to submit a feature request (your post did lead us to discover that DASHDOTs are still being drawn as LONGDASHs under the basic renderer - we're looking into that now).

I'll get Roy to remove the advice about DASHDOT being interpreted as LONGDASH in the help (it was only aliased temporarily while we had no DASHDOT). Additionally the shapescript editor now includes intellisense, so if you mouseover the SetLineStyle function you should get a calltip advising of the official linestyles accepted.
Best Regards,

Michael

[email protected]
"It is more complicated than you think." - RFC 1925, Section 2.8

RoyC

  • EA Administrator
  • EA Practitioner
  • *****
  • Posts: 1297
  • Karma: +21/-4
  • Read The Help!
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #12 on: February 20, 2009, 02:46:10 pm »
Done. References to Longdash have been removed.
Best Regards, Roy

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8626
  • Karma: +259/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: "DASHDOT" == "DASH"  in ShapeScripts
« Reply #13 on: February 20, 2009, 04:17:18 pm »
Quote
LONGDASH is not an official shapescript line style. If you'd like to see it added then please feel free to submit a feature request (your post did lead us to discover that DASHDOTs are still being drawn as LONGDASHs under the basic renderer - we're looking into that now).

I'll get Roy to remove the advice about DASHDOT being interpreted as LONGDASH in the help (it was only aliased temporarily while we had no DASHDOT). Additionally the shapescript editor now includes intellisense, so if you mouseover the SetLineStyle function you should get a calltip advising of the official linestyles accepted.
Thanks, Michael, feature request submitted...

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!