TransWikia.com

Exporting Summary Boxes - Headless

Mathematica Asked by Gladaed on September 26, 2021

This question is a follow up question to Exporting Summary Boxes.

When cutting away the “Head” of a summary box is there a better way than doing the following?

result = ConvolutionLayer[4, 8];

boxData = (result // ToBoxes // 
  ReplaceAll[HoldPattern[Typeset`open = _] :> (Typeset`open = True)] )  
boxData[[1, 1, 1, 1, 3]] // RawBoxes

Since just accessing the particular element seems very inelegant and might be prone to errors in the future. Ideally it would cut the + aswell.

One Answer

Peering into the structure returned, you seem to want the contents of the DynamicModuleBox:

Cases[boxData, _DynamicModuleBox, Infinity];
RawBoxes@%

Mathematica graphics

Answered by MarcoB on September 26, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP