Skip to content

[Bug]: A publication layout's map can be moved toward a pole and drawn several times smaller #3514

Done

Description

@jgregoriorincon

What happened?
layout.publication can draw the map several times smaller than the extent asked for, in a few pixels in the middle of an empty frame. When the legend has no room with the map centred, the placement moves the map aside. On Web Mercator it can move it toward a pole: the frame keeps its ground scale at its centre, so at 85° the same scale shows an area many times larger. The move is accepted because it only checks that the extent stays inside the frame's margins, which a shrunken extent does easily. The graticule then runs across the empty frame, and nothing is said.

Steps to reproduce

  1. project.sample
  2. layout.publication {"profile": "a4-portrait", "extent": [-111.5, -16.6, 146.5, 62.6], "legend": {"columns": 1}}

The map frame comes out centred at latitude 84.9 (30.5 without "legend"), at 1:170,000,000. "profile": "a5-portrait" does the same; "profile": "thesis-full" goes to -80.9.

Expected behavior
A move never changes how large the extent is drawn by more than a little: one that would is not made, as one that leaves the extent out of the margins is not.

How are you running RustGIS? Desktop app (built from source)

Version 21e9aa5. The moves are tried in publication, crates/engine/src/cmd/layout/publication/mod.rs (here_mm, kept_whole).

Activity

  1. jgregoriorincon commented on Dec 1, 2026

    @jgregoriorincon
    ContributorAuthor

    I'm taking this one.

  2. added
    bug
    on Dec 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions