E
emf
I have a textarea with a vertical scrollbar; I have changed the
scrollbar's and I want to change the scrollbar's. After trying
unsuccessfully to change the colors of the scroolbar with
scroller.setForeground(Color.GRAY);
scroller.setBackground(Color.BLACK);
I managed to change its background color with
scroller.getVerticalScrollBar().setBackground(Color.BLACK);
the command however
scroller.getVerticalScrollBar().setForeground(Color.GRAY);
has no effect.
Googling I found that I have to use
public TextPaneRenderer() {
setEditable(false);
putClientProperty(HONOR_DISPLAY_PROPERTIES, Boolean.TRUE);
}
(https://forums.oracle.com/forums/thread.jspa?threadID=2269764)
but I do not know what to make of it. How exactly do I insert it in the
code=? And do I have to import something?
Thanks,
Eustace
scrollbar's and I want to change the scrollbar's. After trying
unsuccessfully to change the colors of the scroolbar with
scroller.setForeground(Color.GRAY);
scroller.setBackground(Color.BLACK);
I managed to change its background color with
scroller.getVerticalScrollBar().setBackground(Color.BLACK);
the command however
scroller.getVerticalScrollBar().setForeground(Color.GRAY);
has no effect.
Googling I found that I have to use
public TextPaneRenderer() {
setEditable(false);
putClientProperty(HONOR_DISPLAY_PROPERTIES, Boolean.TRUE);
}
(https://forums.oracle.com/forums/thread.jspa?threadID=2269764)
but I do not know what to make of it. How exactly do I insert it in the
code=? And do I have to import something?
Thanks,
Eustace