Hi,
I’m trying to round the shape of a group with some panels inside. That group is shadowed but in the outside shadow are appearing some white triangles on the edges…How can I get rid of them?
Here’s the picture:
and here’s my code:
myDiagram.nodeTemplateMap.add("Drivers",
$(go.Node, "Auto",
{
isTreeExpanded: true,
minLocation: new go.Point(NaN, NaN), // not allow movement
maxLocation: new go.Point(NaN, NaN),
deletable: false
},
new go.Binding("location", "loc", go.Point.parse).makeTwoWay(go.Point.stringify),
{
contextMenu: myContextMenu
},
$(go.Shape,"RoundedRectangle",
{ fill: "#EEEEEE" }),
// the content consists of a header and a list of items
$(go.Panel, "Vertical",
// this is the header for the whole node
$(go.Panel, "Auto",
{
stretch: go.GraphObject.Horizontal,
portId: "totale",
fromSpot: go.Spot.Right,
toSpot: go.Spot.Left,
fromLinkable: true,
toLinkable: true,
cursor:"pointer",
mouseEnter: function(e, obj) { // the PORT argument will be this Panel
var shp = obj.panel.findObject("hover-screenshot-panel");
shp.fill = "#FF0000";
},
mouseLeave: function(e, obj) {
var shp = obj.panel.findObject("hover-screenshot-panel");
shp.fill = "#AF5555";
}
}, // as wide as the whole node
$(go.Shape, "Rectangle",
{
fill: "#AF5555",
stroke: null,
minSize: new go.Size(150, 10),
name: "hover-screenshot-panel",
background: "transparent"
}
),
$(go.Picture,
{ source: imgpth+"enter_class.png",
column: 0,
background: "transparent",
width: 20,
height: 20,
alignment: go.Spot.TopLeft
}),
$(go.TextBlock,
{
alignment: go.Spot.Center,
column: 1,
margin: new go.Margin(3, 5, 3, 10),
stroke: "white",
textAlign: "center",
font: "bold 10pt sans-serif"
},
new go.Binding("text", "cname")
),
$("PanelExpanderButton", "TABLE",
{
column: 2,
alignment: go.Spot.TopRight
})
),
$(go.Panel, "Table",
{
name: "TABLE",
padding: 2,
minSize: new go.Size(140, 10),
defaultStretch: go.GraphObject.Horizontal,
itemTemplate: fieldTemplate,
visible: false,
cursor:"pointer"
},
new go.Binding("itemArray", "fields")
) // end Table Panel of items
) // end Vertical Panel
)); // end Node
//
myDiagram.groupTemplateMap.add("GDrivers",
$(go.Group, "Auto",
{
background: "white",
handlesDragDropForMembers: true,
// Groups containing Groups lay out their members horizontally
layout:
$(go.GridLayout,
{
wrappingColumn: 1,
wrappingWidth: Infinity,
alignment: go.GridLayout.Position,
cellSize: new go.Size(1, 1), spacing: new go.Size(4, 4)
}),
isShadowed: true,
shadowColor: "grey",
shadowOffset: new go.Point(4,4)
},
{ contextMenu: myContextMenu },
new go.Binding("location", "loc", go.Point.parse).makeTwoWay(go.Point.stringify),
$(go.Shape, "RoundedRectangle",
{
fill: "white",
stroke: "#000000",
strokeWidth: 2
}),
$(go.Panel, "Vertical", // title above Placeholder
$(go.Panel, "Horizontal", // button next to TextBlock
{ stretch: go.GraphObject.Horizontal, background: "#AF0000" },
$("SubGraphExpanderButton",
{ alignment: go.Spot.Right, margin: 5 }),
$(go.TextBlock,
{
alignment: go.Spot.Center,
margin: 3,
stroke: "white",
textAlign: "center",
font: "bold 10pt sans-serif"
},
new go.Binding("text", "key").makeTwoWay())
), // end Horizontal Panel
$(go.Placeholder,
{ padding: 5, alignment: go.Spot.TopLeft })
) // end Vertical Panel
)); // end Group and call to add to template Map
Pls Help
Thx