类javax.swing.text.html.CSS源码实例Demo

下面列出了怎么用javax.swing.text.html.CSS的API类实例代码及写法,或者点击链接到github查看源代码。

源代码1 项目: pentaho-reporting   文件: HtmlRichTextConverter.java
private boolean isInvisible( final javax.swing.text.Element textElement ) {
  final HTMLDocument htmlDocument = (HTMLDocument) textElement.getDocument();
  final StyleSheet sheet = htmlDocument.getStyleSheet();
  final AttributeSet attr = computeStyle( textElement, sheet );
  final Object o = attr.getAttribute( CSS.Attribute.DISPLAY );
  if ( "none".equals( String.valueOf( o ) ) ) {
    return true;
  }
  final Object tag = findTag( textElement.getAttributes() );
  if ( tag == HTML.Tag.COMMENT ) {
    return true;
  }
  if ( tag == HTML.Tag.SCRIPT ) {
    return true;
  }
  if ( tag == HTML.Tag.HEAD ) {
    return true;
  }
  return false;
}
 
 类所在包
 同包方法