public class CaptionsConfig
extends java.lang.Object
implements com.longtailvideo.jwplayer.utils.Jsonable
Modifier and Type | Class and Description |
---|---|
static class |
CaptionsConfig.Builder |
Modifier and Type | Field and Description |
---|---|
static int |
CAPTION_DEFAULT_FONT_SIZE
Default caption font size in pixels.
|
static java.lang.String |
CAPTION_EDGE_STYLE_DEPRESSED
Edge type value specifying depressed bevel character edges.
|
static java.lang.String |
CAPTION_EDGE_STYLE_DROP_SHADOW
Edge type value specifying drop-shadowed character edges.
|
static java.lang.String |
CAPTION_EDGE_STYLE_NONE
Edge type value specifying no character edges.
|
static java.lang.String |
CAPTION_EDGE_STYLE_RAISED
Edge type value specifying raised bevel character edges.
|
static java.lang.String |
CAPTION_EDGE_STYLE_UNIFORM
Edge type value specifying uniformly outlined character edges.
|
Constructor and Description |
---|
CaptionsConfig(CaptionsConfig src) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getBackgroundColor() |
int |
getBackgroundOpacity() |
java.lang.String |
getColor() |
java.lang.String |
getEdgeStyle() |
java.lang.String |
getFontFamily() |
int |
getFontOpacity() |
int |
getFontSize() |
java.lang.String |
getWindowColor() |
int |
getWindowOpacity() |
static CaptionsConfig |
parseJson(org.json.JSONObject json) |
static CaptionsConfig |
parseJson(java.lang.String jsonStr) |
void |
setBackgroundColor(java.lang.String backgroundColor) |
void |
setBackgroundOpacity(java.lang.Integer backgroundOpacity) |
void |
setColor(java.lang.String color) |
void |
setEdgeStyle(java.lang.String edgeStyle) |
void |
setFontFamily(java.lang.String fontFamily) |
void |
setFontOpacity(java.lang.Integer fontOpacity) |
void |
setFontSize(java.lang.Integer fontSize) |
void |
setWindowColor(java.lang.String windowColor) |
void |
setWindowOpacity(java.lang.Integer windowOpacity) |
org.json.JSONObject |
toJson() |
java.lang.String |
toString() |
public static final java.lang.String CAPTION_EDGE_STYLE_NONE
public static final java.lang.String CAPTION_EDGE_STYLE_DROP_SHADOW
public static final java.lang.String CAPTION_EDGE_STYLE_RAISED
public static final java.lang.String CAPTION_EDGE_STYLE_DEPRESSED
public static final java.lang.String CAPTION_EDGE_STYLE_UNIFORM
public static final int CAPTION_DEFAULT_FONT_SIZE
public CaptionsConfig(CaptionsConfig src)
public void setColor(java.lang.String color)
color
- Hex color of the captions text.public void setFontSize(java.lang.Integer fontSize)
fontSize
- Size of the captions text (Will not affect text size when rendering captions via browser).public void setFontFamily(java.lang.String fontFamily)
fontFamily
- Font Family of the captions text.public void setFontOpacity(java.lang.Integer fontOpacity)
fontOpacity
- Alpha percentage of the captions text.public void setBackgroundColor(java.lang.String backgroundColor)
backgroundColor
- Hex color of the caption characters background.public void setBackgroundOpacity(java.lang.Integer backgroundOpacity)
backgroundOpacity
- Alpha percentage of the caption characters background.public void setEdgeStyle(java.lang.String edgeStyle)
edgeStyle
- Method by which the captions characters are separated from their background, must be one of the CAPTION_EDGE_STYLE_ constants.public void setWindowColor(java.lang.String windowColor)
windowColor
- Hex color of the background of the entire captions area.public void setWindowOpacity(java.lang.Integer windowOpacity)
windowOpacity
- Alpha percentage of the background of the entire captions area.@NonNull public java.lang.String getColor()
public int getFontSize()
@NonNull public java.lang.String getFontFamily()
public int getFontOpacity()
@NonNull public java.lang.String getBackgroundColor()
public int getBackgroundOpacity()
@NonNull public java.lang.String getEdgeStyle()
@NonNull public java.lang.String getWindowColor()
public int getWindowOpacity()
public java.lang.String toString()
toString
in class java.lang.Object
public org.json.JSONObject toJson()
toJson
in interface com.longtailvideo.jwplayer.utils.Jsonable
public static CaptionsConfig parseJson(org.json.JSONObject json) throws org.json.JSONException
org.json.JSONException
public static CaptionsConfig parseJson(java.lang.String jsonStr)