mapnik icon indicating copy to clipboard operation
mapnik copied to clipboard

New text-line-wrap visual tests

Open Andrey-VI opened this issue 11 years ago • 3 comments

Requested by @springmeyer @ https://github.com/mapnik/mapnik/issues/2427

I noticed that dy setting works different for Latin and Cyrillic scripts. For Cyrillic script it looks like dy*2. Wondering why…

P. S.: This is my first pull ever, so sorry about things like text-line-wrap-512-512-1.0-grid-reference.json → text-line-wrap-800-450-1.0-grid-reference.json. I don't know how to fix this.

Andrey-VI avatar Oct 16 '14 13:10 Andrey-VI

After this new visual tests I realized that I need a different behaviour from wrap-character and repeat-wrap-character="true": if we use, for example, wrap-character="-" and repeat-wrap-character="true" all default ICU line breaking are ignored. How to avoid this?

For now I have two ideas, both of them doesn't break wrap-character behaviour:

  1. Use repeat-wrap-character="[symbol]", so if ICU breaks line at this [symbol] it's repeated on the new line.
  2. Use repeat-wrap-character="true/false" and repeat any ICU line break characters except whitespace characters (RegEx \s class) on the new line.

I prefer the first one.

@artemp , @springmeyer , what do you think?

Andrey-VI avatar Oct 16 '14 19:10 Andrey-VI

@Andrey-VI - could you check and resolve conflicts (rebase on latest master?), pls?

artemp avatar Apr 20 '22 08:04 artemp

@artemp, done: https://github.com/mapnik/test-data-visual/pull/85

Andrey-VI avatar Apr 20 '22 20:04 Andrey-VI