Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ZeissZVIReader: Fix detection of label string offset #486

Merged
merged 2 commits into from
Apr 29, 2013
Merged

ZeissZVIReader: Fix detection of label string offset #486

merged 2 commits into from
Apr 29, 2013

Conversation

ghost
Copy link

@ghost ghost commented Apr 25, 2013

There may be a 2 byte pad between the end of the ShapeAttrs
block and the start of the Label string. And the string
may or may not be null, making it difficult to detect
reliably. We allow for a fuzzy match at 0 or 2 bytes after
the end of the ShapeAttrs. This padding is typically
only found in the initial Shape, and missing in subsequent
shapes.

There may be a 2 byte pad between the end of the ShapeAttrs
block and the start of the Label string.  And the string
may or may not be null, making it difficult to detect
reliably.  We allow for a fuzzy match at 0 or 2 bytes after
the end of the ShapeAttrs.  This padding is typically
only found in the initial Shape, and missing in subsequent
shapes.
}

if (nshape.text != null)
LOGGER.debug(" Text=" + nshape.text);
Copy link
Member

Choose a reason for hiding this comment

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

Minor suggestion: LOGGER.debug(" Text={}", nshape.text) to not incur StringBuilder overhead when debugging is turned off.

Copy link
Author

Choose a reason for hiding this comment

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

Done.

@melissalinkert
Copy link
Member

--test zeiss-zvi

@melissalinkert
Copy link
Member

Happy to merge if overnight builds are green.

melissalinkert added a commit that referenced this pull request Apr 29, 2013
ZeissZVIReader: Fix detection of label string offset
@melissalinkert melissalinkert merged commit 1d88f76 into ome:dev_4_4 Apr 29, 2013
@ghost ghost deleted the zvi-roi-missing2 branch April 29, 2013 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants