Drawing a tilted text in Swing

Main.java:

import javax.swing.event.*;
import java.awt.event.*;
import java.awt.geom.*;
import java.awt.font.*;
import javax.swing.*;
import java.util.*;
import java.awt.*;
 
public class Main extends JFrame { 
   JSlider hslider, vslider;
 
   public Main() {
      addWindowListener(new WindowAdapter() {
         public void windowClosing(WindowEvent we) {
            System.exit(1);
         }
      });
 
      hslider = new JSlider(JSlider.HORIZONTAL, 0, 20, 10);
      hslider.addChangeListener(new ChangeListener() {
         public void stateChanged(ChangeEvent ce) {
            repaint();
         }
      });
 
      vslider = new JSlider(JSlider.VERTICAL, 0, 20, 10);
      vslider.addChangeListener(new ChangeListener() {
         public void stateChanged(ChangeEvent ce) {
            repaint();
         }
      });
  
      hslider.setMajorTickSpacing(1);
      hslider.setPaintTicks(true);
      hslider.setPaintLabels(true);
 
      vslider.setMajorTickSpacing(1);
      vslider.setPaintTicks(true);
      vslider.setPaintLabels(true);
 
      getContentPane().setLayout(new BorderLayout());
      getContentPane().add(BorderLayout.SOUTH, hslider);
      getContentPane().add(BorderLayout.WEST, vslider);
   }
  
   public void paint(Graphics g) {
      super.paint(g); 
  
      Graphics2D g2d = (Graphics2D) g;

      g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                           RenderingHints.VALUE_ANTIALIAS_ON);
  
      String text = "90% of all statistics are made up!";
 
      int w = getSize().width;
      int h = getSize().height;
 
      AffineTransform atShear = new AffineTransform();
      atShear.shear((hslider.getValue()-10)/10.0, -(vslider.getValue()-10)/10.0);
 
      FontRenderContext frc = g2d.getFontRenderContext();
      Font font = new Font("Serif", Font.BOLD, 24);
      Font derivedFont = font.deriveFont(atShear);
      TextLayout tl = new TextLayout(text, derivedFont, frc);
 
      AffineTransform at = new AffineTransform();
      at.setToTranslation(70, h/2);
      g2d.transform(at);
 
      g2d.setColor(Color.blue);
      tl.draw(g2d, 0f, 0f);
 
      g2d.setColor(Color.black);
      g2d.drawString("Shear x:" + (hslider.getValue()-10)/10.0, 60, 50-h/2);
      g2d.drawString("Shear y:" + -(vslider.getValue()-10)/10.0, 150, 50-h/2);
   }
   
   public static void main(String []args) {
      Main main = new Main();
      main.setSize(550, 400);
      main.setVisible(true);
   }
}