Java Doc for CSSEngine.java in  » IDE-Netbeans » visualweb.api.designer » org » apache » batik » css » engine » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Netbeans » visualweb.api.designer » org.apache.batik.css.engine 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.batik.css.engine.CSSEngine

All known Subclasses:   org.netbeans.modules.visualweb.designer.markup.RaveElement,  org.netbeans.modules.visualweb.designer.cssengine.XhtmlCssEngine,
CSSEngine
abstract public class CSSEngine (Code)
This is the base class for all the CSS engines.
author:
   Stephane Hillion
version:
   $Id$
author:
   Tor Norbye (see // BEGIN RAVE MODIFICATIONS markers)

Inner Class :public interface StyleElementLink
Inner Class :public interface MainPropertyReceiver
Inner Class :protected class StyleDeclarationDocumentHandler extends DocumentAdapter implements ShorthandManager.PropertyHandler
Inner Class :protected class StyleDeclarationBuilder extends DocumentAdapter implements ShorthandManager.PropertyHandler
Inner Class :protected class StyleSheetDocumentHandler extends DocumentAdapter implements ShorthandManager.PropertyHandler
Inner Class :protected static class DocumentAdapter implements DocumentHandler
Inner Class :protected class StyleDeclarationUpdateHandler extends DocumentAdapter implements ShorthandManager.PropertyHandler
Inner Class :protected class DOMNodeInsertedListener implements EventListener
Inner Class :protected class DOMNodeRemovedListener implements EventListener
Inner Class :protected class DOMSubtreeModifiedListener implements EventListener
Inner Class :protected class DOMCharacterDataModifiedListener implements EventListener
Inner Class :protected class DOMAttrModifiedListener implements EventListener

Field Summary
final protected  int[]ALL_PROPERTIES
     Used to fire a change event for all the properties.
final public static  booleanDEBUG_FILTERING
    
final protected static  CSSEngineListener[]LISTENER_ARRAY
    
final public static  StyleSheetPARSING_SHEET
     Constant which indicates that the given stylesheet is being parsed.
final public static  booleanRULE_FILTERING
     Rule filtering will attempt to quickly filter out rules that don't need to be considered when adding matching rules for an element - that's currently the slowest operation in the designer.
protected  StringalternateStyleSheet
     The alternate stylesheet title.
protected  StringclassLocalName
     The class attribute local name.
protected  StringclassNamespaceURI
     The class attribute namespace URI.
protected  intcolorIndex
     The color property index.
protected  URLcssBaseURI
     The current base URI.
protected  CSSConditionFactorycssConditionFactory
     The CSS condition factory.
protected  CSSContextcssContext
     The CSS context.
protected  Documentdocument
     The associated document.
protected  URLdocumentURI
     The document URI.
protected  EventListenerdomAttrModifiedListener
     The DOMAttrModified event listener.
protected  EventListenerdomCharacterDataModifiedListener
     The DOMCharacterDataModified event listener.
protected  EventListenerdomNodeInsertedListener
     The DOMNodeInserted event listener.
protected  EventListenerdomNodeRemovedListener
     The DOMNodeRemoved event listener.
protected  EventListenerdomSubtreeModifiedListener
     The DOMSubtreeModified event listener.
protected  CSSStylableElementelement
     The current element.
protected  ListfontFaces
     List of StyleMap objects, one for each @font-face rule encountered by this CSSEngine.
protected  intfontSizeIndex
     The font-size property index.
protected  StringIntMapindexes
     The property/int mappings.
protected  intlineHeightIndex
     The line-height property index.
protected  Listlisteners
     The listeners.
protected  SACMediaListmedia
     The media to use to cascade properties.
protected  SetnonCSSPresentationalHints
     The non CSS presentational hints.
protected  StringnonCSSPresentationalHintsNamespaceURI
     The non CSS presentational hints namespace URI.
protected  ExtendedParserparser
     The CSS parser.
protected  String[]pseudoElementNames
     The pseudo-element names.
protected  NoderemovedStylableElementSibling
     The right sibling of the last removed node.
protected  SetselectorAttributes
     The attributes found in stylesheets selectors.
protected  StringIntMapshorthandIndexes
     The shorthand-property/int mappings.
protected  ShorthandManager[]shorthandManagers
     The shorthand managers.
protected  StyleDeclarationBuilderstyleDeclarationBuilder
     The style declaration document handler used to build a StyleDeclaration object.
protected  StyleDeclarationDocumentHandlerstyleDeclarationDocumentHandler
     The style declaration document handler.
protected  StyleDeclarationUpdateHandlerstyleDeclarationUpdateHandler
     The style declaration update handler.
protected  StringstyleLocalName
     The style attribute local name.
public static  intstyleLookupCount
    
protected  StringstyleNamespaceURI
     The style attribute namespace URI.
protected  StyleSheetDocumentHandlerstyleSheetDocumentHandler
     The style sheet document handler.
protected  List<WeakReference<CSSStyleSheetNode>>styleSheetNodes
     The DOM nodes which contains StyleSheets.
protected  booleanstyleSheetRemoved
     Whether a style sheet as been removed from the document.
protected  ListunknownPropertyNames
     When non null, stores a list of properties that were not recognized.
protected  ListunknownPropertyValues
    
 CSSEngineUserAgentuserAgent
    
protected  StyleSheetuserAgentStyleSheet
     The user-agent style-sheet.
protected  StyleSheetuserStyleSheet
     The user style-sheet.
protected  ValueManager[]valueManagers
     The value managers.

Constructor Summary
protected  CSSEngine(Document doc, URL uri, ExtendedParser p, ValueManager[] vm, ShorthandManager[] sm, String[] pe, String sns, String sln, String cns, String cln, boolean hints, String hintsNS, CSSContext ctx)
     Creates a new CSSEngine.
Parameters:
  doc - The associated document.
Parameters:
  uri - The document URI.
Parameters:
  p - The CSS parser.
Parameters:
  vm - The property value managers.
Parameters:
  sm - The shorthand properties managers.
Parameters:
  pe - The pseudo-element names supported by the associatedXML dialect.

Method Summary
public  voidaddCSSEngineListener(CSSEngineListener l)
     Adds a CSS engine listener.
protected  voidaddMatchingRules(List rules, StyleSheet ss, Element elt, String pseudo)
     Adds the rules matching the element/pseudo-element of given style sheet to the list.
protected  voidaddRules(Element elt, String pseudo, StyleMap sm, List rules, short origin)
     Adds the rules contained in the given list to a stylemap.
public  voidaddTransientStyleSheetNode(CSSStyleSheetNode elt)
    
protected  voidapplyNonCSSPresentationalHint(CSSStylableElement elt, StyleMap map, int idx, String value)
     For use by the implementation of applyNonCSSPresentationalHints; apply a non-presentational CSS hint as the given CSS value for the given CSS property.
protected  voidapplyNonCSSPresentationalHint(CSSStylableElement elt, StyleMap map, int idx, Value v)
     For use by the implementation of applyNonCSSPresentationalHints; apply a non-presentational CSS hint as the given CSS value for the given CSS property.
protected  voidapplyNonCSSPresentationalHints(CSSStylableElement elt, StyleMap map)
    
public  voidclearTransientStyleSheetNodes()
    
protected  voiddisplayError(DOMException e, Object location, int lineno, int column)
    
protected  voiddisplayMissingStyleSheet(String uri)
    
public  voiddispose()
     Disposes the CSSEngine and all the attached resources.
protected  voiddisposeStyleMaps(Node node)
    
protected  voidfindSelectorAttributes(Set attrs, StyleSheet ss)
     Finds the selector attributes in the given stylesheet.
protected  voidfindStyleSheetNodes()
    
protected  voidfindStyleSheetNodes(Node n)
     An auxiliary method for getStyleSheets().
protected  voidfirePropertiesChangedEvent(Element target, int[] props)
     Fires a CSSEngineEvent, given a list of modified properties.
public  URLgetCSSBaseURI()
     Returns the current base-url.
public  CSSContextgetCSSContext()
     Returns the CSS context.
public  CSSEngineUserAgentgetCSSEngineUserAgent()
    
public  StyleMapgetCascadedStyleMap(CSSStylableElement elt, String pseudo)
     Returns the cascaded style of the given element/pseudo-element.
public  intgetColorIndex()
     Returns the color property index.
public  ValuegetComputedStyle(CSSStylableElement elt, String pseudo, int propidx)
     Returns the computed style of the given element/pseudo for the property corresponding to the given index.
public  DocumentgetDocument()
     Returns the document associated with this engine.
public  StringgetExpandingShorthandProperty()
     Return the shorthand property being set.
public  ListgetFontFaces()
     Get's the StyleMaps generated by @font-face rules encountered by this CSSEngine thus far.
public  intgetFontSizeIndex()
     Returns the font-size property index.
public static  CSSImportedElementRootgetImportedChild(Node node)
     Returns the imported child of the given node, if any.
public  intgetLineHeightIndex()
     Returns the line-height property index.
public static  NodegetLogicalParentNode(Node parent)
     Returns the logical parent of a node, given its physical parent.
public  StringgetMatchingRules(Element elt, boolean includeAgentRules)
    
public  intgetNumberOfProperties()
     Returns the number of properties.
public static  CSSStylableElementgetParentCSSStylableElement(Element elt)
     Returns the next stylable parent of the given element.
public static  ElementgetParentElement(Element elt)
     Returns the next parent element of the given element, from the CSS point of view.
public  intgetPropertyIndex(String name)
     Returns the property index, or -1.
public  StringgetPropertyName(int idx)
     Returns the name of the property at the given index.
public  intgetShorthandIndex(String name)
     Returns the shorthand property index, or -1.
public  CollectiongetStyleClasses()
     Return a list of style classes defined in the stylesheets for this engine.
public  List<WeakReference<CSSStyleSheetNode>>getStyleSheetNodes()
     Returns the document CSSStyleSheetNodes in a list.
public  StringgetUpdatedLocalStyleValues(CSSStylableElement elt, StyleSetting[] stylesToSet, StyleSetting[] stylesToRemove)
     Updates the local styles for an element.
public  ValueManager[]getValueManagers()
     Returns the ValueManagers.
public  voidimportCascadedStyleMaps(Element src, CSSEngine srceng, Element dest)
     Recursively imports the cascaded style from a source element to an element of the current document.
protected  voidinlineStyleAttributeUpdated(CSSStylableElement elt, StyleMap style, MutationEvent evt)
     Called when the inline style of the given element has been updated.
protected  voidinvalidateProperties(Node node, int[] properties, boolean[] updated, boolean recascade)
     Invalidates all the properties of the given node.
public  booleanisDefaultValue(CSSStylableElement elt, String pseudo, int propidx)
     Return true iff the given CSS property for the given element is not set, e.g.
public  booleanisInheritedValue(CSSStylableElement elt, int propidx)
     Return true iff the given CSS property for the given element was inherited, as opposed to referenced directly by some rule.
protected  booleanmediaMatch(SACMediaList ml)
     Whether the given media list matches the media list of this CSSEngine object.
protected  voidnonCSSPresentationalHintUpdated(CSSStylableElement elt, StyleMap style, String property, MutationEvent evt)
     Called when a non-CSS presentational hint has been updated.
public  ValueparsePropertyValue(CSSStylableElement elt, String prop, String value)
     Parses and creates a property value from elt.
public  StyleDeclarationparseStyleDeclaration(CSSStylableElement elt, String value)
     Parses and creates a style declaration.
public  StyleSheetparseStyleSheet(URL uri, String media, Object location)
     Parses and creates a new style-sheet.
public  StyleSheetparseStyleSheet(InputSource is, URL uri, String media, Object location)
     Parses and creates a new style-sheet.
public  voidparseStyleSheet(StyleSheet ss, URL uri, Object location)
     Parses and fills the given style-sheet.
public  StyleSheetparseStyleSheet(String rules, URL uri, String media, Object location)
     Parses and creates a new style-sheet.
public  voidparseStyleSheet(StyleSheet ss, String rules, URL uri, Object location)
     Parses and fills the given style-sheet.
protected  voidparseStyleSheet(StyleSheet ss, InputSource is, URL uri, Object location)
     Parses and fills the given style-sheet.
protected  voidpropagateChanges(Node node, int[] props, boolean recascade)
     Propagates the changes that occurs on the parent of the given node.
protected  voidputAuthorProperty(StyleMap dest, int idx, Value sval, boolean imp, short origin)
     Puts an author property from a style-map in another style-map, if possible.
public  voidremoveCSSEngineListener(CSSEngineListener l)
     Removes a CSS engine listener.
public  voidsetAlternateStyleSheet(String str)
     Sets the alternate style-sheet title.
protected  voidsetAttributeValue(Element elt, String name, String value)
     Set the given element's value for a given attribute; if value is null, remove the attribute.
public  voidsetCSSEngineUserAgent(CSSEngineUserAgent userAgent)
    
public  voidsetMainProperties(CSSStylableElement elt, MainPropertyReceiver dst, String pname, String value, boolean important)
    
public  voidsetMedia(String str)
     Sets the media to use to compute the styles.
public  voidsetUserAgentStyleSheet(StyleSheet ss)
     Sets the user agent style-sheet.
public  voidsetUserStyleSheet(StyleSheet ss)
     Sets the user style-sheet.
protected  voidsortRules(List rules, Element elt, String pseudo)
     Sorts the rules matching the element/pseudo-element of given style sheet to the list.
protected  StringtoMinimalStyleString(StyleMap map)
     Try to create a minimal (as short as possible) style string from this map, by using shortcuts when possible.
protected  voidwarnCircularReference(URL uri, Object location)
    

Field Detail
ALL_PROPERTIES
final protected int[] ALL_PROPERTIES(Code)
Used to fire a change event for all the properties.



DEBUG_FILTERING
final public static boolean DEBUG_FILTERING(Code)



LISTENER_ARRAY
final protected static CSSEngineListener[] LISTENER_ARRAY(Code)



PARSING_SHEET
final public static StyleSheet PARSING_SHEET(Code)
Constant which indicates that the given stylesheet is being parsed. Used to avoid circular references.



RULE_FILTERING
final public static boolean RULE_FILTERING(Code)
Rule filtering will attempt to quickly filter out rules that don't need to be considered when adding matching rules for an element - that's currently the slowest operation in the designer.



alternateStyleSheet
protected String alternateStyleSheet(Code)
The alternate stylesheet title.



classLocalName
protected String classLocalName(Code)
The class attribute local name.



classNamespaceURI
protected String classNamespaceURI(Code)
The class attribute namespace URI.



colorIndex
protected int colorIndex(Code)
The color property index.



cssBaseURI
protected URL cssBaseURI(Code)
The current base URI.



cssConditionFactory
protected CSSConditionFactory cssConditionFactory(Code)
The CSS condition factory.



cssContext
protected CSSContext cssContext(Code)
The CSS context.



document
protected Document document(Code)
The associated document.



documentURI
protected URL documentURI(Code)
The document URI.



domAttrModifiedListener
protected EventListener domAttrModifiedListener(Code)
The DOMAttrModified event listener.



domCharacterDataModifiedListener
protected EventListener domCharacterDataModifiedListener(Code)
The DOMCharacterDataModified event listener.



domNodeInsertedListener
protected EventListener domNodeInsertedListener(Code)
The DOMNodeInserted event listener.



domNodeRemovedListener
protected EventListener domNodeRemovedListener(Code)
The DOMNodeRemoved event listener.



domSubtreeModifiedListener
protected EventListener domSubtreeModifiedListener(Code)
The DOMSubtreeModified event listener.



element
protected CSSStylableElement element(Code)
The current element.



fontFaces
protected List fontFaces(Code)
List of StyleMap objects, one for each @font-face rule encountered by this CSSEngine.



fontSizeIndex
protected int fontSizeIndex(Code)
The font-size property index.



indexes
protected StringIntMap indexes(Code)
The property/int mappings.



lineHeightIndex
protected int lineHeightIndex(Code)
The line-height property index.



listeners
protected List listeners(Code)
The listeners.



media
protected SACMediaList media(Code)
The media to use to cascade properties.



nonCSSPresentationalHints
protected Set nonCSSPresentationalHints(Code)
The non CSS presentational hints.



nonCSSPresentationalHintsNamespaceURI
protected String nonCSSPresentationalHintsNamespaceURI(Code)
The non CSS presentational hints namespace URI.



parser
protected ExtendedParser parser(Code)
The CSS parser.



pseudoElementNames
protected String[] pseudoElementNames(Code)
The pseudo-element names.



removedStylableElementSibling
protected Node removedStylableElementSibling(Code)
The right sibling of the last removed node.



selectorAttributes
protected Set selectorAttributes(Code)
The attributes found in stylesheets selectors.



shorthandIndexes
protected StringIntMap shorthandIndexes(Code)
The shorthand-property/int mappings.



shorthandManagers
protected ShorthandManager[] shorthandManagers(Code)
The shorthand managers.



styleDeclarationBuilder
protected StyleDeclarationBuilder styleDeclarationBuilder(Code)
The style declaration document handler used to build a StyleDeclaration object.



styleDeclarationDocumentHandler
protected StyleDeclarationDocumentHandler styleDeclarationDocumentHandler(Code)
The style declaration document handler.



styleDeclarationUpdateHandler
protected StyleDeclarationUpdateHandler styleDeclarationUpdateHandler(Code)
The style declaration update handler.



styleLocalName
protected String styleLocalName(Code)
The style attribute local name.



styleLookupCount
public static int styleLookupCount(Code)
For statistics gathering during development



styleNamespaceURI
protected String styleNamespaceURI(Code)
The style attribute namespace URI.



styleSheetDocumentHandler
protected StyleSheetDocumentHandler styleSheetDocumentHandler(Code)
The style sheet document handler.



styleSheetNodes
protected List<WeakReference<CSSStyleSheetNode>> styleSheetNodes(Code)
The DOM nodes which contains StyleSheets.



styleSheetRemoved
protected boolean styleSheetRemoved(Code)
Whether a style sheet as been removed from the document.



unknownPropertyNames
protected List unknownPropertyNames(Code)
When non null, stores a list of properties that were not recognized. This is only currently done for parsing of style expressions, not style sheets, since it's used for local style element manipulation.



unknownPropertyValues
protected List unknownPropertyValues(Code)



userAgent
CSSEngineUserAgent userAgent(Code)



userAgentStyleSheet
protected StyleSheet userAgentStyleSheet(Code)
The user-agent style-sheet.



userStyleSheet
protected StyleSheet userStyleSheet(Code)
The user style-sheet.



valueManagers
protected ValueManager[] valueManagers(Code)
The value managers.




Constructor Detail
CSSEngine
protected CSSEngine(Document doc, URL uri, ExtendedParser p, ValueManager[] vm, ShorthandManager[] sm, String[] pe, String sns, String sln, String cns, String cln, boolean hints, String hintsNS, CSSContext ctx)(Code)
Creates a new CSSEngine.
Parameters:
  doc - The associated document.
Parameters:
  uri - The document URI.
Parameters:
  p - The CSS parser.
Parameters:
  vm - The property value managers.
Parameters:
  sm - The shorthand properties managers.
Parameters:
  pe - The pseudo-element names supported by the associatedXML dialect. Must be null if no support for pseudo-elements is required.
Parameters:
  sns - The namespace URI of the style attribute.
Parameters:
  sln - The local name of the style attribute.
Parameters:
  cns - The namespace URI of the class attribute.
Parameters:
  cln - The local name of the class attribute.
Parameters:
  hints - Whether the CSS engine should support non CSSpresentational hints.
Parameters:
  hintsNS - The hints namespace URI.
Parameters:
  ctx - The CSS context.




Method Detail
addCSSEngineListener
public void addCSSEngineListener(CSSEngineListener l)(Code)
Adds a CSS engine listener.



addMatchingRules
protected void addMatchingRules(List rules, StyleSheet ss, Element elt, String pseudo)(Code)
Adds the rules matching the element/pseudo-element of given style sheet to the list.



addRules
protected void addRules(Element elt, String pseudo, StyleMap sm, List rules, short origin)(Code)
Adds the rules contained in the given list to a stylemap.



addTransientStyleSheetNode
public void addTransientStyleSheetNode(CSSStyleSheetNode elt)(Code)
Notify the engine that a new style element has been created



applyNonCSSPresentationalHint
protected void applyNonCSSPresentationalHint(CSSStylableElement elt, StyleMap map, int idx, String value)(Code)
For use by the implementation of applyNonCSSPresentationalHints; apply a non-presentational CSS hint as the given CSS value for the given CSS property.



applyNonCSSPresentationalHint
protected void applyNonCSSPresentationalHint(CSSStylableElement elt, StyleMap map, int idx, Value v)(Code)
For use by the implementation of applyNonCSSPresentationalHints; apply a non-presentational CSS hint as the given CSS value for the given CSS property.



applyNonCSSPresentationalHints
protected void applyNonCSSPresentationalHints(CSSStylableElement elt, StyleMap map)(Code)
Scan attributes for an element and transcribe deprecated style-type attributes into real style properties



clearTransientStyleSheetNodes
public void clearTransientStyleSheetNodes()(Code)



displayError
protected void displayError(DOMException e, Object location, int lineno, int column)(Code)
Some error occurred while parsing stylesheet - display it to the developer



displayMissingStyleSheet
protected void displayMissingStyleSheet(String uri)(Code)



dispose
public void dispose()(Code)
Disposes the CSSEngine and all the attached resources.



disposeStyleMaps
protected void disposeStyleMaps(Node node)(Code)



findSelectorAttributes
protected void findSelectorAttributes(Set attrs, StyleSheet ss)(Code)
Finds the selector attributes in the given stylesheet.



findStyleSheetNodes
protected void findStyleSheetNodes()(Code)



findStyleSheetNodes
protected void findStyleSheetNodes(Node n)(Code)
An auxiliary method for getStyleSheets().



firePropertiesChangedEvent
protected void firePropertiesChangedEvent(Element target, int[] props)(Code)
Fires a CSSEngineEvent, given a list of modified properties.



getCSSBaseURI
public URL getCSSBaseURI()(Code)
Returns the current base-url.



getCSSContext
public CSSContext getCSSContext()(Code)
Returns the CSS context.



getCSSEngineUserAgent
public CSSEngineUserAgent getCSSEngineUserAgent()(Code)



getCascadedStyleMap
public StyleMap getCascadedStyleMap(CSSStylableElement elt, String pseudo)(Code)
Returns the cascaded style of the given element/pseudo-element.
Parameters:
  elt - The stylable element.
Parameters:
  pseudo - Optional pseudo-element string (null if none).



getColorIndex
public int getColorIndex()(Code)
Returns the color property index.



getComputedStyle
public Value getComputedStyle(CSSStylableElement elt, String pseudo, int propidx)(Code)
Returns the computed style of the given element/pseudo for the property corresponding to the given index.



getDocument
public Document getDocument()(Code)
Returns the document associated with this engine.



getExpandingShorthandProperty
public String getExpandingShorthandProperty()(Code)
Return the shorthand property being set. Set when we're processing a shorthand property such that individual value managers can figure out that they're part of a shorthand property expansion (useful when creating error messages for example. Returns null if no shorthand property is being processed.



getFontFaces
public List getFontFaces()(Code)
Get's the StyleMaps generated by @font-face rules encountered by this CSSEngine thus far.



getFontSizeIndex
public int getFontSizeIndex()(Code)
Returns the font-size property index.



getImportedChild
public static CSSImportedElementRoot getImportedChild(Node node)(Code)
Returns the imported child of the given node, if any.



getLineHeightIndex
public int getLineHeightIndex()(Code)
Returns the line-height property index.



getLogicalParentNode
public static Node getLogicalParentNode(Node parent)(Code)
Returns the logical parent of a node, given its physical parent.



getMatchingRules
public String getMatchingRules(Element elt, boolean includeAgentRules)(Code)
Return a display of the matching rules for the given element



getNumberOfProperties
public int getNumberOfProperties()(Code)
Returns the number of properties.



getParentCSSStylableElement
public static CSSStylableElement getParentCSSStylableElement(Element elt)(Code)
Returns the next stylable parent of the given element.



getParentElement
public static Element getParentElement(Element elt)(Code)
Returns the next parent element of the given element, from the CSS point of view.



getPropertyIndex
public int getPropertyIndex(String name)(Code)
Returns the property index, or -1.



getPropertyName
public String getPropertyName(int idx)(Code)
Returns the name of the property at the given index.



getShorthandIndex
public int getShorthandIndex(String name)(Code)
Returns the shorthand property index, or -1.



getStyleClasses
public Collection getStyleClasses()(Code)
Return a list of style classes defined in the stylesheets for this engine. This will not include any styleclasses defined in the user agent stylesheet.



getStyleSheetNodes
public List<WeakReference<CSSStyleSheetNode>> getStyleSheetNodes()(Code)
Returns the document CSSStyleSheetNodes in a list. This list is updated as the document is modified.



getUpdatedLocalStyleValues
public String getUpdatedLocalStyleValues(CSSStylableElement elt, StyleSetting[] stylesToSet, StyleSetting[] stylesToRemove) throws Exception(Code)
Updates the local styles for an element. First any style settings in the set parameter array are applied, then any properties pointed to by the remove array are applied. The new style string



getValueManagers
public ValueManager[] getValueManagers()(Code)
Returns the ValueManagers.



importCascadedStyleMaps
public void importCascadedStyleMaps(Element src, CSSEngine srceng, Element dest)(Code)
Recursively imports the cascaded style from a source element to an element of the current document.



inlineStyleAttributeUpdated
protected void inlineStyleAttributeUpdated(CSSStylableElement elt, StyleMap style, MutationEvent evt)(Code)
Called when the inline style of the given element has been updated.



invalidateProperties
protected void invalidateProperties(Node node, int[] properties, boolean[] updated, boolean recascade)(Code)
Invalidates all the properties of the given node.



isDefaultValue
public boolean isDefaultValue(CSSStylableElement elt, String pseudo, int propidx)(Code)
Return true iff the given CSS property for the given element is not set, e.g. the default value would be returned instead. Note - it's not the same as asking if the property has the same value as its default property; this method will still return false in that case since it has a value set, so it doesn't have to pull the default value.



isInheritedValue
public boolean isInheritedValue(CSSStylableElement elt, int propidx)(Code)
Return true iff the given CSS property for the given element was inherited, as opposed to referenced directly by some rule.



mediaMatch
protected boolean mediaMatch(SACMediaList ml)(Code)
Whether the given media list matches the media list of this CSSEngine object.



nonCSSPresentationalHintUpdated
protected void nonCSSPresentationalHintUpdated(CSSStylableElement elt, StyleMap style, String property, MutationEvent evt)(Code)
Called when a non-CSS presentational hint has been updated.



parsePropertyValue
public Value parsePropertyValue(CSSStylableElement elt, String prop, String value)(Code)
Parses and creates a property value from elt.
Parameters:
  elt - The element property is from.
Parameters:
  prop - The property name.
Parameters:
  value - The property value.



parseStyleDeclaration
public StyleDeclaration parseStyleDeclaration(CSSStylableElement elt, String value)(Code)
Parses and creates a style declaration.
Parameters:
  value - The style declaration text.



parseStyleSheet
public StyleSheet parseStyleSheet(URL uri, String media, Object location) throws DOMException(Code)
Parses and creates a new style-sheet.
Parameters:
  uri - The style-sheet URI.
Parameters:
  media - The target media of the style-sheet.



parseStyleSheet
public StyleSheet parseStyleSheet(InputSource is, URL uri, String media, Object location) throws DOMException(Code)
Parses and creates a new style-sheet.
Parameters:
  is - The input source used to read the document.
Parameters:
  uri - The base URI.
Parameters:
  media - The target media of the style-sheet.



parseStyleSheet
public void parseStyleSheet(StyleSheet ss, URL uri, Object location) throws DOMException(Code)
Parses and fills the given style-sheet.
Parameters:
  ss - The stylesheet to fill.
Parameters:
  uri - The base URI.



parseStyleSheet
public StyleSheet parseStyleSheet(String rules, URL uri, String media, Object location) throws DOMException(Code)
Parses and creates a new style-sheet.
Parameters:
  rules - The style-sheet rules to parse.
Parameters:
  uri - The style-sheet URI.
Parameters:
  media - The target media of the style-sheet.



parseStyleSheet
public void parseStyleSheet(StyleSheet ss, String rules, URL uri, Object location) throws DOMException(Code)
Parses and fills the given style-sheet.
Parameters:
  ss - The stylesheet to fill.
Parameters:
  rules - The style-sheet rules to parse.
Parameters:
  uri - The base URI.



parseStyleSheet
protected void parseStyleSheet(StyleSheet ss, InputSource is, URL uri, Object location) throws IOException(Code)
Parses and fills the given style-sheet.
Parameters:
  ss - The stylesheet to fill.
Parameters:
  uri - The base URI.



propagateChanges
protected void propagateChanges(Node node, int[] props, boolean recascade)(Code)
Propagates the changes that occurs on the parent of the given node. Props is a list of known 'changed' properties. If recascade is true then the stylesheets will be applied again to see if the any new rules apply (or old rules don't apply).



putAuthorProperty
protected void putAuthorProperty(StyleMap dest, int idx, Value sval, boolean imp, short origin)(Code)
Puts an author property from a style-map in another style-map, if possible.



removeCSSEngineListener
public void removeCSSEngineListener(CSSEngineListener l)(Code)
Removes a CSS engine listener.



setAlternateStyleSheet
public void setAlternateStyleSheet(String str)(Code)
Sets the alternate style-sheet title.



setAttributeValue
protected void setAttributeValue(Element elt, String name, String value)(Code)
Set the given element's value for a given attribute; if value is null, remove the attribute.



setCSSEngineUserAgent
public void setCSSEngineUserAgent(CSSEngineUserAgent userAgent)(Code)



setMainProperties
public void setMainProperties(CSSStylableElement elt, MainPropertyReceiver dst, String pname, String value, boolean important)(Code)



setMedia
public void setMedia(String str)(Code)
Sets the media to use to compute the styles.



setUserAgentStyleSheet
public void setUserAgentStyleSheet(StyleSheet ss)(Code)
Sets the user agent style-sheet.



setUserStyleSheet
public void setUserStyleSheet(StyleSheet ss)(Code)
Sets the user style-sheet.



sortRules
protected void sortRules(List rules, Element elt, String pseudo)(Code)
Sorts the rules matching the element/pseudo-element of given style sheet to the list.



toMinimalStyleString
protected String toMinimalStyleString(StyleMap map)(Code)
Try to create a minimal (as short as possible) style string from this map, by using shortcuts when possible. This will for example compress border-color-left/right/bottom/top into border-color: one two three four, and so on. The default implementation just passes serializes the map directly.



warnCircularReference
protected void warnCircularReference(URL uri, Object location)(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.