Part part = vertical ? Part.TKP_TRACKVERT : Part.TKP_TRACK;
Skin skin = xp.getSkin(slider, part);
if (vertical) {
int x = (trackRect.width - skin.getWidth()) / 2;
skin.paintSkin(g, trackRect.x + x, trackRect.y,
skin.getWidth(), trackRect.height, null);
} else {
int y = (trackRect.height - skin.getHeight()) / 2;
skin.paintSkin(g, trackRect.x, trackRect.y + y,
trackRect.width, skin.getHeight(), null);