AppointmentElement
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.Scheduler.dll
Syntax:
public class AppointmentElement : SchedulerVisualElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider, ISchedulerRecyclableElement
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementSchedulerVisualElementAppointmentElement...
Implements:
Inherited Members
Constructors
Initializes a new instance of the AppointmentElement class.
public AppointmentElement(RadScheduler scheduler, SchedulerView view, IEvent appointment)
The scheduler.
viewSchedulerViewThe view.
appointmentIEventThe appointment.
Fields
The final arrange bounds of the element. This rectangle is calculated durring the layout of the parrent container and is used to perform the final arrange.
public RectangleF DesiredBounds
public static RadProperty ResizeIndicatorColorProperty
public static RadProperty ResizeIndicatorSizeProperty
public static RadProperty SelectedBorderColorProperty
public static RadProperty SelectedProperty
Properties
Gets or sets the appointment.
public IEvent Appointment { get; set; }
The appointment.
Gets or sets the appointment description.
public string AppointmentDescription { get; set; }
The appointment description.
Gets or sets the appointment icon.
public Image AppointmentIcon { get; set; }
The appointment icon.
Gets or sets the appointment location.
public string AppointmentLocation { get; set; }
The appointment location.
Gets or sets the appointment subject.
public string AppointmentSubject { get; set; }
The appointment subject.
Gets or sets a value indicating whether this AppointmentElement is recurring.
public bool Recurring { get; }
true if recurring; otherwise, false.
Gets or sets the related appointments.
public List<AppointmentElement> RelatedAppointments { get; set; }
The related appointments.
Gets or sets the back color of the resize handles of this element.
public Color ResizeIndicatorColor { get; set; }
Gets or sets the size of the resize handles of this element.
public Size ResizeIndicatorSize { get; set; }
Gets or sets a value indicating whether this AppointmentElement is selected.
public virtual bool Selected { get; set; }
true if selected; otherwise, false.
Gets or sets the border color of this element for the selected state.
public Color SelectedBorderColor { get; set; }
Gets or sets a value indicating whether a appointment description should be drawn
public bool ShowAppointmentDescription { get; set; }
true if ShowAppointmentDescription; otherwise, false.
Gets or sets the start date.
public DateTime Start { get; set; }
The start.
Gets or sets the width of the status area displayed on the left side of the appointment element. This colored vertical bar represents the appointment's status (busy, free, tentative, etc.). The default value is 6 pixels.
public int StatusAreaWidth { get; set; }
Gets or sets the text associated with this item.
public override string Text { get; set; }
Overrides:
Gets or sets the title format.
public string TitleFormat { get; set; }
The title format.
Gets or sets a value indicating whether use the built-in LightVisualElement painting.
public bool UseDefaultPaint { get; set; }
Methods
Arranges the content and child elements within the final allocated space, positioning text, images, and child elements.
Disposes of managed resources including cached images and SVG images when the element is being disposed.
protected override void DisposeManagedResources()
Overrides:
protected override RectangleF GetClientRectangle(SizeF finalSize)
Overrides:
protected virtual void InitializeAppointment()
Initializes the internal fields and components of the LightVisualElement. This method sets up text primitives, image primitives, and layout management components.
protected override void InitializeFields()
Overrides:
Measures the desired size of the element by calculating the space needed for content, padding, and borders.
Raises the DoubleClick event.
Called when a mouse button is pressed down over the item.
protected override void OnMouseDown(MouseEventArgs e)
The mouse event arguments.
Overrides:
Called when the mouse moves over the item, handling highlight and border highlight effects.
protected override void OnMouseMove(MouseEventArgs e)
The mouse event arguments.
Overrides:
Called when a mouse button is released over the item.
protected override void OnMouseUp(MouseEventArgs e)
The mouse event arguments.
Overrides:
Raises the standard .NET PropertyChanged event to notify subscribers of property value changes using the provided event arguments.
protected override void OnNotifyPropertyChanged(PropertyChangedEventArgs e)
The PropertyChangedEventArgs containing the property change information.
Overrides:
Handles property change events by invalidating the fill cache and invoking the base class property change handler.
protected override void OnPropertyChanged(RadPropertyChangedEventArgs e)
Event arguments containing information about the property that changed.
Overrides:
Renders the border of the element using the specified graphics context, rotation angle, and scaling factor.
protected override void PaintBorder(IGraphics graphics, float angle, SizeF scale)
The graphics context used for painting operations.
anglefloatThe rotation angle in degrees to apply during painting.
scaleSizeFThe scaling factors to apply for width and height during painting.
Overrides:
Performs the main painting operation for the element, rendering fill, content, and border in the correct order.
Renders the background fill of the element using the specified graphics context, rotation angle, and scaling factor.
protected override void PaintFill(IGraphics graphics, float angle, SizeF scale)
The graphics context used for painting operations.
anglefloatThe rotation angle in degrees to apply during painting.
scaleSizeFThe scaling factors to apply for width and height during painting.
Overrides:
Renders the text content of the element, including horizontal line effects when enabled.
protected override void PaintText(IGraphics graphics)
The graphics context used for rendering text.
Overrides:
Determines whether the element may be treated as a drop target during drag-and-drop operation.
protected override bool ProcessDragOver(Point mousePosition, ISupportDrag dragObject)
The current mouse position.
dragObjectISupportDragThe object being dragged.
Returns:True if the element can accept the drop; otherwise, false.
Overrides:
Sets the background id.
public virtual void SetBackgroundId(int backgroundId)
The background id. The value should be existing in the Scheduler.Backgrounds.
Synchronizes element properties with Appointment properties.
public virtual void Synchronize()
Synchronizes the start and end with event.
public virtual void SyncronizeStartAndEndWithEvent()