Skip to content

Fixes for the layer legend#4484

Open
uclaros wants to merge 9 commits into
masterfrom
fix-legend-size
Open

Fixes for the layer legend#4484
uclaros wants to merge 9 commits into
masterfrom
fix-legend-size

Conversation

@uclaros

@uclaros uclaros commented Apr 29, 2026

Copy link
Copy Markdown
Contributor

Adjust the legend text size, color and margins.

Before After
Screenshot_20260429_154531 Screenshot_20260429_154456

@github-actions

Copy link
Copy Markdown

📦 Build Artifacts Ready

OS Status Build Info Workflow run
macOS Build 📬 Mergin Maps 68031 dmg Expires: 28/07/2026 #6803
linux Build Build failed or not found. #6814
win64 Build 📬 Mergin Maps 59981 win64 Expires: 28/07/2026 #5998
Android Build 📬 Mergin Maps 811511 APK [armeabi-v7a] Expires: 28/07/2026 #8115
📬 Mergin Maps 811511 APK [armeabi-v7a] Google Play Store #8115
Android Build 📬 Mergin Maps 811551 APK [arm64-v8a] Expires: 28/07/2026 #8115
📬 Mergin Maps 811551 APK [arm64-v8a] Google Play Store #8115
iOS Build Build failed or not found. #9054

@uclaros
uclaros marked this pull request as draft April 29, 2026 15:25
@uclaros
uclaros marked this pull request as ready for review May 7, 2026 14:41
@github-actions

github-actions Bot commented May 7, 2026

Copy link
Copy Markdown

Coverage Report for CI Build 29741196624

Warning

No base build found for commit 7de4002 on master.
Coverage changes can't be calculated without a base build.
If a base build is processing, this comment will update automatically when it completes.

Coverage: 59.078%

Details

  • Patch coverage: No coverable lines changed in this PR.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

Requires a base build to compare against. How to fix this →


Coverage Stats

Coverage Status
Relevant Lines: 15647
Covered Lines: 9244
Line Coverage: 59.08%
Coverage Strength: 97.82 hits per line

💛 - Coveralls

@github-actions

github-actions Bot commented May 7, 2026

Copy link
Copy Markdown

📦 Build Artifacts Ready

OS Status Build Info Workflow run
macOS Build 📬 Mergin Maps 68211 dmg Expires: 05/08/2026 #6821
linux Build 📬 Mergin Maps 68381 x86_64 Expires: 05/08/2026 #6838
win64 Build 📬 Mergin Maps 60141 win64 Expires: 05/08/2026 #6014
Android Build 📬 Mergin Maps 813151 APK [arm64-v8a] Expires: 05/08/2026 #8131
📬 Mergin Maps 813151 APK [arm64-v8a] Google Play Store #8131
Android Build 📬 Mergin Maps 813111 APK [armeabi-v7a] Expires: 05/08/2026 #8131
📬 Mergin Maps 813111 APK [armeabi-v7a] Google Play Store #8131
iOS Build Build failed or not found. #9073

@Withalion Withalion added this to the 2026.4.0 milestone May 22, 2026
@Withalion Withalion modified the milestones: 2026.4.0, 2026.3.1 Jul 15, 2026

@Withalion Withalion left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's try another rebase :)

Comment thread app/mmstyle.h
double number720() const {return 720 * mDp;}

double scrollVelocityAndroid() const { return 10000; }
static double scrollVelocityAndroid() { return 10'000; }

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is probably a typo

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a typo, single quotes can be used as visual separators between digits since c++14.
For some reason I can't instantly recognize how many zeros are in10000, but by using thousands' separators I can instantly say 10'000 is 10k.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahh okay, I didn't know that neat

Comment thread app/layer/layerdetaildata.cpp Outdated

QPainter painter( &legend );
painter.setRenderHint( QPainter::Antialiasing );
{

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

out of curiosity what's the reason for having this part of the code wrapped in extra curly braces?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is to limit the scope of the QPainter. By making it go out of scope, the painting is finalized and not affected by setting the dpr.

There's a relevant comment:

// Tag with DPR only after painting so QPainter does not auto-scale the
// coordinate system by dpr (which would otherwise double-apply the factor).
legend.setDevicePixelRatio( dpr );

@github-actions

Copy link
Copy Markdown

📦 Build Artifacts Ready

OS Status Build Info Workflow run
macOS Build 📬 Mergin Maps 70381 dmg Expires: 18/10/2026 #7038
linux Build 📬 Mergin Maps 70641 x86_64 Expires: 18/10/2026 #7064
win64 Build 📬 Mergin Maps 62401 win64 Expires: 18/10/2026 #6240
Android Build 📬 Mergin Maps 834851 APK [arm64-v8a] Expires: 18/10/2026 #8348
📬 Mergin Maps 834851 APK [arm64-v8a] Google Play Store #8348
Android Build 📬 Mergin Maps 834811 APK [armeabi-v7a] Expires: 18/10/2026 #8348
📬 Mergin Maps 834811 APK [armeabi-v7a] Google Play Store #8348
iOS Build 📬 Build number: 26.07.929011 #9290

@Withalion Withalion modified the milestones: 2026.3.1, 2026.3.2 Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants