Class Ext.Shadow
Package: | Ext |
Class: | Shadow |
Extends: | Object |
Defined In: | Shadow.js |
Simple class that can provide a shadow effect for any element. Note that the element MUST be absolutely positioned,
and the shadow does not provide any shimming. This should be used only in simple cases -- for more advanced
functionality that can also provide the same shadow effect, see the
Ext.Layer class.
属性
-
方法
-
事件
-
设置选项
公共属性
此类没有公共属性。
公共方法
|
Shadow(Object config ) |
Shadow |
Create a new Shadow |
|
hide() : void |
Shadow |
Hides this shadow |
|
isVisible() : void |
Shadow |
Returns true if the shadow is visible, else false |
|
realign(Number left , Number top , Number width , Number height ) : void |
Shadow |
Direct alignment when values are already available. Show must be called at least once before
calling this method to e... |
|
setZIndex(Number zindex ) : void |
Shadow |
Adjust the z-index of this shadow |
|
show(String/HTMLElement/Element targetEl ) : void |
Shadow |
Displays the shadow under the target element |
公共事件
此类没有公共事件。
设置选项
|
mode : String |
Shadow |
The shadow display mode. Supports the following options: Option Description ------- --------------------------------... |
|
offset : String |
Shadow |
The number of pixels to offset the shadow from the element (defaults to 4) |
构造函数
Shadow
public function Shadow(Object config
)
Create a new Shadow
参数:
config
: ObjectThe config object
方法详情
hide
public function hide()
This method is defined by Shadow.
isVisible
public function isVisible()
Returns true if the shadow is visible, else false
This method is defined by Shadow.
realign
public function realign(Number left
, Number top
, Number width
, Number height
)
Direct alignment when values are already available. Show must be called at least once before
calling this method to ensure it is initialized.
参数:
left
: NumberThe target element left position
top
: NumberThe target element top position
width
: NumberThe target element width
height
: NumberThe target element height
返回:
This method is defined by Shadow.
setZIndex
public function setZIndex(Number zindex
)
Adjust the z-index of this shadow
参数:
zindex
: NumberThe new z-index
返回:
This method is defined by Shadow.
show
public function show(String/HTMLElement/Element targetEl
)
Displays the shadow under the target element
This method is defined by Shadow.
设置详情
mode
mode : String
The shadow display mode. Supports the following options:
Option Description ------- ---------------------------------------------- sides Shadow displays on both sides and bottom only frame Shadow displays equally on all four sides drop Traditional bottom-right drop shadow
This config option is defined by Shadow.
offset
offset : String
The number of pixels to offset the shadow from the element (defaults to 4)
This config option is defined by Shadow.