windowsforms-devexpress-dot-xtrascheduler-dot-customdrawobjecteventargs-f06e7e66.md
Renders the element using the default drawing mechanism.
Namespace : DevExpress.XtraScheduler
Assembly : DevExpress.XtraScheduler.v25.2.dll
NuGet Package : DevExpress.Win.Scheduler
public void DrawDefault()
Public Sub DrawDefault
The DrawDefault method invokes the default drawing procedure to paint an element, and enables you to combine your own custom painting with a default one. Handle the necessary CustomDraw* event and set CustomDrawObjectEventArgs.Handled to true to prevent default painting from being performed after the handler code execution. Use DrawDefault method in the handler code to render the element using the default drawing mechanism.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the DrawDefault() method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-scheduler-country-specific-work-week-holidays/CS/Form1.cs#L72
header.Caption = holiday.DisplayName;
e.DrawDefault();
// Add the holiday name to the day header's caption.
winforms-scheduler-country-specific-work-week-holidays/VB/Form1.vb#L58
header.Caption = holiday.DisplayName
e.DrawDefault()
' Add the holiday name to the day header's caption.
See Also
How to: Custom Paint Appointments
How to: Custom Paint Day Headers
How to: Hide Grid Lines in the View
CustomDrawObjectEventArgs Class