14

I was wondering if there's a way to tell Mathematica to use the option Appearance -> "Labeled" for all Manipulate commands by default. I use this option quite often and it would be very convenient if I could set it to be the default behaviour

Stan
  • 951
  • 6
  • 16
  • 6
    SetOptions[Manipulator, Appearance -> "Labeled"] but this works for one type of control ofc :) – Kuba Sep 22 '13 at 13:52
  • @Kuba Why don't you post that as an answer? – Mr.Wizard Sep 22 '13 at 14:27
  • @Mr.Wizard Because it isn't the answer. :) One still has to do this for Silders etc. But I will try to put more extended answer unless something very neat appear. – Kuba Sep 22 '13 at 15:13
  • @Kuba -- SetOptions seems to work for sliders. Use your code, then Manipulate[a^2, {a, 1, 10}], and you have the appearance labeled. – bill s Sep 22 '13 at 17:28
  • @bills This is Manipulator, try Manipulate[a^2, {a, 1, 10, Slider}] – Kuba Sep 22 '13 at 18:34

1 Answers1

15

I was hesitating but it seems some people find this information useful.

SetOptions[Manipulator, Appearance -> "Labeled"];
Manipulate[{a, b, c},
           {a, 1, 10}, {b, 1, 10}, {c, 1, 10}]

enter image description here

But, still, I do not consider it the full answer. Like it is stated, it affects only Manipulator, the default control used by Manipulate for domains that are suited for slider-like controls.

Unfortunatelly, undesired behaviour appears in case of other controls. Of course not each has Appearance option, but even though Slider do, something strange happens:

SetOptions[Slider, Appearance -> "Labeled"];
Manipulate[{a, b, c},
           {a, 1, 10},
           {b, 1, 10}, 
           {c, 1, 10, Slider, Appearance -> "Labeled"}, 
           ControlType -> Slider]

enter image description here

I guess it's not something we can easily win with in general :) How can I work with SetOptions

but in this case, thanks to ybeltukov, one can use

 Manipulate[{a, b, c},
           {a, 1, 10},
           {b, 1, 10}, 
           {c, 1, 10}, 
           ControlType -> LabeledSlider]

I think that sometimes Slider is better than Manipulator, the latter gives too much control for the users of applications so the may break something :P. Quick fix that works with the method I've shown is:

SetOptions[Manipulator, Appearance -> "Labeled", AppearanceElements -> None]
Kuba
  • 136,707
  • 13
  • 279
  • 740
  • Good enough for my vote. :-) Improve it later if you think of something better. – Mr.Wizard Sep 22 '13 at 23:35
  • @Mr.Wizard Thanks. I will if I find. I'm also looking forward to seeing some MichaelE2-style spelunking :) – Kuba Sep 22 '13 at 23:45
  • 2
    If you type ?DynamicDump`ControlToBoxes you can see exact definition DynamicDump`ControlToBoxes[Slider[BoxForm`a___,Appearance->Labeled,BoxForm`b___],BoxForm`fmt_]:=DynamicDump`ControlToBoxes[LabeledSlider[BoxForm`a,BoxForm`b],BoxForm`fmt]. Therefore Slider doesn't take into account the default options. However there is LabeledSlider! – ybeltukov Sep 22 '13 at 23:46