Skip to main content
14 events
when toggle format what by license comment
Jul 5, 2014 at 13:52 comment added mfvonh BTW, I figured this out by changing the MakeBoxes to what I wanted, then using CTRL+SHIFT+E in the output cell, and I just copied and pasted the changed code into the MakeExpression definition.
Jul 5, 2014 at 13:49 comment added mfvonh Change relevant part of MakeBoxes to MatrixForm[m*lcm]}, " \[Times] "]], "PrettyMatrix"] and redefine MakeExpression[TagBox[RowBox[{c_,RowBox[{" ",RowBox[{"*"," "}]}],m_}],"PrettyMatrix"],form_]:=MakeExpression[RowBox[{c," ",m}],form];
Jul 5, 2014 at 13:34 comment added unlikely I wish to add a bit of space around \[Times], I think it was a string and added a space everywhere, but with this edit interpretation fails. Of course, your original code works. Not so important, just a curiosity...
Jul 5, 2014 at 13:24 comment added mfvonh @unlikely What problem are you having? One thing that I changed was \[Times] is no longer a string, but a raw symbol. Are you using output generated by the same MakeBoxes I posted?
Jul 5, 2014 at 13:21 comment added unlikely I'm not sure if the box interpretation works as expected. Can you try please?
Jul 3, 2014 at 20:07 vote accept unlikely
Jul 3, 2014 at 15:50 history edited mfvonh CC BY-SA 3.0
added 1589 characters in body
Jul 2, 2014 at 19:11 comment added mfvonh @MichaelE2 (Who is good at this stuff? :P It's some of the most tedious crap you can do in Mathematica in my opinion.) Your example is a good one I hadn't thought about -- my upvalues hack isn't the best I see. I'll have to play with it some more.
Jul 2, 2014 at 17:34 comment added Michael E2 I upvoted already, but, in addition to Out[1] or % not working in a new input cell, consider mat = RandomInteger[{1, 5}, {2, 2}]/12 // PrettyMatrixForm, which displays as lists instead of in PrettyMatrixForm. I thought I had it down once, but I must have had a latent definition lurking in the kernel and I can't reproduce it. :( The output was even labeled Out[1]//PrettyMatrixForm=...but I'm not very good at this stuff.
Jul 2, 2014 at 13:35 comment added unlikely Please see my EDIT 2 to the question.
Jul 2, 2014 at 12:54 comment added mfvonh @unlikely This is essentially how MatrixForm works, and the behavior is fairly close. What behavior do you want that this does not provide?
Jul 2, 2014 at 8:08 comment added unlikely Thanks for your detailed presentation of boxes and related construct. And also for the interesting workaround using upvalues. When I can upvote I'll do. But I'm still interested to know it there is a way to reproduce the exact beahvior of bultin MatrixForm...
Jul 2, 2014 at 0:11 history edited mfvonh CC BY-SA 3.0
missing variable assignment
Jul 1, 2014 at 21:49 history answered mfvonh CC BY-SA 3.0