mozdev.org

LayerEmu    

resources:
Properties of a layer instance
property status emulated notes
Last updated: 11:28 PM EST 7/10/02
_LayerEmu_isLayer read/write n/a This boolean is used internally to shorten code. The only instance this is useful is determing whether a <div> is a layer or not.
_LayerEmu_SpecifiedParent read/write n/a This was implemented because moveAbove() and moveBelow() change a layer's parentLayer without changing the position of the layer. Instead of altering the page's document structure, parentLayer shortcuts to this value if present.
above read/write excellent References the layer directly above it in z-order from all the layers in the entire document, or window if the layer is topmost.
background read/write excellent Refers to (and changes) the layer's background image.
below read/write excellent References the layer directly below it in z-order from all the layers in the entire document, or null if the layer is bottommost.
bgColor read/write excellent Refers to (and changes) the layer's background image.
clip read/write broken The clip property and all related properties (clip.left, clip.width, etc) are broken.
document read excellent For simplicity's sake, refToLayer.document == refToLayer, which means the layer object itself has the document-level collections and methods.
document.anchors
document.applets
document.embeds
document.forms
document.images
document.layers
document.links
read good Collections (actually arrays) of all appropriate elements that are children of the layer. When dealing with nested layers, the outermost layer still treats element within a deeply nested one as a member of this collection, possibly causing a few conflicts. This bug should be fixed in due time.
id read/write excellent This property will always have the same value of the "name" property.
left read/write excellent Always an integer value, it refers to the horizontal distance between the layer and it's parentLayer.
name read/write excellent The layer's name. It provides a means to access to the layer other than by ordinal index in the layers collection.
pageX read/write excellent Always an integer, this value reflects the layer's distance from the left edge of the entire document in pixels.
pageY read/write excellent Always an integer, this value reflects the layer's distance from the top edge of the entire document in pixels.
parentLayer read/write excellent An early form of parentNode, parentLayer refers to the layer's containing layer, or window if it is topmost.
siblingAbove read/write broken *Currently broken* Similar to the "above" property, but only refers to layers with the same parentLayer. If none are found, it returns null.
siblingBelow read/write broken *Currently broken* Similar to the "below" property, but only refers to layers with the same parentLayer. If none are found, it returns null.
src read/write broken? *Currently acting "funny"* Initial tests seem to indicate that it works. The DevEdge docs on layers specify a "source-include" CSS property for layers, which can replace the HTML attribute "src." Unfortunately, I have not found a way in Mozilla to retrieve values of custom CSS-properties (aren't they just ignored and parsed out?). This is perhaps the only unresolvable limitation in this emulation project.
visibility read/write excellent Always has a value of 'show', 'hide', or 'inherit'. It also takes care of any 'visible' and 'hidden' values you may assign it.
x read/write excellent It effectively points to "left".
y read/write excellent It effectively points to "top".
zIndex read/write excellent This refers to the layer's stacking order. (A higher zIndex puts a layer above a layer with a lower zIndex.)

The layeremu project can be contacted through the mailing list or the member list.
Copyright © 2000-2017. All rights reserved. Terms of Use & Privacy Policy.