17.2.6. スケールバーアイテム¶
Scale bars provide a visual indication of the size of features, and distance
between features, on the map item. A scale bar item requires a map item.
Use the Add Scale Bar tool following items creation
instructions to add a new scale bar item that you can
later manipulate the same way as exposed in Interacting with layout items.
By default, a new scale bar item shows the scale of the map item over which it is drawn. If there is no map item below, the reference map is used. You can customize it in the Item Properties panel. Other than the items common properties, this feature has the following functionalities (see figure_layout_scalebar):

図 17.31 スケールバーアイテムプロパティパネル¶
17.2.6.1. メインプロパティ¶
The Main properties group of the scale bar Item Properties panel provides the following functionalities (see figure_layout_scalebar_ppt):

図 17.32 Scale Bar Main properties group¶
First, choose the map the scale bar will be attached to
それから、スケールバーのスタイルを選択します。6つのスタイルが利用可能です:
Single box and Double box styles, which contain one or two lines of boxes alternating colors;
Middle, Up or Down line ticks;
Numeric, where the scale ratio is printed (e.g.,
1:50000
).
Set properties as appropriate
17.2.6.2. 単位と線分列¶
The Units and Segments groups of the scale bar Item Properties panel (not available for the Numeric style) provide the following functionalities (see figure_layout_scalebar_units):

図 17.33 Scale Bar Units and Segments groups¶
In these two groups, you can set how the scale bar will be represented.
Select the units you want to use with Scalebar units. There are many possible choices: Map Units (the default one), Meters, Feet, Miles or Nautical Miles... which may force unit conversions.
The Label unit multiplier specifies how many scale bar units per labeled unit. Eg, if your scale bar units are set to "meters", a multiplier of 1000 will result in the scale bar labels in "kilometers".
The Label for units field defines the text used to describe the units of the scale bar, eg
m
orkm
. This should be matched to reflect the multiplier above.線分列 では, スケールバーの左と右をいくつで区切りるかを指定します.
You can set how long each segment will be (Fixed width), or limit the scale bar size in
mm
with Fit segment width option. In the latter case, each time the map scale changes, the scale bar is resized (and its label updated) to fit the range set.高さ はバーの高さを指定します.
17.2.6.3. ディスプレイ¶
The Display group of the scale bar Item Properties panel provides the following functionalities (see figure_layout_scalebar_display):

図 17.34 Scale Bar Display group¶
フレーム内でどのようにスケールバーが表示されるかを指定することができます.
ボックス幅 : テキストとフレーム枠との間隔です.
Label margin : space between text and scale bar drawing
Vertical label placement: it can be above or below the scale bar segment
Horizontal label placement: which would be centered at the scale bar segment's edge or center
線幅 : スケールバー描画の線幅です.
Join style : Corners at the end of scale bar in Bevel, Miter or Round style (only available for Scale bar style Single Box & Double Box)
頂点スタイル : 線の端の形を 角形, 平坦, 丸み から選びます (スケールバーのスタイルが中心チック, 上向きチック, 上向きチックの場合に有効です).
Alignment : Puts text on the left, center or right side of the frame (works only for Scale bar style Numeric)
17.2.6.4. フォントと色¶
The Fonts and colors group of the scale bar Item Properties panel provides the following functionalities (see figure_layout_scalebar_fonts):

図 17.35 Scale Bar Fonts and colors groups¶
You can define the fonts and colors used for the scale bar. These properties are data-definable.
Use the Font button to set the properties (size, font, color, letter spacing, shadow, background...) of the scale bar label.
Example: The following code applied to the bold property of the scale labels will display texts in bold when they are a multiple of 500:
-- returns True (or 1) if the value displayed on the bar -- is a multiple of 500 @scale_value % 500 = 0
塗りつぶしカラー: 塗りつぶし色を指定します.
2番目の塗りつぶしカラー: もう一つの塗りつぶし色を指定します.
Line color: set the color of the lines of the Scale Bar
Fill colors are only used for Single Box and Double Box styles.