ブロックの背景に設定した画像の表示位置を設定するには、 background-positionプロパティを設定します。
pre> background-position: 横の表示位置 縦の表示位置 background-position: 横の表示位置 /pre>
pre> background-position: 横の表示位置 縦の表示位置 background-position: 横の表示位置
/pre>
background-positionプロパティは、 背景画像のウィンドウの中での表示位置を指定します。 表示位置には次のような設定ができます。
pre> body { background-image: url(bgimage.gif); background-repeat: no-repeat; COLOR(red):background-position: COLOR(blue):center centerCOLOR(black):; } /pre>
pre> body {
background-image: url(bgimage.gif); background-repeat: no-repeat; COLOR(red):background-position: COLOR(blue):center centerCOLOR(black):;
}
次へ進んでください。