Hi Alex,
I worked on the arrows and lines. See the following Screenshot:
.
The arrows are attached with a ROShorterDistanceAttachPoint but the lines
leave a certain gap to the attach point. Also I removed the bottom line of
the arrows.
For this particular visualization I also used some 'visual weighting' to
draw the arrows (using opacity and width).
I did not yet implement my new line class exactly as as you suggested yet,
does not yet use lineSegmentsFor:, I only using drawOnFor: at the moment)
will refactor that soon though.
While looking at the lines and arrow classes I saw some
code duplication in ROAbstractArrow.
I refactored the methods
- drawOn: aCanvas for: anEdge fromPoint: fromPoint toPoint: toPoint line:
line
and
- drawOn: aCanvas for: anEdge line: line
Here is the corresponding .st file:
. If you
agree with the change, you could add it to Roassal.
Will keep you updated about my progress with the arrows and lines.
Cheers,
Dennis
On Wed, Sep 12, 2012 at 1:49 PM, Alexandre Bergel
<alexandre.bergel(a)me.com>wrote;wrote:
Hi Dennis,
This should be easy to achieve. Create a subclass of ROLine, override
lineSegmentsFor: and drawOnFor:
In the implementation of the lines, drawOnFor: does not use
lineSegmentsFor:, however it should. My advice is therefore try to keep
drawOnFor: as simple as possible, by calling lineSegmentsFor:
lineSegmentsFor: is intended to return a collection of points to draw
lines. Give a try, it should not be that hard. We could do a remote pair
programming if you want (my MSN id is godfroy_bern(a)hotmail.com).
Cheers,
Alexandre
On Sep 12, 2012, at 8:07 AM, Dennis Schenk <d.schenk(a)students.unibe.ch>
wrote:
Hi all,
I'd like to customize lines with arrows a little bit more than seems to
be
possible out of the box at the moment and am looking for some pointers.
I have attached a screenshot to explain what I'd like to achieve.
I'd like to be able to:
• Define a certain distance from the arrows beginning and end to
the objects
they are attached to - so they are not directly 'glued' to the
objects.
• Make lines wider, without just affecting
the width of the line
(and in the same extend the line the arrow is made up), but
instead it
should scale to nice looking arrows.
• To place lines besides each other from
and to the same object.
Are some of these points already possible but I missed them?
How would I best go on about modifying, extending Roassal to allow for
edge
styling in this way?
Cheers,
Dennis
<roassal-arrows.png>_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel
http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev