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

The GetLegendGraphics request generate a white image if name is empty #4782

Merged
merged 1 commit into from Oct 5, 2013

Conversation

Projects
None yet
2 participants
@tbonfort
Copy link
Member

tbonfort commented Oct 5, 2013

Using the last trunk:
if set CLASS name = "" the image is empty and white.
Instead it is correctly create if the name is valorized.

As example:

this will get an empty getlegendgraphics image:

LAYER
    NAME "test1"
    TYPE LINE
    STATUS OFF
    EXTENT  1660351.00 4458445.22 1866743.13 4960849.91
    FEATURE
    WKT "LINESTRING(1662120.546188 4858603.677291, 1662738.746295 4858875.082216, 1663854.522097 4858618.755342, 1664779.309249 4858638.85941)"
    END #FEATURE
    METADATA
      "wms_title" "Test"
      "ows_enable_request" "*"
    END
    LABELCACHE on
    CLASS
      name ""
      STYLE
        COLOR 200 0 0
        OUTLINECOLOR 0 255 0
      END
    END #CLASS
  END 

Instead this other will generate a correct getlegendgraphic image.

LAYER
    NAME "test1"
    TYPE LINE
    STATUS OFF
    EXTENT  1660351.00 4458445.22 1866743.13 4960849.91
    FEATURE
    WKT "LINESTRING(1662120.546188 4858603.677291, 1662738.746295 4858875.082216, 1663854.522097 4858618.755342, 1664779.309249 4858638.85941)"
    END #FEATURE
    METADATA
      "wms_title" "Test"
      "ows_enable_request" "*"
    END
    LABELCACHE on
    CLASS
      name "aaaa"
      STYLE
        COLOR 200 0 0
        OUTLINECOLOR 0 255 0
      END
    END #CLASS
  END 
@tbonfort

This comment has been minimized.

Copy link
Member

tbonfort commented Oct 4, 2013

not a bug, unless previous versions exhibited a different behavior. A class with no name or title is ignored in legend requests (or at least that's how I understand it)

@aperi2007

This comment has been minimized.

Copy link
Author

aperi2007 commented Oct 4, 2013

Infact, the precedent version was producing the image without any title on it.
Instead this version will produce an empty image.

@tbonfort

This comment has been minimized.

Copy link
Member

tbonfort commented Oct 4, 2013

ok, definitely a bug then

@ghost ghost assigned tbonfort Oct 4, 2013

tbonfort added a commit to tbonfort/mapserver that referenced this pull request Oct 5, 2013

tbonfort added a commit to mapserver/msautotest_DEPRECATED that referenced this pull request Oct 5, 2013

@tbonfort tbonfort merged commit cea8520 into mapserver:master Oct 5, 2013

1 check passed

default The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.