We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Consider a common case:
A single line label with default valign shows:
<TextSymbolizer ... size="12" dy="16"/>
[[Image(valign-middle_1line_dy16.png)]]
A two line label with default valign is being dropped, because the upper line now intersects the symbol:
[[Image(valign-middle_2line_dy16.png)]]
A two line label with bottom valign:
<TextSymbolizer ... size="12" dy="16" vertical_alignment="bottom"/>
[[Image(valign-bottom_2line_dy16.png)]]
This is now a bit too far away from the symbol, so we can put it closer:
<TextSymbolizer ... size="12" dy="10" vertical_alignment="bottom"/>
[[Image(valign-bottom_2line_dy10.png)]]
Single line labels are still as close to the symbol as well:
[[Image(valign-bottom_1line_dy10.png)]]
In fact, with bottom alignment, it doesn't matter how many lines you have, as they will always start just under the symbol.
The same logic works in reverse when placing the label above the symbol.
The default vertical_alignment for TextSymbolizer should depend on the value of dy:
|| dy = 0 || vertical_alignment="middle" || || dy > 0 || vertical_alignment="bottom" || || dy < 0 || vertical_alignment="top" ||
The text was updated successfully, but these errors were encountered:
[artem] implemented in r1527. Thanks, Ldp!
Sorry, something went wrong.
No branches or pull requests
Consider a common case:
A single line label with default valign shows:
<TextSymbolizer ... size="12" dy="16"/>
[[Image(valign-middle_1line_dy16.png)]]
A two line label with default valign is being dropped, because the upper line now intersects the symbol:
<TextSymbolizer ... size="12" dy="16"/>
[[Image(valign-middle_2line_dy16.png)]]
A two line label with bottom valign:
<TextSymbolizer ... size="12" dy="16" vertical_alignment="bottom"/>
[[Image(valign-bottom_2line_dy16.png)]]
This is now a bit too far away from the symbol, so we can put it closer:
<TextSymbolizer ... size="12" dy="10" vertical_alignment="bottom"/>
[[Image(valign-bottom_2line_dy10.png)]]
Single line labels are still as close to the symbol as well:
[[Image(valign-bottom_1line_dy10.png)]]
In fact, with bottom alignment, it doesn't matter how many lines you have, as they will always start just under the symbol.
The same logic works in reverse when placing the label above the symbol.
The default vertical_alignment for TextSymbolizer should depend on the value of dy:
|| dy = 0 || vertical_alignment="middle" ||
|| dy > 0 || vertical_alignment="bottom" ||
|| dy < 0 || vertical_alignment="top" ||
The text was updated successfully, but these errors were encountered: