Opened 17 years ago

Last modified 13 years ago

#2020 closed defect

FOLLOW ANGLE label property — at Version 4

Reported by: lorenzetti@… Owned by: sdlime
Priority: normal Milestone:
Component: MapServer C Library Version: 4.10
Severity: normal Keywords:
Cc: jdenisgiguere@…, jmckenna@…

Description (last modified by sdlime)

For FOLLOW ANGLE label property, when the line is too windy, the letters in the
label are all garbled (either missing or/and in different order).

Change History (6)

by lorenzetti@…, 17 years ago

Attachment: shot.jpg added

Bug example

comment:1 by sdlime, 17 years ago

It would be helpful to see some data samples too. It's almost impossible to 
debug without test cases.

Steve

by lorenzetti@…, 17 years ago

Attachment: data_sample.tar.gz added

Shape data sample for debug

comment:2 by lorenzetti@…, 17 years ago

(From update of attachment 623)
Hi Steve I attached a shape data sample like you request for debug

Bye
Walter

comment:3 by jdenisgiguere@…, 17 years ago

Cc: jdenisgiguere@… added
If data are stored in a database, the following dirty function can temporarily
fix the problem. Function is in PostgreSQL syntax:

-- Patch for Mapserver bug number #2020
-- Strange behavior of short label when ANGLE is set to FOLLOW

CREATE OR REPLACE FUNCTION pad(cString TEXT) RETURNS TEXT AS $$
BEGIN
    RETURN cString || repeat(' ', 4 - char_length(cString));
END;
$$ LANGUAGE plpgsql;

comment:4 by sdlime, 17 years ago

Description: modified (diff)
Status: newassigned

Has anyone tried the padding fix suggested? I don't think the fix for this will be trivial otherwise as it will involve extensions to the underlying algorithm.

Steve

Note: See TracTickets for help on using tickets.