Export (0) Print
Expand All
Expand Minimize

Bold Property

Visual Studio .NET 2003

Sets or returns whether or not the item should appear in bold.

[Visual Basic .NET]
Public Property Bold() As Boolean
[Visual Basic 6]
Property Get Bold() As Boolean
Property Let Bold( _
   ByVal NewValue As Boolean _
HRESULT __stdcall get_Bold(
   /* [out, retval] */ VARIANT_BOOL* retVal
HRESULT __stdcall put_Bold(
   /* [in] */ VARIANT_BOOL NewValue
public bool Bold {get; set;}
[JScript .NET]
public function get Bold() : Boolean
public function set Bold(
   NewValue : Boolean


Determines if the item is bold.

Return Value

Returns True if the item is bold, False if not.


The following example lists the foreground, background, and bold values for the first colorable item.

Sub BoldExample()
   Dim props As EnvDTE.Properties
   props = DTE.Properties("FontsAndColors", "TextEditor")
   Dim prop As EnvDTE.Property = props.Item("FontsAndColorsItems")
   Dim clritems As EnvDTE.FontsAndColorsItems = prop.Object
   Dim clritem As EnvDTE.ColorableItems = clritems.Item(1)
   Dim ClrList As String

   ClrList += "Background color: " & clritem.Background.ToString & vbCr
   ClrList += "Foreground color: " & clritem.Foreground.ToString & vbCr
   ClrList += "Bold?: " & clritem.Bold.ToString
End Sub

See Also

Applies To: ColorableItems Object | FontsAndColorsItems Collection

© 2014 Microsoft