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

Change some amenity colors to grey #3402

Closed
wants to merge 2 commits into from
Closed

Change some amenity colors to grey #3402

wants to merge 2 commits into from

Conversation

Adamant36
Copy link
Contributor

@Adamant36 Adamant36 commented Sep 18, 2018

This PR changes the color of some amenities to grey. The purpose of it is to "move some culturally insignificant, man made objects to man-made-grey, in order to offload the semantics in the amenity-brown category." Closes #3326

Bench
bench
Picnic table
picnic table
Waste basket
waste basket
Waste disposal
waste disposal
Recycling
recycling
Shelter
shelter

@matthijsmelissen
Copy link
Collaborator

Just to remind me, what was the idea or philosophy behind this?

@Adamant36
Copy link
Contributor Author

Did you look in the original issue? Im pretty sure the reason is given there.

@kocio-pl
Copy link
Collaborator

Please add short summary/rationale for every PR, so it's self-contained. If there were some conclusions, they should be clear without reading all the discussions - they are usually complicated.

@Adamant36
Copy link
Contributor Author

Adamant36 commented Sep 18, 2018

@kocio-pl, my bad. Its hard to write a rational for issues where I wasnt involved in the creation of it or the disscussion at all. Plus, sometimes people's reasons for wanting things a certain way go over my head. But I'll do a better job at it in the future anyway.

@sommerluk
Copy link
Collaborator

I wasnt involved in the creation or disscussion at all

That’s something I don’t understand. Because this PR is created by you. And you also have participated in the discussion of #3326 (the issue that is closed by this PR) since the very beginning.

@kocio-pl
Copy link
Collaborator

I'm happy that you're making PRs and learning details.

When you create PR, you are backing this proposition, so it might be from your point of view, but should be pretty clear why it's a good change and why it's needed. For example:

  • why these objects and not some others?
  • why this color and not something else?

@Tomasz-W Tomasz-W mentioned this pull request Sep 18, 2018
26 tasks
@polarbearing
Copy link
Contributor

IIRC the idea was to move some culturally insignificant, man made objects to man-made-grey, in order to offload the semantics in the amenity-brown category.

@Tomasz-W
Copy link

Tomasz-W commented Sep 18, 2018

@Adamant36 I noticed that you are choosing isolated places for test renderings, but you should pick them rather opposite - it's important to know how certain change would match with another map elements and how it looks on different backgrounds (eg. grey amenity=shelter on landuse=forest but also on highway=platform area)
PS. Please contact me via e-mail provided in my profile :)

@Tomasz-W
Copy link

@Adamant36 Can you left brown icon for amenity=recycling + recycling_type=centre combination?

@kocio-pl
Copy link
Collaborator

Related to #3395.

@sommerluk
Copy link
Collaborator

Yes, more test rendering – maybe at different zoom levels – would be great. You need to show that the PR you propose actually works. So we can discuss it. (Don’t worry, I think that for this PR, chances are quite good.)

@Adamant36
Copy link
Contributor Author

@Tomasz-W and @sommerluk, I'll add more test renderings. Kocio-pl told me several times I need to crop things more to make the icons easier to spot. I guess I over croped in this situation though. I'll fix the recycling thing also.

@Adamant36
Copy link
Contributor Author

More tests

Benches
download
download 1
download 2
Recycling containers
download
download 1
download 2
Picnic tables
download
download 1
download 2
download 3
download 4
Shelters
download
download 2
Waste Baskets
download
Uncle Billy's Cabin
uncle billy s cabin

@Tomasz-W, I fixed the recycling thing. Its back to brown.

@Tomasz-W
Copy link

Tomasz-W commented Sep 22, 2018

@Adamant36 amenity=recycling node without recycling_type=* tag is like a container by default, so it should be in man-made-grey. Is it considered in the code? (sorry, but as I'm not a coder I can't check this indyvidually)

@Adamant36
Copy link
Contributor Author

Adamant36 commented Sep 22, 2018

I was thinking about that and I couldnt decide. So I just left it amenity brown. To me its neutral since we dont know if its a centre or a bin. As it is, the wiki doesnt sound like it has a default. Im fine with grey anyways though.

@polarbearing
Copy link
Contributor

Thanks for the tests. As for the cropping, it probably depends on the stage of the proposal. When introducing an idea, it's good to focus on the new detail, while at this stage it's important to see it in context.

In favour of the change. I wonder, the college example has both brown and grey recycling, but I find it unlikely to have recycling centres in these places? Maybe a tagging error?

For naming the category, I'd like something like infrastructure_minor or so?

@Adamant36
Copy link
Contributor Author

@polarbearing, thanks for the details. That makes sense.

As far as the college example goes, its probably the difference between the type of recycling it is being tagged or not. I was talking about it above. It kind of presents a problem if we have containers tagged as gray, but then recycling centers and no category tagged as brown, because inevitably some of the places without the type tag will be containers, but still show up as brown when they shouldn't. Maybe a solution would be another third color for amenity=recycling. Since we technically don't know if it is an amenity or not. It would be interesting to know how many other tags out there are that change if a modifier can be added to them. Maybe an "unknown" color category could be created so mappers can know if something needs be tagged with a type tag. Or we could just leave recycling out of the grey all together.

@Tomasz-W
Copy link

Before discussion in this ticket I didn't even know about recycling_type=* key, and I was marking recycling containers just by amenity=recycling. I think a lot of people map them like that, so I suggest to render amenity=recycling in man-made-grey. It's a lot more possible that someone forgot to add recycling_type=* key to simple container than to much bigger recycling centre,

@kocio-pl
Copy link
Collaborator

Please be more precise - we have 3 main cases, which should be brown, gray (or anything else)?:

  • amenity=recycling
  • amenity=recycling + recycling_type=container
  • amenity=recycling + recycling_type=centre (it's rendered earlier)

@Tomasz-W
Copy link

Sure, I mean:

  • amenity=recycling -> grey
  • amenity=recycling + recycling_type=container ->grey
  • amenity=recycling + recycling_type=centre -> brown

@polarbearing
Copy link
Contributor

Yes the unknown one should be treated like the minor infrastructure case, i.e. the container.
Only if the major type (centre) is specified, the amenity colour can be awarded.

@Adamant36
Copy link
Contributor Author

@Tomasz-W and @polarbearing, makes sense. I'll update it when I get a chance.

@Adamant36
Copy link
Contributor Author

Adamant36 commented Sep 26, 2018

Fixed it. It should be good to go now.

recycling center in brown
recycling center in brown

regular recycling in gray (ignore the name)
regular recycling in gray



[feature = 'amenity_recycling'][recycling_type = 'container'][zoom >= 19],
[feature = 'amenity_recycling'][zoom >= 19] {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks quite readable, but it means that [feature = 'amenity_recycling'][zoom >= 19] covers also recycling centers on z19+. It might accidentally work because of the order of rules Carto CSS is applying, but it would be harder to debug problems. I think instead of these two lines we should just use something like [feature = 'amenity_recycling'][recycling_type != 'centre'][zoom >= 19].

@Adamant36
Copy link
Contributor Author

@kocio-pl, I updated the code. So, it should be good to go now. Here's some tests with the new code.
Normal recycling in grey
normal recycling in grey
recycling center in brown
recycling center still in brown
recycling container in grey
recycling container in grey

amenity-points.mss Show resolved Hide resolved
amenity-points.mss Outdated Show resolved Hide resolved
@Adamant36
Copy link
Contributor Author

@kocio-pl, I updated it and I think the changes you wanted are fixed now. Also, I tested it on my side and it seemed to work. Although, I didn't do any new test rendering shots.

@Adamant36
Copy link
Contributor Author

@kocio-pl, I think its good to go now.
Normal recycling grey
normal recycling grey
recycling container grey
recycling container grey
recycling center brown
recycling center brown

marker-file: url('symbols/amenity/recycling.svg');
marker-fill: @amenity-brown;
[recycling_type = 'centre'] { marker-fill: @amenity-brown; }
[recycling_type != 'centre'] { marker-fill: @man-made-icon; }
Copy link
Collaborator

@kocio-pl kocio-pl Oct 12, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It also looks like indentation issue.

@Adamant36
Copy link
Contributor Author

@kocio-pl, sorry about that. Hopefully its fixed now (I'm keeping my fingers crossed).

@kocio-pl
Copy link
Collaborator

kocio-pl commented Oct 16, 2018

I have a problem with this code. It has some easy parts, when some lines are replaced, but also some blocks are moved in some other place etc. and I have a hard time following what is really done this way. For example this object has lost its label instead of just changing the color:

a1mkznyu
pnkms0rw

My recommendation is to make it as simple as possible and not clean code along the way (which I suspect is what you've tried to do) to avoid possibility of introducing bugs. Cleaning is always possible in separate PRs and the files are long enough to get lost easily.

@Adamant36
Copy link
Contributor Author

Adamant36 commented Oct 16, 2018

@kocio-pl, I didn't clean any code along the way. Your the one that wanted the recycling bit simplified. That might be whats causing the problem. Since it seemed to work fine before that. There was also three conflict that needed resolving due to it being a month old now. Its probably related to that somehow. Since the recycling part seems to be whats causing all the issues, can I just take it out and do it in a separate PR? I rather just get the simple, none problematic things dealt with, and deal with it on its own.

This is one of the reasons I'm sick of Issues involving multiple issues. I see no reason why things can't be split up more. Especially if its going to hold things up for a month by involving extra testing/fixing that wouldn't be necessary otherwise.

@kocio-pl
Copy link
Collaborator

kocio-pl commented Oct 16, 2018

Sorry for the time it took. I think you're right - in this case it's best if you will make the split and I will check it one by one soon.

However sometimes it's better to make the one big PR, for example it worked goof for adding and fixing towers. I'm not sure what is the golden rule when to split things up or not to do it...

@Adamant36 Adamant36 closed this Oct 20, 2018
@Adamant36 Adamant36 deleted the grey branch October 20, 2018 07:13
@polarbearing
Copy link
Contributor

Do I understand correctly that it's just the PR being closed bu #3326 still on the agenda?

@Adamant36
Copy link
Contributor Author

@polarbearing. Yes, I closed it to split it up into a couple of PRs. The branch was behind by like 10 commits and something was screwing up with the recycling part in the proccess of resolving conflicts that I couldnt figure out. So im going to do it separate from the other stuff with an updated branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants