margin, Background will mostly be set in child of border,
if not border will have a background outside = Margin width
<GraphicObject Width="5"/>\r
<Image Name="Image" Margin="1" Width="12" Height="12" Path="#go.Images.Icons.tetra.png"/>\r
<Label Foreground="White" Width="0" Name="Title" Margin="1" TextAlignment="Center" />\r
- <Border CornerRadius="6" BorderWidth="1" Margin="0" BorderColor="Transparent" Height="12" Width="12"\r
+ <Border CornerRadius="6" BorderWidth="1" BorderColor="Transparent" Height="12" Width="12"\r
MouseEnter="{BorderColor=White}" MouseLeave="{BorderColor=Transparent}">\r
<Image Focusable="true" Name="Image" Margin="0" Width="0" Height="0" Path="#go.Images.Icons.exit2.svg"\r
MouseClick="butQuitPress"/>\r
{
Rectangle rBack = new Rectangle (Slot.Size);
+ rBack.Inflate (-Margin);
if (BorderWidth > 0)
- rBack.Inflate (-BorderWidth / 2);
+ rBack.Inflate (-BorderWidth / 2);
gr.Color = Background;
CairoHelpers.CairoRectangle(gr,rBack,CornerRadius);
gr.Fill ();
if (BorderWidth > 0) {
-
gr.LineWidth = BorderWidth;
gr.Color = BorderColor;
- CairoHelpers.CairoRectangle(gr,rBack,CornerRadius);
+ CairoHelpers.CairoRectangle(gr, rBack, CornerRadius);
gr.Stroke ();
}
}