I am writing a palette to work with units on Mathematica 9, using just PasteButtons, and have a Button map that works as I want it to, but the formatting of the palette itself is giving me issues. I want to have it dynamically resize like the Wolfram created "Basic Math Assistant" does, so that when a section is closed, it fits tightly around the Opener and text, and when a section opens, the Palette resizes to accommodate, and includes scrollbars iff necessary. Below is my code for my Palette, with "ButtonMap" being just a 3X18 grid of PasteButtons.

CreatePalette[Column[{OpenerView[{Style["Units and Constants", FontSize -> 18], 

The only real issue is the implementation of the scrollbar, Having it only when needed. Any Help would be greatly appreciated.

  • $\begingroup$ That's unclear ot me. If you want to resize to fit, when should your scrollbar appear? I'm also not sure why are you mentioning resizing the window at all, when, as you say, it works already. Could you explain further? $\endgroup$ – Kuba May 6 '16 at 8:27
  • $\begingroup$ The button map extends beyond the size of my screen, so if i don't have a scrollbar, i cant get to the bottom buttons. $\endgroup$ – Brandon Myers May 6 '16 at 17:54
  • 2
    $\begingroup$ Is that the answer? mathematica.stackexchange.com/q/96674/5478 $\endgroup$ – Kuba May 6 '16 at 18:03
  • $\begingroup$ Absolutely Perfect. Thank you. $\endgroup$ – Brandon Myers May 9 '16 at 0:12

Browse other questions tagged or ask your own question.