14
$\begingroup$

Mathematica seriously lacks some useful toolbars. I wonder why keeping a totally barebone gui is part of WRI's policy? Would such a feature be so platform-specific that it does not worth design it? I really am clueless here. Palettes are fine, but they don't behave like toolbars or dockers. First of all, I have to write them (which is in itself is not trivial to do, see e.g. this post on MathGroup), but then even if I create some, how can I tell them to appear every time I start Mathematica, and that they should appear the same place (e.g. toolbar should be below menubar)? It would be nice to have a toolbar where some of the functionality of the menu and custom-wrote functions can be accessed easily.

Note that this question is not just about how to implement it, but also about why this was not implemented so far. If you think that this does not belong here, I am happy to ask it on meta or delete it. For those requiring a specific question for which some coding can be done, here it is:

Question:

How to implement a toolbar with buttons like Restart kernel, Delete all output, Show memory in use, Turn off syntax colouring, etc. which always starts with Mathematica and docks just below the menubar in such a way that when windows are maximized, they do not go behind or cover it?

$\endgroup$
6
  • 1
    $\begingroup$ Do docked cells not do what you want, apart from being there by default? If yes then I would have thought the real question is "How do I arrange it so that when I start a new nb it has some docked cells by default?". Or are docked cells inappropriate? $\endgroup$
    – acl
    Feb 3, 2012 at 11:54
  • 2
    $\begingroup$ No, because docked cells dock to notebooks and not to the menu bar as far as I understand the concept. This is not the proper way of doing a toolbar. Also, docked cells quickly become redundant if you have multiple notebooks, but you can't use any of their functionality if all notebooks are minimized. $\endgroup$ Feb 3, 2012 at 12:05
  • $\begingroup$ If all notebooks are minimized, there's no menu bar under which the toolbar could be docked. Or any other place (apart possibly from palettes) where I could imagine putting a toolbar. $\endgroup$
    – celtschk
    Feb 3, 2012 at 13:39
  • $\begingroup$ On Linux each window (each notebook) has a menu bar. A docked cell set for the $FrontEnd object would be very similar. I agree though that it seems like a waste of space. @celtschk Menu bars are part of notebook windows only on Linux, not on Windows or Mac. $\endgroup$
    – Szabolcs
    Feb 3, 2012 at 14:02
  • $\begingroup$ @Szabolcs: Ok, on Mac the menu bar is always on the top of the screen, for all applications. However I wonder where Mathematica puts the menu bar on Windows, because Windows also has the menu bars on top of the windows. $\endgroup$
    – celtschk
    Feb 3, 2012 at 14:07

1 Answer 1

8
$\begingroup$

To begin with, if you use menu: Palettes > Install Palette... the palette should open in the place it last appeared every time you start Mathematica. I always have two custom palettes visible when I start Mathematica:

  1. A palette to open one of dozen Notebooks I use frequently

  2. Szabolcs's Paste Tabular Data

These admittedly do not "dock" if I move them around, but I have never actually looked for that option so it may be possible. I know that you can make a palette float always-on-top with the option WindowFloating (in fact this may be the default; it it switchable with WindowFloating).

In answer to why I suppose:

  1. Because people do such a range of different things with Mathematica there is less value in a standard toolbar.

  2. Palettes actually do provide for a reasonably similar functionality

  3. Actual toolbars are seen as taking up screen space

  4. Someone in the FrontEnd GUI department is lazy. This would also explain the lack of a multi-step Undo. ;-)

$\endgroup$
8
  • 1
    $\begingroup$ +1, and +lots for the multilevel undo comment $\endgroup$
    – WReach
    Feb 5, 2012 at 0:52
  • 1
    $\begingroup$ Point 4 touches something I did not dare to ask here... $\endgroup$ Feb 16, 2012 at 0:04
  • $\begingroup$ Mathematica 10 does have multiple-level undo (and re-do). $\endgroup$
    – murray
    Feb 5, 2015 at 23:42
  • $\begingroup$ @murray Yes, and I think we're all grateful for it. $\endgroup$
    – Mr.Wizard
    Feb 6, 2015 at 3:44
  • $\begingroup$ @Mr.Wizard, you say " I always have two custom palettes visible when I start Mathematica". How do you do that? Specifically, I have installed the Palette from here, and I want this to appear whenever I open a notebook. Sorry for off topic. $\endgroup$ Mar 25, 2015 at 7:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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