Thuộc tính style textDecorationStyle
Ví dụ
Hiển thị một đường lượn sóng bên dưới phần tử an:
document.getElementById("demo").style.textDecorationStyle = "wavy";
Hãy tự mình thử »Sự miêu tả
Thuộc tính textDecorationStyle đặt hoặc trả về cách dòng, nếu có, sẽ hiển thị.
Hỗ trợ trình duyệt
Property | |||||
---|---|---|---|---|---|
textDecorationStyle | 57.0 | 79.0 | 36.0 | 12.1 | 44.0 |
Cú pháp
Trả về thuộc tính textDecorationStyle:
object .style.textDecorationStyle
Đặt thuộc tính textDecorationStyle:
object .style.textDecorationStyle = "solid|double|dotted|dashed|wavy|initial|inherit"
Giá trị tài sản
Value | Description |
---|---|
solid | Default value. The line will display as a single line |
double | The line will display as a double line |
dotted | The line will display as a dotted line |
dashed | The line will display as a dashed line |
wavy | The line will display as a wavy line |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Chi tiết kỹ thuật
Giá trị mặc định: | chất rắn |
---|---|
Giá trị trả về: | Một Chuỗi, biểu thị thuộc tính kiểu trang trí văn bản của một phần tử |
Phiên bản CSS | CSS3 |
Trang liên quan
Tham chiếu CSS: thuộc tính kiểu trang trí văn bản