blob: c49d44c8b58714069237b26a5458f44367cfb5e6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
|
---
title: text-decoration-style
slug: Web/CSS/text-decoration-style
tags:
- Propiedad CSS
- Texto CSS
translation_of: Web/CSS/text-decoration-style
---
<div>{{CSSRef}}</div>
<h2 id="Resumen">Resumen</h2>
<p>La propiedad CSS <strong><code>text-decoration-style</code></strong> define el estilo de las líneas especificadas por {{ cssxref("text-decoration-line") }}. El estilo aplica a todas las líneas, no hay manera de establecer diferentes estilos para cada línea definida por <code>text-decoration-line</code>.</p>
<p>Si la decoración especificada tiene un significado semántico propio, como <em>line-through</em>, que significa que el texto ha sido removido, se recomienda a los autores denotar este significado usando una etiqueta HTML, como {{ HTMLElement("del") }} o {{ HTMLElement("s") }}. Siendo que los navegadores pueden deshabilitar estilos en algunos casos, el significado semántico no desaparecerá en dicha situación.</p>
<p>{{cssinfo}}</p>
<h2 id="Sintaxis">Sintaxis</h2>
<pre class="brush: css">/* Valores clave */
text-decoration-style: solid;
text-decoration-style: double;
text-decoration-style: dotted;
text-decoration-style: dashed;
text-decoration-style: wavy;
/* Valores globales */
text-decoration-style: inherit;
text-decoration-style: initial;
text-decoration-style: unset;
</pre>
<h3 id="Valores">Valores</h3>
<dl>
<dt><code>solid double dotted dashed wavy</code></dt>
<dd>Es una de las siguientes palabras clave:
<table class="standard-table">
<thead>
<tr>
<th scope="col">Palabra clave</th>
<th scope="col">Descripción</th>
<th scope="col">Comentario</th>
</tr>
</thead>
<tbody>
<tr>
<td><code>solid</code></td>
<td>Dibuja una línea simple</td>
<td> </td>
</tr>
<tr>
<td><code>double</code></td>
<td>Dibuja una línea doble</td>
<td> </td>
</tr>
<tr>
<td><code>dotted</code></td>
<td>Dibuja una línea punteada</td>
<td> </td>
</tr>
<tr>
<td><code>dashed</code></td>
<td>Dibuja una línea discontinua</td>
<td> </td>
</tr>
<tr>
<td><code>wavy</code></td>
<td>Dibuja una línea ondulada</td>
<td> </td>
</tr>
<tr>
<td><code>-moz-none</code>{{ non-standard_inline }}<code> </code></td>
<td>No dibuja una línea</td>
<td><strong>No usarse:</strong> usar {{ cssxref("text-decoration-line") }}<code>: none</code> en su lugar</td>
</tr>
</tbody>
</table>
</dd>
<dt><code>inherit</code></dt>
<dd>Es una palabra clave que indica que se reutilice el valor calculado del elemento padre.</dd>
</dl>
<h3 id="Sintaxis_formal">Sintaxis formal</h3>
{{csssyntax}}
<h2 id="Ejemplos">Ejemplos</h2>
<pre class="brush: css" class="hidden">.example {
-moz-text-decoration-line: underline;
-moz-text-decoration-style: wavy;
-moz-text-decoration-color: red;
-webkit-text-decoration-line: underline;
-webkit-text-decoration-style: wavy;
-webkit-text-decoration-color: red;
}</pre>
<pre class="brush: css">.example {
text-decoration-line: underline;
text-decoration-style: wavy;
text-decoration-color: red;
}
</pre>
<pre class="brush: html"><p class="example">Así se ve el resultado.</p>
</pre>
<p>{{ EmbedLiveSample('Ejemplos', '', '', '') }}</p>
<h2 id="Especificaciones">Especificaciones</h2>
<table class="standard-table">
<thead>
<tr>
<th scope="col">Especificación</th>
<th scope="col">Estado</th>
<th scope="col">Comentarios</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{ SpecName('CSS3 Text Decoration', '#text-decoration-style', 'text-decoration-style') }}</td>
<td>{{ Spec2('CSS3 Text Decoration') }}</td>
<td>Definición inicial. La propiedad {{cssxref("text-decoration")}} no era una forma reducida anteriormente.</td>
</tr>
</tbody>
</table>
<h2 id="Compatibilidad_de_navegadores">Compatibilidad de navegadores</h2>
{{Compat("css.properties.text-decoration-style")}}
|