Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.math.mathematica

Topic: Using a notebook - how to add a caption and ...
Replies: 1   Last Post: Feb 10, 2013 3:35 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View  
David Park

Posts: 1,560
Registered: 5/19/07
Re: Using a notebook - how to add a caption and ...
Posted: Feb 10, 2013 3:35 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Ed,

For the picture you might try something like the following:

CellPrint[
Cell[BoxData[
ToBoxes[Image[pastePictureHere, ImageSize -> 400] // Framed //
Labeled[#,
Style["A beautiful picture", 16, FontFamily -> "Ariel",
ShowStringCharacters -> False], {{Bottom, Left}}] &]],
CellMargins -> {{200, Automatic}, {4, 4}}
]
]

However, I don't know how to keep the picture centered if the notebook width
is changed.

Using Framed and Labeled (or sometimes just Labeled) is a good way to add a
"caption" to any graphic. In my opinion much better than using PlotLabel,
which is practically archaic.

To obtain a dynamic entry in a Text cell use an InlineCell.
omega = 3.4
Then a Text cell:

In the following the value of omega is Dynamic[omega] until it is changed
again.

Here the Dynamic[omega] is put in an InlineCell and then evaluated in place.
Then whenever you change omega it will also change in the Text cell.


David Park
djmpark@comcast.net
http://home.comcast.net/~djmpark/index.html




From: Eduardo MAM Mendes [mailto:emammendes@me.com]

Hello

I have been using notebooks to write reports for a while. Although I am
getting by (the package Presentations by David Park has been of great help),
I still have some points that I am not sure how to handle. Ok, here they
are:

a) Insert-> Picture-> From file inserts the jpg as advertised however I did
not figure out how to add a text box that works as a caption just below the
figure in the same cell. Of course the cell cannot be evaluated, so I have
turn off that option. If there is a way to add the caption, I wonder whether
the whole cell - picture + caption - could be centered justified.

b) Style - Text - How to create a dynamic cell, that is, suppose I have a
text cell as follows

After some calculation the value of the variable omega is 3.4.

Instead of 3.4, I wonder whether it could be the actual calculated value of
omega. If omega changes I do not need to change the text cell to update its
value.

One thing that I've noticed is that one has to keep the cell size to a
minimum, otherwise lots of almost blank pages come out of the printer.

Any tips and help will be most appreciated.

Many thanks

Ed






Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.