diff --git a/src/layoutable.jl b/src/layoutable.jl index f96f355..3cbb4b7 100644 --- a/src/layoutable.jl +++ b/src/layoutable.jl @@ -35,7 +35,7 @@ end LTeX(x, tex; kwargs...) = LTeX(x; tex = tex, kwargs...) -_to_cachedtex(x) = CachedTeX(x) +_to_cachedtex(x) = CachedTEX(x) _to_cachedtex(x::AbstractDocument) = Cached(x) function Makie.initialize_block!(l::LTeX) diff --git a/src/recipe.jl b/src/recipe.jl index 6a7449b..8e70cc1 100644 --- a/src/recipe.jl +++ b/src/recipe.jl @@ -96,7 +96,7 @@ function Makie.plot!(plot::TeXImg) # changing dpi should rerender plottable_images = lift(plot[1], plot.render_density, plot.scale) do cachedtex, render_density, scale if cachedtex isa AbstractString || cachedtex isa AbstractArray{<: AbstractString} - to_array(_bc_if_array(CachedTeX, cachedtex)) + to_array(_bc_if_array(CachedTEX, cachedtex)) else to_array(_bc_if_array(Cached, cachedtex)) end diff --git a/src/rendering/tex.jl b/src/rendering/tex.jl index ad79e88..8ad3aac 100644 --- a/src/rendering/tex.jl +++ b/src/rendering/tex.jl @@ -2,7 +2,7 @@ # TeX rendering =# -function rasterize(ct::CachedTeX, scale::Int64 = 1) +function rasterize(ct::CachedTEX, scale::Int64 = 1) return page2img(ct, ct.doc.page; scale) end @@ -105,6 +105,6 @@ function compile_latex( end -compile_latex(document::TeXDocument; kwargs...) = compile_latex(doc.doc; kwargs...) +compile_latex(document::TEXDocument; kwargs...) = compile_latex(String(doc.doc); kwargs...) latex2pdf(args...; kwargs...) = compile_latex(args...; kwargs...) diff --git a/src/text_utils.jl b/src/text_utils.jl index e18f43a..6a3c4db 100644 --- a/src/text_utils.jl +++ b/src/text_utils.jl @@ -48,7 +48,7 @@ function to_texdoc(lstr, font, textsize, lineheight, color) \\color{maincolor} """ * String(lstr) - return TeXDocument( + return TEXDocument( string, true; requires = requires, preamble = preamble, @@ -58,7 +58,7 @@ function to_texdoc(lstr, font, textsize, lineheight, color) end function to_plottable_cachedtex(lstr, font, textsize, lineheight, color) - return CachedTeX(to_texdoc(lstr, font, textsize, lineheight, color)) + return CachedTEX(to_texdoc(lstr, font, textsize, lineheight, color)) end function _plottable_cachedtex_from_array(lstrs::AbstractVector{<: AbstractString}, fonts, textsizes, lineheights, colors) @@ -113,7 +113,7 @@ function _plottable_cachedtex_from_array(lstrs::AbstractVector{<: AbstractString i += 1 end - doc = TeXDocument( + doc = TEXDocument( contents, true; requires = requires, preamble = preamble, @@ -129,7 +129,7 @@ function _plottable_cachedtex_from_array(lstrs::AbstractVector{<: AbstractString pdfs = split_pdf(full_pdf) - return CachedTeX.(pdfs) + return CachedTEX.(pdfs) end