aboutsummaryrefslogtreecommitdiff
path: root/files/pt-br/web/svg/element/glyph/index.html
blob: 7d53098e414c24e2dabb9b6873c6f7f6ef3c47e8 (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
---
title: glyph
slug: Web/SVG/Element/glyph
tags:
  - Conteúdo de Texto SVG
  - Elemento
  - Referencia
  - SVG
translation_of: Web/SVG/Element/glyph
---
<div>{{SVGRef}}</div>

<p><code>glyph</code> determina um único glifo em uma fonte SVG.</p>

<h2 id="Contexto_de_uso">Contexto de uso</h2>

<p>{{svginfo}}</p>

<h2 id="Exemplo">Exemplo</h2>

<pre class="brush: xml">&lt;?xml version="1.0" standalone="yes"?&gt;
&lt;svg width="400px" height="300px" version="1.1"
  xmlns = 'http://www.w3.org/2000/svg'&gt;
&lt;!-- Exemplo copiado de http://www.w3.org/TR/SVG/fonts.html#GlyphElement --&gt;
  &lt;defs&gt;

    &lt;font id="Font1" horiz-adv-x="1000"&gt;
      &lt;font-face font-family="Super Sans" font-weight="bold" font-style="normal"
          units-per-em="1000" cap-height="600" x-height="400"
          ascent="700" descent="300"
          alphabetic="0" mathematical="350" ideographic="400" hanging="500"&gt;
        &lt;font-face-src&gt;
          &lt;font-face-name name="Super Sans Bold"/&gt;
        &lt;/font-face-src&gt;
      &lt;/font-face&gt;

      &lt;missing-glyph&gt;&lt;path d="M0,0h200v200h-200z"/&gt;&lt;/missing-glyph&gt;
      &lt;glyph unicode="!" horiz-adv-x="80" d="M0,0h200v200h-200z"&gt;&lt;/glyph&gt;
      &lt;glyph unicode="@" d="M0,50l100,300l400,100z"&gt;&lt;/glyph&gt;

    &lt;/font&gt;
  &lt;/defs&gt;
  &lt;text x="100" y="100"
           style="font-family: 'Super Sans', Helvetica, sans-serif;
                  font-weight: bold; font-style: normal"&gt;Texto utilizando fonte embed@da!&lt;/text&gt;
&lt;/svg&gt;


</pre>

<h2 id="Atributos">Atributos</h2>

<h3 id="Atributos_globais">Atributos globais</h3>

<ul>
 <li><a href="/pt-BR/SVG/Attribute#Core" title="en/SVG/Attribute#Core">Atributos principais</a> »</li>
 <li><a href="/pt-BR/SVG/Attribute#Presentation" title="en/SVG/Attribute#Presentation">Atributos de apresentação</a> »</li>
 <li>{{ SVGAttr("class") }}</li>
 <li>{{ SVGAttr("style") }}</li>
</ul>

<h3 id="Atributos_específicos">Atributos específicos</h3>

<ul>
 <li>{{ SVGAttr("d") }}</li>
 <li>{{ SVGAttr("horiz-adv-x") }}</li>
 <li>{{ SVGAttr("vert-origin-x") }}</li>
 <li>{{ SVGAttr("vert-origin-y") }}</li>
 <li>{{ SVGAttr("vert-adv-y") }}</li>
 <li>{{ SVGAttr("unicode") }}</li>
 <li>{{ SVGAttr("glyph-name") }}</li>
 <li>{{ SVGAttr("orientation") }}</li>
 <li>{{ SVGAttr("arabic-form") }}</li>
 <li>{{ SVGAttr("lang") }}</li>
</ul>

<h2 id="Interface_DOM">Interface DOM</h2>

<p>Este elemento implementa a interface do <code><a href="/pt-BR/DOM/SVGGlyphElement" title="en/DOM/SVGGlyphElement">SVGGlyphElement</a></code>.</p>

<h2 id="Relacionado">Relacionado</h2>

<ul>
 <li>{{ SVGElement("font") }}</li>
 <li>{{ SVGElement("missing-glyph") }}</li>
 <li><a href="/pt-BR/SVG/Tutorial/SVG_fonts" title="en/SVG/Tutorial/SVG_Fonts">Tutorial SVG: SVG fonts</a></li>
</ul>