Quintiq file version 2.0
|
#parent: CustomDrawRC/CustomDrawDataLayerOperationOutputEdge
|
Response OnDrawObject (
|
PISPOperationOutputEdge object
|
) id:Response_CustomDrawRC_CustomDrawDataLayerOperationOutputEdge_OnDrawObject
|
{
|
#keys: '[139394.0.1302356623]'
|
CanBindMultiple: false
|
DefinitionID: 'Responsedef_WebCustomDrawDataLayer_OnDrawObject'
|
QuillAction
|
{
|
Body:
|
[*
|
// Draw PISP Operation output Edge
|
rcv := MacroPlan.RoutingConfiguratorView();
|
|
// Adjust line based on its orientations
|
topdown := object.FromY() < object.ToY();
|
leftright := object.FromX() < object.ToX();
|
padding := 6;
|
|
fromx := region.BoundingRect().Left();
|
tox := region.BoundingRect().Width();
|
|
fromy := region.BoundingRect().Top() + padding;
|
toy := region.BoundingRect().Height() - padding;
|
|
if( not topdown )
|
{
|
tmp := fromy;
|
fromy := toy;
|
toy := tmp;
|
}
|
|
if( not leftright )
|
{
|
tmp := fromx;
|
fromx := tox;
|
tox := tmp;
|
}
|
|
surface.Brush().Reset(); // strange. without this line, the arrow head will not be filled.
|
surface.Brush().Color( ColorScheme.RoutingConfigurator_RoutingArrow() ); // to paint the solid arrowhead
|
surface.Pen().Color( ColorScheme.RoutingConfigurator_RoutingArrow() );
|
|
surface.Pen().Style( PenSpecification::StyleSolid() );
|
surface.Pen().Width( rcv.EdgeThickness() );
|
|
// Draw the directional line
|
line := GraphicalLine::LineTo( fromx, fromy, tox, toy );
|
line.ArrowToEnd( true ).ArrowPos( GraphicalLine::ArrowPosMiddle() );
|
surface.Draw( line );
|
*]
|
GroupServerCalls: false
|
}
|
}
|