Tag Info

New answers tagged

2

You can explicitly specify that only "Input" Cells should be closed: Do[CurrentValue[cell, CellOpen] = False, {cell, Cells[CellStyle -> {"Input"}, CellTags -> {"noclass"}]} ] As Kuba notes in the comment, it is CellTags what is inherited by generated output Cell. This issue recently raised in this question. If the inheritance is not desirable you ...


1

Ok so I fixed it: Cell[StyleData[StyleDefinitions -> "Default.nb"], CellMargins->{{21, 3}, {4, 4}}] Cell[StyleData[All], ShowGroupOpener->False, FontFamily->"Avenir"] Cell[StyleData["Title"], CellMargins->{{10, 3}, {4, 4}}, FontColor-> RGBColor[0,0.0,0.6], CellGroupingRules->{"SectionGrouping", 9}] Cell[StyleData["Section"], ...


0

This is not a full response, but I have some info that might be helpful. The subsection issue is caused by the Stylesheet entry for Subsubsection, changing it to the default of 50 should fix it, or anything >40. Cell[ StyleData["Subsubsection"], CellGroupingRules -> {"SectionGrouping", 50} ] The issue is that the default for SectionGrouping ...


4

You can select it just like any other cell, and then delete it. On my system, it is a cell of the form: Cell[" ", "Text", Editable -> False, Selectable -> False, CellFrame -> {{0, 0}, {0, 3}}, ShowCellBracket -> False, CellMargins -> {{0, 0}, {1, 1}}, CellElementSpacings -> {"CellMinHeight" -> 1}, CellFrameMargins -> 0, ...


5

The FE always opens the stylesheet named in the DefaultStyleDefinitions option at the global level. In certain failsafe cases, it will fall back to this stylesheet if style definitions can't be found anywhere else. The one case I know for certain(*) where this happens is if the FE followed a stylesheet chain all the way to the end looking for stylename, ...


3

In the interest of showcasing a functional answer to an interesting question, I take the liberty of turning @Szabolcs comments above to an answer, since the OP has confirmed that this approach has solved his problem. Szabolcs pointed out that when one is "evaluating" a cell in the front end it really just queues that cell for evaluation. When one evaluates ...


7

There is a special cell attribute called CellID. I would suggest using this instead of cell tags to avoid the problem that you mentioned with cell tags being inherited. Here's an example of how Select can be used to retrieve a cell with a specific cell ID: nb = CreateWindow[]; cells = <| "name" -> RandomInteger[10^6], "status" -> ...


4

This is very efficient for large Notebooks: NotebookPut[Notebook[{}], EvaluationNotebook[]]; (simple replacement of the evaluation notebook with blank notebook). I have tested this method with a Notebook of size 976 Mb containing 36031 Cells and it was cleared out in no time, while the NotebookDelete[Cells[]] method seems to take forever for this ...


5

This will delete everything in the evaluation Notebook: NotebookDelete[Cells[]] This will generate a Palette Button that deletes everything is the selected Notebook: CreatePalette @ Button["Clear Notebook", NotebookDelete @ Cells @ InputNotebook[]] As noted in the comments it is probably just as fast, if not faster, to simply Select All and Clear ...


2

If you mean screen, then ctrl + A to select all cells and then hit del. If you mean memory, then ClearAll["Global`*"] if it does not help, restart...



Top 50 recent answers are included