mirror of
https://github.com/dgis/xsddiagram.git
synced 2024-08-17 06:20:23 +03:00
show occurence always
This commit is contained in:
parent
54bc647d52
commit
79556d733c
@ -522,7 +522,7 @@ namespace XSDDiagram.Rendering
|
||||
}
|
||||
|
||||
// Draw occurences small text
|
||||
if (drawingItem.MaxOccurrence > 1 || drawingItem.MaxOccurrence == -1)
|
||||
// if (drawingItem.MaxOccurrence > 1 || drawingItem.MaxOccurrence == -1)
|
||||
{
|
||||
StringFormat stringFormatOccurences = new StringFormat();
|
||||
stringFormatOccurences.Alignment = StringAlignment.Far;
|
||||
@ -531,8 +531,8 @@ namespace XSDDiagram.Rendering
|
||||
//string occurences = string.Format("{0}..", drawingItem.MinOccurrence) + (drawingItem.MaxOccurrence == -1 ? "\u0066∞" : string.Format("{0}", drawingItem.MaxOccurrence));
|
||||
string occurences = string.Format("{0}..", drawingItem.MinOccurrence) + (drawingItem.MaxOccurrence == -1 ? "\u221E" : string.Format("{0}", drawingItem.MaxOccurrence));
|
||||
PointF pointOccurences = new PointF();
|
||||
pointOccurences.X = drawingItem.Diagram.Scale * (drawingItem.Location.X + drawingItem.Size.Width - 10);
|
||||
pointOccurences.Y = drawingItem.Diagram.Scale * (drawingItem.Location.Y + drawingItem.Size.Height + 10);
|
||||
pointOccurences.X = drawingItem.Diagram.Scale * (drawingItem.Location.X + drawingItem.Size.Width + 20);
|
||||
pointOccurences.Y = drawingItem.Diagram.Scale * (drawingItem.Location.Y + drawingItem.Size.Height - 17 );
|
||||
_graphics.DrawString(occurences, drawingItem.SmallFontScaled, foreground, pointOccurences, stringFormatOccurences);
|
||||
}
|
||||
|
||||
|
@ -76,9 +76,9 @@ namespace XSDDiagram.Rendering
|
||||
_childExpandButtonBox = Rectangle.Empty;
|
||||
_boundingBox = Rectangle.Empty;
|
||||
_documentationMinWidth = 100;
|
||||
_size = new Size(50, 25);
|
||||
_size = new Size(100, 25);
|
||||
_margin = new Size(10, 5);
|
||||
_padding = new Size(10, 15);
|
||||
_padding = new Size(10, 2);
|
||||
_itemType = DiagramItemType.element;
|
||||
_childElements = new List<DiagramItem>();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user