VOOZH about

URL: https://www.geeksforgeeks.org/html/svg-markerheight-attribute/

⇱ SVG markerHeight Attribute - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

SVG markerHeight Attribute

Last Updated : 31 Mar, 2022

The markerHeight attribute indicates the height of the viewport into which the <marker> is to be fitted when it is displayed according to the preserveAspectRatio and viewBox attributes. Only <marker> element is using this attribute.

Syntax:

markerrHeight = "length-percentage" | "number"

Attribute values: The markerHeight attribute accepts values mentioned above and described below. 

  • length-percentage: It indicates either a relative or an absolute height of the marker.
  • number: It indicates the height of the marker in the units defined by the markerUnits attribute.

Note: The default value of markerHeight attribute is 3.

Example 1: Below are the examples that illustrates the use of markerHeight attribute.

Output:

👁 Image

Example 2:

Output:

👁 Image
Comment