开发者

Customise JScrollBar arrow

开发者 https://www.devze.com 2023-03-03 23:35 出处:网络
I would like to create JScrollBar with increase and decrease buttons at the bottom in case of vertical scrollbar as shown in the image attached. (Mac OS Style)

I would like to create JScrollBar with increase and decrease buttons at the bottom in case of vertical scrollbar as shown in the image attached. (Mac OS Style)

I need something like

------------O--------开发者_开发百科---<>

instead of

<----------O-------------->

Could you please help me with this?

Customise JScrollBar arrow


Take a look at the source code for the ScrollBarUI or one of the L&F implementations, to see how the individual Look And Feel classes achieve what they achieve. You will then need to re-write the paint method to draw your version.

here is the source code for the BasicL&F.

However, I would also suggest searching for a L&F that already does this, as I am sure someone has already done this in one of the L&F platforms.

0

精彩评论

暂无评论...
验证码 换一张
取 消