SVG ������ �� 'svg' �v�f���Ɋ܂܂��C�ӌ��� SVG �v�f�ɂ��\�������B
An SVG document fragment consists of any number of SVG elements contained within an 'svg' element.
SVG �����Ђ͋�̂��́i���� 'svg' ���ɉ����܂�ł��Ȃ����́j��A 'rect' �Ȃǂ� �O���t�B�b�N�X�v�f ��������܂ނ����P���Ȃ��̂���A �R���e�i�v�f �� �O���t�B�b�N�X�v�f ����\�z����镡�G�Ő[������q�\���������̂܂łɂȂ蓾��B
An SVG document fragment can range from an empty fragment (i.e., no content inside of the 'svg' element), to a very simple SVG document fragment containing a single SVG graphics element such as a 'rect', to a complex, deeply nested collection of container elements and graphics elements.
SVG �����Ђ͂��ꎩ�g���Ɨ������t�@�C���܂��̓��\�[�X�ƂȂ��B���̏ꍇ�� SVG ���� �ɂȂ�B���邢�́A�e�ƂȂ� XML �����ɕ����ЂƂ��ăC�����C���ɖ��ߍ��ނ��Ƃ��ł���B
An SVG document fragment can stand by itself as a self-contained file or resource, in which case the SVG document fragment is an SVG document, or it can be embedded inline as a fragment within a parent XML document.
�e�� XML �����ɕ����ЂƂ��Ė��ߍ��܂ꂽ�P���� SVG ���e�̗�����Ɏ����B XML ���O��Ԃ̗��p�ɂ�� 'svg' �v�f�� 'ellipse' �v�f�� SVG ���O��Ԃɑ����邱�Ƃ��w�����Ă��邱�Ƃɒ��ӁF
The following example shows simple SVG content embedded inline as a fragment within a parent XML document. Note the use of XML namespaces to indicate that the 'svg' and 'ellipse' elements belong to the SVG namespace:
<?xml version="1.0" standalone="yes"?> <parent xmlns="http://example.org" xmlns:svg="http://www.w3.org/2000/svg"> <!-- �e�̓��e�͂����� --> <svg:svg width="4cm" height="8cm" version="1.1"> <svg:ellipse cx="2cm" cy="4cm" rx="2cm" ry="1cm" /> </svg:svg> <!-- ... --> </parent>
�������G�ȗ�Łi�������̋�`���܂܂�Ă���j�Ɨ������O���ˑ��̂Ȃ� SVG �����ɂȂ��Ă���F
This example shows a slightly more complex (i.e., it contains multiple rectangles) stand-alone, self-contained SVG document:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="5cm" height="4cm" version="1.1" xmlns="http://www.w3.org/2000/svg"> <desc>�S�̕ʁX�̋�` </desc> <rect x="0.5cm" y="0.5cm" width="2cm" height="1cm"/> <rect x="0.5cm" y="2cm" width="1cm" height="1.5cm"/> <rect x="3cm" y="0.5cm" width="1.5cm" height="2cm"/> <rect x="3.5cm" y="3cm" width="1cm" height="0.5cm"/> <!-- 'rect' �v�f�ŃL�����o�X�̋��E��\�� --> <rect x=".01cm" y=".01cm" width="4.98cm" height="3.98cm" fill="none" stroke="blue" stroke-width=".02cm" /> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
'svg' �v�f�� SVG ���e�̒��Ɍ���Ă��悢�B���ꂪ SVG �����Г��ւ̑��� SVG �����Ђ̖��ߍ��݂��\�ɂ���d�g�ɂȂ�B
'svg' elements can appear in the middle of SVG content. This is the mechanism by which SVG document fragments can be embedded within other SVG document fragments.
SVG ���e���� 'svg' �v�f�̂�����̗p�r�͐V�����r���[�|�[�g���m�������邱�Ƃł���i �V�����r���[�|�[�g�̊m�� ������j�B
Another use for 'svg' elements within the middle of SVG content is to establish a new viewport. (See Establishing a new viewport.)
�����Ȃ�ꍇ�ł��A�S�Ă� SVG �v�f�� SVG ���O��Ԃɑ�������̂Ǝ��ʂ����悤�ɂ��邽�߁A�u XML ���O��ԁv�����i"Namespaces in XML" Recommendation �j [XML-NS] �ɏ]���� SVG ���O��Ԑ錾���^�����Ȃ���Ȃ�Ȃ��B�ȉ��� SVG ���O��Ԑ錾�Ƃ��ĉ\�ȋL�@�ɂȂ�B���O��Ԑړ����̖��� xmlns ������ 'svg' �v�f�Ɏw�肵���ꍇ�A���̃X�R�[�v�ɂ���S�Ă̗v�f�ɑ������̖��O��Ԃ� SVG �ɂȂ�F
In all cases, for compliance with the "Namespaces in XML" Recommendation [ XML-NS], an SVG namespace declaration must be provided so that all SVG elements are identified as belonging to the SVG namespace. The following are possible ways to provide a namespace declaration. An xmlns attribute without a namespace prefix could be specified on an 'svg' element, which means that SVG is the default namespace for all elements within the scope of the element with the xmlns attribute:
<svg xmlns="http://www.w3.org/2000/svg"...> <rect .../> </svg>
xmlns
�����Ŗ��O��Ԑړ�����t�����ꍇ�i�Ⴆ��
xmlns:svg="http://www.w3.org/2000/svg"
�j�A�Ή����閼�O��Ԃ͊���̖��O��Ԃɂ͂Ȃ�Ȃ��̂ŁA�S�v�f�ɑ����O��Ԑړ�����^���Ȃ���Ȃ�Ȃ��F
If a namespace prefix is specified on the xmlns attribute (e.g.,
xmlns:svg="http://www.w3.org/2000/svg")
, then the corresponding namespace is not the default namespace, so an explicit namespace prefix must be assigned to the elements:
<svg:svg xmlns:svg="http://www.w3.org/2000/svg"...> <svg:rect .../> </svg:svg>
���O��Ԑړ����͑c��v�f�Ɏw�肷�邱�Ƃ��\�ł���i ��̗� �Ɏ�����Ă���j�B�ڍׂ́u XML ���O��ԁv���� [XML-NS] ���Q�Ƃ̂��ƁB
Namespace prefixes can be specified on ancestor elements (illustrated in the above example). For more information, refer to the "Namespaces in XML" Recommendation [ XML-NS].
<!-- svg: SVG Document Element ......................... --> <!ENTITY % SVG.svg.extra.content "" > <!ENTITY % SVG.svg.element "INCLUDE" > <![%SVG.svg.element;[ <!ENTITY % SVG.svg.content "( %SVG.Description.class; | %SVG.Animation.class; %SVG.Structure.class; %SVG.Conditional.class; %SVG.Image.class; %SVG.Style.class; %SVG.Shape.class; %SVG.Text.class; %SVG.Marker.class; %SVG.ColorProfile.class; %SVG.Gradient.class; %SVG.Pattern.class; %SVG.Clip.class; %SVG.Mask.class; %SVG.Filter.class; %SVG.Cursor.class; %SVG.Hyperlink.class; %SVG.View.class; %SVG.Script.class; %SVG.Font.class; %SVG.Extensibility.class; %SVG.svg.extra.content; )*" > <!ELEMENT %SVG.svg.qname; %SVG.svg.content; > <!-- end of SVG.svg.element -->]]> <!ENTITY % SVG.svg.attlist "INCLUDE" > <![%SVG.svg.attlist;[ <!ATTLIST %SVG.svg.qname; %SVG.xmlns.attrib; %SVG.Core.attrib; %SVG.Conditional.attrib; %SVG.Style.attrib; %SVG.Presentation.attrib; %SVG.DocumentEvents.attrib; %SVG.GraphicalEvents.attrib; %SVG.External.attrib; x %Coordinate.datatype; #IMPLIED y %Coordinate.datatype; #IMPLIED width %Length.datatype; #IMPLIED height %Length.datatype; #IMPLIED viewBox %ViewBoxSpec.datatype; #IMPLIED preserveAspectRatio %PreserveAspectRatioSpec.datatype; 'xMidYMid meet' zoomAndPan ( disable | magnify ) 'magnify' version %Number.datatype; #FIXED '1.1' baseProfile %Text.datatype; #IMPLIED contentScriptType %ContentType.datatype; 'text/ecmascript' contentStyleType %ContentType.datatype; 'text/css' > <!-- end of SVG.svg.attlist -->]]> |
������`�F
Attribute definitions:
SVG ���������̕����̕��i�Ƃ��ĎQ�Ƃ���邱�Ƃ��\�������ꍇ�A viewBox ������ �ł��O���� svg �v�f �Ɏw�肷��Ƃ悢�B���̑����� SVG ������C�ӂ̃r���[�|�[�g�ɓK�X�{����ς��Ă͂ߍ��ފȕւȕ��@�����B
If an SVG document is likely to be referenced as a component of another document, the author will often want to include a viewBox attribute on the outermost 'svg' element of the referenced document. This attribute provides a convenient way to design SVG documents to scale-to-fit into an arbitrary viewport.
'g' �v�f�݂͌��Ɋ֘A���� �O���t�B�b�N�X�v�f ���O���[�v�����邽�߂� �R���e�i�v�f �ł���B
The 'g' element is a container element for grouping together related graphics elements.
'desc' �v�f�� 'title' �v�f�ƃO���[�v���Ƃ̕��p�ɂ��A�����\���ƈӖ����e�̏�^������悤�ɂȂ�B �\���ɕx�����̓X�s�[�`�Ƃ���, �_���Ƃ���, ���邢�̓O���t�B�b�N�Ƃ��Ă̏o�͂��\�ɂȂ�A �A�N�Z�V�r���e�B �����シ��B
Grouping constructs, when used in conjunction with the 'desc' and 'title' elements, provide information about document structure and semantics. Documents that are rich in structure may be rendered graphically, as speech, or as braille, and thus promote accessibility.
�O���[�v�����ꂽ�v�f�ɑ��Ă��A�X�̃I�u�W�F�N�g�Ɠ��l�� id ������p���Ė��O��t������B���O�t���̃O���[�v�̓A�j���[�V������ė��p�ȂǗl�X�ȋǖʂŕK�v�ɂȂ�B
A group of elements, as well as individual objects, can be given a name using the id attribute. Named groups are needed for several purposes such as animation and re-usable objects.
��F
An example:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="5cm" height="5cm" version="1.1" xmlns="http://www.w3.org/2000/svg"> <desc>���ꂼ�ꂪ�Q�̋�`����Ȃ�Q�̃O���[�v </desc> <g id="group1" fill="red" > <rect x="1cm" y="1cm" width="1cm" height="1cm" /> <rect x="3cm" y="1cm" width="1cm" height="1cm" /> </g> <g id="group2" fill="blue" > <rect x="1cm" y="3cm" width="1cm" height="1cm" /> <rect x="3cm" y="3cm" width="1cm" height="1cm" /> </g> <!-- 'rect' �v�f�ŃL�����o�X�̋��E��\�� --> <rect x=".01cm" y=".01cm" width="4.98cm" height="4.98cm" fill="none" stroke="blue" stroke-width=".02cm" /> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
'g' �v�f�́A���� 'g' �v�f��C�ӂ̊K�w�ɂ킽���ē���q�ɂł���B���̗�̂悤�ɁF
A 'g' element can contain other 'g' elements nested within it, to an arbitrary depth. Thus, the following is possible:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="4in" height="3in" version="1.1" xmlns="http://www.w3.org/2000/svg"> <desc>�O���[�v�͓���q�ɂł��� </desc> <g> <g> <g> </g> </g> </g> </svg>
'g' ���Ɋ܂܂�Ȃ��ǂ�ȗv�f���A�i���Ȃ��Ƃ��T�O�I�ɂ́j���������P�ƂŃO���[�v���Ȃ����̂Ƃ��Ĉ�����B
Any element that is not contained within a 'g' is treated (at least conceptually) as if it were in its own group.
<!ENTITY % SVG.g.extra.content "" > <!ENTITY % SVG.g.element "INCLUDE" > <![%SVG.g.element;[ <!ENTITY % SVG.g.content "( %SVG.Description.class; | %SVG.Animation.class; %SVG.Structure.class; %SVG.Conditional.class; %SVG.Image.class; %SVG.Style.class; %SVG.Shape.class; %SVG.Text.class; %SVG.Marker.class; %SVG.ColorProfile.class; %SVG.Gradient.class; %SVG.Pattern.class; %SVG.Clip.class; %SVG.Mask.class; %SVG.Filter.class; %SVG.Cursor.class; %SVG.Hyperlink.class; %SVG.View.class; %SVG.Script.class; %SVG.Font.class; %SVG.Extensibility.class; %SVG.g.extra.content; )*" > <!ELEMENT %SVG.g.qname; %SVG.g.content; > <!-- end of SVG.g.element -->]]> <!ENTITY % SVG.g.attlist "INCLUDE" > |
SVG �ɂ����ẮA�L�͈͂ɓn��A���̃I�u�W�F�N�g�ւ� URI �Q�� [URI] �����p�ł���B�Ⴆ��`����^�O���f�[�V�����œh��Ԃ��ꍇ�A���̗l�ɍŏ��� 'linearGradient' �v�f���`���� ID ��^����F
SVG makes extensive use of URI references [ URI] to other objects. For example, to fill a rectangle with a linear gradient, you first define a 'linearGradient' element and give it an ID, as in:
<linearGradient id="MyGradient">...</linearGradient>
���ɁA��`�� 'fill' �v���p�e�B�ɐ���̐��^�O���f�[�V�����ւ̎Q�Ƃ�^����F
You then reference the linear gradient as the value of the 'fill' property for the rectangle, as in:
<rect style="fill:url(#MyGradient)"/>
URI �Q�Ƃ͎��̏����ŗ^������F
URI references are defined in either of the following forms:
<URI-reference> = [ <absoluteURI> | <relativeURI> ] [ "#" <elementID> ]-�܂���- <URI-reference> = [ <absoluteURI> | <relativeURI> ] [ "#xpointer(id(" <elementID> "))" ]
������ <elementID> �͎Q�Ɛ�̗v�f�� ID �ł���B
where <elementID> is the ID of the referenced element.
�i��̂Q�̏����i����
#<elementID>
��
#xpointer(id(<elementID>))
�j�́u XML �|�C���^����i XPointer �j�v
[XPTR]
�̏����ɏ]���Ă��邱�Ƃɒ��ӁB SVG 1.0 �̂t�`�� XPointer �̏����̂��������Q�����̂݃T�|�[�g���Ă���Ώ\���ł���B�j
(Note that the two forms above (i.e., #<elementID> and #xpointer(id(<elementID>))) are formulated in syntaxes compatible with "XML Pointer Language (XPointer)" [ XPTR]. These two formulations of URI references are the only XPointer formulations that are required in SVG 1.0 user agents.)
SVG �͂Q��ނ� URI �Q�Ƃ��T�|�[�g����F
SVG supports two types of URI references:
���̋K���� URI �Q�ƂɓK�p�����F
The following rules apply to the processing of URI references:
�Q�ƌ��ƗL���ȎQ�Ɛ�̎�ނƂ��ċ��e�����v�f�ƃv���p�e�B���ȉ��ɗ���F
The following list describes the elements and properties that allow URI references and the valid target types for those references:
���̋K���������� URI �Q�ƂɓK�p�����F
The following rules apply to the processing of invalid URI references:
�Q�Ɛ�̗v�f�͉\�Ȍ��� 'defs' �v�f���ɒ�`���邱�Ƃ����������B��ɎQ�ƂƂ��ė��p�����v�f�́A 'altGlyphDef', 'clipPath', 'cursor', 'filter', 'linearGradient', 'marker', 'mask', 'pattern', 'radialGradient', 'symbol' �ł���B�����̗v�f�� 'defs' �v�f���Œ�`�������������̒��g���������Ղ��Ȃ�A�A�N�Z�V�r���e�B�����シ��B
It is recommended that, wherever possible, referenced elements be defined inside of a 'defs' element. Among the elements that are always referenced: 'altGlyphDef', 'clipPath', 'cursor', 'filter', 'linearGradient', 'marker', 'mask', 'pattern', 'radialGradient' and 'symbol'. Defining these elements inside of a 'defs' element promotes understandability of the SVG content and thus promotes accessibility.
URI �Q�Ƃ� XLink [XLINK] ���O��Ԃ� href �����Ŏw�肳���B����̐ړ��� 'xlink:' �� XLink ���O��Ԃ̑����ɗ��p�����ꍇ�A���̑������� xlink:href �ƂȂ�B���̑����ɂ͗��p���������\�[�X�i�܂��̓��\�[�X�Ёj�ւ� URI �Q�Ƃ��w�肷��B
A URI reference is specified within an href attribute in the XLink [ XLINK] namespace. If the default prefix of 'xlink:' is used for attributes in the XLink namespace, then the attribute will be specified as xlink:href. The value of this attribute is a URI reference for the desired resource (or resource fragment).
href �����̒l�� [RFC2396] �Œ�`����� URI �Q�Ƃ��A��ŏq�ׂ�G�X�P�[�v�������{������� URI �Q�ƂɂȂ�Ȃ���Ȃ�Ȃ��B���̏����� URI �Q�Ƃ� URI ���]���o�ɓn����鎞�_�œK�p�����B
The value of the href attribute must be a URI reference as defined in [ RFC2396], or must result in a URI reference after the escaping procedure described below is applied. The procedure is applied when passing the URI reference to a URI resolver.
�ꕔ�̕����͂��Ƃ� XML �ŋ�����Ă���Ƃ��Ă� URI �Q�ƂɊ܂܂�Ă͂Ȃ�Ȃ��B�܂܂�ĂȂ�Ȃ������� ASCII �ȊO�̑S�Ă̕����� [RFC2396] �� 2.4 �߂ɏ����ꂽ��O�����̑S�Ăł���B�A�� [RFC2732] �ō��@�����ꂽ�A�ԍ��L���i#�j, �p�[�Z���g�i%�j, �p���ʁi[, ]�j�������B���@�łȂ������͎��̗l�ɂ��ăG�X�P�[�v����˂Ȃ�Ȃ��F
Some characters are disallowed in URI references, even if they are allowed in XML; the disallowed characters include all non-ASCII characters, plus the excluded characters listed in Section 2.4 of [ RFC2396], except for the number sign (#) and percent sign (%) and the square bracket characters re-allowed in [ RFC2732]. Disallowed characters must be escaped as follows:
�S�Ă̍��@�łȂ������͂P�o�C�g�ȏ�� UTF-8 [RFC2279] �ɕϊ������B
Each disallowed character is converted to UTF-8 [ RFC2279] as one or more bytes.
���@�łȂ������ɑΉ�����S�Ẵo�C�g�� URI �G�X�P�[�v�����ɂ����i���� HH ���o�C�g�� 16 �i�\�L�Ƃ���Ƃ��A%
HH�j�B
Any bytes corresponding to a disallowed character are escaped with the URI escaping mechanism (that is, converted to %
HH, where HH is the hexadecimal notation of the byte value).
���̕����͕ϊ����ʂɒu�������B
The original character is replaced by the resulting character sequence.
�A�v���P�[�V�����ɂƂ��Ă͒l�� URI �Q�Ƃł��邩�ǂ��������������`�F�b�N����͔̂��I�Ȃ��ƂȂ̂ŁA���̎d�l�� [RFC2396] �ɏ]���Ă��邾���ł���A SVG �A�v���P�[�V���������̂悤�ȓK�����̃e�X�g����K�v�����邱�Ƃ�������킯�ł͂Ȃ��B �y URI �Q�Ƃł��邩�ǂ��� - �\���I�Ȑ������ł͂Ȃ��A���݂��� URI ���ǂ����̃`�F�b�N���w�����̂Ǝv����B�z
Because it is impractical for any application to check that a value is a URI reference, this specification follows the lead of [ RFC2396] in this matter and imposes no such conformance testing requirement on SVG applications.
URI �Q�Ƃ����ΎQ�Ƃ̏ꍇ�A�g�p�O�� [XML-Base] �ɑ��������@�Ő�ΎQ�Ƃ����o����Ȃ���Ȃ�Ȃ��B
If the URI reference is relative, its absolute version must be computed by the method of [ XML-Base] before use.
XML ���\�[�X�ւ̎Q�Ƃ̏ꍇ�A URI �Q�ƂɎg���Ă��镶���Ў��ʎq�i��������j�̏����� XPointer
[XPTR]
�̎d�l�ɏ]���B
For locators into XML resources, the format of the fragment identifier (if any) used within the URI reference is specified by the XPointer specification [ XPTR].
�Q�Ɛ�̃��\�[�X�ɂ��Ă̕⑫����lj��� XLink �����Ŏw��ł���B�����̒lj������͎��̎��̂Ƃ��� DTD �Ɋ܂܂�Ă���B�R�̎��̒�`�� xlink:show �̒l���قȂ邾���ł���A�ŏ��̂Q�͒l other �A���Ƃ̂P�͒l embed ���Ƃ�B�ŏ��̂Q�̎��̒�`�̓��\�[�X���Q�Ƃ���قƂ�ǂ̗v�f�ŗp��������̂ł���B�R�Ԗڂ̎��̒�`�͗v�f 'use', 'image', 'feImage' �ŗp������B
Additional XLink attributes can be specified that provide supplemental information regarding the referenced resource. These additional attributes are included in the DTD in the following entities. The three entity definitions differ only in the value of xlink:show, which has the value other in the first two entities and the value embed in the third. The first two entity definitions are used in most element definitions which reference resources. The third entity definition is used by elements 'use', 'image' and 'feImage'.
<!ENTITY % SVG.XLink.extra.attrib "" > <!ENTITY % SVG.XLink.attrib "%XLINK.xmlns.attrib; %XLINK.pfx;type ( simple ) #FIXED 'simple' %XLINK.pfx;href %URI.datatype; #IMPLIED %XLINK.pfx;role %URI.datatype; #IMPLIED %XLINK.pfx;arcrole %URI.datatype; #IMPLIED %XLINK.pfx;title CDATA #IMPLIED %XLINK.pfx;show ( other ) 'other' %XLINK.pfx;actuate ( onLoad ) #FIXED 'onLoad' %SVG.XLink.extra.attrib;" > <!ENTITY % SVG.XLinkRequired.extra.attrib "" > <!ENTITY % SVG.XLinkRequired.attrib "%XLINK.xmlns.attrib; %XLINK.pfx;type ( simple ) #FIXED 'simple' %XLINK.pfx;href %URI.datatype; #REQUIRED %XLINK.pfx;role %URI.datatype; #IMPLIED %XLINK.pfx;arcrole %URI.datatype; #IMPLIED %XLINK.pfx;title CDATA #IMPLIED %XLINK.pfx;show ( other ) 'other' %XLINK.pfx;actuate ( onLoad ) #FIXED 'onLoad' %SVG.XLinkRequired.extra.attrib;" > <!ENTITY % SVG.XLinkEmbed.extra.attrib "" > <!ENTITY % SVG.XLinkEmbed.attrib "%XLINK.xmlns.attrib; %XLINK.pfx;type ( simple ) #FIXED 'simple' %XLINK.pfx;href %URI.datatype; #REQUIRED %XLINK.pfx;role %URI.datatype; #IMPLIED %XLINK.pfx;arcrole %URI.datatype; #IMPLIED %XLINK.pfx;title CDATA #IMPLIED %XLINK.pfx;show ( embed ) 'embed' %XLINK.pfx;actuate ( onLoad ) #FIXED 'onLoad' %SVG.XLinkEmbed.extra.attrib;" > <!ENTITY % SVG.XLinkReplace.extra.attrib "" > <!ENTITY % SVG.XLinkReplace.attrib "%XLINK.xmlns.attrib; %XLINK.pfx;type ( simple ) #FIXED 'simple' %XLINK.pfx;href %URI.datatype; #REQUIRED %XLINK.pfx;role %URI.datatype; #IMPLIED %XLINK.pfx;arcrole %URI.datatype; #IMPLIED %XLINK.pfx;title CDATA #IMPLIED %XLINK.pfx;show ( new | replace ) 'replace' %XLINK.pfx;actuate ( onRequest ) #FIXED 'onRequest' %SVG.XLinkReplace.extra.attrib;" > |
�����Ȃ�ꍇ�ł��A��L XLink �����̂����ꂩ�� SVG ���e�ɂ����ė��p����ۂɂ́A XML ���O��Ԋ��� [XML-NS] �ɓK������悤�A XLink ���O��Ԑ錾�������I�ɗ^�����Ȃ���Ȃ�Ȃ��B���̂悤�� XLink ���O��Ԑ錾��^����ȒP�ȕ��@�̈�́A XLink �����𗘗p������e�ɂ����� �ł��O���� svg �v�f �� XLink ���O��Ԃ̂��߂� xmlns �������܂߂邱�Ƃł���B�Ⴆ�F
In all cases, for compliance with the "Namespaces in XML" Recommendation [ XML-NS], an explicit XLink namespace declaration must be provided whenever one of the above XLink attributes is used within SVG content. One simple way to provide such an XLink namespace declaration is to include an xmlns attribute for the XLink namespace on the outermost 'svg' element for content that uses XLink attributes. For example:
<svg xmlns:xlink="http://www.w3.org/1999/xlink"...> <image xlink:href="foo.png" .../> </svg>
'defs' �v�f�͔�Q�Ɨv�f�̂��߂̃R���e�i�v�f�ł���B�ǐ��� �A�N�Z�V�r���e�B �̗v������A�Q�Ƃ����\���̂���v�f�͉\�Ȃ炱�̗v�f���ɒ�`���邱�Ƃ����������B
The 'defs' element is a container element for referenced elements. For understandability and accessibility reasons, it is recommended that, whenever possible, referenced elements be defined inside of a 'defs'.
'defs' �v�f�̓��e���f���� 'g' �v�f�ƑS�������ł���B���������� 'g' �v�f�̎q�ɂȂ��S�Ă̗v�f�� 'defs' �v�f�̎q�ɂȂ�A�t���܂��^�ł���B
The content model for 'defs' is the same as for the 'g' element; thus, any element that can be a child of a 'g' can also be a child of a 'defs', and vice versa.
'defs' �v�f�̎q���̗v�f�͒��ڕ`�悳��邱�Ƃ͂Ȃ��B�����͂������� 'defs' �v�f�� 'g' �v�f�������Ƃ����Ƃ��� 'display' �v���p�e�B�� none �Ɏw�肳��Ă��邩�̂��Ƃ��A�`��̈ꕔ���Ƃ݂Ȃ���Ȃ��B�������Ȃ���A 'defs' �v�f�̎q���͌��X�̖ɂ��ł����݂��Ă���A���̗v�f����̎Q�Ƃ͏�ɉ\�ł���B���������āA 'display' �v���p�e�B�� 'defs' �v�f�܂��͂��̎q���̂ǂ����ɂ������Ƃ��Ă��A���̗v�f����̎Q�Ƃ�W���邱�Ƃ͂Ȃ��B
Elements that are descendants of a 'defs' are not rendered directly; they are prevented from becoming part of the rendering tree just as if the 'defs' element were a 'g' element and the 'display' property were set to none. Note, however, that the descendants of a 'defs' are always present in the source tree and thus can always be referenced by other elements; thus, the value of the 'display' property on the 'defs' element or any of its descendants does not prevent those elements from being referenced by other elements.
<!ENTITY % SVG.defs.extra.content "" > <!ENTITY % SVG.defs.element "INCLUDE" > <![%SVG.defs.element;[ <!ENTITY % SVG.defs.content "( %SVG.Description.class; | %SVG.Animation.class; %SVG.Structure.class; %SVG.Conditional.class; %SVG.Image.class; %SVG.Style.class; %SVG.Shape.class; %SVG.Text.class; %SVG.Marker.class; %SVG.ColorProfile.class; %SVG.Gradient.class; %SVG.Pattern.class; %SVG.Clip.class; %SVG.Mask.class; %SVG.Filter.class; %SVG.Cursor.class; %SVG.Hyperlink.class; %SVG.View.class; %SVG.Script.class; %SVG.Font.class; %SVG.Extensibility.class; %SVG.defs.extra.content; )*" > <!ELEMENT %SVG.defs.qname; %SVG.defs.content; > <!-- end of SVG.defs.element -->]]> <!ENTITY % SVG.defs.attlist "INCLUDE" > <![%SVG.defs.attlist;[ <!ATTLIST %SVG.defs.qname; %SVG.Core.attrib; %SVG.Conditional.attrib; %SVG.Style.attrib; %SVG.Presentation.attrib; %SVG.GraphicalEvents.attrib; %SVG.External.attrib; transform %TransformList.datatype; #IMPLIED > |
�X�g���[�~���O���ɂ����Ăt�`�̌����I�Ȏ��s�𑣂����߂ɂ́A SVG ���e�쐬�҂͎Q�ƌ��̗v�f�̑c��v�f�̒��ڂ̎q�Ƃ��� 'defs' �v�f��u���A���̒��ɋǏ� URI �Q�Ƃɂ��Q�Ƃ����q�v�f���ׂĂ�u�����Ƃ����コ���B�Ⴆ�F
To provide some SVG user agents with an opportunity to implement efficient implementations in streaming environments, creators of SVG content are encouraged to place all elements which are targets of local URI references within a 'defs' element which is a direct child of one of the ancestors of the referencing element. For example:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="8cm" height="3cm" xmlns="http://www.w3.org/2000/svg"> <desc>�c��v�f�� 'defs' �q�v�f���ɂ�����Ǐ� URI �Q�ƁB</desc> <defs> <linearGradient id="Gradient01"> <stop offset="20%" stop-color="#39F" /> <stop offset="90%" stop-color="#F3F" /> </linearGradient> </defs> <rect x="1cm" y="1cm" width="6cm" height="1cm" fill="url(#Gradient01)" /> <!-- 'rect' �v�f�ŃL�����o�X�̋��E��\�� --> <rect x=".01cm" y=".01cm" width="7.98cm" height="2.98cm" fill="none" stroke="blue" stroke-width=".02cm" /> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
��̕����ł� 'svg' �v�f�����^�O���f�[�V�������܂� 'defs' �v�f�ڂ̎q�Ƃ��Ď����A�����^�O���f�[�V�������Q�Ƃ��� 'rect' �v�f�̑c��Ɉʒu���Ă���B���̂悤�ɁA��̕����͏�q�̎w�j�ɉ����Ă���B
In the document above, the linear gradient is defined within a 'defs' element which is the direct child of the 'svg' element, which in turn is an ancestor of the 'rect' element which references the linear gradient. Thus, the above document conforms to the guideline.
�R���e�i�v�f �� �O���t�B�b�N�X�v�f �ɂ͌ʂ� 'desc' �v�f�A�܂��̓e�L�X�g�݂̂̐�����^���� 'title' �v�f�A���邢�͂����̗������w�肷�邱�Ƃ��ł���B SVG �����Ђ����o���f�B�A�� SVG �Ƃ��ĕ`�悳���ꍇ�A 'desc' �� 'title' �v�f�̓O���t�B�b�N�̈ꕔ�Ƃ��Ă͏o�͂���Ȃ��B�������Ȃ���A�Ⴆ�|�C���e�B���O���u�ŐG���ƌ����c�[���`�b�v�Ƃ��� 'title' �v�f��\�������邱�Ƃ��t�`�ɂ͉\�ł���B���o�A���o�����ɂ��đ�֕\���͉\�ł���A 'path' �Ȃǂ̃O���t�B�b�N�X�v�f��\�����邩���� 'desc' ����� 'title' �v�f��\�����邱�Ƃ͏\���l������B���̂悤�Ȃ��Ƃ́i�ꍇ�ɂ���Ă͗��p�҂́j�X�^�C���V�[�g��ύX���邱�Ƃŗe�ՂɎ����ł���B�[���K�w�\�������悤�ȏꍇ��A 'use' �v�f�̎Q�Ƃ�H��悤�ȏꍇ�A�ǂ��܂Ő[�����������@�艺���邩�̐���𗘗p�҂ɂ䂾�˂������]�܂�����ʂ͑��X����B
Each container element or graphics element in an SVG drawing can supply a 'desc' and/or a 'title' description string where the description is text-only. When the current SVG document fragment is rendered as SVG on visual media, 'desc' and 'title' elements are not rendered as part of the graphics. User agents may, however, for example, display the 'title' element as a tooltip, as the pointing device moves over particular elements. Alternate presentations are possible, both visual and aural, which display the 'desc' and 'title' elements but do not display 'path' elements or other graphics elements. This is readily achieved by using a different (perhaps user) style sheet. For deep hierarchies, and for following 'use' element references, it is sometimes desirable to allow the user to control how deep they drill down into descriptive text.
<!ENTITY % SVG.desc.extra.content "" > <!ENTITY % SVG.desc.element "INCLUDE" > <![%SVG.desc.element;[ <!ENTITY % SVG.desc.content "( #PCDATA %SVG.desc.extra.content; )*" > <!ELEMENT %SVG.desc.qname; %SVG.desc.content; > <!-- end of SVG.desc.element -->]]> <!ENTITY % SVG.desc.attlist "INCLUDE" > <![%SVG.desc.attlist;[ <!ATTLIST %SVG.desc.qname; %SVG.Core.attrib; %SVG.Style.attrib; > |
<!ENTITY % SVG.title.extra.content "" > <!ENTITY % SVG.title.element "INCLUDE" > <![%SVG.title.element;[ <!ENTITY % SVG.title.content "( #PCDATA %SVG.title.extra.content; )*" > <!ELEMENT %SVG.title.qname; %SVG.title.content; > |
�ȉ��ɗ��������B�ʏ�̏����ł͂t�`�� 'g' �v�f���� 'desc' �� 'title' �v�f���������c��̕����݂̂�\������B
The following is an example. In typical operation, the SVG user agent would not render the 'desc' and 'title' elements but would render the remaining contents of the 'g' element.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg SYSTEM "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="4in" height="3in" version="1.1" xmlns="http://www.w3.org/2000/svg"> <g> <title> �n��ʔ��㍂ </title> <desc> ����͒n��ʔ��㍂��\���_�O���t�ł���B </desc> <!-- �x�N�^�[�f�[�^�Œ�`�����_�O���t --> </g> </svg>
�������ƃ^�C�g���v�f�͑��̖��O��ԂŃ}�[�N�A�b�v���ꂽ�e�L�X�g���܂߂邱�Ƃ��ł���F
Description and title elements can contain marked-up text from other namespaces. Here is an example:
<?xml version="1.0" standalone="yes"?> <svg width="4in" height="3in" version="1.1" xmlns="http://www.w3.org/2000/svg"> <desc xmlns:mydoc="http://example.org/mydoc"> <mydoc:title>����͗Ꭶ�p SVG �t�@�C��</mydoc:title> <mydoc:para>�S�̓I�Ȑ����� <mydoc:emph>mydoc</mydoc:emph> ���O��� �ɂ��}�[�N�A�b�v�𗘗p�B</mydoc:para> </desc> <g> <!-- �G�}�͂����� --> </g> </svg>
�����쐬�҂͓Ɨ����� SVG ������ �ł��O���� svg �v�f �ɑ���� 'title' �v�f���q�v�f�Ƃ��ė^����ׂ��ł���B 'svg' �v�f�̎q�v�f�Ƃ��Ă� 'title' �v�f�� SVG �����Ђ̓��e�̊m�F�ɖ𗧂B���p�҂͂����Ε����̊O���當�����Q�Ƃ���̂ŁA�����쐬�҂͕����ɑ������^�C�g�������ׂ��ł���B�u�����v�̗l�ȕ������ɖR�����^�C�g�����A�u�����̗{�I�ƁE�����v�̗l�Ƀ^�C�g��������ׂ��ł���B �t�`�� �ł��O���� svg �v�f �� 'title' �q�v�f������A�A�N�Z�V�r���e�B�ɔz�����ĕK�����p�҂Ɏ������悤�ɂ��ׂ��ł���B���̂悤�Ȏd�g�̎����͂t�`���ɑ�����Ă���i�Ⴆ�A�����ɂ��L���v�V�����j�B
Authors should always provide a 'title' child element to the outermost 'svg' element within a stand-alone SVG document. The 'title' child element to an 'svg' element serves the purposes of identifying the content of the given SVG document fragment. Since users often consult documents out of context, authors should provide context-rich titles. Thus, instead of a title such as "Introduction", which doesn’t provide much contextual background, authors should supply a title such as "Introduction to Medieval Bee-Keeping" instead. For reasons of accessibility, user agents should always make the content of the 'title' child element to the outermost 'svg' element available to users. The mechanism for doing so depends on the user agent (e.g., as a caption, spoken).
������ SVG �̗v�f�i���ɃR���e�i�v�f�ƃe�L�X�g�v�f�j�� DTD ��`�ł� 'desc' �� 'title' �q�v�f�̔z�u�␔�ɐ�����݂��Ă��Ȃ��B���̗Z�ʐ��̓R���e�i�v�f�ɑ����ѐ��̂�����e���f�����J�������܂ł̈ꎞ�I�ȑ[�u�ł���B�ꕔ�̃R���e�i�v�f�͍������e�����e���A�]�܂�鐧��� XML �̍������e�̋K�� [XML-MIXED] ������Ă���Ȃ�����ł���B�����ł� SVG ����̕\���� DTD �����\�o�I�ɂȂ�A��萧�ꂽ�������e�K�������Ă�悤�ɂȂ�ł��낤�B�S�Ă̗v�f�ɑ��A���X�P�� 'desc' �ƍ��X�P�� 'title' ���q�v�f�Ƃ��ė^���A�������i 'metadata' �v�f�ƕ����f�[�^�������j���̑S�Ă̎q�v�f����Ɉʒu�����邱�Ƃ��������������B�t�`�͏����̍ۂɕ����� 'desc' �� 'title' ����̑I���𔗂�ꂽ�ꍇ�A�ŏ��̂��̂�I�Ԃׂ��ł���i�Ⴆ�c�[���`�b�v�ɂǂ̃e�L�X�g��p���邩�Ȃǁj�B
The DTD definitions of many of SVG's elements (particularly, container and text elements) place no restriction on the placement or number of the 'desc' and 'title' sub-elements. This flexibility is only present so that there will be a consistent content model for container elements, because some container elements in SVG allow for mixed content, and because the mixed content rules for XML [ XML-MIXED] do not permit the desired restrictions. Representations of future versions of the SVG language might use more expressive representations than DTDs which allow for more restrictive mixed content rules. It is strongly recommended that at most one 'desc' and at most one 'title' element appear as a child of any particular element, and that these elements appear before any other child elements (except possibly 'metadata' elements) or character data content. If user agents need to choose among multiple 'desc' or 'title' elements for processing (e.g., to decide which string to use for a tooltip), the user agent shall choose the first one.
'symbol' �v�f�̓O���t�B�b�N�̂ЂȌ^�I�u�W�F�N�g���`���A 'use' �v�f�ɂ��C���X�^���X�������B
The 'symbol' element is used to define graphical template objects which can be instantiated by a 'use' element.
�O���t�B�b�N�ɌJ��Ԃ��p���� 'symbol' �v�f�̗��p�ɂ��A�����ɍ\���ƈӖ����e����������B�\���ɕx�����̓O���t�B�b�N, �ǂݏグ, ���邢�͓_���ɂ��o�͂��\�ɂȂ�A �A�N�Z�V�r���e�B �����シ��B
The use of 'symbol' elements for graphics that are used multiple times in the same document adds structure and semantics. Documents that are rich in structure may be rendered graphically, as speech, or as braille, and thus promote accessibility.
'symbol' �� 'g' �̍��{�I�ȑ���́F
The key distinctions between a 'symbol' and a 'g' are:
'marker'
�v�f��
'pattern'
�v�f��
'symbol'
�v�f�Ɩ��ڂɊ֘A����B
Closely related to the 'symbol' element are the
'marker' and
'pattern' elements.
<!ENTITY % SVG.symbol.extra.content "" > <!ENTITY % SVG.symbol.element "INCLUDE" > <![%SVG.symbol.element;[ <!ENTITY % SVG.symbol.content "( %SVG.Description.class; | %SVG.Animation.class; %SVG.Structure.class; %SVG.Conditional.class; %SVG.Image.class; %SVG.Style.class; %SVG.Shape.class; %SVG.Text.class; %SVG.Marker.class; %SVG.ColorProfile.class; %SVG.Gradient.class; %SVG.Pattern.class; %SVG.Clip.class; %SVG.Mask.class; %SVG.Filter.class; %SVG.Cursor.class; %SVG.Hyperlink.class; %SVG.View.class; %SVG.Script.class; %SVG.Font.class; %SVG.Extensibility.class; %SVG.symbol.extra.content; )*" > <!ELEMENT %SVG.symbol.qname; %SVG.symbol.content; > |
'symbol' �v�f�͌����Ē��ڕ`�悳��邱�Ƃ͂Ȃ��A 'use' �v�f����̎Q�ƈȊO�Ɏg�����͂Ȃ��B 'display' �v���p�e�B�� 'symbol' �v�f�ɂ͓K�p����Ȃ��B���Ȃ킿�A 'symbol' �v�f�� 'display' �v���p�e�B�̒l�� none �ȊO�ł����Ă����ڕ`�悳��邱�Ƃ͂Ȃ��A 'symbol' �v�f���g���邢�͑c��ɂ����� 'display' �v���p�e�B�̒l�� none �ł����Ă��Q�Ɨ��p�͉\�ł���B
'symbol' elements are never rendered directly; their only usage is as something that can be referenced using the 'use' element. The 'display' property does not apply to the 'symbol' element; thus, 'symbol' elements are not directly rendered even if the 'display' property is set to a value other than none, and 'symbol' elements are available for referencing even when the 'display' property on the 'symbol' element or any of its ancestors is set to none.
�ǂ� 'svg', 'symbol', 'g', 'use' �v�f���邢�� �O���t�B�b�N�X�v�f ���A 'use' �v�f�ɂ��ЂȌ^�Ƃ��Ă̍ė��p�i�����C���X�^���X���j�̑ΏۂɂȂ�B 'use' �v�f�͕����̗^����ꂽ�ꏊ�ɂ����đ��̗v�f���Q�Ƃ��A���̃O���t�B�b�N���e�̎�荞�݂ƕ`����w������B
Any 'svg', 'symbol', 'g', graphics element or other 'use' is potentially a template object that can be re-used (i.e., "instanced") in the SVG document via a 'use' element. The 'use' element references another element and indicates that the graphical contents of that element is included/drawn at that given point in the document.
'image' �v�f�Ƃ͈قȂ�A 'use' �v�f�͕����S�̂��Q�Ƃ��邱�Ƃ͂ł��Ȃ��B
Unlike 'image', the 'use' element cannot reference entire files.
'use' �v�f�͏ȗ��\�Ȏ��̑����F x, y, width, height �����B�����͎Q�Ɛ�̗v�f�̃O���t�B�b�N���e�����݂̍��W�n�̋�`�̈�Ɏʑ����邽�߂ɗ��p�����B
The 'use' element has optional attributes x, y, width and height which are used to map the graphical contents of the referenced element onto a rectangular region within the current coordinate system.
'use' �v�f�ɂ����ʂ́A���������Q�Ɛ�̗v�f�̓��e�� DOM �ɂ����� - ���� 'use' �v�f��e�Ƃ���ʌ̔���J�Ƃ��āA���� 'use' �v�f�̑S�Ă̑c�悪���̖̑c��ɂȂ�悤�� - ���[�܂ŕ������ꂽ���̂悤�ɂӂ�܂��B�������ꂽ DOM �͔���J�Ȃ̂ŁA SVG �����I�u�W�F�N�g���f���i DOM �j�ɂ����Ă� 'use' �v�f�Ƃ��̑��������݂��邾���ł���A�Q�Ɛ�̗v�f�̓��e�� 'use' �v�f�̎q�Ƃ��Ă͌���邱�Ƃ͂Ȃ��B
The effect of a 'use' element is as if the contents of the referenced element were deeply cloned into a separate non-exposed DOM tree which had the 'use' element as its parent and all of the 'use' element's ancestors as its higher-level ancestors. Because the cloned DOM tree is non-exposed, the SVG Document Object Model (DOM) only contains the 'use' element and its attributes. The SVG DOM does not show the referenced element's contents as children of 'use' element.
CSS �ɂ��X�^�C���t�� ���T�|�[�g����t�`�ɂ����ẮA���̊T�O�I�Ȕ���J DOM �̒��ւ̎Q�Ɛ�̗v�f�Ƃ��̎q���̖��[�܂ł̕����́A CSS �J�X�P�[�h [CSS2-CASCADE] �ɂ������炳���Q�Ɛ�̗v�f�Ƃ��̓��e�̑S�Ẵv���p�e�B�̒l�̕������Ӗ�����B CSS2 �Z���N�^�̓K�p�ɂ��ẮA���́i�����Q�Ɛ�́j�v�f�ɂ��Ă͐����ȕ����\���̈ꕔ�Ȃ̂œK�p��������A�i�T�O�I�ȁj�����ɂ��Ă͐����ȕ����\���̈ꕔ�ł͂Ȃ��̂œK�p����Ȃ��B
For user agents that support Styling with CSS, the conceptual deep cloning of the referenced element into a non-exposed DOM tree also copies any property values resulting from the CSS cascade [ CSS2-CASCADE] on the referenced element and its contents. CSS2 selectors can be applied to the original (i.e., referenced) elements because they are part of the formal document structure. CSS2 selectors cannot be applied to the (conceptually) cloned DOM tree because its contents are not part of the formal document structure.
�������Ȃ���A�v���p�e�B�p���ɂ����ẮA�Q�Ɛ�̗v�f���e�L�X�g���̂܂܂Ƃ��� 'use' �v�f���ɖ��[�̎q���܂ŕ�������Ă�����̂Ƃ݂Ȃ���A 'use' �v�f�Ƃ��̑c��v�f�̃v���p�e�B���p�����A�����ؓ��̃C���X�^���X�����ꂽ�v�f�͎Q�Ɛ�̗v�f�̌��X�̐e�̃v���p�e�B���p�����Ȃ��B
Property inheritance, however, works as if the referenced element had been textually included as a deeply cloned child of the 'use' element. The referenced element inherits properties from the 'use' element and the 'use' element's ancestors. An instance of a referenced element does not inherit properties from the referenced element's original parents.
�����C�x���g�������Q�Ɛ�̗v�f�ɂ��Ă����Ă���ꍇ�A���̃C�x���g�̎��ۂ̕W�I�́u�C���X�^���X�����ꂽ�v���̑Ή����� SVGElementInstance �I�u�W�F�N�g�ɂȂ�B
If event attributes are assigned to referenced elements, then the actual target for the event will be the SVGElementInstance object within the "instance tree" corresponding to the given referenced element.
����J�ɂ�����C�x���g�����́A SVGElementInstance �I�u�W�F�N�g�֔z������邱�Ƃ������A���������Q�Ɛ�̗v�f���e�L�X�g�̂܂� 'use' �v�f���ɖ��[�̎q���܂ŕ������ꂽ���̂悤�ɏ��������B�C�x���g�̕W�I�� currentTarget �����́A�Q�Ɛ�̕����̒��̃C�x���g�̕W�I�ɑΉ����� SVGElementInstance �ƌ��݂̕W�I�v�f�ɐݒ肳���B�C�x���g�͒ʏ�̖̂��Ƃ��A�̔���J���������J�������ʂ��ē`�d����F�ŏ��̓��[�g�v�f���� 'use' �v�f�ցA�����Ĕ���J�������C�x���g�̕W�I�܂ŒH��i�ߊl�ߒ� - capture phase �j�A�W�I�Ńo�u�������A�Ăє���J������ʂ��� 'use' �v�f�ցA�����Ēʏ�̖����[�g�v�f�܂ŕ��シ��i����ߒ� - bubbling phase �j�B
The event handling for the non-exposed tree works as if the referenced element had been textually included as a deeply cloned child of the 'use' element, except that events are dispatched to the SVGElementInstance objects. The event's target and currentTarget attributes are set to the SVGElementInstance that corresponds to the target and current target elements in the referenced subtree. An event propagates through the exposed and non-exposed portions of the tree in the same manner as it would in the regular document tree: first going from the root element to the 'use' element and then through non-exposed tree elements in the capture phase, followed by the target phase at the target of the event, then bubbling back through non-exposed tree to the use element and then back through regular tree to the root element in bubbling phase.
��̗v�f�ɑΉ�����S�Ă� SVGElementInstance �I�u�W�F�N�g�̓C�x���g���X�i�̃��X�g�����L����B�ǂ̃I�u�W�F�N�g���C�x���g���X�i���Ăяo�������̓C�x���g�� currentTarget �����Œm�邱�Ƃ��ł���B
An element and all its corresponding SVGElementInstance objects share an event listener list. The currentTarget attribute of the event can be used to determine through which object an event listener was invoked.
'visibility' �v���p�e�B�̐U��܂��͂����ł̃v���p�e�B�p�����f���ɏ]���B���������� 'use' �v�f�� 'visibility:hidden' �Ǝw�肳��Ă����Ƃ��Ă��Q�Ɛ�̓��e���`�悳��Ȃ��Ȃ�킯�ł͂Ȃ��B 'use' �v�f�� 'visibility:hidden' �Ǝw�肳��Ă��āA�Q�Ɛ�̗v�f�ł� 'visibility:hidden' �܂��� 'visibility:inherit' �Ǝw�肳��Ă���Ȃ���̗v�f�͌����Ȃ��Ȃ�B�������Ȃ���A�Q�Ɛ�̗v�f�ł� 'visibility:visible' �Ǝw�肳��Ă����ꍇ�A���Ƃ� 'use' �v�f�� 'visibility:hidden' �Ǝw�肳��Ă����Ƃ��Ă����̗v�f�͌����邱�ƂɂȂ�B
The behavior of the 'visibility' property conforms to this model of property inheritance. Thus, specifying 'visibility:hidden' on a 'use' element does not guarantee that the referenced content will not be rendered. If the 'use' element specifies 'visibility:hidden' and the element it references specifies 'visibility:hidden' or 'visibility:inherit', then that one element will be hidden. However, if the referenced element instead specifies 'visibility:visible', then that element will be visible even if the 'use' element specifies 'visibility:hidden'.
�Q�Ɛ�̗v�f�ɂ�����A�j���[�V�����͂��̃C���X�^���X�ł��L���ł���B
Animations on a referenced element will cause the instances to also be animated.
'use' �v�f�ɂ����鎋�o��̌��ʂ͂������� 'use' �v�f���ȉ��̂悤�ɂ��Đ����������e�ɒu��������ꂽ���̂悤�ɂӂ�܂� �i�F���������܂�ɂ��璷�Ȃ̂ʼn��̖�ł͍č\�������j �F
A 'use' element has the same visual effect as if the 'use' element were replaced by the following generated content:
CSS �ɂ��X�^�C���t�� ���T�|�[�g����t�`�ɂ����ẮA�������ꂽ 'g' �v�f�� CSS �J�X�P�[�h [CSS2-CASCADE] �ɂ��u�J�X�P�[�h���ꂽ�v 'use' �v�f�̃v���p�e�B�l���ꏏ�ɉ^�ԁB�����āA�Q�Ɛ�̃��\�[�X�̃R�s�[�i���[�܂ł̕����j�̓I���W�i���́i�܂�A�Q�Ɛ�́j�v�f�́u�J�X�P�[�h���ꂽ�v�v���p�e�B�l���ꏏ�ɉ^�ԁB���������� class ��������� style �����Ƒg�ݍ��킹�ėp������l�X�� CSS �Z���N�^�ɂ����ʂ́A���ۏ�A�������ꂽ���e�ɂ����āu�J�X�P�[�h���ꂽ�v�v���p�e�B�l��`�B����@�\�㓯�l�� style �����ɒu���������B
For user agents that support Styling with CSS, the generated 'g' element carries along with it the "cascaded" property values on the 'use' element which result from the CSS cascade [ CSS2-CASCADE]. Additionally, the copy (deep clone) of the referenced resource carries along with it the "cascaded" property values resulting from the CSS cascade on the original (i.e., referenced) elements. Thus, the result of various CSS selectors in combination with the class and style attributes are, in effect, replaced by the functional equivalent of a style attribute in the generated content which conveys the "cascaded" property values.
Example Use01 �� 'rect' �𗘗p����P���� 'use' �v�f�������F
Example Use01 below has a simple 'use' on a 'rect'.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <desc>Example Use01 - 'rect' �𗘗p����P���� 'use'</desc> <defs> <rect id="MyRect" width="60" height="10"/> </defs> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <use x="20" y="10" xlink:href="#MyRect" /> </svg>
![]() |
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
���o���ʂɂ����Ă͎��Ɠ����ɂȂ�F
The visual effect would be equivalent to the following document:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" xmlns="http://www.w3.org/2000/svg" version="1.1"> <desc>Example Use01-GeneratedContent - 'rect' �𗘗p����P���� 'use'</desc> <!-- 'defs' ���͏ȗ� --> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <!-- 'use' ��u�������鐶�����e�͂������� --> <g transform="translate(20,10)"> <rect width="60" height="10"/> </g> <!-- �������e�͂����܂� --> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
Example Use02 �� 'symbol' �𗘗p���� 'use' �v�f�������F
Example Use02 below has a 'use' on a 'symbol'.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <desc>Example Use02 - 'symbol' �𗘗p���� 'use'</desc> <defs> <symbol id="MySymbol" viewBox="0 0 20 20"> <desc>MySymbol - �i�q��ɕ��ԂS��`</desc> <rect x="1" y="1" width="8" height="8"/> <rect x="11" y="1" width="8" height="8"/> <rect x="1" y="11" width="8" height="8"/> <rect x="11" y="11" width="8" height="8"/> </symbol> </defs> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <use x="45" y="10" width="10" height="10" xlink:href="#MySymbol" /> </svg>
![]() |
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
���o���ʂɂ����Ă͎��Ɠ����ɂȂ�F
The visual effect would be equivalent to the following document:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" xmlns="http://www.w3.org/2000/svg" version="1.1"> <desc>Example Use02-GeneratedContent - 'symbol' �𗘗p���� 'use'</desc> <!-- 'defs' ���͏ȗ� --> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <!-- 'use' ��u�������鐶�����e�͂������� --> <g transform="translate(45, 10)" > <!-- ��������͎Q�Ɛ�� 'symbol'�B 'symbol' �� x,y,width,height=0,0,100%,100% �ɐݒ肳�ꂽ 'svg' �ɒu�������--> <svg width="10" height="10" viewBox="0 0 20 20"> <rect x="1" y="1" width="8" height="8"/> <rect x="11" y="1" width="8" height="8"/> <rect x="1" y="11" width="8" height="8"/> <rect x="11" y="11" width="8" height="8"/> </svg> <!-- �����܂ł��Q�Ɛ�� 'symbol' --> </g> <!-- �����܂ł��������e --> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
Example Use03 �� 'use' �v�f�� transform ���������Ƃ��ǂ̂悤�Ȍ��ʂ������邩�������F
Example Use03 illustrates what happens when a 'use' has a transform attribute.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <desc>Example Use03 - 'transform' ���������� 'use' </desc> <defs> <rect id="MyRect" x="0" y="0" width="60" height="10"/> </defs> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <use xlink:href="#MyRect" transform="translate(20,2.5) rotate(10)" /> </svg>
![]() |
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
���o���ʂɂ����Ă͎��Ɠ����ɂȂ�F
The visual effect would be equivalent to the following document:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="10cm" height="3cm" viewBox="0 0 100 30" xmlns="http://www.w3.org/2000/svg" version="1.1"> <desc>Example Use03-GeneratedContent - 'transform' ���������� 'use' </desc> <!-- 'defs' ���͏ȗ� --> <rect x=".1" y=".1" width="99.8" height="29.8" fill="none" stroke="blue" stroke-width=".2" /> <!-- 'use' ��u�������鐶�����e�͂������� --> <g transform="translate(20,2.5) rotate(10)"> <rect x="0" y="0" width="60" height="10"/> </g> <!-- �������e�͂����܂� --> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
Example Use04 �� 'use' �v�f�ɑ����X�� CSS �ɂ��X�^�C���t���̓K�p�������F
Example Use04 illustrates a 'use' element with various methods of applying CSS styling.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="12cm" height="3cm" viewBox="0 0 1200 300" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <desc>Example Use04 - 'use' �ɑ��� CSS �ɂ��X�^�C���t��</desc> <defs style=" /* �K�� 9 */ stroke-miterlimit: 10" > <path id="MyPath" d="M300 50 L900 50 L900 250 L300 250" class="MyPathClass" style=" /* �K�� 10 */ stroke-dasharray:300,100" /> </defs> <style type="text/css"> <![CDATA[ /* �K�� 1 */ #MyUse { fill: blue } /* �K�� 2 */ #MyPath { stroke: red } /* �K�� 3 */ use { fill-opacity: .5 } /* �K�� 4 */ path { stroke-opacity: .5 } /* �K�� 5 */ .MyUseClass { stroke-linecap: round } /* �K�� 6 */ .MyPathClass { stroke-linejoin: bevel } /* �K�� 7 */ use > path { shape-rendering: optimizeQuality } /* �K�� 8 */ g > path { visibility: hidden } ]]> </style> <rect x="0" y="0" width="1200" height="300" style="fill:none; stroke:blue; stroke-width:3"/> <g style=" /* �K�� 11 */ stroke-width:40"> <use id="MyUse" xlink:href="#MyPath" class="MyUseClass" style="/* �K�� 12 */ stroke-dashoffset:50" /> </g> </svg>
![]() |
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
���o���ʂɂ����Ă͉��Ɏ������̂Ɠ����ɂȂ�B�X�^�C���K���̂����ꕔ�i�K�� 1-6, �K�� 10-12 �j�͐������e�ɔ��f����A����ȊO�i�K�� 7-9 �j�͔��f����Ȃ����Ƃ��m�F���ꂽ���B�������e�ɔ��f����Ȃ��K���Ƃ́F
The visual effect would be equivalent to the following document. Observe that some of the style rules above apply to the generated content (i.e., rules 1-6, 10-12), whereas others do not (i.e., rules 7-9). The rules which do not affect the generated content are:
��̂��߂̕X��A���̐������e�ł͗L���ȃZ���N�^�� 'style' �����Ƃ��ăC�����C�������Ă���B
In the generated content below, the selectors that yield a match have been transferred into inline 'style' attributes for illustrative purposes.
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="12cm" height="3cm" viewBox="0 0 1200 300" xmlns="http://www.w3.org/2000/svg" version="1.1"> <desc>Example Use04-GeneratedContent - 'use' �ɑ��� CSS �ɂ��X�^�C���t��</desc> <!-- 'style' ���� 'defs' ���͏ȗ� --> <rect x="0" y="0" width="1200" height="300" style="fill:none; stroke:blue; stroke-width:3"/> <g style="/* �K�� 11 */ stroke-width:40"> <!-- 'use' ��u�������鐶�����e�͂������� --> <g style="/* �K�� 1 */ fill:blue; /* �K�� 3 */ fill-opacity:.5; /* �K�� 5 */ stroke-linecap:round; /* �K�� 12 */ stroke-dashoffset:50" > <path d="M300 50 L900 50 L900 250 L300 250" style="/* �K�� 2 */ stroke:red; /* �K�� 4 */ stroke-opacity:.5; /* �K�� 6 */ stroke-linejoin: bevel; /* �K�� 10 */ stroke-dasharray:300,100" /> </g> <!-- �������e�͂����܂� --> </g> </svg>
���̗�� SVG �Ō���i SVG �Ή��u���E�U�̂݁j
'use' �v�f������ 'use' �v�f�������� 'use' �v�f����e�Ɏ����̗v�f���Q�Ƃ���ꍇ�A��ŏq�ׂ����[�܂ł̕��������͍ċA�I�ɍs����B�������Ȃ���A�Q�Ƃɂ��A�������ړI���ԐړI�����킸�z�����ꍇ�́A �Q�Ƃ� 'defs' �v�f �ŏq�ׂ��悤�ɃG���[�Ƃ݂Ȃ����B
When a 'use' references another element which is another 'use' or whose content contains a 'use' element, then the deep cloning approach described above is recursive. However, a set of references that directly or indirectly reference a element to create a circular dependency is an error, as described in References and the 'defs' element.
<!ENTITY % SVG.use.extra.content "" > <!ENTITY % SVG.use.element "INCLUDE" > <![%SVG.use.element;[ <!ENTITY % SVG.use.content "(( %SVG.Description.class; )*, ( %SVG.Animation.class; %SVG.use.extra.content; )*)" > <!ELEMENT %SVG.use.qname; %SVG.use.content; > <!-- end of SVG.use.element -->]]> <!ENTITY % SVG.use.attlist "INCLUDE" > <![%SVG.use.attlist;[ <!ATTLIST %SVG.use.qname; %SVG.Core.attrib; %SVG.Conditional.attrib; %SVG.Style.attrib; %SVG.Presentation.attrib; %SVG.GraphicalEvents.attrib; %SVG.XLinkEmbed.attrib; %SVG.External.attrib; x %Coordinate.datatype; #IMPLIED y %Coordinate.datatype; #IMPLIED width %Length.datatype; #IMPLIED height %Length.datatype; #IMPLIED transform %TransformList.datatype; #IMPLIED > |
������`�F
'image' �v�f�̓t�@�C���̊��S�Ȓ��g�����݂̗��p���W�n�̗^����ꂽ��`�̈�ɕ`�悳���邱�Ƃ��w������B 'image' �v�f�� PNG �� JPEG �Ȃǂ̃��X�^�[�摜�̃t�@�C�����邢�́A MIME �^�C�v�� "image/svg+xml" �̃t�@�C�����Q�Ƃ��邱�Ƃ��ł���B �K�� SVG �r���[�A �͏��Ȃ��Ƃ� PNG, JPEG, SVG �`���̃t�@�C�����T�|�[�g����K�v������B
The 'image' element indicates that the contents of a complete file are to be rendered into a given rectangle within the current user coordinate system. The 'image' element can refer to raster image files such as PNG or JPEG or to files with MIME type of "image/svg+xml". Conforming SVG viewers need to support at least PNG, JPEG and SVG format files.
'image' �v�f�̏������ʂ͕K���S�`�����l�� RGBA �ł���B 'image' �v�f���R�`�����l���i RGB �j�݂̂������X�^�[�摜�̃t�@�C�����Q�Ƃ����ꍇ�A�A���t�@�l����l�ɂP�ɂ��ꂽ�S�`�����l�� RGBA �ɕϊ������B�P�`�����l���݂̂̃��X�^�[�摜�̏ꍇ�A�R�̐F�`�����l���i RGB �j�̒l�����̂P�`�����l���̒l����v�Z����A�A���t�@�`�����l������l�ɂP�ɂ��ꂽ�S�`�����l�� RGBA �ɕϊ������B
The result of processing an 'image' is always a four-channel RGBA result. When an 'image' element references a raster image file such as PNG or JPEG files which only has three channels (RGB), then the effect is as if the object were converted into a 4-channel RGBA image with the alpha channel uniformly set to 1. For a single-channel raster image, the effect is as if the object were converted into a 4-channel RGBA image, where the single channel from the referenced object is used to compute the three color channels and the alpha channel is uniformly set to 1.
'image' �v�f�͐V�K�̃r���[�|�[�g�� �V�����r���[�|�[�g�̊m�� �ŏq�ׂ���悤�ɂ��Ċm������B�r���[�|�[�g�̋��E�͑��� x, y, width, height �Ŏw�肳���B�Q�Ɛ�̉摜�̔z�u��L�k���� 'image' �v�f�� preserveAspectRatio �����Ő��䂳���B
An 'image' element establishes a new viewport for the referenced file as described in Establishing a new viewport. The bounds for the new viewport are defined by attributes x, y, width and height. The placement and scaling of the referenced image are controlled by the preserveAspectRatio attribute on the 'image' element.
'image' �v�f�� SVG �摜���Q�Ƃ���ꍇ�A SVG �摜�̃��[�g�v�f�� preserveAspectRatio ����, clip, overflow �v���p�e�B�͖��������i x, y, width, height ���������������̂Ɠ����悤�Ɂj�B���̂����A�Q�Ƃ��� 'image' �v�f�� preserveAspectRatio ����, clip, overflow �v���p�e�B���A SVG �摜���ǂ̂悤�Ƀr���[�|�[�g�ɂ͂ߍ��݁A�ǂ̂悤�ɃN���b�s���O���邩���Ȃ��������肷��B
When an 'image' element references an SVG image the preserveAspectRatio attribute as well as the clip and overflow properties on the root element in the referenced SVG image are ignored (in the same manner as the x, y, width and height attributes are ignored). Instead, the preserveAspectRatio attribute on the referencing 'image' element defines how the SVG image content is fitted into the viewport and the clip and overflow properties on the 'image' element define how the SVG image content is clipped (or not) relative to the viewport.
preserveAspectRatio ������]������Ƃ��ɗ��p����� viewBox �����̒l�͎Q�Ɛ�̓��e�Œ�`�����B������ viewBox �������e�i�Ⴆ�� viewBox ������ �ł��O���� svg �v�f �Ɏw�肳��Ă��� SVG �t�@�C���j�Ȃ�A���̒l�����p�����ׂ��ł���B�قƂ�ǂ̃��X�^�[�摜�i PNG, JPEG �j�ł͉摜�̑傫�������p�����ׂ��ł���i���� 'image' �v�f�͈Öق� viewBox �̒l�F "0, 0, ���X�^�[�摜�̕�, ���X�^�[�摜�̍���" �����j�B�l���w�肳��Ă��Ȃ��ꍇ�i�Ⴆ�� viewBox ������ �ł��O���� svg �v�f �Ɏw�肳��Ă��Ȃ� SVG �t�@�C���j preserveAspectRatio �����͖�������A�r���[�|�[�g�� x, y �����ɂ��ϊ��݂̂����e�̕\���ɗp������B
The value of the ' viewBox' attribute to use when evaluating the preserveAspectRatio attribute is defined by the referenced content. For content that clearly identifies a viewBox (e.g. an SVG file with the ' viewBox' attribute on the outermost svg element) that value should be used. For most raster content (PNG, JPEG) the bounds of the image should be used (i.e. the 'image' element has an implicit 'viewBox' of "0 0 raster-image-width raster-image-height"). Where no value is readily available (e.g. an SVG file with no ' viewBox' attribute on the outermost 'svg' element) the preserveAspectRatio attribute is ignored, and only the translate due to the ' x' & ' y' attributes of the viewport is used to display the content.
�Ⴆ�� image �v�f�� PNG �� JPEG ���Q�Ƃ��A
preserveAspectRatio="xMinYMin meet"
�Ǝw�肳��Ă���Ȃ�A���X�^�[�ɂ�����c����͕ۂ����i�摜�̍��W�n���猻�݂̗��p���W�n�ւ̂w�������Ƃx�������̐L�k���͓������Ȃ�j�B���X�^�[��
'image'
�v�f�̑���
x,
y,
width,
height
�Œ�܂�r���[�|�[�g�Ɏ��܂�͈͓��܂ʼn\�Ȍ���傫������A���X�^�[�̍���[�̓r���[�|�[�g�̍���[�ɍ��킹����B����
preserveAspectRatio
�̒l�� 'none'�ł���Ή摜�̏c����͈ێ�����Ȃ��B�摜�̓��X�^�[�̍���[�����W
(x,
y)
�ɁA���X�^�[�̉E���[�����W
(x +
width,
y +
height)
�ɐ��m�ɑ����悤�ɂ͂ߍ��܂��B
'image'
�v�f�ɎQ�Ƃ���郊�\�[�X�͕ʌ̑�����ǖƁi���\�[�X�� XML �Ȃ�j�����I�u�W�F�N�g���f�������ʌ̕�����\������B���������Ă��̉摜�ւ̃v���p�e�B�p���͖����B
For example, if the image element referenced a PNG or JPEG and preserveAspectRatio="xMinYMin meet", then the aspect ratio of the raster would be preserved (which means that the scale factor from image's coordinates to current user space coordinates would be the same for both X and Y), the raster would be sized as large as possible while ensuring that the entire raster fits within the viewport, and the top/left of the raster would be aligned with the top/left of the viewport as defined by the attributes '
x', '
y', '
width' and '
height' on the 'image' element. If the value of
preserveAspectRatio was 'none' then aspect ratio of the image would not be preserved. The image would be fitted such that the top/left corner of the raster exactly aligns with coordinate (
x,
y) and the bottom/right corner of the raster exactly aligns with coordinate (
x+
width,
y+
height).
The resource referenced by the 'image' element represents a separate document which generates its own parse tree and document object model (if the resource is XML). Thus, there is no inheritance of properties into the image.
'use' �v�f�Ƃ͈قȂ�A 'image' �v�f�� SVG �t�@�C�����̗v�f���Q�Ƃ��邱�Ƃ͂ł��Ȃ��B
Unlike 'use', the 'image' element cannot reference elements within an SVG file.
<!ENTITY % SVG.Image.extra.class "" > <!ENTITY % SVG.Image.class "| %SVG.image.qname; %SVG.Image.extra.class;" > <!-- image: Image Element .............................. --> <!ENTITY % SVG.image.extra.content "" > <!ENTITY % SVG.image.element "INCLUDE" > <![%SVG.image.element;[ <!ENTITY % SVG.image.content "(( %SVG.Description.class; )*, ( %SVG.Animation.class; %SVG.image.extra.content; )*)" > <!ELEMENT %SVG.image.qname; %SVG.image.content; > <!-- end of SVG.image.element -->]]> <!ENTITY % SVG.image.attlist "INCLUDE" > <![%SVG.image.attlist;[ <!ATTLIST %SVG.image.qname; %SVG.Core.attrib; %SVG.Conditional.attrib; %SVG.Style.attrib; %SVG.Viewport.attrib; %SVG.Color.attrib; %SVG.Opacity.attrib; %SVG.Graphics.attrib; %SVG.ColorProfile.attrib; %SVG.Clip.attrib; %SVG.Mask.attrib; %SVG.Filter.attrib; %SVG.GraphicalEvents.attrib; %SVG.Cursor.attrib; %SVG.XLinkEmbed.attrib; %SVG.External.attrib; x %Coordinate.datatype; #IMPLIED y %Coordinate.datatype; #IMPLIED width %Length.datatype; #REQUIRED height %Length.datatype; #REQUIRED preserveAspectRatio %PreserveAspectRatioSpec.datatype; 'xMidYMid meet' transform %TransformList.datatype; #IMPLIED > |
������`�F
��F
An example:
<?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> <svg width="4in" height="3in" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <desc>���̃O���t�B�b�N�͊O���̉摜�փ����N���� </desc> <image x="200" y="200" width="100px" height="100px" xlink:href="myimage.png"> <title>My image</title> </image> </svg>
SVG �� 'switch' �v�f�� requiredFeatures, requiredExtensions, systemLanguage ������p���Ăt�`�̔\�͂◘�p�҂̌�����ɉ�������֕\�����w�肷�邽�߂̋@�\�����B
SVG contains a 'switch' element along with attributes requiredFeatures, requiredExtensions and systemLanguage to provide an ability to specify alternate viewing depending on the capabilities of a given user agent or the user's language.
<!ENTITY % SVG.Conditional.extra.attrib "" > <!ENTITY % SVG.Conditional.attrib "requiredFeatures %FeatureList.datatype; #IMPLIED requiredExtensions %ExtensionList.datatype; #IMPLIED systemLanguage %LanguageCodes.datatype; #IMPLIED %SVG.Conditional.extra.attrib;" > |
requiredFeatures, requiredExtensions, systemLanguage �����͈��̃e�X�g�̂悤�ɓ������̂ł���A�^�܂��͋U�̒l��Ԃ��B 'switch' �v�f�͂��̎q�v�f�̂��������̑������S�Đ^�ƕ]�������ŏ��̎q�v�f�݂̂�`�悷��B�����̑����̂����^�����Ă��Ȃ����̂�����A�����̑����ɂ��Ă̕]���͐^�ł�����̂Ƃ݂Ȃ����B
Attributes requiredFeatures, requiredExtensions and systemLanguage act as tests and return either true or false results. The 'switch' renders the first of its children for which all of these attributes test true. If the given attribute is not specified, then a true value is assumed.
'display'�v���p�e�B�Ɠ��l�A�����̏����t�����������͗v�f�̒��ړI�`��ɂ̂݉e�����A�i 'use' �v�f�Ȃǂɂ��j�v�f����v�f�ւ̎Q�Ƃɂ͊֗^���Ȃ��B
Similar to the 'display' property, conditional processing attributes only affect the direct rendering of elements and do not prevent elements from being successfully referenced by other elements (such as via a 'use').
�䂦�ɁF
In consequence:
'switch' �v�f�͂��̒��ڂ̎q�v�f�ɑ����� requiredFeatures, requiredExtensions, systemLanguage ������]�����A�����̑��������ׂĐ^�ƂȂ�ŏ��̎q�v�f�ɑ��Ă݂̂��̏����ƕ`����s���B���̗v�f�͖�������A�`�悳��Ȃ��B�q�v�f�� 'g' �ł������Ƃ��Ă������ؑS�̂���������邩��������A�]���ĕ`�悳��邩����Ȃ����̂ǂ��炩�ɂȂ�B
The 'switch' element evaluates the requiredFeatures, requiredExtensions and systemLanguage attributes on its direct child elements in order, and then processes and renders the first child for which these attributes evaluate to true. All others will be bypassed and therefore not rendered. If the child element is a container element such as a 'g', then the entire subtree is either processed/rendered or bypassed/not rendered.
���ӁF 'display', 'visibility' �v���p�e�B�̒l�� 'switch' �v�f�̏����ɂ͉e�����Ȃ��B���ɁA 'switch' �v�f�̎q�� 'display' �� none �ɐݒ肵�Ă� 'switch' �v�f�ɂ��^�U�e�X�g�ɂ͖��W�ł���B
Note that the values of properties 'display' and 'visibility' have no effect on 'switch' element processing. In particular, setting 'display' to none on a child of a 'switch' element has no effect on true/false testing associated with 'switch' element processing.
<!ENTITY % SVG.switch.extra.content "" > <!ENTITY % SVG.switch.element "INCLUDE" > <![%SVG.switch.element;[ <!ENTITY % SVG.switch.content "(( %SVG.Description.class; )*, ( %SVG.svg.qname; | %SVG.g.qname; | %SVG.use.qname; | %SVG.text.qname; | %SVG.Animation.class; %SVG.Conditional.class; %SVG.Image.class; %SVG.Shape.class; %SVG.Hyperlink.class; %SVG.Extensibility.class; %SVG.switch.extra.content; )*)" > <!ELEMENT %SVG.switch.qname; %SVG.switch.content; > <!-- end of SVG.switch.element -->]]> <!ENTITY % SVG.switch.attlist "INCLUDE" > <![%SVG.switch.attlist;[ <!ATTLIST %SVG.switch.qname; %SVG.Core.attrib; %SVG.Conditional.attrib; %SVG.Style.attrib; %SVG.Presentation.attrib; %SVG.GraphicalEvents.attrib; %SVG.External.attrib; transform %TransformList.datatype; #IMPLIED > |
���̗�ɂ��Ă̏ڍׂ� �O���̌^�̃I�u�W�F�N�g�̖��ߍ��� ������B
For more information and an example, see Embedding foreign object types.
requiredFeatures �̒�`�F
Definition of requiredFeatures:
���̑������^�����Ă��Ȃ��Ƃ��͈Öقɐ^�ƕ]�������B���̑����� null ������܂��͋��w�肳�ꂽ�ꍇ�A�U�ƕ]�������B
If the attribute is not present, then its implicit return value is "true". If a null string or empty string value is given to attribute requiredFeatures, the attribute returns "false".
requiredFeatures �͒ʏ� 'switch' �v�f�Ɣ��ɗp������B requiredFeatures �����̋ǖʂŗp����ꂽ�ꍇ�A���̗v�f��`�悷�邩�^���Ȃ����̒P���ȃX�C�b�`�ɂȂ�B
requiredFeatures is often used in conjunction with the 'switch' element. If the requiredFeatures is used in other situations, then it represents a simple switch on the given element whether to render the element or not.
requiredExtensions �����͕K�v�Ȍ���g���̃��X�g���w�肷��B����g���͂��̎d�l�Œ�߂��Ă�����F�@�\�͈̔͊O�ł���A�t�`�̋@�\�̔��e�ł���B�X�̌���g���� URI �Q�� �Ŏw�肳���B
The requiredExtensions attribute defines a list of required language extensions. Language extensions are capabilities within a user agent that go beyond the feature set defined in this specification. Each extension is identified by a URI reference.
requiredExtensions �̒�`�F
Definition of requiredExtensions:
�^����ꂽ URI �Q�� �����܂ޏꍇ�A�G�X�P�[�v����Ȃ���Ȃ�Ȃ��B
If a given URI reference contains white space within itself, that white space must be escaped.
���̑������^�����Ă��Ȃ��Ƃ��͈Öقɐ^�ƕ]�������B���̑����� null ������܂��͋��w�肳�ꂽ�ꍇ�A�U�ƕ]�������B
If the attribute is not present, then its implicit return value is "true". If a null string or empty string value is given to attribute requiredExtensions, the attribute returns "false".
requiredExtensions �͒ʏ� 'switch' �v�f�Ɣ��ɗp������B requiredExtensions �����̋ǖʂŗp����ꂽ�ꍇ�A���̗v�f��`�悷�邩�^���Ȃ����̒P���ȃX�C�b�`�ɂȂ�B
requiredExtensions is often used in conjunction with the 'switch' element. If the requiredExtensions is used in other situations, then it represents a simple switch on the given element whether to render the element or not.
�g���� URI ���̓X�N���v�g�̏����肪�قȂ�o�[�W��������ʂł���悤
"http://example.org/SVGExtensionXYZ/1.0"
�Ȃǂ̂悤�Ƀo�[�W���������܂߂�ׂ��ł���B
The URI names for the extension should include versioning information, such as "http://example.org/SVGExtensionXYZ/1.0", so that script writers can distinguish between different versions of a given extension.
���̑����̒l�� [RFC3066] �Œ�`���ꂽ���ꖼ�̃R���}���̃��X�g�ł���B
The attribute value is a comma-separated list of language names as defined in [ RFC3066].
���p�҂̊��Őݒ肳��Ă��錾��̈���A���̑����Ŏw�肳�ꂽ����i�̕�����j�A���邢�͂��̐ړ����i�ړ����ɑ����ŏ��̃^�O��蕶���� "-"�j�Ɋ��S�Ɉ�v����ΐ^�ƕ]�������B
Evaluates to "true" if one of the languages indicated by user preferences exactly equals one of the languages given in the value of this parameter, or if one of the languages indicated by user preferences exactly equals a prefix of one of the languages given in the value of this parameter such that the first tag character following the prefix is "-".
���̏ꍇ�͋U�ƕ]�������B
Evaluates to "false" otherwise.
���ӁF���̈�v�K���̗��p�����邩��ƌ����āA����ɑ��錾��^�O�̊��蓖�Ă��A���p�҂��Ȃ�炩�̃^�O�̌���𗝉�����Ȃ�A���̃^�O��ړ��q�Ƃ��邷�ׂẴ^�O�̌���ɂ��Ă������ł��邱�Ƃ�K���������悤�ɍs���Ă��邱�Ƃ��킯�ł͂Ȃ��B
Note: This use of a prefix matching rule does not imply that language tags are assigned to languages in such a way that it is always true that if a user understands a language with a certain tag, then this user will also understand all languages with tags for which this tag is a prefix.
���̐ړ��q��v�K���͒P���ɂ��̂悤�Ȏg���������e������̂ł���B
The prefix rule simply allows the use of prefix tags if this is the case.
�����ɂ����钍�ӁF����ɂ��ė��p�҂̚n�D�ɂ��ݒ���\�ɂ���ꍇ�A�����҂́u���p�҂���L�̌����v�K���̏ڍׂɂ��Ēm��Ȃ��v�Ƃ������Ƃ�O���ɒu���āA�K�ȃK�C�h����ׂ��ł���B�Ⴆ�A���p�҂́u "en-gb" ��I�����Ă����ΑS�Ẳp�ꕶ���͉p���p��łȂ��Ƃ����p�ł���v�ƍl���邩������Ȃ��B����ݒ�̃��[�U�[�C���^�[�t�F�[�X�ł́u�ŗǂ̌����v�̂��߂ɂ́i"en-gb" �ɉ����āj"en" ���lj����ׂ��ł���v�Ƃ������Ƃ��������ׂ��ł���B
Implementation note: When making the choice of linguistic preference available to the user, implementers should take into account the fact that users are not familiar with the details of language matching as described above, and should provide appropriate guidance. As an example, users may assume that on selecting "en-gb", they will be served any kind of English document if British English is not available. The user interface for setting user preferences should guide the user to add "en" to get the best matching behavior.
�����l�ɂ�铯���������Ӑ}�������e�̂��߂ɕ����̌�����܂߂Ă��悢�B�Ⴆ�A�I���W�i���̃}�I����ɉ����ē����ɉp����\���ł�����e�͎��̂悤�ɏ������ł��낤�F
Multiple languages MAY be listed for content that is intended for multiple audiences. For example, content that is presented simultaneously in the original Maori and English versions, would call for:
<text systemLanguage="mi, en"><!-- content
goes here --></text>
�������Ȃ���A systemLanguage �e�X�g�����̕t�����I�u�W�F�N�g�ɕ����̌��ꂪ�p�ӂ���Ă��邩��Ƃ����āA�����̌���̎����҂Ɍ��������̂ɂȂ�Ƃ͌���Ȃ��B�Ⴆ�u�p����u�v�̗l�ȓ��{��ǎҌ����ł��邱�Ƃ������ȏ��S�Ҍ����̌������ȂǁB���̂悤�ȏꍇ�AsystemLanguage �e�X�g������ "ja" �݂̂��܂ނׂ��ł���B
However, just because multiple languages are present within the object on which the systemLanguage test attribute is placed, this does not mean that it is intended for multiple linguistic audiences. An example would be a beginner's language primer, such as "A First Lesson in Latin," which is clearly intended to be used by an English-literate audience. In this case, the systemLanguage test attribute should only include "en".
�����쐬�҂ւ̒��ӁF�����쐬�҂� 'switch' �v�f�Ɋ܂܂�Ă��镡���̑����̃I�u�W�F�N�g���ǂ���\������Ȃ��\�����l���ɓ���Ă����ׂ��ł���B���������� 'switch' �v�f�̍Ō�ɁA�����Ȃ�ꍇ�ł��������u���\�I��v���܂߂邱�Ƃ����������B
Authoring note: Authors should realize that if several alternative language objects are enclosed in a 'switch', and none of them matches, this may lead to situations where no content is displayed. It is thus recommended to include a "catch-all" choice at the end of such a 'switch' which is acceptable in all cases.
systemLanguage �����ł́A �A�j���[�V�����F�s��
For the systemLanguage attribute: Animatable: no.
���̑������^�����Ă��Ȃ��Ƃ��͈Öقɐ^�ƕ]�������B���̑����� null ������܂��͋��w�肳�ꂽ�ꍇ�A�U�ƕ]�������B
If the attribute is not present, then its implicit return value is "true". If a null string or empty string value is given to attribute systemLanguage, the attribute returns "false".
systemLanguage �͒ʏ� 'switch' �v�f�Ɣ��ɗp������B systemLanguage �����̋ǖʂŗp����ꂽ�ꍇ�A���̗v�f��`�悷�邩�^���Ȃ����̒P���ȃX�C�b�`�ɂȂ�B
systemLanguage is often used in conjunction with the 'switch' element. If the systemLanguage is used in other situations, then it represents a simple switch on the given element whether to render the element or not.
���ړI�ɕ`�悳��Ȃ��v�f�ɑ���e�X�g�����̓K�p�����ȉ��ɗ���B
The following list describes the applicability of the test attributes to the elements that do not directly produce rendering.
�����͂����Α��̃t�@�C���i���̃E�F�u���\�[�X�j���Q�Ƃ��ĕ`��̈ꕔ�Ƃ��ė��p����B�����쐬�҂ɂƂ��ẮA���̃��\�[�X�̑��݂������̐������Ɍ������Ȃ����ǂ������w��ł��邱�Ƃ��]�܂����ꍇ������B
Documents often reference and use the contents of other files (and other Web resources) as part of their rendering. In some cases, authors want to specify that particular resources are required for a document to be considered correct.
externalResourcesRequired �����͑S�ẴR���e�i�v�f�ƁA�O�����\�[�X���Q�Ƃ�����S�Ă̗v�f�ɗ��p�ł���B�Q�Ɛ�̊O�����\�[�X���A�^����ꂽ�R���e�i�v�f�^�O���t�B�b�N�X�v�f�̐����ȕ`��Ɍ������Ȃ����ǂ��������̑����Ŏw��ł���B
Attribute externalResourcesRequired is available on all container elements and to all elements which potentially can reference external resources. It specifies whether referenced resources that are not part of the current document are required for proper rendering of the given container element or graphics element.
������`�F
Attribute definition:
���̑����́A�X�^�C���V�[�g, �J���[�v���t�@�C���i �J���[�v���t�@�C���L�q ������j, 'font-face' �v�f�ɂ�� URI �Q�� �Ŏw�肳���t�H���g, CSS @font-face �Ŏw�肳���t�H���g���܂ށA�S�Ă̎�ނ̃��\�[�X�Q�ƂɓK�p�ł���B���� externalResourcesRequired="true" �Ɛݒ肳�ꂽ�v�f�����݂���ꍇ�A�S�ẴX�^�C���V�[�g�����p�\�łȂ���Ȃ�Ȃ��B�Ȃ��Ȃ�A�ǂ̃X�^�C���V�[�g���v�f�̕`��ɉe�������邩��ł���B
This attribute applies to all types of resource references, including style sheets, color profiles (see Color profile descriptions) and fonts specified by a URI reference using a 'font-face' element or a CSS @font-face specification. In particular, if an element sets externalResourcesRequired="true", then all style sheets must be available since any style sheet might affect the rendering of that element.
externalResourcesRequired �����́i�����l�̌p���̈Ӗ��Łj�p���ł��Ȃ����A�R���e�i�v�f�Ɏg�p���ꂽ�ꍇ�͊܂܂��S�Ă̗v�f�ɓK�p�����B
Attribute externalResourcesRequired is not inheritable (from a sense of attribute value inheritance), but if set on a container element, its value will apply to all elements within the container.
�R���e�i�v�f�� externalResourcesRequired="true" ���w�肷��ƁA�R���e�i�̓��e�̑Q�i�I�ȕ\���������ɂȂ�B �i �G���[�^ �F�R���e�i���O�����\�[�X���Q�Ƃ���v�f���܂ތ���ɂ����āB�j SVG ���e������c�[���ނ́A�ʏ�̈�ʓ���Ƃ��ĒP�� �ł��O���� svg �v�f �� externalResourcesRequired="true" ���w�肷��悤�Ȃ��Ƃ͔�����ׂ��ł���A�O�����\�[�X�̑��݂��`��̐������ɓ��Ɍ������Ȃ��悤�ȓ���̃O���t�B�b�N�X�v�f��R���e�i�v�f�ɑ��Ă̂݁A externalResourcesRequired="true" ���w�肷������D�܂����B
Because setting externalResourcesRequired="true" on a container element can have the effect of disabling progressive display of the contents of that container, tools that generate SVG content are cautioned against using simply setting externalResourcesRequired="true" on the outermost 'svg' element on a universal basis. Instead, it is better to specify externalResourcesRequired="true" on those particular graphics elements or container elements which specify need the availability of external resources in order to render properly.
externalResourcesRequired �ł́A �A�j���[�V�����F�s��
For externalResourcesRequired: Animatable: no.
id �� xml:base �����͑S�Ă� SVG �v�f�ŗ��p�ł���F
The id and xml:base attributes are available on all SVG elements:
������`�F
�����f�[�^���e���܂ݓ���v�f�� xml:lang ������ xml:space �����������Ƃ��ł���F
Elements that might contain character data content have attributes xml:lang and xml:space:
<!ENTITY % SVG.id.attrib "id ID #IMPLIED" > <!ENTITY % SVG.base.attrib "xml:base %URI.datatype; #IMPLIED" > <!ENTITY % SVG.lang.attrib "xml:lang %LanguageCode.datatype; #IMPLIED" > <!ENTITY % SVG.space.attrib "xml:space ( default | preserve ) #IMPLIED" > <!ENTITY % SVG.Core.extra.attrib "" > <!ENTITY % SVG.Core.attrib "%SVG.id.attrib; %SVG.base.attrib; %SVG.lang.attrib; %SVG.space.attrib; %SVG.Core.extra.attrib;" > |
������`�F
Core �������W���[���͑S�Ă̗v�f�ɕt���ł��钆�j�I�ȑ����̏W�� Core.attrib ���`����B
�R���N�V������ | �R���N�V�����Ɋ܂܂�鑮�� |
---|---|
Core.attrib | id, xml:base, xml:lang, xml:space |
�v�f | ���� | ���e���f�� |
---|---|---|
svg | Core.attrib, Conditional.attrib, Style.attrib, x, y, width, height, viewBox, preserveAspectRatio, zoomAndPan, version, baseProfile, contentScriptType, contentStyleType, External.attrib, Presentation.attrib, GraphicalEvents.attrib, DocumentEvents.attrib | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
g | Core.attrib, Conditional.attrib, Style.attrib, External.attrib, Presentation.attrib, GraphicalEvents.attrib, transform | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
defs | Core.attrib, Conditional.attrib, Style.attrib, External.attrib, Presentation.attrib, GraphicalEvents.attrib, transform | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
desc | Core.attrib, Style.attrib | (PCDATA)* |
title | Core.attrib, Style.attrib | (PCDATA)* |
metadata | Core.attrib | (PCDATA)* |
symbol | Core.attrib, Style.attrib, External.attrib, viewBox, preserveAspectRatio, Presentation.attrib, GraphicsElementEventAttrs | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
use | Core.attrib, Style.attrib, Conditional.attrib, transform, x, y, width, height, XLinkEmbed.attrib, Presentation.attrib, GraphicsElementEventAttrs | (Description.class | Animation.class)* |
�v�f | ���� | ���e���f�� |
---|---|---|
svg | Core.attrib, Conditional.attrib, Style.attrib, x, y, width, height, viewBox, preserveAspectRatio, zoomAndPan, version, baseProfile, External.attrib, Presentation.attrib, GraphicalEvents.attrib, DocumentEvents.attrib | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
g | Core.attrib, Conditional.attrib, Style.attrib, External.attrib, Presentation.attrib, GraphicalEvents.attrib, transform | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
defs | Core.attrib, Conditional.attrib, Style.attrib, External.attrib, Presentation.attrib, GraphicalEvents.attrib, transform | (Description.class | Structure.class | Shape.class | Image.class | View.class | Conditional.class | Hyperlink.class | Text.class | Script.class | Style.class | Marker.class | Clip.class | Mask.class | Gradient.class | Pattern.class | Filter.class | Cursor.class | Font.class | Animation.class | ColorProfile.class)* |
desc | Core.attrib, Style.attrib | (PCDATA)* |
title | Core.attrib, Style.attrib | (PCDATA)* |
metadata | Core.attrib | (PCDATA)* |
use | Core.attrib, Style.attrib, Conditional.attrib, transform, x, y, width, height, XLinkEmbed.attrib, Presentation.attrib, GraphicsElementEventAttrs | (Description.class | Animation.class)* |
Container �������W���[���� Container.attrib �����Z�b�g���`����B
�R���N�V������ | �R���N�V�����Ɋ܂܂�鑮�� |
---|---|
Container.attrib | enable-background |
�v�f | ���� | ���e���f�� |
---|---|---|
switch | Core.attrib, Conditional.attrib, External.attrib, Style.attrib, transform, Presentation.attrib, GraphicalEvents.attrib | (Description.class | Shape.class | Text.class | Structure.class | Image.class | Hyperlink.class | Extensibility.class | Animation.class)* |
Conditional Processing ���W���[���� Conditional.class ���e�Z�b�g���`����B
���e�Z�b�g�� | ���e�Z�b�g�Ɋ܂܂��v�f |
---|---|
Conditional.class | switch |
Conditional Processing ���W���[���� Conditional.attrib �����Z�b�g���`����B
�R���N�V������ | �R���N�V�����Ɋ܂܂�鑮�� |
---|---|
Conditional.attrib | requiredFeatures, requiredExtensions, systemLanguage |
�v�f | ���� | ���e���f�� |
---|---|---|
image | Core.attrib, XLinkEmbed.attrib, Conditional.attrib, Style.attrib, External.attrib, GraphicalEvents.attrib, preserveAspectRatio, Paint.attrib, Opacity.attrib, Graphics.attrib, Cursor.attrib, Filter.attrib, Mask.attrib, GraphicalEvents.attrib, Clip.attrib, Profile.attrib, Viewport.attrib, transform, x, y, width, height | (Description.class | Animation.class)* |
Image ���W���[���� Image.class ���e�Z�b�g���`����B
���e�Z�b�g�� | ���e�Z�b�g�Ɋ܂܂��v�f |
---|---|
Image.class | image |
���ɋ�����C���^�[�t�F�[�X���ȉ��Œ�`�����F SVGDocument, SVGSVGElement, SVGGElement, SVGDefsElement, SVGDescElement, SVGTitleElement, SVGSymbolElement, SVGUseElement, SVGElementInstance, SVGElementInstanceList, SVGImageElement, SVGSwitchElement, GetSVGDocument
'svg' �v�f�� XHTML ���� [XHTML] �Ȃǂ̑��̖��O��Ԃ̕����̕��i�Ƃ��ăC�����C���ɖ��ߍ��܂�Ă���ꍇ�A SVGDocument �I�u�W�F�N�g�͑��݂����A���̂����ɕ����I�u�W�F�N�g�K�w�ɂ����郋�[�g�I�u�W�F�N�g�� HTMLDocument �I�u�W�F�N�g�Ȃǂ̈قȂ�^�̕����I�u�W�F�N�g�ɂȂ�B
����ŁA�Ɨ� SVG �t�@�C���i���� MIME �^�C�v "image/svg+xml" �̃t�@�C���j��\�����Ă���Ƃ��̗l�ɁA XML �����K�w�ɂ����郋�[�g�v�f�� 'svg' �v�f�ł���ꍇ�� SVGDocument �I�u�W�F�N�g�����ۂɑ��݂���B���̏ꍇ�A SVGDocument �I�u�W�F�N�g�͕����I�u�W�F�N�g���f���K�w�̃��[�g�I�u�W�F�N�g�ɂȂ�B
XHTML ������ 'object' �v�f�������A���� href ������ SVG �����i���� MIME �^�C�v "image/svg+xml" �̃t�@�C���ł���A���������Ă��̃��[�g�v�f�� 'svg' �v�f�j���Q�Ƃ��Ă���Ƃ��̗l�ɁA SVG �������Q�Ƃɂ�薄�ߍ��܂�Ă���ꍇ�͂Q�̕ʁX�� DOM �K�w�����݂��邱�ƂɂȂ�B��͎Q�Ƃ��Ă��镶���̂��́i�Ⴆ�� XHTML �����j�ł���A������͎Q�Ɛ�� SVG �����̂��̂ɂȂ�B��҂ɂ����郋�[�g�I�u�W�F�N�g�� SVGDocument �I�u�W�F�N�g�ł���B
SVGDocument �C���^�[�t�F�[�X�́A [DOM1] �d�l�� �����I�u�W�F�N�g���f���i HTML �j���x���P �ŏq�ׂ��Ă��� HTMLDocument �C���^�[�t�F�[�X�Ɨގ����������ƃ��\�b�h�̃��X�g���܂�ł���B
interface SVGDocument : Document, events::DocumentEvent { readonly attribute DOMString title; readonly attribute DOMString referrer; readonly attribute DOMString domain; readonly attribute DOMString URL; readonly attribute SVGSVGElement rootElement; };
SVGSVGElement �C���^�[�t�F�[�X�� 'svg' �v�f�ɑΉ������{�I�ȃC���^�[�t�F�[�X�ł���B���̃C���^�[�t�F�[�X�́A�s�Z�⎋�o�`�摕�u�ɂ�����ĕ`��̎��ԓI����\�͂ȂǁA�L�p�ł��葽���ʂŋ��ʂ��ė��p�����l�X�ȃ��\�b�h���܂ށB
SVGSVGElement �� ViewCSS �� DocumentCSS ���g�����A�v���p�e�B�̌v�Z�l�ւ̃A�N�Z�X�� DOM2 �ŏq�ׂ��Ă���X�^�C���V�[�g�̏㏑�������B
interface SVGSVGElement : SVGElement, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGLocatable, SVGFitToViewBox, SVGZoomAndPan, events::EventTarget, events::DocumentEvent, css::ViewCSS, css::DocumentCSS { readonly attribute SVGAnimatedLength x; readonly attribute SVGAnimatedLength y; readonly attribute SVGAnimatedLength width; readonly attribute SVGAnimatedLength height; attribute DOMString contentScriptType; // raises DOMException on setting attribute DOMString contentStyleType; // raises DOMException on setting readonly attribute SVGRect viewport; readonly attribute float pixelUnitToMillimeterX; readonly attribute float pixelUnitToMillimeterY; readonly attribute float screenPixelToMillimeterX; readonly attribute float screenPixelToMillimeterY; readonly attribute boolean useCurrentView;// raises DOMException on settingreadonly attribute SVGViewSpec currentView; attribute float currentScale;// raises DOMException on settingreadonly attribute SVGPoint currentTranslate; unsigned long suspendRedraw ( in unsigned long max_wait_milliseconds ); void unsuspendRedraw ( in unsigned long suspend_handle_id ) raises( DOMException ); void unsuspendRedrawAll ( ); void forceRedraw ( ); void pauseAnimations ( ); void unpauseAnimations ( ); boolean animationsPaused ( ); float getCurrentTime ( ); void setCurrentTime ( in float seconds );NodeList getIntersectionList ( in SVGRect rect, in SVGElement referenceElement ); NodeList getEnclosureList ( in SVGRect rect, in SVGElement referenceElement );StaticNodeList getIntersectionList ( in SVGRect rect, in SVGElement referenceElement ); StaticNodeList getEnclosureList ( in SVGRect rect, in SVGElement referenceElement ); boolean checkIntersection ( in SVGElement element, in SVGRect rect ); boolean checkEnclosure ( in SVGElement element, in SVGRect rect ); void deselectAll ( ); SVGNumber createSVGNumber ( ); SVGLength createSVGLength ( ); SVGAngle createSVGAngle ( ); SVGPoint createSVGPoint ( ); SVGMatrix createSVGMatrix ( ); SVGRect createSVGRect ( ); SVGTransform createSVGTransform ( ); SVGTransform createSVGTransformFromMatrix ( in SVGMatrix matrix ); Element getElementById ( in DOMString elementId ); };
typedef StaticNodeList NodeList;
StaticNodeList �́A���̖��������Ƃ���A�ÓI�ł���A������Ԃł͂Ȃ����Ƃ������� [DOM2] �Œ�`����� NodeList �ƑS�������ł���l�Ɏ������Ȃ���Ȃ�Ȃ��B
DOMException |
NO_MODIFICATION_ALLOWED_ERR �F�ǂݏo����p�̑����l�̕ύX�����݂��Ƃ��Ƀ��C�Y�����B
|
DOMException |
NO_MODIFICATION_ALLOWED_ERR �F�ǂݏo����p�̑����l�̕ύX�����݂��Ƃ��Ƀ��C�Y�����B
|
���� 'svg' �v�f�ɑΉ�����i�Öق܂��͖����I�ȁj�r���[�|�[�g�̈ʒu�Ƒ傫���B�t�`�����ۂɓ��e��`�悵�Ă���Ƃ��̈ʒu�Ƒ傫����\������B�ʒu�Ƒ傫���͐e�v�f�̍��W�n�ɂ�����P�ʖ����̒l��\���B�e�v�f�����݂��Ȃ��i���� 'svg' �v�f�������̃��[�g�j�ꍇ�A���� SVG ���������̕����̈ꕔ�Ƃ��Ė��ߍ��܂�Ă���Ȃ�i�Ⴆ�� HTML �� 'object' �v�f�ɂ��j�A�e�̕����̍��W�n�ɂ�����P�ʖ����̒l��\���i�����e�� CSS �܂��� XSL �ɂ�郌�C�A�E�g�𗘗p���Ă���ꍇ�́A�P�ʖ����̒l�� CSS2 �d�l�ŏq�ׂ���悤�Ɍ��݂� CSS �܂��� XSL �r���[�|�[�g�̉�f�P�ʂɂ��l��\������j�B�e�v�f�����W�n�������Ȃ��ꍇ�A�t�`�͂��̑����ɑ��K�Ȋ���l��^����ׂ��ł���B
�I�u�W�F�N�g���g�Ƃ��̓��e�͋��ɓǂݏo����p�ł���B
DOMException |
NO_MODIFICATION_ALLOWED_ERR �F�ǂݏo����p�̑����l�̕ύX�����݂��Ƃ��Ƀ��C�Y�����B
|
�I�u�W�F�N�g���g�Ƃ��̓��e�͋��ɓǂݏo����p�ł���B
DOMException |
NO_MODIFICATION_ALLOWED_ERR �F�ǂݏo����p�̑����l�̕ύX�����݂��Ƃ��Ƀ��C�Y�����B
|
in unsigned long max_wait_milliseconds | ���u�ւ̍ĕ`����~�߂鎞�Ԃ̒������~���b�Ŏw�肷��B 60 �b�ȏ�̒l�� 60 �b�ɗ}������B |
unsigned long | suspendRedraw() �Ăяo���ɑ����ӓI�� ID �Ƃ��ē������B���̒l�͑Ή����� unsuspendRedraw() �Ăяo���ɓn����Ȃ���Ȃ�Ȃ��B |
in unsigned long suspend_handle_id | ���������� suspendRedraw() �Ăяo���ɑΉ������ӓI�� ID �B���̒l�͑O�� suspendRedraw() �Ăяo���ŕԂ��ꂽ���łȂ���Ȃ�Ȃ��B �i �G���[�^ �F����lj��j ������ suspend_handle_id ���n���ꂽ�ꍇ�i�����A���̂悤�Ȋ�����Ԃ� suspend_handle_id ���Ȃ��j�A unsuspendRedraw �ւ̗v���͖ق��Ė��������B |
DOMException |
|
boolean | ���� SVG �����Ђ��x�~��Ԃ��ǂ�����\���^�U�l�B |
float | ���݂̎����i�b�j�B |
in float seconds | �V�����ݒ肷�錻�݂̎��������݂� SVG �����Ђ̊J�n���Ԃ���̕b���ŗ^����B |
in SVGRect rect | �e�X�g�����`�B�l�͌��݂� 'svg' �v�f�̏������W�n�ɂ�������́B | |
in SVGElement referenceElement | null �łȂ��Ȃ�A�`�揇���ɂ����ė^����ꂽ�v�f��艺�ʂɂ���v�f�݂̂��Ԃ����B |
�`����e���^����ꂽ��`�ƌ����v�f�̃��X�g�B �i �G���[�^ �F�߂�l�̌^��ύX�j |
in SVGRect rect | �e�X�g�����`�B�l�͌��݂� 'svg' �v�f�̏������W�n�ɂ�������́B | |
in SVGElement referenceElement | null �łȂ��Ȃ�A�`�揇���ɂ����ė^����ꂽ�v�f��艺�ʂɂ���v�f�݂̂��Ԃ����B |
�`����e���^����ꂽ��`�Ɋ��S�Ɉ͂܂��v�f�̃��X�g�B �i �G���[�^ �F�߂�l�̌^��ύX�j |
in SVGElement element | �e�X�g�����v�f�B | |
in SVGRect rect | �e�X�g�����`�B�l�͌��݂� 'svg' �v�f�̏������W�n�ɂ�������́B |
boolean | �^����ꂽ�v�f���^����ꂽ��`�ƌ���邩�ǂ�����\���^�U�l�B |
in SVGElement element | �e�X�g�����v�f�B | |
in SVGRect rect | �e�X�g�����`�B�l�͌��݂� 'svg' �v�f�̏������W�n�ɂ�������́B |
boolean | �^����ꂽ�v�f���^����ꂽ��`�Ɋ��S�Ɉ͂܂�邩�ǂ�����\���^�U�l�B |
SVGNumber | SVGNumber �I�u�W�F�N�g�B |
SVGLength | SVGLength �I�u�W�F�N�g�B |
SVGAngle | SVGAngle �I�u�W�F�N�g�B |
SVGPoint | SVGPoint �I�u�W�F�N�g�B |
SVGMatrix | SVGMatrix �I�u�W�F�N�g�B |
SVGRect | SVGRect �I�u�W�F�N�g�B |
SVGTransform | SVGTransform �I�u�W�F�N�g�B |
in SVGMatrix matrix | �ϊ��s��B |
SVGTransform | SVGTransform �I�u�W�F�N�g�B |
in DOMString elementId | �v�f�ɑ���ӓI�� id �̒l�B |
Element | ���v�����v�f�B |
SVGGElement �C���^�[�t�F�[�X�� 'g' �v�f�ɑΉ�����B
interface SVGGElement : SVGElement, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGTransformable, events::EventTarget {};
SVGDefsElement �C���^�[�t�F�[�X�� 'defs' �v�f�ɑΉ�����B
interface SVGDefsElement : SVGElement, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGTransformable, events::EventTarget {};
SVGDescElement �C���^�[�t�F�[�X�� 'desc' �v�f�ɑΉ�����B
interface SVGDescElement : SVGElement, SVGLangSpace, SVGStylable {};
SVGTitleElement �C���^�[�t�F�[�X�� 'title' �v�f�ɑΉ�����B
interface SVGTitleElement : SVGElement, SVGLangSpace, SVGStylable {};
SVGSymbolElement �C���^�[�t�F�[�X�� 'symbol' �v�f�ɑΉ�����B
interface SVGSymbolElement : SVGElement, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGFitToViewBox, events::EventTarget {};
SVGUseElement �C���^�[�t�F�[�X�� 'use' �v�f�ɑΉ�����B
interface SVGUseElement : SVGElement, SVGURIReference, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGTransformable, events::EventTarget { readonly attribute SVGAnimatedLength x; readonly attribute SVGAnimatedLength y; readonly attribute SVGAnimatedLength width; readonly attribute SVGAnimatedLength height; readonly attribute SVGElementInstance instanceRoot; readonly attribute SVGElementInstance animatedInstanceRoot; };
�e 'use' �v�f�ɑ��A SVG DOM �� SVGElementInstance �^�̃I�u�W�F�N�g����Ȃ����J�i�u�C���X�^���X�v�j���ێ��Ǘ�����B SVGElementInstance �́A�C���X�^���X�ɂ������̃m�[�h��\������B 'use' �v�f�ɑΉ����� SVGUseElement �I�u�W�F�N�g�� instanceRoot �������C���X�^���X�̃��[�g�I�u�W�F�N�g���w���B
'use' �v�f�� 'rect' �Ȃǂ̒P���ȃO���t�B�b�N�X�v�f���Q�Ƃ���ꍇ�A������� SVGElementInstance �I�u�W�F�N�g�����݂��A���� SVGElementInstance �I�u�W�F�N�g�� correspondingElement �����͎Q�Ɛ�� 'rect' �v�f�ɑΉ����� SVGRectElement �ł���B
'use' �v�f���Q�� 'rect' �v�f���܂� 'g' �v�f���Q�Ƃ��Ă���ꍇ�A�C���X�^���X�ɂ͂R�� SVGElementInstance �I�u�W�F�N�g�F correspondingElement �� 'g' �ɑ��� SVGGElement �I�u�W�F�N�g�ɂȂ��Ă��郋�[�g�� SVGElementInstance �I�u�W�F�N�g�A����� correspondingElement �� SVGRectElement �I�u�W�F�N�g�ɂȂ��Ă���Q�� SVGElementInstance �q�I�u�W�F�N�g�����݂���B
�Q�Ɛ�̃I�u�W�F�N�g���g�� 'use' �v�f�ł��邩�A���邢�͎Q�Ɛ�̃I�u�W�F�N�g���� 'use' �q�v�f������ꍇ�A�C���X�^���X�͊��S�Ȗ��`�����邽�߂ɊԐڎQ�Ƃɂ��ċA�I�Ɋg�������B�Ⴆ�A 'use' �v�f�� 'g' ���Q�Ƃ��A 'g' �v�f���g�� 'use' ���܂݁A���� 'use' �� 'rect' �v�f���Q�Ƃ��Ă���ꍇ�A�ŏ��́i�ł��O���́j 'use' �̃C���X�^���X�͎��̂悤�� SVGElementInstance �I�u�W�F�N�g�̊K�w����\�������F
SVGElementInstance #1 (parentNode=null, firstChild=#2, correspondingElement is the 'g') SVGElementInstance #2 (parentNode=#1, firstChild=#3, correspondingElement is the other 'use') SVGElementInstance #3 (parentNode=#2, firstChild=null, corresponding Element is the 'rect')
interface SVGElementInstance : events::EventTarget { readonly attribute SVGElement correspondingElement; readonly attribute SVGUseElement correspondingUseElement; readonly attribute SVGElementInstance parentNode; readonly attribute SVGElementInstanceList childNodes; readonly attribute SVGElementInstance firstChild; readonly attribute SVGElementInstance lastChild; readonly attribute SVGElementInstance previousSibling; readonly attribute SVGElementInstance nextSibling; };
SVGElementInstanceList �C���^�[�t�F�[�X�́A���g�̒�`�Ɛ��B�����ꂽ�A SVGElementInstance �I�u�W�F�N�g�̒��ۉ����ꂽ���X�g��\������B
interface SVGElementInstanceList { readonly attribute unsigned long length; SVGElementInstance item ( in unsigned long index ); };
���X�g�� index �Ԗڂ̃m�[�h��Ԃ��B index �����X�g���̃m�[�h���ȏ�̏ꍇ�� null ��Ԃ��B
in unsigned long index | ���X�g�̍��ڂ̓Y���B |
SVGElementInstance | SVGElementInstanceList �� index �Ԗڂ� SVGElementInstance �I�u�W�F�N�g�B�Y�����͈͊O�̏ꍇ�� null ��Ԃ��B |
SVGImageElement �C���^�[�t�F�[�X�� 'image' �v�f�ɑΉ�����B
interface SVGImageElement : SVGElement, SVGURIReference, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGTransformable, events::EventTarget { readonly attribute SVGAnimatedLength x; readonly attribute SVGAnimatedLength y; readonly attribute SVGAnimatedLength width; readonly attribute SVGAnimatedLength height; readonly attribute SVGAnimatedPreserveAspectRatio preserveAspectRatio; };
SVGSwitchElement �C���^�[�t�F�[�X�� 'switch' �v�f�ɑΉ�����B
interface SVGSwitchElement : SVGElement, SVGTests, SVGLangSpace, SVGExternalResourcesRequired, SVGStylable, SVGTransformable, events::EventTarget {};
XHTML ������
'object'
�v�f�������A����
href
�����i�܂��͂���Ɠ����ȑ����j�� SVG �������Q�Ƃ��Ă���i���� MIME �^�C�v�� "image/svg+xml" �̕����ł���A���������ă��[�g�v�f��
'svg'
�v�f�j�Ƃ��̂悤�ɁA SVG �������Q�Ƃɂ�薄�ߍ��܂�Ă���ꍇ�A�Q�ƌ��̗v�f�i�Ⴆ�� HTML ��
'object'
���邢�͗ގ��̎Q�Ɨv�f�j�ɑ�
GetSVGDocument
�C���^�[�t�F�[�X���������邱�Ƃ� SVG-�t�`�ɗv�������B
���̃C���^�[�t�F�[�X�͑��� DOM-�x�[�X�̌���ɂ����ĎQ�Ƃɂ�薄�ߍ��܂ꂽ SVG �����ւ̃A�N�Z�X�����B ��O�́A HTML 'object' �v�f�ɑΉ����� DOM Element �I�u�W�F�N�g�Ȃǂ̗l�ɁA DOM �I�u�W�F�N�g�ɂ��̂悤�� SVG �����ւ̎Q�Ƃ��\�ɂ���C���^�[�t�F�[�X����������Ă���ꍇ�ł���B���̏ꍇ�A���̂悤�� DOM �I�u�W�F�N�g�ɂ� Window �d�l [WINDOW] �Œ�߂��Ă��� EmbeddingElement �̎������v������Ă���B
���̃C���^�[�t�F�[�X�͔p�~�\��ł���A�����ł� SVG �d�l����͍폜���꓾��B�����쐬�҂ɂ́A�Q�Ɛ�� SVG �����̎擾����ۂɂ́i��������j EmbeddingElement �C���^�[�t�F�[�X�� contentDocument
�����̗��p�����コ���B
interface GetSVGDocument { SVGDocument getSVGDocument ( ) raises( DOMException ); };
�Q�Ɛ�� SVG �����ɑ���
SVGDocument
�I�u�W�F�N�g��Ԃ��B
���̃��\�b�h�͖��ߍ��v�f�ɂ����Ė��ߍ��܂ꂽ���e�� Document �I�u�W�F�N�g�A���邢�͕������������ null ��Ԃ��Ȃ���Ȃ�Ȃ��B
����͖��ߍ��v�f�� EmbeddingElement
�C���^�[�t�F�[�X����������Ă���Ȃ�A���̗v�f�� EmbeddingElement::contentDocument
�����ɃA�N�Z�X����ɓ������Ȃ邱�Ƃɒ��ӁB�����쐬�҂ɂ́A�Ԃ��ꂽ Document �̕��������ۂ� 'svg' �v�f�Ȃ̂��ǂ����m���߂邱�Ƃ�E�߂�B
SVGDocument | �Q�Ɛ�� SVG �����ɑ��� SVGDocument �I�u�W�F�N�g�B���݂��Ȃ���� null ��Ԃ��B |
DOMException |
NOT_SUPPORTED_ERR �F SVGDocument �I�u�W�F�N�g�����p�ł��Ȃ��^���݂��Ȃ��B
|