Advertisement
Guest User

Untitled

a guest
Feb 19th, 2017
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. foo /: MakeBoxes[foo[x_, y_], StandardForm] := ToBoxes @ Graphics[{
  2. Point@{x, y}
  3. }, Frame -> True, PlotRange -> {{-2, 2}, {-2, 2}}
  4. ]
  5.  
  6. foobar[foo[x_, y_]] := (Print["Matched"]; x + y)
  7.  
  8. foo2[x_, y_] := Interpretation[
  9. Graphics[{
  10. Point@{x, y}
  11. }, Frame -> True, PlotRange -> {{-2, 2}, {-2, 2}}
  12. ],
  13. foo2[x, y]
  14. ]
  15.  
  16. foobar2[foo2[x_, y_]] := (Print["Matched"]; x + y)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement