Opened 19 years ago
Last modified 17 years ago
#1236 new defect
[PATCH] allow 'const' strings to be passed to msGetCharacterSize() + fix a warning
Reported by: | Owned by: | mapserverbugs | |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Build Problems | Version: | 4.4 |
Severity: | minor | Keywords: | |
Cc: | sdlime |
Description (last modified by )
The function msGetCharacterSize() should be able to accept const strings as the font specifier. Especially since it at the moment is passing it to gdImageStringFT(), which only read the string and don't write to it. At the moment, the 'constness' is removed in at least one place. This patch move this 'constness' removal from msGetMarkerSize() to msGetCharacterSize() in preparation for libgd to fix the prototype of gdImageStringFT(). The code should also use floating point values as the ptsize and angle argument when calling gdImageStringFT(), to make sure the variables matchines the type of the recieving function. This patch fixes these two issues. This patch reduces the number warnings when compiling the source with lots of warning flags enabled.
Attachments (1)
Change History (2)
by , 19 years ago
Attachment: | charsize-font-const.diff added |
---|
comment:1 by , 17 years ago
Cc: | added |
---|---|
Description: | modified (diff) |
Adding Steve to see if we can easily squish this one...
Note:
See TracTickets
for help on using tickets.
patch for msGetCharacterSize()