As you can see in the drawing, I'm making a little Manipulate program. I'd now like to decrease the size of the controls at the left—to have more space for the Graphics[]. How is this possible? I've searched in the Documentation, but haven't found anything helpful.

Perhaps is it possible to use the grey space in the left part of the screen for displaying purposes (Print or Text)? For example, print the Cosine of the angle alpha somewhere in the left Pane?

Thanks for all help!

enter image description here

  • $\begingroup$ Look up the ImageSize option to Manipulator. $\endgroup$ – Michael E2 Nov 20 '13 at 17:00

Put the slider vertical instead of horizontal:

Manipulate[Plot[Sin[2 Pi f t], {t, 0, 10}], 
   {f, 1, 5, ControlType -> VerticalSlider, ControlPlacement -> Left}]

enter image description here

You can use the grey space for text, graphics, or whatever you wish. There are many examples in the help file for the Manipulate command.

 Plot[Sin[x], {x, 0, 1}], 
    {R, 0, 1},
   {{y, 1, ""}, {1, 2, 3}, Appearance -> "Vertical", Labeled -> False}, 
    ControlType -> {Slider, CheckboxBar}, 
    ControlPlacement -> {Top, Left}]

Mathematica graphics


Reading the manual some more, I found the construct Item[] to add text in the left panel. So, for example:

   Row[{"sin(α) = ",
   Dynamic[Round[Sin[alpha], 0.01]]

together with

{{alpha, 0, "alpha"}, 0, Pi/2}

works very well!

Edit: I add here the full code of the little program, as asked:

 ParametricPlot[{Cos@t, Sin@t}, {t, 0, alpha}, PlotRange -> 1.2] /. 
  Line -> Arrow
 , {alpha, 0.1, 2 Pi}
 , Delimiter
 , Item[Row[{"sin(\[Alpha]) = ", Dynamic[Round[Sin[alpha], 0.01]]}]]
 , Item[Row[{"cos(\[Alpha]) = ", Dynamic[Round[Cos[alpha], 0.01]]}]]
 , ControlPlacement -> Left

Hope this helps!

  • $\begingroup$ The Item is unnecessary. Row[..] works fine without it. And you can put both Row into one Grid, if you want. $\endgroup$ – Michael E2 Nov 21 '13 at 18:44
  • $\begingroup$ @MichaelE2: thanks for the comment! $\endgroup$ – Gabriel Nov 21 '13 at 20:40
  • $\begingroup$ @Gabriel Thank you, now I see. To address your original question you can gain a lot of space by replacing in your code this: {alpha, 0.1, 2 Pi} by this: {alpha, 0.1, 2 Pi, ControlType -> Slider, ImageSize -> {100, 15}}. Play a bit with the parameters of the ImageSize. There are few other ways I use. For example, slider - on top, sin(alfa) and so on - left. But you seem to have already received a satisfactory solution, have you? $\endgroup$ – Alexei Boulbitch Nov 22 '13 at 10:00
  • $\begingroup$ @AlexeiBoulbitch: yes, indeed, the solutions are satisfactory. Thanks for your comment! $\endgroup$ – Gabriel Nov 23 '13 at 8:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.