Questions on Notebooks (*.nb, *.ma in earlier versions), structured interactive documents produced by Mathematica that can contain text, graphics, sound, calculations, typeset expressions, and user interface elements.

learn more… | top users | synonyms (1)

2
votes
1answer
55 views

Prevent Cell Deletion

How might I be able to prevent a Cell form being deleted when you press the Delete key? Maybe there is a way to display some type of ...
2
votes
1answer
57 views

How do I force all Graphics Text to be StandardForm?

I've been playing around for while trying to determine how to get all graphic objects to use StandardForm fonts. That is, I want all axes labelling, titling, legends, inserted text, etc., for 2D/3D ...
3
votes
1answer
159 views

Disable and Enable Hyperlinks Graphics

I have a Graphics element which I edit with Drawing Tools. I have determined a technique using NotebookWrite to add ...
2
votes
1answer
312 views

How to calculate the whole run time in a specific notebook?

I have found a way to show the run time in a specific cell in a notebook (.nb). Now, I want to have the whole run time including all cells in a specific notebook. How is it possible to calculate it ...
0
votes
0answers
42 views

How to syntax highlight a code cell in another language? [duplicate]

I'm learning c/c++/objective-c and I wanted to write my notes in a mathematica notebook. But without the proper syntax color highlighting it looks terrible....
1
vote
1answer
176 views

Is it possible to use Find with wild cards?

When making global changes to code and variables Find is a great resource. Is there a way to use Find with wild cards to find and replace any non numerical elements or to find and replace only ...
3
votes
0answers
80 views

Make all new cells have a specific style as a function of the Mathematica installation

I would like all new input and output cells, in fact all new cells including section headers and such, to have a specific stylistic property (...
2
votes
1answer
112 views

Notebook output behaving erratically

Normally, when reevaluating a cell, the following output cell is overwritten with the new result. I have a lengthy notebook in which at some point for unknown reasons each reevaluation generates a new ...
1
vote
1answer
88 views

How to pop out of a subsection in a notebook

Let's say I have a section in a notebook, which I begin with a cmd-4 keystroke. I type in some text and expressions, and now I want to introduce a subsection for ...
1
vote
0answers
92 views

Remote access to notebook is very slow

I am using Mathematica at work remotely from a computer in my building and I can edit notebooks by opening them from terminal via ssh without problem (a little slow if there is a figure with many ...
8
votes
0answers
198 views

How to convert a notebook cell to a string retaining all formatting, colorization of identifiers etc?

I have an opened Mathematica notebook containing several cells. Suppose, I am interested in one of them -- it may contain a complete or incomplete expression (e.g. with syntax errors, highlighted ...
3
votes
2answers
157 views

How can I change the highlighting color of an InlineMathCell?

When using the InlineMathCell one types Ctrl+9 within the text cell, and gets a slot for starting typing the InlineMathCell part. When typing the content of the InlineMathCell is slightly highlighted ...
4
votes
2answers
249 views

Adapting “Find and Replace” functionality to work with Patterns

I was thinking if there is something like Find and Replace (Crtl+F) functionality adapted to work with patterns. Probably not, but it seems possible to create this with some effort and skills in ...
3
votes
1answer
454 views

Why isn't autosave enabled by default?

While I've come across several ways to implement/enable autosave (see: Is there a notebook autosave frequency configuration?, Saving my code before cell evaluations: Insurance against front end ...
1
vote
1answer
108 views

Is it possible to create a styled cell with pre-defined content?

When you create a new styled notebook from the Stylesheets chooser dialag, you get a new notebook using the chosen style with some sample content provided. But if you apply styles from the same ...
3
votes
3answers
206 views

Preventing notebook cells from being broken across two pages when printing

Sometimes I create a number of plots together, e.g. by GraphicsGrid[]. If it happens that I have to print the notebook, very often the cell is broken, half on one ...
3
votes
2answers
148 views

Mouse cursor very slight difference

Mathematica uses a very thin, translucent cursor in Input style cells. But in text style cells Mathematica uses a cursor theme from Windows. How do I make the cursor visible as normal? photos of ...
0
votes
1answer
84 views

Evaluation of notebook from chosen cell to end

There is option to evaluate the complete notebook but I wanted to know if its possible to evaluate notebook from some desired cell to end or some other desired cell following?
7
votes
1answer
120 views

ClearAll[“Global`*”] stops working with Context set to 'unique to this Notebook'

I just changed my default notebook context to 'unique to this Notebook' so that variables don't roll across numerous open notebooks. Doing this, however, made the command ClearAll["Global*"] stop ...
2
votes
1answer
81 views

Fastest way to select the longest cell

I'm trying to learn low-level notebook programming and I have a question. Is there faster way to select the longest cell in a notebook than this: ...
3
votes
1answer
155 views

How to replace a string within a selected region in a notebook?

I want to replace a string in a selected region/cell in mathematica notebook/package. I searched but didn' t get any result. I think it' s a quite common feature for editors/programming environments. ...
11
votes
1answer
165 views

Cell brackets on left side?

Is it possible to have the cell brackets on the left? I looked through the options and couldn't find anything, but maybe it's some kind of esoteric style setting or something. The reason I'm looking ...
12
votes
3answers
298 views

Notebook vs. DocumentNotebook; display a Notebook inline, like a DocumentNotebook

If you evaluate a DocumentNotebook[] expression in the front-end, it nicely displays inline, inside of an output cell in the current notebook: For my purposes, ...
2
votes
1answer
73 views

Use Initialization Cells to open a CellGroup

I would like to use "Evaluate Initialization Cells" to open a CellGroup in a notebook. However, the following code doesn't work if placed in an initialization cell: ...
4
votes
1answer
121 views

Can I customize In[] and Out[] headers?

Can I customize the In[] and Out[] headers? I'd like to add $UserName, ...
2
votes
1answer
88 views

How to make a notebook not savable?

How to make a particular notebook not savable? Optionally, how to do this by evaluating a command in the notebook?
4
votes
1answer
93 views

Why can't I change the style of a cell repeatedly?

I ran into this when I was working with an example from the Help Pages of V9. Cells is a new function added in V9. The following appears to work the first time it ...
11
votes
2answers
405 views

How can I make a cell that contains an image which can be shifted?

When you're looking at some help pages, they may have cells containing images which can be shifted within the cell by left-clicking and dragging the mouse. Here is a sample: ...
3
votes
1answer
210 views

Use different kernels for different Notebooks

I know that the command LaunchKernels[] starts up four kernels on my machine: ...
7
votes
2answers
729 views

Viewing Mathematica Demonstrations Project Code

I hope I am going insane and the I'm not seeing the snake about to bite me... How does one view the code in the demonstration projects that one can download from wolfram.com? It seems like all of ...
2
votes
0answers
59 views

How to retroactively merge cell change history according to a merge interval

I recently noted that there is an option in the options inspector to set a merge interval for cell changes. This (I think) prevents a quick series of changes from spamming your notebook history with a ...
3
votes
1answer
122 views

Use NotebookWrite with Graphics?

I am trying to use NotebookWrite to paste a plot into another notebook. The code looks something like: ...
7
votes
1answer
193 views

ClearAll just for current notebook

So in my search to fine tune Mathematica to what works for me, I found a nice setting that helps separate variable declaration between notebooks. Under Global Preferences, searching for CellContext ...
1
vote
1answer
58 views

How to change Compiled->False to Method->{Compiled->False} in multiple notebooks?

I have a collection of about 40 notebooks where the options for ParametricPlot and ParametricPlot3D have: Compiled->False and I need to switch any/all ...
1
vote
2answers
107 views

How to set the background of a section to light gray?

How to set the background of a section to light gray and leave background of content below and above the section as default?
11
votes
2answers
256 views

Is it possible to create Evaluatable cell which will be automatically overwritten?

Am trying to generate an Evaluatable cell which itself is an output cell which will be overwritten when the original Input cell ...
5
votes
3answers
245 views

Storing data in the Notebook in readable form

The common problem in my theretical work is a need to import some experimental data to work with. This means that my notebook depends on some external files which makes it difficult to share it with ...
4
votes
2answers
783 views

How do you configure Mathematica 9 to automatically evaluate all notebooks?

I have a Mathematica 6 course that I am using in Mathematica 9; there is no updated version. Every time I open a notebook I have to go to the Evaluation menu and click on "Evaluate Notebook". Is there ...
3
votes
3answers
130 views

How to create a button that colors a selected piece of text in a cell?

I use Mathematica 9.0.1 and I want change the color of a selection in a text cell using a button. But when I use this code it changes the color of the entire cell. ...
4
votes
2answers
182 views

Background color of Code cell lost when convert a notebook file to pdf

Well, I have a notebook with the built-in stylesheet Preprint, which I'd like to convert it to pdf. Everything works well except for the code cells(I use the shortcut key alt+8 to create cells of code ...
2
votes
2answers
143 views

How to find out if invisible notebooks are still open

If I create a notebook CreateDocument and I set options such that Visible -> False, is there any way to tell if it's still ...
2
votes
0answers
39 views

Does an equivalent of marks in vim exist for navigating notebooks quickly? [duplicate]

Is it possible in the Mathematica front-end to associate a keyboard shortcut with a cursor location in the notebook (kind of like marks in vim) so that one can return to them quickly later? (Just ...
1
vote
1answer
109 views

Controlling preferences of deployed notebooks

The following screenshot shows a toy example to illustrate what I want to accomplish: The above mimics the structure a type of notebook that I want to deploy for both Mathematica and PlayerPro ...
4
votes
0answers
84 views

Is there a way to check whether two notebooks share the same variables?

When I code in Mathematica, I often re-use code from old notebooks which fulfilled a specific purpose; for example, one testing for soft matches in strings, or one that identifies outliers on a graph ...
3
votes
1answer
214 views

How to build and operate a master Notebook?

Suppose you have some notebooks, they work for a family of related tasks, each one doing a certain task. Lets say Notebook 1 gets two inputs from its variables in11 ...
12
votes
1answer
106 views

Is there a callback for notebook exit?

I know that $Epilog is called when Mathematica is exited; is there a callback upon exiting the notebook? If so, what is it?
0
votes
2answers
291 views

Creating an API or Widget based on a Mathematica notebook

I'm trying to create a matrix calculator and graph tools for our website and was wondering if there is a way to create Wolfram API or Widgets based on a Mathematica notebook.
5
votes
1answer
788 views

Manipulate (Linux version of Mathematica)

I'm runnning Mathematica 9 on Ubuntu 11.10. After installing CDF player I still have problem (most of time) with Manipulate. Only way I'm able to change value of a ...
1
vote
3answers
145 views

Entering Sum in traditional form

The documentation for Sum says that it is possible to replace Sum by EscsumEsc. The limits ($i_\max$ and $i_\min$) should be ...
8
votes
1answer
194 views

How can I add a background to a stylesheet?

In version 9 we can set the background to an image, however I'd like to save this into a stylesheet that can be installed.