Closed legokichi closed 9 years ago
@Galadirith is this because of our change to the mathjax dependency rather than the wrapper?
@legokichi I'm really sorry your having a problem with maths fonts. I've produced a simplified version of the file in your screenshot and unfortunately I've been unable to replicate your issue (A gist of the file I used can be found here):
To try to figure out whats going on I would be very grateful if you could send a file that doesn't work for you as a gist. Please could you also post back with a list of all the packages you have installed by running apm list --installed
. Thanks @legokichi.
is this because of our change to the mathjax dependency rather than the wrapper?
@leipert Its certainly possible, however all of the fonts that are needed for there different maths styles are present. For example the \mathfrak
style uses the MathJax_Fraktur-*.woff
fonts, which I have verified are included in an installation of MPP under the reduced mathjax dependency.
I would speculate that their may be another package installed that is loading MathJax, and the changes implemented in v2.2.0
mean that MPP is no longer loading its MathJax first. But thats just a guess.
This is the .md file in that screenshot, and the others that written by previous mathjax-preview-plus have same problem.
$ apm list --installed
/Users/***/.atom/packages (25)
├── .bin
├── Stylus@1.2.1
├── atom-html-preview@0.1.11
├── atom-typescript@7.4.1
├── browser-plus@0.0.35
├── clang-format@1.16.0
├── gist-it@0.8.0
├── japanese-wrap@0.2.7
├── language-clojure@0.17.0
├── language-d@3.2.1
├── language-haskell@1.4.11
├── language-ino@0.1.0
├── language-jade@0.6.2
├── language-latex@0.6.1
├── language-livescript@0.0.2
├── language-purescript@0.4.0
├── language-scheme@1.4.0
├── language-verilog@0.3.0
├── language-vhdl@0.7.1
├── latexer@0.2.7
├── linter@1.8.1
├── markdown-preview-plus@2.2.0
├── markdown-scroll-sync@0.4.2
├── mathjax-wrapper@0.1.0
└── pdf-view@0.32.0
my .atom/config.cson
to check "disabledPackages"
@legokichi Thanks so much for all the info, really help to try to diagnose this problem. I'm afraid I still cannot reproduce your error, but I'm still going through your installed packages (even though its clear you've disabled most of them) to check for any possible conflicts.
In the mean time it would be helpful if you could open a preview of the markdown document and run the following command's in your Atom's dev tools (which on OSX I believe is still done with ctrl-alt-i
):
$('script[src*="MathJax.js"]').src
and
$x('//html/head/style').filter( function(elm){ return elm.innerHTML.match('MathJax_Fraktur')} )
And then copy and paste any output to this issue. Thanks again @legokichi and I'm sorry this issue is taking a long time to resolve for you, but hopefully we can figure out the cause soon.
On mac it is command-alt-i
@Galadirith
$('script[src*="MathJax.js"]').src
"file:///Users/yohsukeino/.atom/packages/mathjax-wrapper/node_modules/MathJax/MathJax.js?delayStartupUntil=configured"
$x('//html/head/style').filter( function(elm){ return elm.innerHTML.match('MathJax_Fraktur')} )
[]
GET file:///Users/yohsukeino/.atom/packages/markdown-preview-plus/node_modules/MathJax/jax/output/HTML-CSS/fonts/STIX/fontdata.js?rev=2.4-beta-2 net::ERR_FILE_NOT_FOUNDa.Ajax.loader.JS @ MathJax.js?delayStartupUntil=configured:19a.Ajax.Load @ MathJax.js?delayStartupUntil=configured:19a.Ajax.Require @ MathJax.js?delayStartupUntil=configured:19MathJax.Hub.Startup.loadArray @ MathJax.js?delayStartupUntil=configured:19(anonymous function) @ MathJax.js?delayStartupUntil=configured:19CALLBACK.execute @ MathJax.js?delayStartupUntil=configured:19cb @ MathJax.js?delayStartupUntil=configured:19BASE.Object.Subclass.Process @ MathJax.js?delayStartupUntil=configured:19BASE.Object.Subclass.Push @ MathJax.js?delayStartupUntil=configured:19MathJax.Object.Subclass.loadComplete @ MathJax.js?delayStartupUntil=configured:19CALLBACK.execute @ MathJax.js?delayStartupUntil=configured:19cb @ MathJax.js?delayStartupUntil=configured:19
$('script[src*="MathJax.js"]').src
"file:///Users/yohsukeino/.atom/packages/markdown-preview-plus/node_modules/MathJax/MathJax.js?delayStartupUntil=configured"
$x('//html/head/style').filter( function(elm){ return elm.innerHTML.match('MathJax_Fraktur')} )
[]
file:///Users/yohsukeino/.atom/packages/markdown-preview-plus/node_modules/MathJax/jax/output/HTML-CSS/fonts/STIX/fontdata.js?rev=2.4-beta-2 Failed to load resource: net::ERR_FILE_NOT_FOUND
$('script[src*="MathJax.js"]').src
"file:///Users/yohsukeino/.atom/packages/markdown-preview-plus/node_modules/MathJax/MathJax.js?delayStartupUntil=configured"
$x('//html/head/style').filter( function(elm){ return elm.innerHTML.match('MathJax_Fraktur')} )
[]
$ pwd
/Users/yohsukeino/.atom/packages/markdown-preview-plus
$ npm list
markdown-preview-plus@2.2.1 /Users/yohsukeino/.atom/packages/markdown-preview-plus
├─┬ atom-space-pen-views@2.1.0
│ ├── fuzzaldrin@2.1.0
│ └─┬ space-pen@5.1.1
│ └── jquery@2.1.4
├─┬ cheerio@0.15.0
│ ├─┬ CSSselect@0.4.1
│ │ ├── CSSwhat@0.4.7
│ │ └─┬ domutils@1.4.3
│ │ └── domelementtype@1.3.0
│ ├── entities@1.0.0
│ ├─┬ htmlparser2@3.7.3
│ │ ├── domelementtype@1.3.0
│ │ ├── domhandler@2.2.1
│ │ ├─┬ domutils@1.5.1
│ │ │ └─┬ dom-serializer@0.1.0
│ │ │ ├── domelementtype@1.1.3
│ │ │ └── entities@1.1.1
│ │ └─┬ readable-stream@1.1.13
│ │ ├── core-util-is@1.0.1
│ │ ├── inherits@2.0.1
│ │ ├── isarray@0.0.1
│ │ └── string_decoder@0.10.31
│ └── lodash@2.4.2
├─┬ fs-plus@2.8.1
│ ├── async@0.2.10
│ ├── mkdirp@0.3.5
│ └── rimraf@2.2.8
├─┬ grim@1.4.2
│ └─┬ emissary@1.3.3
│ ├─┬ es6-weak-map@0.1.4
│ │ ├── d@0.1.1
│ │ ├─┬ es5-ext@0.10.8
│ │ │ ├── es6-iterator@2.0.0
│ │ │ └── es6-symbol@3.0.0
│ │ ├── es6-iterator@0.1.3
│ │ └── es6-symbol@2.0.1
│ ├── mixto@1.0.0
│ └── property-accessors@1.1.3
├─┬ highlights-native@2.1.0
│ └─┬ optimist@0.6.1
│ ├── minimist@0.0.10
│ └── wordwrap@0.0.3
├── lodash@3.10.1
├─┬ markdown-it@4.4.0
│ ├─┬ argparse@1.0.2
│ │ └── sprintf-js@1.0.3
│ ├── entities@1.1.1
│ ├── linkify-it@1.2.0
│ ├── mdurl@1.0.1
│ └── uc.micro@1.0.0
├── markdown-it-lazy-headers@0.1.3
├── markdown-it-math@3.0.1
├── MathJax@2.4.0-electron.0.2.0
├── pdc@0.2.2
├─┬ season@5.3.0
│ ├─┬ cson-parser@1.0.9
│ │ └── coffee-script@1.9.0
│ └─┬ optimist@0.4.0
│ └── wordwrap@0.0.3
├─┬ temp@0.8.3
│ ├── os-tmpdir@1.0.1
│ └── rimraf@2.2.8
├─┬ underscore-plus@1.6.6
│ └── underscore@1.6.0
└── wrench@1.5.8
@Galadirith, I can reproduce the error with 2.2.1
:
There just seem to be some files missing (file:///Users/leipert/repos/markdown-preview-plus/node_modules/MathJax/jax/output/HTML-CSS/fonts/STIX/fontdata.js?rev=2.4-beta-2
)
The tarball dependency (https://github.com/Galadirith/MathJax/tarball/2.4.0-electron.0.2.0) doesn't contain the STIX folder...
Thanks again for your really thorough response @legokichi. @leipert thanks so much for checking this out.
So that's really useful to know, it seems OSX is preferring the STIX fonts. @leipert would you be able to checkout hotfix/2.2.2
and tell me if that now works for you?
If not then I'll add the STIX fonts back to 2.4.0-electron*
and hopefully that will then work. Thanks @leipert @legokichi.
👍
markdown-preview-plus@2.2.0 this fonts is strange.
v2.1.1, It work completely.
markdown-preview-plus@2.1.1
so I do this
here is my environment