Also import px and pct into PlotMeasures
Necessary for example 29 to work
This commit is contained in:
parent
073724a84c
commit
b37f2141a1
@ -138,12 +138,15 @@ module PlotMeasures
|
|||||||
import Measures
|
import Measures
|
||||||
import Measures: Length, AbsoluteLength, Measure, BoundingBox, mm, cm, inch, pt, width, height, w, h
|
import Measures: Length, AbsoluteLength, Measure, BoundingBox, mm, cm, inch, pt, width, height, w, h
|
||||||
const BBox = Measures.Absolute2DBox
|
const BBox = Measures.Absolute2DBox
|
||||||
export BBox, BoundingBox, mm, cm, inch, pt, px, pct, w, h
|
|
||||||
|
# allow pixels and percentages
|
||||||
|
const px = AbsoluteLength(0.254)
|
||||||
|
const pct = Length{:pct, Float64}(1.0)
|
||||||
|
export BBox, BoundingBox, mm, cm, inch, px, pct, pt, w, h
|
||||||
end
|
end
|
||||||
|
|
||||||
using .PlotMeasures
|
using .PlotMeasures
|
||||||
import .PlotMeasures: Length, AbsoluteLength, Measure, width, height
|
import .PlotMeasures: Length, AbsoluteLength, Measure, width, height
|
||||||
export BBox, BoundingBox
|
|
||||||
# ---------------------------------------------------------
|
# ---------------------------------------------------------
|
||||||
|
|
||||||
include("types.jl")
|
include("types.jl")
|
||||||
|
|||||||
@ -1,10 +1,6 @@
|
|||||||
|
|
||||||
# NOTE: (0,0) is the top-left !!!
|
# NOTE: (0,0) is the top-left !!!
|
||||||
|
|
||||||
# allow pixels and percentages
|
|
||||||
const px = AbsoluteLength(0.254)
|
|
||||||
const pct = Length{:pct, Float64}(1.0)
|
|
||||||
|
|
||||||
to_pixels(m::AbsoluteLength) = m.value / 0.254
|
to_pixels(m::AbsoluteLength) = m.value / 0.254
|
||||||
|
|
||||||
const _cbar_width = 5mm
|
const _cbar_width = 5mm
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user