Skip to main content
22 votes

What are "\<" and "\>" delimiters in box expressions?

This syntax was deprecated in the version 6.0 era. According to the legacy documentation, For example, in version 5.2, the following strings are interpreted differently ...
ilian's user avatar
  • 25.5k
17 votes
Accepted

How to make version 12 print Root objects to screen normally as in earlier versions?

Making the comments into an an answer as suggested. SetSystemOptions[ "TypesetOptions" -> "NumericalApproximationForms" -> False] will restore the legacy ...
ilian's user avatar
  • 25.5k
14 votes
Accepted

ToExpression and ToBoxes aren't inverses of each other?

It is well-documented! According to the Documentation page for StandardForm, StandardForm generates output that gives a ...
Alexey Popkov's user avatar
13 votes

Tokenize Mathematica input in a simple way

I am a developer at Wolfram Research and I am trying to share some of the work I have been doing with parsing WL code. I have written a package for parsing WL code and retaining interesting metadata, ...
brenton's user avatar
  • 521
11 votes
Accepted

How do I use the third and fourth arguments of Parenthesize?

An good explanation can be found an old mathgroup archive thread which I have reconstructed: When you create a typeset form for a function or operator, you must write a MakeBoxes definition for that ...
M.R.'s user avatar
  • 31.5k
10 votes

Understanding evaluation and typesetting

Question 1: What is the typesetting in Mathematica? What procedures does it include? I think that this 2008 year MathGroup post by John Fultz completely answers this question, so I'll cite it here:...
Alexey Popkov's user avatar
10 votes

What are "\<" and "\>" delimiters in box expressions?

Summary of the all available information In the hoarier days space-like characters (spaces, newlines, tabs) inside strings were interpreted on input in an odd way: for example single newlines ...
Alexey Popkov's user avatar
10 votes

What are the differences between using MakeBoxes and Interpretation?

Assuming that you want to create a special display form for foo that can be used in all contexts, you should use neither of these solutions. Why? ...
Szabolcs's user avatar
  • 235k
10 votes
Accepted

Validate `Box` grammar, is it possible?

You may try using MathLink`CallFrontEnd[FrontEnd`ReparseBoxStructurePacket[...]]. ...
Domen's user avatar
  • 26.5k
10 votes

What is box-structure in Mathematica? Why can a function be left-value?

Definitions The tech note, Transformation Rules and Definitions, starting with the section "Making Definitions for Indexed Objects" and going on through "Modifying Built-in Functions&...
Michael E2's user avatar
  • 237k
9 votes
Accepted

What are the differences between using MakeBoxes and Interpretation?

Point of conversion A large and perhaps key difference is that MakeBoxes (foo) only transforms the expression into the expanded ...
Mr.Wizard's user avatar
  • 272k
9 votes
Accepted

Make a custom object look like MatrixForm of a matrix?

InterpretationBox will take care of making safe round trip from boxes to expression but we need to take extra care during condition checking and partition not to ...
Kuba's user avatar
  • 137k
9 votes
Accepted

How do I view the built-in definition of TemplateBox styles in terms of low level boxes?

They live in stylesheets: CurrentValue[{StyleDefinitions, "Binomial"}] ...
Kuba's user avatar
  • 137k
8 votes
Accepted

How to convert arbitrary raw boxes directly into String?

As Kuba notices in the comment, undocumented FrontEnd`ExportPacket allows conversion of a whole Notebook into plain text: ...
Alexey Popkov's user avatar
8 votes

How do I use the third and fourth arguments of Parenthesize?

You can check also the docs for PrecedenceForm for examples. Precedence can be used to force parenthesization. If you put a low-ish number, you will likely get a ...
magma's user avatar
  • 5,290
8 votes

MakeBoxes for Power not matching when inside Times?

I believe the existing rules for Times take precedence. (i.e. act first.) Perhaps a derivative of this can work for you: ...
Mr.Wizard's user avatar
  • 272k
8 votes
Accepted

Is there a way to print simple roots as Root objects?

expr = 3 - Sqrt[2]; Use ToNumberField to convert the expression to an AlgebraicNumber ...
Bob Hanlon's user avatar
  • 159k
7 votes
Accepted

How to convert expression with Subscript to string

how to convert a expression containing 2D format into corresponding string that retains the format programmatically? For example, how to convert ...
Alexey Popkov's user avatar
7 votes

This code crashes the FrontEnd - can I remove anything else?

Thank you for bringing this to our attention. I've done a preliminary investigation. On Unix only the kernel crashes, on Windows the FE crashes (or, more accurately, the FE crashes before the kernel ...
Itai Seggev's user avatar
  • 14.2k
7 votes

Symbolize Does Not Work in `.m` Files or What?

This answer may seem slightly off but it was posted before recent updates. The bottom line holds though. It symbolizes boxes, not expressions, it is not Subscript ...
Kuba's user avatar
  • 137k
7 votes

TagBox + InterpretationBox vs ConvertTo/StandardForm

This report finally found its way to me, and this is not a bug. I'm sorry support gave you incorrect information. This has nothing to do with the particular boxes involved, but rather with your use ...
Itai Seggev's user avatar
  • 14.2k
7 votes
Accepted

Export Table with URL as HTML?

This is what it looks like for me when I try to export the grid as HTML: These are just the first couple of errors. It goes on like that. On the other hand, ...
C. E.'s user avatar
  • 70.7k
7 votes

Are there any good tutorials on Boxes?

Converting a comment to an answer for the record: I am not aware of a better (?any at all) tutorial than Jason's Typesetting Workshop. I am not counting documentation. Otherwise you can learn a lot ...
6 votes
Accepted

Why doesn't defined MakeBoxes display what is constructed in RHS?

Interesting question. Building on comments by glS It appears that HoldForm is treated specially by (conversion to) ...
Mr.Wizard's user avatar
  • 272k
6 votes
Accepted

How to make TeXForm use TemplateBox to generate code?

The internal function used by TeXForm to process boxes is System`Convert`CommonDump`ExpandTemplateBoxes. This function is ...
Carl Woll's user avatar
  • 131k
6 votes
Accepted

How to display fractional expression like this?

In this particular case it is sufficient to add a custom formatting rule: ...
Alexey Popkov's user avatar
6 votes

Make a custom object look like MatrixForm of a matrix?

InterpretationBox used in answer by J.M. and by Kuba allows you to copy formatted object and keep its proper interpretation as an ...
jkuczm's user avatar
  • 15.1k
6 votes
Accepted

How to recover these TemplateBox into normal form?

If you want to edit the box expressions, there're already some similar questions on MSE, such as 47213, 13317. Solution 1 However, the direct use of ...
rnotlnglgq's user avatar
  • 3,740
6 votes

What is box-structure in Mathematica? Why can a function be left-value?

Assigning values to symbols or expressions follows conventinal rules of programming laguages. Plus[x,y]=1 is simply not allowed, because it changes the definition ...
Roland F's user avatar
  • 3,782
6 votes
Accepted

Converting WolframAlpha Output to Markdown

An easiest way is to make use: Pod ComputableData - see how HERE MathJax in markdown So getting the data from ...
Vitaliy Kaurov's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible