Skip to content

Fix/measurebased relative part zoom#227

Merged
bwbohl merged 3 commits into
Edirom:developfrom
baz-ga:fix/measurebased-relative-part-zoom
Jul 6, 2026
Merged

Fix/measurebased relative part zoom#227
bwbohl merged 3 commits into
Edirom:developfrom
baz-ga:fix/measurebased-relative-part-zoom

Conversation

@bwbohl

@bwbohl bwbohl commented Jul 1, 2026

Copy link
Copy Markdown
Member

Description, Context and related Issue

Strongly connected to and probably depending on: #225

Fixes measure-based relative part zoom by implementing proportional vertical space distribution and aligned zone display.

Refs #25
closes #25

Important Changes

  • Proportionally distribute vertical space between parts based on their height instead of equal division
  • Track tallest slice height within each part for accurate space allocation
  • Add fitHeight parameter to force zone height to fill container while maintaining full staff visibility
  • Add alignment parameter to support horizontal positioning ('left', 'right', 'center') for zone display
  • Ensure all parts display at common zoom level with consistent staff visibility in multi-part view
  • Update flex values to trigger layout recalculation through owner container's updateLayout method

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • Improvement

@bwbohl bwbohl added this to the 1.4.0 milestone Jul 1, 2026
@github-project-automation github-project-automation Bot moved this to In Progress in Edirom Development Jul 1, 2026
@bwbohl bwbohl added the Type: bugfix A pull request providing a bugfix label Jul 1, 2026
@bwbohl bwbohl moved this from In Progress to Ready for Review in Edirom Development Jul 1, 2026
@krHERO krHERO requested a review from hizclick July 1, 2026 12:19
@bwbohl bwbohl force-pushed the fix/measurebased-relative-part-zoom branch from 3ebfe7c to 8913fe9 Compare July 1, 2026 12:22
@bwbohl

bwbohl commented Jul 2, 2026

Copy link
Copy Markdown
Member Author
  1. I added some test data to the Erstdruck source of the EditionExample, cf. pull request: Ftr: part measures EditionExample#40

With the above test data, the development version of the frontend should show the following in measureBasedView:

CleanShot 2026-07-02 at 14 06 11

With the changes of this pull request applied, the area each part gets should be proportional to the space it requires on the score page (screenshot made with #225 applied, too):

CleanShot 2026-07-02 at 14 07 34

bwbohl added 3 commits July 2, 2026 16:28
Track the tallest slice height within each part and use it to
proportionally distribute vertical space between parts instead of
dividing equally. This ensures image viewers are sized according to
their content rather than splitting space uniformly. The flex value
is updated to match the part's representative height, triggering
layout recalculation through the owner container's updateLayout
method.
Closes Edirom#25
Add alignment parameter to showRect to position zones based on
viewer count. Implement fitHeight mode to fit zone height to
container, ensuring all parts display at common zoom level with
full staff visibility. Update vertical space distribution to be
proportional to part height rather than equal, maintaining
consistent zoom across stacked parts.
Add fitHeight parameter to showRect methods in ImageViewer and
OpenSeaDragonViewer to force zone height to fill container while
left-aligning content. This ensures each part shows its full staff
at common zoom in measure-based view.

Add alignment parameter to OpenSeaDragonViewer.showRect to support
positioning zones horizontally ('left', 'right', 'center') for
proper display in spread layouts.

Update MeasureBasedView to pass fitHeight=true and alignment based
on part position in row for correct multi-part rendering.
@bwbohl bwbohl force-pushed the fix/measurebased-relative-part-zoom branch from 8913fe9 to 0556b6d Compare July 2, 2026 14:35
@bwbohl

bwbohl commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

@hizclick I can reproduce the above difference using develop vs this branch, how is the status for you?

@hizclick

hizclick commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

@hizclick I can reproduce the above difference using develop vs this branch, how is the status for you?

I sent you a DM

@github-project-automation github-project-automation Bot moved this from Ready for Review to Approved in Edirom Development Jul 6, 2026
@bwbohl bwbohl merged commit 3ec3ac1 into Edirom:develop Jul 6, 2026
@github-project-automation github-project-automation Bot moved this from Approved to Done in Edirom Development Jul 6, 2026
@bwbohl bwbohl deleted the fix/measurebased-relative-part-zoom branch July 6, 2026 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Type: bugfix A pull request providing a bugfix

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[ftr] measureBasedView: Adjust height of part areas

2 participants