diff --git a/Project.toml b/Project.toml index a2d7a4b..fb185b3 100644 --- a/Project.toml +++ b/Project.toml @@ -23,8 +23,7 @@ julia = "1.10" [extras] ArchGDAL = "c9ce4bd3-c3d5-55b8-8973-c0e20141b8c3" GeoJSON = "61d90e0f-e114-555e-ac52-39dfb47a3ef9" -RasterDataSources = "3cb90ccd-e1b6-4867-9617-4276c8b2ca36" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [targets] -test = ["Test", "ArchGDAL", "RasterDataSources", "GeoJSON"] +test = ["Test", "ArchGDAL", "GeoJSON"] diff --git a/src/InteractiveGeospatial.jl b/src/InteractiveGeospatial.jl index 7085abd..5ab639f 100644 --- a/src/InteractiveGeospatial.jl +++ b/src/InteractiveGeospatial.jl @@ -76,7 +76,7 @@ function draw_features(r) sublabel(text) = Label(fig, text, fontsize=10, halign=:left, padding = (0,0,-15,0), color=:gray) # `aggregate` Inputs - init_scale = round(Int, maximum(size(r)) / 1000) + init_scale = max(1, round(Int, maximum(size(r)) / 1000)) scale = Textbox(fig; stored_string=string(init_scale), validator=Int, width=ui_width) aggregate_fun = menu(sum, mean, minimum, maximum) diff --git a/test/runtests.jl b/test/runtests.jl index 7abf774..e1e0613 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -1,7 +1,7 @@ -using Test, InteractiveGeospatial, Rasters, ArchGDAL, RasterDataSources, GeoJSON, GLMakie, Markdown +using Test, InteractiveGeospatial, Rasters, ArchGDAL, GeoJSON, GLMakie, Markdown -file = getraster(WorldClim{Climate}, :wind; month=1) +file = download("https://github.com/yeesian/ArchGDALDatasets/raw/master/pyrasterio/example.tif") r = Raster(file)