From c058fa0fb22dc40ef0225b21a97578cddd0aaffa Mon Sep 17 00:00:00 2001 From: Florian Merz Date: Thu, 11 Feb 2021 14:51:05 +0100 Subject: unslug ru: move --- files/ru/web/svg/element/foreignobject/index.html | 119 ++++++++++++++++++++++ 1 file changed, 119 insertions(+) create mode 100644 files/ru/web/svg/element/foreignobject/index.html (limited to 'files/ru/web/svg/element/foreignobject') diff --git a/files/ru/web/svg/element/foreignobject/index.html b/files/ru/web/svg/element/foreignobject/index.html new file mode 100644 index 0000000000..64e32d019f --- /dev/null +++ b/files/ru/web/svg/element/foreignobject/index.html @@ -0,0 +1,119 @@ +--- +title: +slug: Web/SVG/Элемент/foreignObject +translation_of: Web/SVG/Element/foreignObject +--- +
{{SVGRef}}
+Элемент <foreignObject> SVG позволяет включать другое пространство имен XML.
+В контексте браузера это, скорее всего, XHTML / HTML.
+ +
+ + +
<svg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg">
+  <style>
+    polygon { fill: black }
+
+    div {
+      color: white;
+      font:18px serif;
+      height: 100%;
+      overflow: auto;
+    }
+  </style>
+
+  <polygon points="5,5 195,10 185,185 10,195" />
+
+  <!-- Типичный пример использования: встраивание HTML-текста в SVG -->
+  <foreignObject x="20" y="20" width="160" height="160">
+  <!--
+В контексте SVG, внедренного в HTML, пространство имен XHTML может и следует избегать,
+но это обязательно в контексте документа SVG
+   -->
+    <div xmlns="http://www.w3.org/1999/xhtml">
+    - Смолчал хозяин, да и то, что мог сказать
+    - Мне невдомёк, но во владениях чертога
+    Поможет дом срубить да судьбы вам связать.
+    Не веришь ежли - испроси у Бога...
+    </div>
+  </foreignObject>
+</svg>
+ +

{{EmbedLiveSample('Exemple', 150, '100%')}}

+
+ +

Атрибуты

+ +
+
{{SVGAttr("height")}}
+
Этот атрибут определяет высоту прямоугольника.
+ Value type: <length>|<percentage> ; Default value: auto; Animatable: yes
+
{{SVGAttr("width")}}
+
Этот атрибут определяет ширину прямоугольника.
+ Value type: <length>|<percentage> ; Default value: auto; Animatable: yes
+
{{SVGAttr("x")}}
+
Этот атрибут определяет координату x контейнера svg.
+ Это не влияет на внешние элементы SVG.
+ Value type: <length>|<percentage> ; Default value: 0; Animatable: yes
+
{{SVGAttr("y")}}
+
Этот атрибут определяет координату Y контейнера SVG.
+ Это не влияет на внешние элементы SVG.
+ Value type: <length>|<percentage> ; Default value: 0; Animatable: yes
+
+ +
+

Note: Starting with SVG2 x, y, width, and height are Geometry Properties, meaning those attributes can also be used as CSS properties for that element.

+
+ +

Глобальные атрибуты

+ +
+
Core Attributes
+
Most notably: {{SVGAttr('id')}}, {{SVGAttr('tabindex')}}
+
Styling Attributes
+
{{SVGAttr('class')}}, {{SVGAttr('style')}}
+
Conditional Processing Attributes
+
Most notably: {{SVGAttr('requiredExtensions')}}, {{SVGAttr('systemLanguage')}}
+
Event Attributes
+
Global event attributes, Graphical event attributes, Document event attributes, Document element event attributes
+
Presentation Attributes
+
Most notably: {{SVGAttr('clip-path')}}, {{SVGAttr('clip-rule')}}, {{SVGAttr('color')}}, {{SVGAttr('color-interpolation')}}, {{SVGAttr('color-rendering')}}, {{SVGAttr('cursor')}}, {{SVGAttr('display')}}, {{SVGAttr('fill')}}, {{SVGAttr('fill-opacity')}}, {{SVGAttr('fill-rule')}}, {{SVGAttr('filter')}}, {{SVGAttr('mask')}}, {{SVGAttr('opacity')}}, {{SVGAttr('pointer-events')}}, {{SVGAttr('shape-rendering')}}, {{SVGAttr('stroke')}}, {{SVGAttr('stroke-dasharray')}}, {{SVGAttr('stroke-dashoffset')}}, {{SVGAttr('stroke-linecap')}}, {{SVGAttr('stroke-linejoin')}}, {{SVGAttr('stroke-miterlimit')}}, {{SVGAttr('stroke-opacity')}}, {{SVGAttr('stroke-width')}}, {{SVGAttr("transform")}}, {{SVGAttr('vector-effect')}}, {{SVGAttr('visibility')}}
+
Aria Attributes
+
aria-activedescendant, aria-atomic, aria-autocomplete, aria-busy, aria-checked, aria-colcount, aria-colindex, aria-colspan, aria-controls, aria-current, aria-describedby, aria-details, aria-disabled, aria-dropeffect, aria-errormessage, aria-expanded, aria-flowto, aria-grabbed, aria-haspopup, aria-hidden, aria-invalid, aria-keyshortcuts, aria-label, aria-labelledby, aria-level, aria-live, aria-modal, aria-multiline, aria-multiselectable, aria-orientation, aria-owns, aria-placeholder, aria-posinset, aria-pressed, aria-readonly, aria-relevant, aria-required, aria-roledescription, aria-rowcount, aria-rowindex, aria-rowspan, aria-selected, aria-setsize, aria-sort, aria-valuemax, aria-valuemin, aria-valuenow, aria-valuetext, role
+
+ +

Примечания по использованию

+ +

{{svginfo}}

+ +

Характеристики

+ + + + + + + + + + + + + + + + + + + + + +
SpecificationStatusComment
{{SpecName('SVG2', 'embedded.html#ForeignObjectElement', '<foreignObject>')}}{{Spec2('SVG2')}} 
{{SpecName('SVG1.1', 'extend.html#ForeignObjectElement', '<foreignObject>')}}{{Spec2('SVG1.1')}}Initial definition
+ +

Совместимость браузера

+ + + +

{{Compat("svg.elements.foreignObject")}}

-- cgit v1.2.3-54-g00ecf