Package com.teamdev.jxbrowser.zoom
Class ZoomLevel
java.lang.Object
com.teamdev.jxbrowser.zoom.ZoomLevel
A zoom level of a web page. Provides a set of the pre-defined constants. Each constant name
consists of the
"P_"
prefix followed by a number. The number represents a zoom level in
percents. For example, the P_25
and P_110
values represent the 25% and 110% zoom
levels accordingly.-
Field Summary
Modifier and TypeFieldDescriptionstatic final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
static final ZoomLevel
-
Method Summary
Modifier and TypeMethodDescriptionboolean
int
hashCode()
static ZoomLevel
of
(double value) Returns aZoomLevel
instance for the given double value.toString()
double
value()
Returns double representation of the current zoom level.values()
Returns an immutable list of the pre-defined zoom levels.
-
Field Details
-
P_25
-
P_33
-
P_50
-
P_67
-
P_75
-
P_80
-
P_90
-
P_100
-
P_110
-
P_125
-
P_150
-
P_175
-
P_200
-
P_250
-
P_300
-
P_400
-
P_500
-
-
Method Details
-
of
Returns aZoomLevel
instance for the given double value.- Parameters:
value
- double representation of the zoom level. For 100% zoom level the double value should be 1.0, for 25% – 0.25, etc. See theP_
zoom level constants.- Returns:
- a
ZoomLevel
instance for the given double value - Throws:
IllegalArgumentException
- whenvalue
is negative
-
values
Returns an immutable list of the pre-defined zoom levels. -
toString
-
equals
-
hashCode
public int hashCode() -
value
public double value()Returns double representation of the current zoom level.
-