Redigera

Dela via


HtmlTextWriterStyle Enum

Definition

Specifies the HTML styles available to an HtmlTextWriter or Html32TextWriter object output stream.

public enum class HtmlTextWriterStyle
public enum HtmlTextWriterStyle
type HtmlTextWriterStyle = 
Public Enum HtmlTextWriterStyle
Inheritance
HtmlTextWriterStyle

Fields

Name Value Description
BackgroundColor 0

Specifies the HTML backgroundcolor style.

BackgroundImage 1

Specifies the HTML backgroundimage style.

BorderCollapse 2

Specifies the HTML bordercollapse style.

BorderColor 3

Specifies the HTML bordercolor style.

BorderStyle 4

Specifies the HTML borderstyle style.

BorderWidth 5

Specifies the HTML borderwidth style.

Color 6

Specifies the HTML color style.

FontFamily 7

Specifies the HTML fontfamily style.

FontSize 8

Specifies the HTML fontsize style.

FontStyle 9

Specifies the HTML fontstyle style.

FontWeight 10

Specifies the HTML fontheight style.

Height 11

Specifies the HTML height style.

TextDecoration 12

Specifies the HTML textdecoration style.

Width 13

Specifies the HTML width style.

ListStyleImage 14

Specifies the HTML liststyleimage style.

ListStyleType 15

Specifies the HTML liststyletype style.

Cursor 16

Specifies the HTML cursor style.

Direction 17

Specifies the HTML direction style.

Display 18

Specifies the HTML display style.

Filter 19

Specifies the HTML filter style.

FontVariant 20

Specifies the HTML fontvariant style.

Left 21

Specifies the HTML left style.

Margin 22

Specifies the HTML margin style.

MarginBottom 23

Specifies the HTML marginbottom style.

MarginLeft 24

Specifies the HTML marginleft style.

MarginRight 25

Specifies the HTML marginright style.

MarginTop 26

Specifies the HTML margintop style.

Overflow 27

Specifies the HTML overflow style.

OverflowX 28

Specifies the HTML overflowx style.

OverflowY 29

Specifies the HTML overflowy style.

Padding 30

Specifies the HTML padding style.

PaddingBottom 31

Specifies the HTML paddingbottom style.

PaddingLeft 32

Specifies the HTML paddingleft style.

PaddingRight 33

Specifies the HTML paddingright style.

PaddingTop 34

Specifies the HTML paddingtop style.

Position 35

Specifies the HTML position style.

TextAlign 36

Specifies the HTML textalign style.

VerticalAlign 37

Specifies the HTML verticalalign style.

TextOverflow 38

Specifies the HTML textoverflow style.

Top 39

Specifies the HTML top style.

Visibility 40

Specifies the HTML visibility style.

WhiteSpace 41

Specifies the HTML whitespace style.

ZIndex 42

Specifies the HTML zindex style.

Examples

The following example uses the HtmlTextWriterStyle enumeration with the AddStyleAttribute method to add a color style attribute to an HTML element and sets its value.

writer->AddStyleAttribute( HtmlTextWriterStyle::Color, "Red" );
writer.AddStyleAttribute(HtmlTextWriterStyle.Color, "Red");
writer.AddStyleAttribute(HtmlTextWriterStyle.Color, "Red")

Remarks

HtmlTextWriter and Html32TextWriter objects use these enumeration values to register HTML strings to the proper HTML style.

Applies to

See also