[ESS] ESS toolbar

David Scott d.scott at auckland.ac.nz
Tue Apr 7 13:57:45 CEST 2009


On Tue, 7 Apr 2009, Stephen Eglen wrote:

>>
>> which doesn't seem to work at all. The variables mentioned,
>> tool-bar-lines and auto-resize-tool-bars don't appear as options when
>> I look for them under Customize. I tried
>>
>> (setq tool-bar-lines 2)
>
> hi David, tool-bar-lines is not a variable -- it is a frame parameter,
> as noted in the manual.  you can set it by setting the X resource
> 'toolbar', but unfortunately for gtk and X11, it has a maximal value of
> 1; from emacs lisp info, in the section on frame parameters:
>
> `menu-bar-lines'
>     The number of lines to allocate at the top of the frame for a menu
>     bar.  The default is 1.  A value of `nil' means don't display a
>     menu bar.  *Note Menu Bar::.  (The X toolkit and GTK allow at most
>     one menu bar line; they treat larger values as 1.)
>
> So, I'm afraid you may be stuck with that.  The only option is to use
> this from ess-toolbar:
>
> (defcustom ess-toolbar-own-icons nil
>  "*Non-nil means that we only put our toolbar entries in ESS.
> Otherwise we get standard toolbar as well as ESS entries.
> Under Emacs, the standard toolbar items are copied from the default toolbar.
> Under XEmacs, the items stored in `ess-toolbar-xemacs-general' are added."
>  :group 'ess-toolbar
>  :type 'boolean)
>
>
> Stephen
>
>

Thanks Stephen. I did try playing around with .Xresources setting the 
value of toolBar before writing to ess-help. I thought the X resources and 
tool-bar-lines were different ways of dealing with the tool bars which is 
probably pretty dumb.

Even after your explanation I am a bit mystified by a few things:

Firstly why does the manual say
  Variable: auto-resize-tool-bar

     If this variable is non-nil, the tool bar automatically resizes to 
show all defined tool bar items but not larger than a quarter of the 
frame's height.

when the tool bar can only have one line? I read that to mean the tool bar 
would increase in height to fit the icons. And auto-resize-tool-bar is 
stated there to be a variable, so what is going on?

Secondly, how is the different behaviour that I noted on windows (where 
the tool bar does expand giving a second row of icons) achieved? Is it 
because the windowing system is different on windows, ie not X?

I can probably live with your workaround, because the only button I really 
use is the Eval line & step one which I use to feed my code into R. It is 
much more convenient to just click on this with the mouse than use command 
keys repeatedly to invoke this function. I guess another option would be 
to rebind that function to some other key sequence, but that could bring 
unforeseen conflicts.

David Scott



_________________________________________________________________
David Scott	Department of Statistics
 		The University of Auckland, PB 92019
 		Auckland 1142,    NEW ZEALAND
Phone: +64 9 373 7599 ext 85055		Fax: +64 9 373 7018
Email:	d.scott at auckland.ac.nz

Graduate Officer, Department of Statistics
Director of Consulting, Department of Statistics




More information about the ESS-help mailing list