6.1.3記述例
直線サンプル1
描画領域(X,Y,Width,Heightの各属性)を指定しないケースのサンプルです。
<?xml version="1.0" encoding="UTF-8"?>
<!-- XML file created by biz-Stream Designer -->
<!-- biz-Stream Copyright BrainSellers.com Corp. -->
<Layout Name="LineSample1" Width="80" Height="60" X="10" Y="10" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:bs="http://www.brainsellers.com/schema" xmlns:svg="http://www.brainsellers.com/schema" xmlns:form="http://www.brainsellers.com/schema" xmlns:pdf="http://www.brainsellers.com/schema" version="5.0.0">
<!-- 枠線(青線) -->
<Square Width="50" Height="35" LineColor="14,0,176" LineStyle="Solid"/>
<!-- (1)Line1 -->
<Line Name="Line1" StartX="10" StartY="10" EndX="20" EndY="10" Horizon="left" Vertical="bottom" LineStyle="Solid"/>
<!-- (2)Line2 -->
<Line Name="Line2" StartX="10" StartY="10" EndX="20" EndY="20" Horizon="left" Vertical="bottom" LineStyle="Solid"/>
<!-- (3)Line3 -->
<Line Name="Line3" StartX="10" StartY="10" EndX="10" EndY="20" Horizon="left" Vertical="bottom" LineStyle="Solid"/>
<!-- (4)Line4 -->
<Line Name="Line4" StartX="30" StartY="10" EndX="40" EndY="10" Horizon="left" Vertical="bottom" LineWidth="0" LineStyle="Solid"/>
<!-- (5)Line5 -->
<Line Name="Line5" StartX="30" StartY="15" EndX="40" EndY="15" Horizon="left" Vertical="bottom" LineWidth="1" LineStyle="Solid"/>
<!-- (6)Line6 -->
<Line Name="Line6" StartX="30" StartY="20" EndX="40" EndY="20" Horizon="left" Vertical="bottom" LineWidth="2" LineStyle="Solid"/>
<!-- (7)Line7 -->
<Line Name="Line7" StartX="30" StartY="25" EndX="40" EndY="25" Horizon="left" Vertical="bottom" LineColor="102,102,102" LineWidth="3" LineStyle="Solid"/>
</Layout>
- ①Line1(横線):StartX = "10",EndX = "20"
- ②Line2(斜め線):StartX = "10",EndX = "20",
StartY = "10",EndY ="20"
- ③Line3(縦線):StartY = "10",EndY = "20"
- ④Line4:LineWidth = "0"
- ⑤Line5:LineWidth = "1"
- ⑥Line6:LineWidth = "2"
- ⑦Line7:LineWidth = "3",LineColor = "40"
直線サンプル2
領域(X,Y,Width,Heightの各属性)を指定するケースのサンプルです。
- StartX,StartY,EndX,EndYは、領域の座標(X,Y)で指定されている位置を基点(0,0)として計算します。(例:Line1、2)
- 垂直方向配置(Vertical属性)、水平方向配置(Horizon属性)は領域内で行われますが、StartX,StartY,EndX,EndYで指定された座標を考慮した上での配置となります。
(例:Line3、4、5、6)
<?xml version="1.0" encoding="UTF-8"?>
<!-- XML file created by biz-Stream Designer -->
<!-- biz-Stream Copyright BrainSellers.com Corp. -->
<Layout Name="LineSample2" Width="110" Height="100" X="10" Y="10" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:bs="http://www.brainsellers.com/schema" xmlns:svg="http://www.brainsellers.com/schema" xmlns:form="http://www.brainsellers.com/schema" xmlns:pdf="http://www.brainsellers.com/schema" version="5.0.0">
<Square Width="80" Height="52" LineColor="14,0,176" LineStyle="Solid"/>
<!-- (1)Line1 -->
<Square Width="30" Height="10" X="5" Y="5" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line1" Width="30" Height="10" X="5" Y="5" StartX="0" StartY="0" EndX="20" EndY="0" Horizon="left" Vertical="bottom" LineWidth="1" LineStyle="Solid"/>
<!-- (2)Line2 -->
<Square Width="30" Height="10" X="5" Y="20" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line2" Width="30" Height="10" X="5" Y="20" StartX="5" StartY="5" EndX="25" EndY="5" Horizon="left" Vertical="bottom" LineWidth="1" LineStyle="Solid"/>
<!-- (3)Line3 -->
<Square Width="30" Height="10" X="5" Y="35" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line3" Width="30" Height="10" X="5" Y="35" StartX="5" StartY="0" EndX="25" EndY="0" Horizon="right" Vertical="center" LineWidth="1" LineStyle="Solid"/>
<!-- (4)Line4 -->
<Square Width="30" Height="10" X="45" Y="5" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line4" Width="30" Height="10" X="45" Y="5" StartX="0" StartY="0" EndX="20" EndY="0" Horizon="left" Vertical="center" LineWidth="1" LineStyle="Solid"/>
<!-- (5)Line5 -->
<Square Width="30" Height="10" X="45" Y="20" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line5" Width="30" Height="10" X="45" Y="20" StartX="20" StartY="0" EndX="0" EndY="0" Horizon="center" Vertical="center" LineWidth="1" LineStyle="Solid"/>
<!-- (6)Line6 -->
<Square Width="30" Height="10" X="45" Y="35" LineColor="102,102,102" LineStyle="Solid"/>
<Line Name="Line6" Width="30" Height="10" X="45" Y="35" StartX="0" StartY="0" EndX="20" EndY="0" Horizon="right" Vertical="center" LineWidth="1" LineStyle="Solid"/>
</Layout>
各Lineを囲む枠線および軸線は、X,Y,Width,Heightで指定された
描画領域を表します。
- ①Line1
- ②Line2
- ③Line3
- ④Line4
- ⑤Line5
- ⑥Line6
- ※領域の座標を基点(0,0)として計算するため、
- ①Line1:領域の座標(5,5)を基点(0,0)として、Start(0,0)・End(20,0)と指定しています。
- ②Line2:領域の座標(5,20)を基点(0,0)として、Start(5,5)・End(25,5)と指定しています。
- ※領域内で行われる配置は、StartX,StartY,EndX,EndYの座標を考慮した配置となります。
- ③Line3:水平方向および、垂直方向の中央揃え配置が指定されていますが、Start(5,0)、End(25,0)が考慮されるため、長さ20の線が右揃え位置から水平方向に5ずれたものとなります。
直線サンプル3
スタイルを指定するケースのサンプルです。
<?xml version="1.0" encoding="UTF-8"?>
<!-- XML file created by biz-Stream Designer -->
<!-- biz-Stream Copyright BrainSellers.com Corp. -->
<Layout Name="LineSample3" Width="125" Height="75" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:bs="http://www.brainsellers.com/schema" xmlns:svg="http://www.brainsellers.com/schema" xmlns:form="http://www.brainsellers.com/schema" xmlns:pdf="http://www.brainsellers.com/schema" version="5.0.0">
<Square Width="110" Height="60" X="5" Y="5" LineColor="14,0,176" LineStyle="Solid"/>
<Line StartX="10" StartY="60" EndX="102" EndY="60" Horizon="left" Vertical="bottom" LineStyle="Solid"/>
<Line StartX="10" StartY="58" EndX="102" EndY="58" Horizon="left" Vertical="bottom" LineStyle="Border"/>
<Line StartX="10" StartY="56" EndX="102" EndY="56" Horizon="left" Vertical="bottom" LineStyle="Border2"/>
<Line StartX="10" StartY="54" EndX="102" EndY="54" Horizon="left" Vertical="bottom" LineStyle="Borderx2"/>
<Line StartX="10" StartY="52" EndX="102" EndY="52" Horizon="left" Vertical="bottom" LineStyle="Center"/>
<Line StartX="10" StartY="50" EndX="102" EndY="50" Horizon="left" Vertical="bottom" LineStyle="Center2"/>
<Line StartX="10" StartY="48" EndX="102" EndY="48" Horizon="left" Vertical="bottom" LineStyle="Centerx2"/>
<Line StartX="10" StartY="46" EndX="102" EndY="46" Horizon="left" Vertical="bottom" LineStyle="Continuous"/>
<Line StartX="10" StartY="44" EndX="102" EndY="44" Horizon="left" Vertical="bottom" LineStyle="DashDot"/>
<Line StartX="10" StartY="42" EndX="102" EndY="42" Horizon="left" Vertical="bottom" LineStyle="DashDot2"/>
<Line StartX="10" StartY="40" EndX="102" EndY="40" Horizon="left" Vertical="bottom" LineStyle="DashDotx2"/>
<Line StartX="10" StartY="38" EndX="102" EndY="38" Horizon="left" Vertical="bottom" LineStyle="Dashed"/>
<Line StartX="10" StartY="36" EndX="102" EndY="36" Horizon="left" Vertical="bottom" LineStyle="Dashed2"/>
<Line StartX="10" StartY="34" EndX="102" EndY="34" Horizon="left" Vertical="bottom" LineStyle="Dashedx2"/>
<Line StartX="10" StartY="32" EndX="102" EndY="32" Horizon="left" Vertical="bottom" LineStyle="Divide"/>
<Line StartX="10" StartY="30" EndX="102" EndY="30" Horizon="left" Vertical="bottom" LineStyle="Divide2"/>
<Line StartX="10" StartY="28" EndX="102" EndY="28" Horizon="left" Vertical="bottom" LineStyle="Dividex2"/>
<Line StartX="10" StartY="26" EndX="102" EndY="26" Horizon="left" Vertical="bottom" LineStyle="Dot"/>
<Line StartX="10" StartY="24" EndX="102" EndY="24" Horizon="left" Vertical="bottom" LineStyle="Dot2"/>
<Line StartX="10" StartY="22" EndX="102" EndY="22" Horizon="left" Vertical="bottom" LineStyle="Dotx2"/>
<Line StartX="10" StartY="20" EndX="102" EndY="20" Horizon="left" Vertical="bottom" LineStyle="Hidden"/>
<Line StartX="10" StartY="18" EndX="102" EndY="18" Horizon="left" Vertical="bottom" LineStyle="Hidden2"/>
<Line StartX="10" StartY="16" EndX="102" EndY="16" Horizon="left" Vertical="bottom" LineStyle="Hiddenx2"/>
<Line StartX="10" StartY="14" EndX="102" EndY="14" Horizon="left" Vertical="bottom" LineStyle="Phantom"/>
<Line StartX="10" StartY="12" EndX="102" EndY="12" Horizon="left" Vertical="bottom" LineStyle="Phantom2"/>
<Line StartX="10" StartY="10" EndX="102" EndY="10" Horizon="left" Vertical="bottom" LineStyle="Phantomx2"/>
<Label Width="10" Height="2" X="104" Y="59.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Solid</Label>
<Label Width="10" Height="2" X="104" Y="57.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Border</Label>
<Label Width="10" Height="2" X="104" Y="55.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Border2</Label>
<Label Width="10" Height="2" X="104" Y="53.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Borderx2</Label>
<Label Width="10" Height="2" X="104" Y="51.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Center</Label>
<Label Width="10" Height="2" X="104" Y="49.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Center2</Label>
<Label Width="10" Height="2" X="104" Y="47.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Centerx2</Label>
<Label Width="10" Height="2" X="104" Y="45.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Continuous</Label>
<Label Width="10" Height="2" X="104" Y="43.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">DashDot</Label>
<Label Width="10" Height="2" X="104" Y="41.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">DashDot2</Label>
<Label Width="10" Height="2" X="104" Y="39.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">DashDotx2</Label>
<Label Width="10" Height="2" X="104" Y="37.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dashed</Label>
<Label Width="10" Height="2" X="104" Y="35.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dashed2</Label>
<Label Width="10" Height="2" X="104" Y="33.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dashedx2</Label>
<Label Width="10" Height="2" X="104" Y="31.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Divide</Label>
<Label Width="10" Height="2" X="104" Y="29.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Divide2</Label>
<Label Width="10" Height="2" X="104" Y="27.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dividex2</Label>
<Label Width="10" Height="2" X="104" Y="25.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dot</Label>
<Label Width="10" Height="2" X="104" Y="23.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dot2</Label>
<Label Width="10" Height="2" X="104" Y="21.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Dotx2</Label>
<Label Width="10" Height="2" X="104" Y="19.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Hidden</Label>
<Label Width="10" Height="2" X="104" Y="17.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Hidden2</Label>
<Label Width="10" Height="2" X="104" Y="15.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Hiddenx2</Label>
<Label Width="10" Height="2" X="104" Y="13.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Phantom</Label>
<Label Width="10" Height="2" X="104" Y="11.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Phantom2</Label>
<Label Width="10" Height="2" X="104" Y="9.5" Horizon="left" Vertical="bottom" Vector="horizon" Font="MSGothic" FontSize="5" FontStyle="PLAIN" Narrow="horizon">Phantomx2</Label>
</Layout>