Microsoft
Software
Hardware
Network
Question : anyone familur ith using the swing classes HTMLEditorKit StyleSheet and reading a external CSS
hello i am trying to read an external CSS file and get some attributes , like background color of a ID
so this part works ok
HTMLEditorKit kit = new HTMLEditorKit();
HTMLDocument doc = (HTMLDocument) kit.createDefaultDocument(
);
StyleSheet styles = doc.getStyleSheet();
styles.importStyleSheet( new URL("
http://test2.mydomain
.com/user.
css
") );
Enumeration rules = styles.getStyleNames();
while (rules.hasMoreElements()) {
System.out.println("------
----------
----------
---------"
);
String name = (String) rules.nextElement();
Style rule = styles.getStyle(name);
System.out.println(name+"-
-->"+rule.
toString()
);
}
i am trying to get the background color of the content
this is what the outs are printing
#content--->NamedStyle:#co
ntent {resolver=AttributeSet,nam
e=#content
,}
not sure where to go from here?
thanks for any help
Answer : anyone familur ith using the swing classes HTMLEditorKit StyleSheet and reading a external CSS
you can also donate to non-profit organisations...
Random Solutions
Communigate Pro bounce back "The message was not delivered because the return address was refused"
dateDiff - combining a date selection and a time selection
How does the pointers of an inode's data block relattes to the logical block address of a SCSI device?
PHP: Decode Modified Base64
Combofix Log - Analysis Assistance Request
SPID process blocking itself
After moving mailbox to Exchange 2007 lost all Outlook rules
Quickbooks 2010 QB crashes when trying to print to network printer
Installing SSL certifcate on exchange 2010
How do I delete a file from a folder (uploads directory) when I delete its reference in the database?