diff --git a/src/Winston.jl b/src/Winston.jl index 293da38..a5b0ab3 100644 --- a/src/Winston.jl +++ b/src/Winston.jl @@ -10,7 +10,6 @@ end using IniFile using Compat using Dates - isdefined(Base, :Libc) && (strftime = Libc.strftime) isdefined(Base, :Dates) && (datetime2unix = Dates.datetime2unix) @@ -93,7 +92,7 @@ import Base: copy, export get_context, device_to_data, data_to_device if VERSION < v"0.3-" - typealias AbstractVecOrMat{T} (@compat Union{AbstractVector{T}, AbstractMatrix{T}}) + typealias AbstractVecOrMat{T}(@compat Union{AbstractVector{T}, AbstractMatrix{T}}) extrema(x) = (minimum(x),maximum(x)) Base.push!(x, a, b) = (push!(x, a); push!(x, b)) elseif VERSION < v"0.4-" diff --git a/src/plot.jl b/src/plot.jl index d37fdfd..2fb32b8 100644 --- a/src/plot.jl +++ b/src/plot.jl @@ -569,7 +569,7 @@ function fplot(f::Function, limits, args...; kvs...) pargs = [arg] elseif typeof(arg) <: Integer fopts[:min_points] = arg - elseif typeof(arg) <: FloatingPoint + elseif typeof(arg) <: @compat AbstractFloat fopts[:tol] = arg else error("unrecognized argument ", arg) diff --git a/src/renderer.jl b/src/renderer.jl index 6b1ebca..fc3af34 100644 --- a/src/renderer.jl +++ b/src/renderer.jl @@ -60,7 +60,7 @@ end ## state commands color_to_rgb(i::Integer) = convert(RGB, RGB24(unsigned(i))) -color_to_rgb(s::AbstractString) = color(s) +color_to_rgb(s::AbstractString) =parse(Colorant,s) color_to_rgb(rgb::@compat(Tuple{Real,Real,Real})) = RGB(rgb...) color_to_rgb(cv::Color) = convert(RGB, cv) color_to_rgb(cv::TransparentColor) = cv