本文整理汇总了C#中PurplePen.EventDB.AddSpecial方法的典型用法代码示例。如果您正苦于以下问题:C# EventDB.AddSpecial方法的具体用法?C# EventDB.AddSpecial怎么用?C# EventDB.AddSpecial使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PurplePen.EventDB
的用法示例。
在下文中一共展示了EventDB.AddSpecial方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddRectangleSpecial
public static Id<Special> AddRectangleSpecial(EventDB eventDB, RectangleF rect, SpecialColor color, LineKind lineKind, float lineWidth, float gapSize, float dashSize, float cornerRadius)
{
Special special = new Special(SpecialKind.Rectangle, new PointF[] { rect.Location, new PointF(rect.Right, rect.Bottom)});
special.color = color;
special.lineKind = lineKind;
special.lineWidth = lineWidth;
special.gapSize = gapSize;
special.dashSize = dashSize;
special.cornerRadius = cornerRadius;
return eventDB.AddSpecial(special);
}
示例2: AddTextSpecial
// Add a text special to the event
public static Id<Special> AddTextSpecial(EventDB eventDB, RectangleF boundingRectangle, string text, string fontName, bool bold, bool italic, SpecialColor color)
{
Special special = new Special(SpecialKind.Text, new PointF[2] { new PointF(boundingRectangle.Left, boundingRectangle.Bottom), new PointF(boundingRectangle.Right, boundingRectangle.Top) });
special.text = text;
special.fontName = fontName;
special.fontBold = bold;
special.fontItalic = italic;
special.color = color;
return eventDB.AddSpecial(special);
}
示例3: AddPointSpecial
// Add a point special to the event. The special is visible in all courses.
public static Id<Special> AddPointSpecial(EventDB eventDB, SpecialKind specialKind, PointF location, float orientation)
{
Special special = new Special(specialKind, new PointF[1] { location });
special.orientation = orientation;
return eventDB.AddSpecial(special);
}
示例4: AddLineSpecial
public static Id<Special> AddLineSpecial(EventDB eventDB, PointF[] locations, SpecialColor color, LineKind lineKind, float lineWidth, float gapSize, float dashSize)
{
Special special = new Special(SpecialKind.Line, locations);
special.color = color;
special.lineKind = lineKind;
special.lineWidth = lineWidth;
special.gapSize = gapSize;
special.dashSize = dashSize;
return eventDB.AddSpecial(special);
}
示例5: AddLineAreaSpecial
// Add a line or area special to the event. The special is visible in all courses.
public static Id<Special> AddLineAreaSpecial(EventDB eventDB, SpecialKind specialKind, PointF[] locations)
{
Special special = new Special(specialKind, locations);
return eventDB.AddSpecial(special);
}
示例6: AddImageSpecial
// Add a text special to the event
public static Id<Special> AddImageSpecial(EventDB eventDB, RectangleF boundingRectangle, Bitmap imageBitmap, string imageName)
{
Debug.Assert(imageBitmap != null);
Debug.Assert(imageName != null);
Special special = new Special(SpecialKind.Image, new PointF[2] { new PointF(boundingRectangle.Left, boundingRectangle.Bottom), new PointF(boundingRectangle.Right, boundingRectangle.Top) });
special.text = imageName;
special.imageBitmap = imageBitmap;
return eventDB.AddSpecial(special);
}
示例7: AddDescription
// Add a description to the event.
public static Id<Special> AddDescription(EventDB eventDB, bool allCourses, CourseDesignator[] courses, PointF topLeft, float cellSize, int numColumns)
{
Special special = new Special(SpecialKind.Descriptions, new PointF[2] { topLeft, new PointF(topLeft.X + cellSize, topLeft.Y) });
special.allCourses = allCourses;
if (! allCourses)
special.courses = courses;
special.numColumns = numColumns;
Id<Special> specialId = eventDB.AddSpecial(special);
// Descriptions special are unique per course -- enforce this.
UpdateDescriptionCourses(eventDB, specialId);
return specialId;
}