• Skip to main content
  • Skip to search
  • Skip to select language
MDN Web Docs
  • 参考手册
    • 概述 / Web 技术

      适用于开发者的 Web 技术参考手册

    • HTML

      Web 内容的结构

    • CSS

      用于描述文档样式的代码

    • JavaScript

      通用脚本语言

  • 开发指南
    • 概述 / MDN 学习区

      学习 Web 开发

    • MDN 学习区

      学习 Web 开发

    • HTML

      学习使用 HTML 构建 Web 内容

    • CSS

      学习使用 CSS 设置内容样式

    • JavaScript

      学习在浏览器中运行脚本

  • 更多中文网
  1. 面向开发者的 Web 技术
  2. 网络 API
  3. SVGImageElement
  4. preserveAspectRatio

目录

  • Value
  • Specifications
  • Browser compatibility
  1. SVG API
  2. SVGImageElement
  3. Instance properties
    1. decoding
    2. height
    3. preserveAspectRatio
    4. width
    5. x
    6. y
  4. Instance methods
    1. decode()
  5. Inheritance
    1. SVGGraphicsElement
    2. SVGElement
    3. Element
    4. Node
    5. EventTarget
  6. Related pages for SVG
    1. SVGAElement
    2. SVGAngle
    3. SVGAnimateColorElement Deprecated
    4. SVGAnimateElement
    5. SVGAnimateMotionElement
    6. SVGAnimateTransformElement
    7. SVGAnimatedAngle
    8. SVGAnimatedBoolean
    9. SVGAnimatedEnumeration
    10. SVGAnimatedInteger
    11. SVGAnimatedLength
    12. SVGAnimatedLengthList
    13. SVGAnimatedNumber
    14. SVGAnimatedNumberList
    15. SVGAnimatedPreserveAspectRatio
    16. SVGAnimatedRect
    17. SVGAnimatedString
    18. SVGAnimatedTransformList
    19. SVGAnimationElement
    20. SVGCircleElement
    21. SVGClipPathElement
    22. SVGComponentTransferFunctionElement
    23. SVGCursorElement Deprecated
    24. SVGDefsElement
    25. SVGDescElement
    26. SVGElement
    27. SVGEllipseElement
    28. SVGFEBlendElement
    29. SVGFEColorMatrixElement
    30. SVGFEComponentTransferElement
    31. SVGFECompositeElement
    32. SVGFEConvolveMatrixElement
    33. SVGFEDiffuseLightingElement
    34. SVGFEDisplacementMapElement
    35. SVGFEDistantLightElement
    36. SVGFEDropShadowElement
    37. SVGFEFloodElement
    38. SVGFEFuncAElement
    39. SVGFEFuncBElement
    40. SVGFEFuncGElement
    41. SVGFEFuncRElement
    42. SVGFEGaussianBlurElement
    43. SVGFEImageElement
    44. SVGFEMergeElement
    45. SVGFEMergeNodeElement
    46. SVGFEMorphologyElement
    47. SVGFEOffsetElement
    48. SVGFEPointLightElement
    49. SVGFESpecularLightingElement
    50. SVGFESpotLightElement
    51. SVGFETileElement
    52. SVGFETurbulenceElement
    53. SVGFilterElement
    54. SVGFontElement Deprecated
    55. SVGFontFaceElement Deprecated
    56. SVGFontFaceFormatElement Deprecated
    57. SVGFontFaceNameElement Deprecated
    58. SVGFontFaceSrcElement Deprecated
    59. SVGFontFaceUriElement Deprecated
    60. SVGForeignObjectElement
    61. SVGGElement
    62. SVGGlyphElement Deprecated
    63. SVGGradientElement
    64. SVGGraphicsElement
    65. SVGHKernElement Deprecated
    66. SVGLength
    67. SVGLengthList
    68. SVGLineElement
    69. SVGLinearGradientElement
    70. SVGMPathElement
    71. SVGMarkerElement
    72. SVGMaskElement
    73. SVGMetadataElement
    74. SVGMissingGlyphElement Deprecated
    75. SVGNumber
    76. SVGNumberList
    77. SVGPathElement
    78. SVGPatternElement
    79. SVGPoint Deprecated
    80. SVGPointList
    81. SVGPolygonElement
    82. SVGPolylineElement
    83. SVGPreserveAspectRatio
    84. SVGRadialGradientElement
    85. SVGRect
    86. SVGRectElement
    87. SVGSVGElement
    88. SVGScriptElement
    89. SVGSetElement
    90. SVGStopElement
    91. SVGStringList
    92. SVGStyleElement
    93. SVGSwitchElement
    94. SVGSymbolElement
    95. SVGTRefElement Deprecated
    96. SVGTSpanElement
    97. SVGTextContentElement
    98. SVGTextElement
    99. SVGTextPathElement
    100. SVGTextPositioningElement
    101. SVGTitleElement
    102. SVGTransform
    103. SVGTransformList
    104. SVGUnitTypes
    105. SVGUseElement
    106. SVGVKernElement Deprecated
    107. SVGViewElement
    108. TimeEvent

目录

  • Value
  • Specifications
  • Browser compatibility

SVGImageElement: preserveAspectRatio property

The preserveAspectRatio read-only property of the SVGImageElement interface returns an SVGAnimatedPreserveAspectRatio corresponding to the preserveAspectRatio attribute of the given <image> element.

Value

An SVGAnimatedPreserveAspectRatio.

Specifications

Specification
Scalable Vector Graphics (SVG) 2
# PreserveAspectRatioAttribute

Browser compatibility

BCD tables only load in the browser

MDN Web 中文网 - 粤ICP备13048890号