이미지를 테스트했지만 투명하지 않습니다. 틀림없이 그것은 이유 다.
<html>
<body style="background-color:#99cccc;">
<table>
<tr>
<th>your one isn't transparent</th>
<th>this one is</th></tr>
<tr>
<td><img src="http://i.stack.imgur.com/BvYxM.png" style="border:5px solid green;"/></td>
<td><img src="http://www.axdn.com/redist/axpssp_logo.png" style="border:5px solid green;"/></td></tr>
</table>
</body>
</html>
@Gabe :이 파일을 html 파일에 붙여넣고 브라우저에로드하십시오. 이것은 분명히 java와 관련된 문제가 아닙니다.
여기에 이미지가 투명하지 않고 적절한 투명 PNG가 잘 작동한다는 Java 증명이 있습니다.
public static void main(String[] args) throws Throwable
{
JFrame frame = new JFrame();
frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
Container cp = frame.getContentPane();
cp.setBackground(Color.RED);
cp.setLayout(new FlowLayout());
cp.add(new JLabel(new ImageIcon(new URL("http://i.stack.imgur.com/BvYxM.png"))));
cp.add(new JLabel(new ImageIcon(new URL("http://www.axdn.com/redist/axpssp_logo.png"))));
frame.pack();
frame.setVisible(true);
}
투명 왜이 HTML 페이지에 투명하게 표시하지 않는 이유는 무엇입니까? – pstanton