x1

x1 属性は、二つ以上の座標を必要とする SVG 要素を描画するための一つ目の x 座標を指定するのに使います。一つしか座標を必要としない要素は、これの代わりに x 属性を使います。

二つの要素がこの属性を使っています。つまり、<line><linearGradient> です。

html
<svg viewBox="0 0 10 10" xmlns="http://www.w3.org/2000/svg">
  <line x1="1" x2="5" y1="1" y2="9" stroke="red" />
  <line x1="5" x2="5" y1="1" y2="9" stroke="green" />
  <line x1="9" x2="5" y1="1" y2="9" stroke="blue" />
</svg>

line

<line> に関しては、x1 は、その直線の開始点の x 座標を定めます。

<length> | <percentage>
デフォルト値 0
アニメーション可能 Yes

html
<svg viewBox="0 0 10 10" xmlns="http://www.w3.org/2000/svg">
  <line x1="1" x2="5" y1="1" y2="9" stroke="red" />
  <line x1="5" x2="5" y1="1" y2="9" stroke="green" />
  <line x1="9" x2="5" y1="1" y2="9" stroke="blue" />
</svg>

linearGradient

<linearGradient> に関しては、x1 は、グラデーションのストップ値をマッピングするのに使われるグラデーション・ベクトル (gradient vector) の開始点の x 座標を定めます。この属性の正確な振る舞いは、gradientUnits (en-US) 属性の影響を受けます。

<length> | <percentage>
デフォルト値 0%
アニメーション可能 Yes

html
<svg viewBox="0 0 20 10" xmlns="http://www.w3.org/2000/svg">
  <!--
  デフォルトでは、グラデーション・ベクトルは、適用先の形状を囲う境界の
  左端から始まります。
  -->
  <linearGradient x1="0%" id="g0">
    <stop offset="0" stop-color="black" />
    <stop offset="100%" stop-color="red" />
  </linearGradient>

  <rect x="1" y="1" width="8" height="8" fill="url(#g0)" />

  <!--
  ここでは、グラデーション・ベクトルは、適用先の形状を囲う境界の
  左端から 80% のところから始まります。
  -->
  <linearGradient x1="80%" id="g1">
    <stop offset="0" stop-color="black" />
    <stop offset="100%" stop-color="red" />
  </linearGradient>

  <rect x="11" y="1" width="8" height="8" fill="url(#g1)" />
</svg>

仕様

Specification
Scalable Vector Graphics (SVG) 2
# LineElementX1Attribute
Scalable Vector Graphics (SVG) 2
# LinearGradientElementX1Attribute