使用JTable的JScrollpane中的背景图像 [英] Background image in JScrollpane with JTable

查看:47
本文介绍了使用JTable的JScrollpane中的背景图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在JScrollPane中的JTable之后添加居中的背景图像. 背景相对于视口的位置应居中且固定.

Im trying to add a centered background image behind a JTable in a JScrollPane. The position of the background relative to the Viewport should be centered and static.

我曾尝试将JScrollPane添加到具有绘制图像的JPanel上,并使其他所有东西都变得半透明,但是结果很丑陋,并且存在渲染问题.

Ive tried adding the JScrollPane to a JPanel with a drawn image and making everything else translucent, but the result was ugly and had rendering issues.

推荐答案

在末尾查看 WatermarkDemo 本文提供了完整的示例.

Check out the WatermarkDemo at the end of the article for a complete example.

这篇关于使用JTable的JScrollpane中的背景图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆