Skip to content

Commit

Permalink
merge jk/html-png-display + highdpi adjustments
Browse files Browse the repository at this point in the history
new figure size and related theming adjustments

move html backend show out of cairomakie

move WEB_MIMES constant from WGLMakie into Makie

use strings again

fix test

smaller colorbar ticks

adjust more theming gaps

padding adjust

fix size of docs example

make toggle smaller

make colorbar thinner

smaller colorbar

adjust legend doc example

fix intervalslider and example

more docs fixes, axis legend padding

improve faq example

fix test value
  • Loading branch information
jkrumbiegel authored and SimonDanisch committed Aug 16, 2023
1 parent 0000543 commit 8959d00
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CairoMakie/src/screen.jl
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ end
to_cairo_antialias(aa::Int) = aa

"""
* `px_per_unit = 2.0`: see [figure docs](https://docs.makie.org/stable/documentation/figure_size/).
* `pt_per_unit = 0.75`: see [figure docs](https://docs.makie.org/stable/documentation/figure_size/).
* `px_per_unit = 2.0`: see [figure docs](https://docs.makie.org/stable/documentation/figure/).
* `pt_per_unit = 0.75`: see [figure docs](https://docs.makie.org/stable/documentation/figure/).
* `antialias::Union{Symbol, Int} = :best`: antialias modus Cairo uses to draw. Applicable options: `[:best => Cairo.ANTIALIAS_BEST, :good => Cairo.ANTIALIAS_GOOD, :subpixel => Cairo.ANTIALIAS_SUBPIXEL, :none => Cairo.ANTIALIAS_NONE]`.
* `visible::Bool`: if true, a browser/image viewer will open to display rendered output.
"""
Expand Down
3 changes: 3 additions & 0 deletions src/display.jl
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,9 @@ const WEB_MIMES = (
MIME"application/prs.juno.plotpane+html",
MIME"juliavscode/html")

# because we have a default way to display pngs in html contexts, we can say that
# if png is showable, so are the html types
Base.showable(mime::Union{WEB_MIMES...}, fig::FigureLike) = showable(MIME"image/png"(), fig)

backend_showable(@nospecialize(screen), @nospecialize(mime)) = false

Expand Down

0 comments on commit 8959d00

Please sign in to comment.