code: public void setTextMatrix (final Matrix matrix) throws IOException
    {
      if (!inTextMode)
      {
        throw new IllegalStateException ("Error: must call beginText() before setTextMatrix");
      }
      writeAffineTransform (matrix.createAffineTransform ());
      writeOperator ((byte) 'T', (byte) 'm');
    }
docs: The Tm operator. Sets the text matrix to the given values. A current text
  matrix will be replaced with the new one.
  
  @param matrix
  the transformation matrix
  @throws IOException
  If there is an error writing to the stream.
  @throws IllegalStateException
  If the method was not allowed to be called at this time.