public final class BackgroundImage extends Object
Region
に背景としてイメージをレンダリングする方法を記述するプロパティを定義します。BackgroundImageにはImageを指定する必要があります(nullにはできません)。repeatX
およびrepeatY
プロパティは、各方向でイメージを繰り返す方法を定義します。position
プロパティはリージョンにイメージを配置する方法を定義し、size
プロパティはリージョンのイメージのサイズを定義します。たとえば、size
がcover = true
に定義されている場合は、リージョンのレンダリング面全体をカバーするようにイメージを拡大する必要があることを意味します。
BackgroundImageは不変であるため、どのキャッシュでも安全に使用でき、複数のリージョンの間で安全に再使用できます。コンストラクタと説明 |
---|
BackgroundImage(Image image, BackgroundRepeat repeatX, BackgroundRepeat repeatY, BackgroundPosition position, BackgroundSize size)
新しいBackgroundImageを作成します。
|
修飾子と型 | メソッドと説明 |
---|---|
boolean |
equals(Object o) |
Image |
getImage()
使用されるイメージ。
|
BackgroundPosition |
getPosition()
リージョンに対して相対的なこのBackgroundImageの位置。
|
BackgroundRepeat |
getRepeatX()
該当する場合に、背景イメージがリージョンのx軸に沿ってどのように繰り返されるかを示します。
|
BackgroundRepeat |
getRepeatY()
該当する場合に、背景イメージがリージョンのy軸に沿ってどのように繰り返されるかを示します。
|
BackgroundSize |
getSize()
リージョンに対して相対的なこのイメージのサイズ。
|
int |
hashCode() |
public BackgroundImage(Image image, BackgroundRepeat repeatX, BackgroundRepeat repeatY, BackgroundPosition position, BackgroundSize size)
image
を指定する必要があります。image
- 使用するイメージ。nullを指定することはできません。repeatX
- x軸に対するBackgroundRepeat。nullの場合、この値のデフォルトはREPEATです。repeatY
- y軸に対するBackgroundRepeat。nullの場合、この値のデフォルトはREPEATです。position
- 使用するBackgroundPosition。nullの場合、デフォルトはBackgroundPosition.DEFAULTです。size
- BackgroundSize。nullの場合、デフォルトはBackgroundSize.DEFAULTです。public final Image getImage()
public final BackgroundRepeat getRepeatX()
public final BackgroundRepeat getRepeatY()
public final BackgroundPosition getPosition()
public final BackgroundSize getSize()
Copyright (c) 2008, 2015, Oracle and/or its affiliates. All rights reserved.