VisualStyleRenderer.GetBoolean(BooleanProperty) 方法

定义

返回当前视觉样式元素的指定布尔属性的值。Returns the value of the specified Boolean property for the current visual style element.

public:
 bool GetBoolean(System::Windows::Forms::VisualStyles::BooleanProperty prop);
public bool GetBoolean (System.Windows.Forms.VisualStyles.BooleanProperty prop);
member this.GetBoolean : System.Windows.Forms.VisualStyles.BooleanProperty -> bool
Public Function GetBoolean (prop As BooleanProperty) As Boolean

参数

prop
BooleanProperty

BooleanProperty 值之一,指定要为当前视觉样式元素检索的属性值。One of the BooleanProperty values that specifies which property value to retrieve for the current visual style element.

返回

如果 prop 参数指定的属性值对于当前视觉样式元素为 true,则为 true,否则为 falsetrue if the property specified by the prop parameter is true for the current visual style element; otherwise, false.

异常

prop 不是 BooleanProperty 值之一。prop is not one of the BooleanProperty values.

注解

视觉样式使用一组布尔值来描述样式定义的元素的某些属性。Visual styles use a set of Boolean values to describe some properties of the elements defined by a style. 这些属性由 BooleanProperty 值封装。These properties are encapsulated by the BooleanProperty values.

适用于