Examples 文字関連 str02.pxdx

文字の色を変更
<?xml version="1.0" encoding="utf-8"?>
<!-- 用紙サイズ「A4」用紙方向「縦」 -->
<pxd paper-type="a4" orientation="portrait" title="文字">
<page>
   <!-- 値10の時1mmになるように設定 -->
   <svg x="0" y="0" width="21cm" height="29.7cm" viewBox="0 0 2100 2970 ">
      
      <!-- 横2cm 縦5cm の位置から 2cmの大きさの文字「文字の例」を色「赤」外周の線「無し」で記述 -->
      <text x="200" y="500" font-size="200" fill="red" stroke="none">文字の例</text>
      
      <!-- 横2cm 縦5cm の位置から横15cm 縦5cmの位置に黒色の線を引く。 -->
      <line x1="200" y1="500" x2="1500" y2="500" stroke="black" stroke-width="1"/>

      <!-- 横2cm 縦8cm の位置から 2cmの大きさの文字「文字の例」を色「緑」外周の線「無し」で記述 -->
      <text x="200" y="800" font-size="200" fill="rgb(0,255,0)" stroke="none">文字の例</text>
   </svg>
</page>
</pxd>