Repository navigation
d.barscale: Correct the length option description - #8069
Merged
Merged
Conversation
The label said the length is in map units, but draw_scale() reads it in the units given by the units option and only falls back to map units when that is not set, so length=5000 units=kilometers draws a 5000 km bar. Say so, and note that the default of 0 picks a length automatically.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
lengthlabel says map units, butdraw_scale()reads it in whateverunitsis set to, and only uses map units whenunitsis not givenlength=5000, units="kilometers"drew a 5000 km barlength=5000with no units andlength=5 units=kilometersgive the same 5 km bar, andlength=3 units=milesmatches 4.8 km