From: Simon on
Hi,

I have a notebook with a button in its docked cell. I've been trying
and failing to make it put a message in the status area when you move
the mouse over it, a task that is easy with normal cells.
See the code below, where I've made it clear that the docked cell is
identical to the final cell.

With[{taggedcell=Cell[BoxData[TagBox[StyleBox["Move the mouse over
me!",FontFamily->"Times"],#&, TagBoxNote->"A note in the StatusArea
set by using TagBoxNote"]],"Text"]},
NotebookPut[Notebook[{
Cell["Can DockedCells play nice with the
StatusArea?","Subsubtitle"],
Cell["I want to have a button with a ButtonNote in the docked cell,
but:","Text"],
Cell["As of Version 6.0, the ButtonNote option has been superseded
by the function StatusArea.","Text", Background->LightYellow],
Cell["StatusArea generates a TagBox, so I should first try to get
that working...","Text"],
taggedcell},
DockedCells->{taggedcell}
]]]

Does anyone know a way of doing what I want to do? (or even just
improving the above code?)

Cheers,
Simon

From: John Fultz on
This did work for me on Windows in versions 6 and 7. And there's nothing wrong
with your code. It's quite possible that, if there's a bug here, it's specific
to a particular computer platform. So it'd be useful to know what OS you're
running, and which version of Mathematica.

Sincerely,

John Fultz
jfultz(a)wolfram.com
User Interface Group
Wolfram Research, Inc.

On Sat, 20 Mar 2010 02:45:46 -0500 (EST), Simon wrote:
> Hi,
>
> I have a notebook with a button in its docked cell. I've been trying
> and failing to make it put a message in the status area when you move
> the mouse over it, a task that is easy with normal cells.
> See the code below, where I've made it clear that the docked cell is
> identical to the final cell.
>
> With[{taggedcell=Cell[BoxData[TagBox[StyleBox["Move the mouse over
> me!",FontFamily->"Times"],#&, TagBoxNote->"A note in the StatusArea
> set by using TagBoxNote"]],"Text"]},
> NotebookPut[Notebook[{
> Cell["Can DockedCells play nice with the
> StatusArea?","Subsubtitle"],
> Cell["I want to have a button with a ButtonNote in the docked cell,
> but:","Text"],
> Cell["As of Version 6.0, the ButtonNote option has been superseded
> by the function StatusArea.","Text", Background->LightYellow],
> Cell["StatusArea generates a TagBox, so I should first try to get
> that working...","Text"],
> taggedcell},
> DockedCells->{taggedcell}
> ]]]
>
> Does anyone know a way of doing what I want to do? (or even just
> improving the above code?)
>
> Cheers,
> Simon



From: Simon on
Just to close this thread,

With some help from John Fultz at WRI, it turns out that the above
code works in both Windows and OSX, just not in Linux. Thus it is a
small bug in the front-end for Linux only. A bug report has been
submitted.

Simon