# Altering layout and sizing of Manipulate controls?

I'm currently working on a display project using Manipulate and was wondering if there is a straightforward way to alter the placement of the control options that I use. For example, the following shows my issue:

The Manipulate argument of concern is as follows:

Style["View Control", 16, Bold],
{{setter, True, ""}, {True -> "Zoom", False -> "Pan"}},
ControlPlacement -> Left,


I would just like the Zoom and Pan buttons of the SetterBar to be a bit larger and closer to centered if possible. I've messed with things like Appearance and Alignment, but haven't really had any luck with previous questions or my own efforts.

-

## 1 Answer

I think you've got to take over placement manually. First declare the variable setter with no control (None). Next add a SetterBar. Put this inside a Pane so you can control placement. The ImageSize of the Pane needs to be determined by hand. You can use ImageSize -> Full, which makes it fill the width of the notebook window -- perhaps desirable or not. You can Style the text how you wish.

Manipulate[setter,
Delimiter, Style["View Control", 16, Bold],
{{setter, True, ""}, None},
Dynamic@Pane[
SetterBar[Dynamic@setter,
{True -> Style["Zoom", Larger], False ->  Style["Pan", Larger]}],
Alignment -> Center, ImageSize -> 100],
ControlPlacement -> Left]


If you are really fighting the automatic decisions of Manipulate, you might consider doing everything yourself in a DynamicModule. Many find it easier. (Or just go with the default in Manipulate.)

-
I used to control the SetterBar elements with f = Framed[#, Alignment -> Center, FrameStyle -> None, ImageSize -> {45, 25}] &;. And then simply: True -> f@"Zoom",.... A little way around, but SetterBar has no ItemSize option. –  Kuba Jul 22 '13 at 17:29
@Kuba One of the Wolfram people once showed me how to use Pane, the way you used Frame (mapping it onto each item). –  Michael E2 Jul 22 '13 at 17:37