Rotate a Graphic Using the Keyboard

by Allen Wyatt
(last updated June 1, 2016)

19

Don knows how to rotate a graphic using the mouse. He wonders, though, if there is a way to rotate a graphic using nothing but the keyboard.

The short answer is "not really." The reason for this is because before you can rotate a graphic you need to select it, and selecting can only be done (as far as I can tell) by using the mouse. If you've just clicked on the graphic to select it, your mouse pointer is already very close to the rotation handle, so you might as well use it to do the rotation.

That being said, after you select the graphic (again, using the mouse) you could use the Alt key, in conjunction with the left and right arrow keys, to rotate the graphic in 15-degree increments in the direction consistent with the arrow key used.

If you want a bit finer control over the rotation, you can follow this convoluted set of steps:

  1. Select the graphic.
  2. Press and release the Alt key. Word displays a set of shortcut indicators next to the ribbon tools.
  3. Press JP to select the Format tab of the ribbon.
  4. Press AY to activate the Rotate tool.
  5. Press R or L to rotate the graphic 90 degrees right or left.
  6. If you prefer, press M to display the options that allow you to specify a rotation angle directly.

You could also set up a keyboard shortcut to directly display the options that appear when you press M. Follow these steps:

  1. Display the Word Options dialog box. (In Word 2007 click the Office button and then click Word Options. In Word 2010 and Word 2013 display the File tab of the ribbon and then click Options.)
  2. At the left side of the dialog box click Customize (Word 2007) or Customize Ribbon (later versions of Word). (See Figure 1.)
  3. Figure 1. The customize options of the Word Options dialog box.

  4. Click the Customize button, near the bottom of the dialog box. Word displays the Customize Keyboard dialog box. (See Figure 2.)
  5. Figure 2. The Customize Keyboard dialog box.

  6. In the list of Categories, choose All Commands.
  7. In the list of Commands, choose MoreRotationOption.
  8. Place the insertion point in the Press New Shortcut Key box.
  9. Press the shortcut key you want to use, such as Alt+R.
  10. Click Assign.
  11. Close the dialog boxes.

Now, after selecting a graphic, you can jump right to the rotation options by pressing the shortcut key you defined in step 7.

Of course, you could also create a set of macros to do the rotations for you and then assign those macros to a set of keyboard shortcuts. The following consists of four macros, three of which can be used to easily rotate a graphic. The RotateCW1 and RotateCW5 macros rotate a graphic clockwise either 1 or 5 degrees. The RotateCCW5 macro rotates a graphic 5 degrees counterclockwise. All three graphics rely on the RotateShape macro to do the majority of the work.

Sub RotateCW1()
    RotateShape (1)
End Sub
Sub RotateCW5()
    RotateShape (5)
End Sub
Sub RotateCCW5()
    RotateShape (-5)
End Sub
Sub RotateShape(Degrees As Single)
    With Selection
        If .ShapeRange.Count = 0 And .Range.ShapeRange.Count = 0 Then
            MsgBox "No shape selected"
            Exit Sub
        End If
        If .ShapeRange.Count > 0 Then
            .ShapeRange.IncrementRotation Degrees
        Else
            .Range.ShapeRange(1).IncrementRotation Degrees
        End If
    End With
End Sub

Again, assign the RotateCW1, RotateCW5, and RotateCCW5 macros to shortcut keys and you can then directly rotate a selected graphic as desired.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (12606) applies to Microsoft Word 2007, 2010, and 2013.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He  is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Stepping Through a Non-Contiguous Range of Cells

Using macros to step through each cell in a selection is a common occurrence. What if that selected range is made up of ...

Discover More

Creating a CSV File

Need to get your data into a format that can be easily read by other programs? Chances are good that a simple CSV file will ...

Discover More

Formatting Captions

When you add captions to elements in your document, Word allows you to modify how those captions are formatted. Here's how ...

Discover More

Do More in Less Time! Are you ready to harness the full power of Word 2013 to create professional documents? In this comprehensive guide you'll learn the skills and techniques for efficiently building the documents you need for your professional and your personal life. Check out Word 2013 In Depth today!

More WordTips (ribbon)

Unwanted Graph Paper Effect

When you open a document or start to use Word, do you see a background that looks like graph paper? It could be because of ...

Discover More

Vertical Lines in Word

Lines can help to organize the data on a page or make certain points clearer. Word provides several different ways you can ...

Discover More

Moving Object Anchors

When you insert an object into your document, it is anchored to a paragraph. If you want to change the paragraph to which the ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 6 + 0?

2015-03-17 09:35:37

Kevin Watters

Thanks Ken! Thats really great of you to write out a macro for me! Thank you very much! It works great too! So as I re-read your original comments that 1st macro was intended for graphics I guess, such as a pasted or imported picture I suppose, and the drawing objects are "Inline Shapes" and require some different code to handle... I did try a picture and your new macro works fine with it too.


2015-03-16 07:48:55

Ken Endacott

Here is a complete macro to rotate shapes including inline shapes.

Sub RotateShape(Degrees As Single)
Dim scountR As Long
Dim scountI As Long
Dim scountS As Long
With Selection
scountR = 0
scountI = 0
scountS = 0
On Error Resume Next
scountS = scountS + .ShapeRange.Count
scountI = scountI + .InlineShapes.Count
scountR = scountR + .Range.ShapeRange.Count
On Error GoTo 0

If Val(Application.Version) < 14 And scountS > 0 Then
If .ShapeRange(1).Type = msoTextBox Then
MsgBox "Cannot rotate textbox in Word 2007"
Exit Sub
End If
End If

If scountR + scountS + scountI = 0 Then
MsgBox "No shape has been selected"
Exit Sub
End If
If scountS > 0 Then .ShapeRange.IncrementRotation Degrees
If scountR > 0 Then .Range.ShapeRange.IncrementRotation Degrees
If scountI > 0 Then
On Error Resume Next
.InlineShapes(1).ConvertToShape
.ShapeRange.IncrementRotation Degrees
.ShapeRange(1).WrapFormat.Type = wdWrapInline
On Error GoTo 0
End If
End With
End Sub


2015-03-15 09:19:46

Kevin Watters

Maybe this is a difference between Word and Excel?


2015-03-15 09:18:32

Kevin Watters

It is a problem with all drawing shapes. I tried Freeform, block arrow, regular arrow, rectangle, scroll, callout and moon. When I edit it by remarking out the If block as shown below, it works fine. It behaves this way on my work pc and my home pc, both win7 64bit though my work pc is win7Pro.
Hmmm - the error message is different on my home pc: "Run-time error '438':
Object doesn't support this property or method."
Sub RotateShape(Degrees As Single)
With Selection
' If .ShapeRange.Count = 0 And .Range.ShapeRange.Count = 0 Then
' MsgBox "No shape selected"
' Exit Sub
' End If
If .ShapeRange.Count > 0 Then
.ShapeRange.IncrementRotation Degrees
Else
.Range.ShapeRange(1).IncrementRotation Degrees
End If
End With
End Sub
I'm happy with it as edited above, with the error trap remarked out. If I forget to select the object first and get an error that's no big deal. Just wondering why that part causes a problem... not that I understand much about vba anyway.


2015-03-14 05:36:02

Ken Endacott

What type of shape were you trying to rotate?


2015-03-13 15:30:26

Kevin Watters

I get error:
Compile error:
Argument bot optional
win764bit excel2010
It does not like:
If ShapeRange.Count = 0 And Range.ShapeRange.Count = 0 Then


2014-04-03 18:26:58

Ken Endacott

I cannot see how the moves by the arrow keys can be made faster except by using macros that increase the move increments.

If you are manipulating graphics, you will find useful free tools at:
http://www.editordie.com.au/editorkae/shapes.html


2014-04-02 12:07:52

ahh

How can I make the graphics move faster when I use the arrow key to move it?


2013-05-22 06:51:42

s.wilkin@adm.com

I'm am on Word 2010 both here and at home so something is different between the two.


2013-05-22 06:50:26

Shirlene

Perhaps it is version driven. On my home PC, I can SHIFT+ARROW in any direction to select a picture or clipart. Here at the office, I have to have my cursor to the immediate right of the object and then SHIFT+LEFT ARROW to select it. I can then ALT+ARROW to rotate in any direction. Drawn objects from the SHAPES options doesn't work from the office either.


2013-05-21 18:22:20

Ken Endacott

The SHIFT + ARROW keys don't seem to work in a copy of Word 2007 that I have on an old laptop. Also, the rotation menu in the Drawing Tools ribbon works differently to Word 2010. It deselects the shape after each rotation.


2013-05-21 03:36:57

Richard

I am using W2007 SP2 from Office Professional Plus.
It doesn't matter whether I insert a picture, a shape or clip art, the result is the same.


2013-05-18 21:09:58

Ken Endacott

I mean version of Word, not Windows.


2013-05-18 05:10:16

Ken Endacott

Richard,

What version of Word are you using?

The ability to rotate only came in with W2007 and there were bugs that were fixed in W2010.


2013-05-17 06:09:49

Richard

"The problem seems to be how the shape is selected. There are two types of selection - the first is by clicking just the shape, in which case the four corners of the box containing the shape are marked with small circles as well as the midpoint in the sides. Also a rotation handle is displayed. ALT + left or right arrow keys will then rotate the shape."

Ken - this is how I selected the shape, but Alt + left or right arrow keys does nothing.


2013-05-16 06:44:30

Ken Endacott

Richard,

The problem seems to be how the shape is selected. There are two types of selection - the first is by clicking just the shape, in which case the four corners of the box containing the shape are marked with small circles as well as the midpoint in the sides. Also a rotation handle is displayed. ALT + left or right arrow keys will then rotate the shape.

The second selection method is by clicking to the left of the text margin at the shape, or by SHIFT + arrow, or by dragging the cursor past the shape, or if you want to use keyboard only, by usung SHIFT + arrow, or by using the arrow keys to move the cursor to above the shape, clicking F8 then moving the cursor via arrow keys to below the shape and clicking ESC. The shape is then highlighted (along with one or more paragraph marks) and surrounded by a thick walled box. There will be no rotation handle shown and the ALT + arrow keys will not rotate it.

You could use a macro to convert from the second to the first selection type, after which the ALT + arrow keys work. The macro is:
Sub SwitchShape()
Selection.Range.ShapeRange(1).Select
Selection.Range.ShapeRange(1).IncrementRotation 0
End Sub

It would be much simpler to use the mouse to click on the shape, then use the rotation keys.



2013-05-16 03:34:32

Richard

Alt plus arrow keys doesn't work for me for a selected object in Word 2007. I inserted the 5-point star shape but Alt+left and Alt+right did nothing. Alt+up deselected the star. Also tried turning off Num Lock and using the keypad arrows. Tried Alt+Shift+left/right but this set and changed heading levels.


2013-04-29 23:51:32

Ken Endacott

You can use the keypad to select and rotate shapes including drawn shapes, without using the mouse.

As Shirlene mentions, you can use shortcut keys to select a block of text that also contains the shape's anchor and hence the shape. Unfortunately, the ALT + arrow rotation tools will not work on such a composite selection unless the shape is the only thing selected. The following will get around this problem.

Select a portion of the document containing the shape. My suggestion is to move the cursor to a paragraph before the shape's anchor paragraph, click F8, move the cursor to below the anchor and click ESC. The shape will now be highlighted as well as the text in the selection.

To rotate the shape click the the keyboard shortcuts that are associated with the macros given in the tip. Click the shortcuts again to further rotate the shape.




2013-04-27 21:55:46

Shirlene Wilkin

You can select an image or clipart using SHIFT+ARROW (any direction, depending on where you need to go). This does not work with a drawn shape. And, yes, the steps for rotating are convoluted but they do work. For those of us who eschew the mouse whenever possible, we put up with convoluted keystrokes.


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.