public class JsCSSStyleDeclaration extends JsElementalMixinBase implements CSSStyleDeclaration
CSSStyleDeclaration.BorderStyle, CSSStyleDeclaration.Cursor, CSSStyleDeclaration.Display, CSSStyleDeclaration.FontStyle, CSSStyleDeclaration.FontWeight, CSSStyleDeclaration.ListStyleType, CSSStyleDeclaration.Overflow, CSSStyleDeclaration.OverflowX, CSSStyleDeclaration.OverflowY, CSSStyleDeclaration.Position, CSSStyleDeclaration.TextDecoration, CSSStyleDeclaration.Unit, CSSStyleDeclaration.Visibility, CSSStyleDeclaration.WhiteSpace
SVG_ZOOMANDPAN_DISABLE, SVG_ZOOMANDPAN_MAGNIFY, SVG_ZOOMANDPAN_UNKNOWN
Modifier | Constructor and Description |
---|---|
protected |
JsCSSStyleDeclaration() |
Modifier and Type | Method and Description |
---|---|
void |
clearBackgroundColor() |
void |
clearBackgroundImage() |
void |
clearBorderColor() |
void |
clearBorderStyle() |
void |
clearBorderWidth() |
void |
clearBottom() |
void |
clearColor() |
void |
clearCursor() |
void |
clearDisplay() |
void |
clearFontSize() |
void |
clearFontStyle() |
void |
clearFontWeight() |
void |
clearHeight() |
void |
clearLeft() |
void |
clearListStyleType() |
void |
clearMargin() |
void |
clearMarginBottom() |
void |
clearMarginLeft() |
void |
clearMarginRight() |
void |
clearMarginTop() |
void |
clearOpacity() |
void |
clearOverflow() |
void |
clearOverflowX() |
void |
clearOverflowY() |
void |
clearPadding() |
void |
clearPaddingBottom() |
void |
clearPaddingLeft() |
void |
clearPaddingRight() |
void |
clearPaddingTop() |
void |
clearPosition() |
void |
clearRight() |
void |
clearTextDecoration() |
void |
clearTop() |
void |
clearVisibility() |
void |
clearWhiteSpace() |
void |
clearWidth() |
void |
clearZIndex() |
String |
getBackgroundColor() |
String |
getBackgroundImage() |
String |
getBorderColor() |
String |
getBorderStyle() |
String |
getBorderWidth() |
String |
getBottom() |
String |
getColor() |
String |
getCssText()
Textual representation of the declaration block.
|
String |
getCursor() |
String |
getDisplay() |
String |
getFontSize() |
String |
getFontStyle() |
String |
getFontWeight() |
String |
getHeight() |
String |
getLeft() |
int |
getLength()
The number of properties.
|
String |
getListStyleType() |
String |
getMargin() |
String |
getMarginBottom() |
String |
getMarginLeft() |
String |
getMarginRight() |
String |
getMarginTop() |
double |
getOpacity() |
String |
getOverflow() |
String |
getOverflowX() |
String |
getOverflowY() |
String |
getPadding() |
String |
getPaddingBottom() |
String |
getPaddingLeft() |
String |
getPaddingRight() |
String |
getPaddingTop() |
JsCSSRule |
getParentRule()
The containing
cssRule. |
String |
getPosition() |
JsCSSValue |
getPropertyCSSValue(String propertyName)
Only supported via getComputedStyle.
Returns a CSSValue, or null for Shorthand properties.Example: cssString= window.getComputedStyle(elem, null ).getPropertyCSSValue('color').cssText;Note: Gecko 1.9 returns null unless using getComputedStyle(). Note: this method may be deprecated by the W3C. |
String |
getPropertyPriority(String propertyName)
Returns the optional priority, "important".
Example: priString= styleObj.getPropertyPriority('color') |
String |
getPropertyShorthand(String propertyName) |
String |
getPropertyValue(String propertyName)
Returns the property value.
Example: valString= styleObj.getPropertyValue('color') |
String |
getRight() |
String |
getTextDecoration() |
String |
getTop() |
String |
getVisibility() |
String |
getWhiteSpace() |
String |
getWidth() |
int |
getZIndex() |
boolean |
isPropertyImplicit(String propertyName) |
String |
item(int index)
Returns a property name.
Example: nameString= styleObj.item(0) Alternative: nameString= styleObj[0] |
String |
removeProperty(String propertyName)
Returns the value deleted.
Example: valString= styleObj.removeProperty('color') |
void |
setBackgroundColor(String value) |
void |
setBackgroundImage(String value) |
void |
setBorderColor(String value) |
void |
setBorderStyle(String value) |
void |
setBorderWidth(double value,
String unit) |
void |
setBorderWidth(String value) |
void |
setBottom(double value,
String unit) |
void |
setBottom(String value) |
void |
setColor(String value) |
void |
setCssText(String param_cssText) |
void |
setCursor(String value) |
void |
setDisplay(String value) |
void |
setFontSize(double value,
String unit) |
void |
setFontSize(String value) |
void |
setFontStyle(String value) |
void |
setFontWeight(String value) |
void |
setHeight(double value,
String unit) |
void |
setHeight(String value) |
void |
setLeft(double value,
String unit) |
void |
setLeft(String value) |
void |
setListStyleType(String value) |
void |
setMargin(double value,
String unit) |
void |
setMargin(String value) |
void |
setMarginBottom(double value,
String unit) |
void |
setMarginBottom(String value) |
void |
setMarginLeft(double value,
String unit) |
void |
setMarginLeft(String value) |
void |
setMarginRight(double value,
String unit) |
void |
setMarginRight(String value) |
void |
setMarginTop(double value,
String unit) |
void |
setMarginTop(String value) |
void |
setOpacity(double value) |
void |
setOverflow(String value) |
void |
setOverflowX(String value) |
void |
setOverflowY(String value) |
void |
setPadding(double value,
String unit) |
void |
setPadding(String value) |
void |
setPaddingBottom(double value,
String unit) |
void |
setPaddingBottom(String value) |
void |
setPaddingLeft(double value,
String unit) |
void |
setPaddingLeft(String value) |
void |
setPaddingRight(double value,
String unit) |
void |
setPaddingRight(String value) |
void |
setPaddingTop(double value,
String unit) |
void |
setPaddingTop(String value) |
void |
setPosition(String value) |
void |
setProperty(String propertyName,
String value)
No return.
Example: styleObj.setProperty('color', 'red', 'important') |
void |
setProperty(String propertyName,
String value,
String priority)
No return.
Example: styleObj.setProperty('color', 'red', 'important') |
void |
setRight(double value,
String unit) |
void |
setRight(String value) |
void |
setTextDecoration(String value) |
void |
setTop(double value,
String unit) |
void |
setTop(String value) |
void |
setVisibility(String value) |
void |
setWhiteSpace(String value) |
void |
setWidth(double value,
String unit) |
void |
setWidth(String value) |
void |
setZIndex(int value) |
addEventListener, addEventListener, beginElement, beginElementAt, dispatchEvent, endElement, endElementAt, getAnimatedClassName, getAnimatedHeight, getAnimatedHref, getAnimatedResult, getAnimatedTransform, getAnimatedWidth, getAnimatedX, getAnimatedY, getBBox, getChildElementCount, getCTM, getExternalResourcesRequired, getFarthestViewportElement, getFirstElementChild, getLastElementChild, getNearestViewportElement, getNextElementSibling, getPresentationAttribute, getPreserveAspectRatio, getPreviousElementSibling, getRequiredExtensions, getRequiredFeatures, getScreenCTM, getSvgStyle, getSystemLanguage, getTransformToElement, getViewBox, getXmllang, getXmlspace, getZoomAndPan, hasExtension, querySelector, querySelectorAll, removeEventListener, removeEventListener, setXmllang, setXmlspace, setZoomAndPan
at, at, intAt, intAt, length, numberAt, numberAt, setAt, setAt, setAt, setAt, setAt, setAt
cast, createArray, createArray, createFunction, createObject, equals, hashCode, toSource, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
intAt, length
numberAt
public final String getCssText()
CSSStyleDeclaration
getCssText
in interface CSSStyleDeclaration
public final void setCssText(String param_cssText)
setCssText
in interface CSSStyleDeclaration
public final int getLength()
CSSStyleDeclaration
getLength
in interface CSSStyleDeclaration
public final JsCSSRule getParentRule()
CSSStyleDeclaration
cssRule.
getParentRule
in interface CSSStyleDeclaration
public final JsCSSValue getPropertyCSSValue(String propertyName)
CSSStyleDeclaration
null
for Shorthand properties.null
).getPropertyCSSValue('color').cssText;getPropertyCSSValue
in interface CSSStyleDeclaration
public final String getPropertyPriority(String propertyName)
CSSStyleDeclaration
getPropertyPriority
in interface CSSStyleDeclaration
public final String getPropertyShorthand(String propertyName)
getPropertyShorthand
in interface CSSStyleDeclaration
public final String getPropertyValue(String propertyName)
CSSStyleDeclaration
getPropertyValue
in interface CSSStyleDeclaration
public final boolean isPropertyImplicit(String propertyName)
isPropertyImplicit
in interface CSSStyleDeclaration
public final String item(int index)
CSSStyleDeclaration
item
in interface CSSStyleDeclaration
public final String removeProperty(String propertyName)
CSSStyleDeclaration
removeProperty
in interface CSSStyleDeclaration
public final void setProperty(String propertyName, String value)
CSSStyleDeclaration
setProperty
in interface CSSStyleDeclaration
public final void setProperty(String propertyName, String value, String priority)
CSSStyleDeclaration
setProperty
in interface CSSStyleDeclaration
public final String getBackgroundColor()
getBackgroundColor
in interface CSSStyleDeclaration
public final void setBackgroundColor(String value)
setBackgroundColor
in interface CSSStyleDeclaration
public final void clearBackgroundColor()
clearBackgroundColor
in interface CSSStyleDeclaration
public final String getBackgroundImage()
getBackgroundImage
in interface CSSStyleDeclaration
public final void setBackgroundImage(String value)
setBackgroundImage
in interface CSSStyleDeclaration
public final void clearBackgroundImage()
clearBackgroundImage
in interface CSSStyleDeclaration
public final String getBorderColor()
getBorderColor
in interface CSSStyleDeclaration
public final void setBorderColor(String value)
setBorderColor
in interface CSSStyleDeclaration
public final void clearBorderColor()
clearBorderColor
in interface CSSStyleDeclaration
public final String getBorderStyle()
getBorderStyle
in interface CSSStyleDeclaration
public final void setBorderStyle(String value)
setBorderStyle
in interface CSSStyleDeclaration
public final void clearBorderStyle()
clearBorderStyle
in interface CSSStyleDeclaration
public final String getBorderWidth()
getBorderWidth
in interface CSSStyleDeclaration
public final void setBorderWidth(String value)
setBorderWidth
in interface CSSStyleDeclaration
public final void clearBorderWidth()
clearBorderWidth
in interface CSSStyleDeclaration
public final void setBorderWidth(double value, String unit)
setBorderWidth
in interface CSSStyleDeclaration
public final String getBottom()
getBottom
in interface CSSStyleDeclaration
public final void setBottom(String value)
setBottom
in interface CSSStyleDeclaration
public final void clearBottom()
clearBottom
in interface CSSStyleDeclaration
public final void setBottom(double value, String unit)
setBottom
in interface CSSStyleDeclaration
public final String getColor()
getColor
in interface CSSStyleDeclaration
public final void setColor(String value)
setColor
in interface CSSStyleDeclaration
public final void clearColor()
clearColor
in interface CSSStyleDeclaration
public final String getCursor()
getCursor
in interface CSSStyleDeclaration
public final void setCursor(String value)
setCursor
in interface CSSStyleDeclaration
public final void clearCursor()
clearCursor
in interface CSSStyleDeclaration
public final String getDisplay()
getDisplay
in interface CSSStyleDeclaration
public final void setDisplay(String value)
setDisplay
in interface CSSStyleDeclaration
public final void clearDisplay()
clearDisplay
in interface CSSStyleDeclaration
public final String getFontSize()
getFontSize
in interface CSSStyleDeclaration
public final void setFontSize(String value)
setFontSize
in interface CSSStyleDeclaration
public final void clearFontSize()
clearFontSize
in interface CSSStyleDeclaration
public final void setFontSize(double value, String unit)
setFontSize
in interface CSSStyleDeclaration
public final String getFontStyle()
getFontStyle
in interface CSSStyleDeclaration
public final void setFontStyle(String value)
setFontStyle
in interface CSSStyleDeclaration
public final void clearFontStyle()
clearFontStyle
in interface CSSStyleDeclaration
public final String getFontWeight()
getFontWeight
in interface CSSStyleDeclaration
public final void setFontWeight(String value)
setFontWeight
in interface CSSStyleDeclaration
public final void clearFontWeight()
clearFontWeight
in interface CSSStyleDeclaration
public final String getHeight()
getHeight
in interface CSSStyleDeclaration
public final void setHeight(String value)
setHeight
in interface CSSStyleDeclaration
public final void clearHeight()
clearHeight
in interface CSSStyleDeclaration
public final void setHeight(double value, String unit)
setHeight
in interface CSSStyleDeclaration
public final String getLeft()
getLeft
in interface CSSStyleDeclaration
public final void setLeft(String value)
setLeft
in interface CSSStyleDeclaration
public final void clearLeft()
clearLeft
in interface CSSStyleDeclaration
public final void setLeft(double value, String unit)
setLeft
in interface CSSStyleDeclaration
public final String getListStyleType()
getListStyleType
in interface CSSStyleDeclaration
public final void setListStyleType(String value)
setListStyleType
in interface CSSStyleDeclaration
public final void clearListStyleType()
clearListStyleType
in interface CSSStyleDeclaration
public final String getMargin()
getMargin
in interface CSSStyleDeclaration
public final void setMargin(String value)
setMargin
in interface CSSStyleDeclaration
public final void clearMargin()
clearMargin
in interface CSSStyleDeclaration
public final void setMargin(double value, String unit)
setMargin
in interface CSSStyleDeclaration
public final String getMarginBottom()
getMarginBottom
in interface CSSStyleDeclaration
public final void setMarginBottom(String value)
setMarginBottom
in interface CSSStyleDeclaration
public final void clearMarginBottom()
clearMarginBottom
in interface CSSStyleDeclaration
public final void setMarginBottom(double value, String unit)
setMarginBottom
in interface CSSStyleDeclaration
public final String getMarginLeft()
getMarginLeft
in interface CSSStyleDeclaration
public final void setMarginLeft(String value)
setMarginLeft
in interface CSSStyleDeclaration
public final void clearMarginLeft()
clearMarginLeft
in interface CSSStyleDeclaration
public final void setMarginLeft(double value, String unit)
setMarginLeft
in interface CSSStyleDeclaration
public final String getMarginRight()
getMarginRight
in interface CSSStyleDeclaration
public final void setMarginRight(String value)
setMarginRight
in interface CSSStyleDeclaration
public final void clearMarginRight()
clearMarginRight
in interface CSSStyleDeclaration
public final void setMarginRight(double value, String unit)
setMarginRight
in interface CSSStyleDeclaration
public final String getMarginTop()
getMarginTop
in interface CSSStyleDeclaration
public final void setMarginTop(String value)
setMarginTop
in interface CSSStyleDeclaration
public final void clearMarginTop()
clearMarginTop
in interface CSSStyleDeclaration
public final void setMarginTop(double value, String unit)
setMarginTop
in interface CSSStyleDeclaration
public final double getOpacity()
getOpacity
in interface CSSStyleDeclaration
public final void setOpacity(double value)
setOpacity
in interface CSSStyleDeclaration
public final void clearOpacity()
clearOpacity
in interface CSSStyleDeclaration
public final String getOverflow()
getOverflow
in interface CSSStyleDeclaration
public final void setOverflow(String value)
setOverflow
in interface CSSStyleDeclaration
public final void clearOverflow()
clearOverflow
in interface CSSStyleDeclaration
public final String getOverflowX()
getOverflowX
in interface CSSStyleDeclaration
public final void setOverflowX(String value)
setOverflowX
in interface CSSStyleDeclaration
public final void clearOverflowX()
clearOverflowX
in interface CSSStyleDeclaration
public final String getOverflowY()
getOverflowY
in interface CSSStyleDeclaration
public final void setOverflowY(String value)
setOverflowY
in interface CSSStyleDeclaration
public final void clearOverflowY()
clearOverflowY
in interface CSSStyleDeclaration
public final String getPadding()
getPadding
in interface CSSStyleDeclaration
public final void setPadding(String value)
setPadding
in interface CSSStyleDeclaration
public final void clearPadding()
clearPadding
in interface CSSStyleDeclaration
public final void setPadding(double value, String unit)
setPadding
in interface CSSStyleDeclaration
public final String getPaddingBottom()
getPaddingBottom
in interface CSSStyleDeclaration
public final void setPaddingBottom(String value)
setPaddingBottom
in interface CSSStyleDeclaration
public final void clearPaddingBottom()
clearPaddingBottom
in interface CSSStyleDeclaration
public final void setPaddingBottom(double value, String unit)
setPaddingBottom
in interface CSSStyleDeclaration
public final String getPaddingLeft()
getPaddingLeft
in interface CSSStyleDeclaration
public final void setPaddingLeft(String value)
setPaddingLeft
in interface CSSStyleDeclaration
public final void clearPaddingLeft()
clearPaddingLeft
in interface CSSStyleDeclaration
public final void setPaddingLeft(double value, String unit)
setPaddingLeft
in interface CSSStyleDeclaration
public final String getPaddingRight()
getPaddingRight
in interface CSSStyleDeclaration
public final void setPaddingRight(String value)
setPaddingRight
in interface CSSStyleDeclaration
public final void clearPaddingRight()
clearPaddingRight
in interface CSSStyleDeclaration
public final void setPaddingRight(double value, String unit)
setPaddingRight
in interface CSSStyleDeclaration
public final String getPaddingTop()
getPaddingTop
in interface CSSStyleDeclaration
public final void setPaddingTop(String value)
setPaddingTop
in interface CSSStyleDeclaration
public final void clearPaddingTop()
clearPaddingTop
in interface CSSStyleDeclaration
public final void setPaddingTop(double value, String unit)
setPaddingTop
in interface CSSStyleDeclaration
public final String getPosition()
getPosition
in interface CSSStyleDeclaration
public final void setPosition(String value)
setPosition
in interface CSSStyleDeclaration
public final void clearPosition()
clearPosition
in interface CSSStyleDeclaration
public final String getRight()
getRight
in interface CSSStyleDeclaration
public final void setRight(String value)
setRight
in interface CSSStyleDeclaration
public final void clearRight()
clearRight
in interface CSSStyleDeclaration
public final void setRight(double value, String unit)
setRight
in interface CSSStyleDeclaration
public final String getTextDecoration()
getTextDecoration
in interface CSSStyleDeclaration
public final void setTextDecoration(String value)
setTextDecoration
in interface CSSStyleDeclaration
public final void clearTextDecoration()
clearTextDecoration
in interface CSSStyleDeclaration
public final String getTop()
getTop
in interface CSSStyleDeclaration
public final void setTop(String value)
setTop
in interface CSSStyleDeclaration
public final void clearTop()
clearTop
in interface CSSStyleDeclaration
public final void setTop(double value, String unit)
setTop
in interface CSSStyleDeclaration
public final String getVisibility()
getVisibility
in interface CSSStyleDeclaration
public final void setVisibility(String value)
setVisibility
in interface CSSStyleDeclaration
public final void clearVisibility()
clearVisibility
in interface CSSStyleDeclaration
public final String getWhiteSpace()
getWhiteSpace
in interface CSSStyleDeclaration
public final void setWhiteSpace(String value)
setWhiteSpace
in interface CSSStyleDeclaration
public final void clearWhiteSpace()
clearWhiteSpace
in interface CSSStyleDeclaration
public final String getWidth()
getWidth
in interface CSSStyleDeclaration
public final void setWidth(String value)
setWidth
in interface CSSStyleDeclaration
public final void clearWidth()
clearWidth
in interface CSSStyleDeclaration
public final void setWidth(double value, String unit)
setWidth
in interface CSSStyleDeclaration
public final int getZIndex()
getZIndex
in interface CSSStyleDeclaration
public final void setZIndex(int value)
setZIndex
in interface CSSStyleDeclaration
public final void clearZIndex()
clearZIndex
in interface CSSStyleDeclaration
Copyright © 2018. All rights reserved.