]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/teximg.pm
update for rename of recentchanges.mdwn to json.tl.ph.mdwn
[git.ikiwiki.info.git] / IkiWiki / Plugin / teximg.pm
index 521af499fc77323870951883b49736509081cd8f..e0f97614b9bf29e7424857e45041ca668c7e449a 100644 (file)
@@ -13,6 +13,7 @@ use IkiWiki 3.00;
 
 my $default_prefix = <<EOPREFIX;
 \\documentclass{article}
+\\usepackage[utf8]{inputenc}
 \\usepackage{amsmath}
 \\usepackage{amsfonts}
 \\usepackage{amssymb}
@@ -143,10 +144,10 @@ sub gen_image ($$$$) {
        }
        
        my $tex = $config{teximg_prefix};
-       $tex .= '$$'.$code.'$$';
+       $tex .= '\['.$code.'\]';
        $tex .= $config{teximg_postfix};
-       $tex =~ s!\\documentclass{article}!\\documentclass[${height}pt]{article}!g;
-       $tex =~ s!\\documentclass{scrartcl}!\\documentclass[${height}pt]{scrartcl}!g;
+       $tex =~ s!\\documentclass\{article}!\\documentclass[${height}pt]{article}!g;
+       $tex =~ s!\\documentclass\{scrartcl}!\\documentclass[${height}pt]{scrartcl}!g;
 
        my $tmp = eval { create_tmp_dir($digest) };
        if (! $@ &&