VisualStyleElement.ListView.SortedDetail Класс

Определение

Предоставляет VisualStyleElement для элемента управления отсортированный список в подробном представлении. Этот класс не может быть унаследован.

public: ref class VisualStyleElement::ListView::SortedDetail abstract sealed
public static class VisualStyleElement.ListView.SortedDetail
type VisualStyleElement.ListView.SortedDetail = class
Public Class VisualStyleElement.ListView.SortedDetail
Наследование
VisualStyleElement.ListView.SortedDetail

Примеры

В следующем примере кода показано, как создать VisualStyleRenderer объект с свойством , VisualStyleElement возвращаемым свойством Normal . Чтобы запустить этот пример, вставьте его в форму Windows Forms. Обработайте событие формы Paint и вызовите DrawVisualStyleElementListViewSortedDetail1 метод из Paint метода обработки событий, передавая e как PaintEventArgs.

public void DrawVisualStyleElementListViewSortedDetail1(PaintEventArgs e)
{
    if (VisualStyleRenderer.IsElementDefined(
        VisualStyleElement.ListView.SortedDetail.Normal))
    {
        VisualStyleRenderer renderer =
             new VisualStyleRenderer(VisualStyleElement.ListView.SortedDetail.Normal);
        Rectangle rectangle1 = new Rectangle(10, 50, 50, 50);
        renderer.DrawBackground(e.Graphics, rectangle1);
        e.Graphics.DrawString("VisualStyleElement.ListView.SortedDetail.Normal",
             this.Font, Brushes.Black, new Point(10, 10));
    }
    else
        e.Graphics.DrawString("This element is not defined in the current visual style.",
             this.Font, Brushes.Black, new Point(10, 10));
}
Public Sub DrawVisualStyleElementListViewSortedDetail1(ByVal e As PaintEventArgs)
    If (VisualStyleRenderer.IsElementDefined( _
     VisualStyleElement.ListView.SortedDetail.Normal)) Then
        Dim renderer As New VisualStyleRenderer _
          (VisualStyleElement.ListView.SortedDetail.Normal)
        Dim rectangle1 As New Rectangle(10, 50, 50, 50)
        renderer.DrawBackground(e.Graphics, rectangle1)
        e.Graphics.DrawString("VisualStyleElement.ListView.SortedDetail.Normal", _
          Me.Font, Brushes.Black, New Point(10, 10))
    Else
        e.Graphics.DrawString("This element is not defined in the current visual style.", _
          Me.Font, Brushes.Black, New Point(10, 10))
    End If
End Sub

Комментарии

Свойство NormalVisualStyleElement.ListView.SortedDetail класса возвращает объект , VisualStyleElement представляющий элемент управления отсортированного представления списка в подробном представлении.

Свойства

Normal

Возвращает элемент визуального стиля, представляющий отсортированный список в подробном представлении.

Применяется к

См. также раздел