Table: Rotate Column Headers

Rotate the cell content of the selected row 90 degrees clockwise.

This script is part of the Tables collection. See the full collection here.ย 

This script is part of the Type and Text collection. See the full collection here.ย 

To rotate a cell’s contents, place the text cursor in the cell and select one of the rotation icons in the Table panel. Here, the content was rotated 90 degrees counter-clockwise:

Rotated cell content causes the cell to become overset.

But as you can see, the cell’s height isn’t adjusted automatically, you’ll have to do that manually. It’s not difficult or a lot of work, but if you have a lot of tables it gets tedious. The script decribed here makes light work of it.

Use

To use the script, place the text cursor in any column heading and run the script. It has no interface. All the cells in the selected row are rotated and the row’s height is adjusted to the longest cell content:

Rotated cells in column headers.

(The script does not snap the columns to their widths. You can use the Table: Column Snap scriptย for that.)

Note

The script defaults to 90 degrees counter-clockwise. You can change that in the script to 90 degrees clockwise by changing the number 270 to 90, other angles aren’t possible with this script.

If you do want other angles (30, 45, or 60 degrees) you can use a method and script created by Keith Gilbert.


Version history

Last updated 25 Jan. 2026


Peter Kahrel Script Repository
Hosted as a community service, and with deep appreciation, by CreativePro.com


Scripts by Topic | Script Index
Basic Script Installation and Use
How to Modify or Configure These Scripts
Resources for Scripting and Publishing Automation
About This Repository


Repository Home Page


Contact Peter Kahrel


Note to users: You run scripts at your own risk: CreativePro and the author accept no liability for anything that may be caused by any of these scripts. Always take the necessary precautions. We encourage you to save backups and test scripts on copies of your documents.

Bookmark
Please login to bookmark Close

This article was last modified on August 22, 2026

Comments (0)

Leave a Reply

Your email address will not be published. Required fields are marked *

Loading comments...