sb12 / OSMTrainRouteAnalysis

Analysis of Train Routes Based on OpenStreetMap Data
Other
14 stars 6 forks source link

Use color constants #88

Closed ghost closed 9 years ago

ghost commented 9 years ago

Use (new) color constants with new values

sb12 commented 9 years ago

Why having an extra file to define the colors? Ok they might be hard to find in line 250, but why not just have the constants defined in the first rows?

ghost commented 9 years ago

Why having an extra file to define the colors?

Because the colors should ABSOLUTELY have NOTHING to do with any code. Not even the svg code.

Someone changes the colors: Look at file colors.php. Change it. Everybody sees directly with the pull request: Nothing functional, only asthetics.

You change the signals.php. You split it up. Who knows. The colors stay safe in colors.php. No longer searching for it in any files. ;)

ghost commented 9 years ago

Very good. From now on I know where to look to change the colors, if neccessary again.