ndavis added a comment.

  I don't trust optimizers unless it's `scour`. That's the only one I know of 
that doesn't seem to cause problems occasionally. Inkscape's Optimized SVG save 
option actually uses `scour` to do the optimization.
  
  I'm somewhat open to the idea of only requiring optimization at build time 
for the sake of making it easier for newbies to contribute, but I prefer 
reading optimized SVGs in patches because that makes it easier for me to spot 
mistakes. The massive quantity of noise that Inkscape puts into SVGs, even 
plain SVGs, is staggering. Maybe we could have something that cleans the SVGs 
when submitted for a patch? If it won't work with Phabricator, it might work 
with GitLab.
  
  In T11950#206330 <https://phabricator.kde.org/T11950#206330>, @ngraham wrote:
  
  > As far as I can tell, every single icon in the `icons-dark` folder is 
identical to the other ones with the exception of having the colors in the 
stylesheet changed. Auto-generating these in CMake seems quite feasible.
  
  
  There are a few that can't be auto-generated that way (gradients don't work 
with stylesheets), so we should have some logic to avoid overwriting files that 
already exist. Then we can eliminate all the icons that only need to have their 
stylesheet changed while keeping the option to do Breeze Dark specific icons.
  
  > Optimization creates real problem - sometimes icons after optimizations 
become hard to edit, so less people want to do modifications.
  
  There are 2 main issues that Optimizers introduce (in order of severity):
  
  - That gradients that don't get their properties from another gradient that 
they reference can't be swapped, unless you unset and reset the fill of the 
object you want to change the gradient for. This seems like a bug in Inkscape.
  - That some optimizers combine paths with similar properties by default. This 
isn't a big deal if you know to go to Path > Break Apart in Inkscape, but 
obviously not everyone is going to know Inkscape or SVGs very well. It's hard 
to say how much a new contributor should be expected to know about SVGs or 
Inkscape.
    - Sometimes Break Apart causes objects to lose their properties and turn 
black. Usually not a big deal, it's very easy to fix, but not good for workflow.
    - I suppose we could just make sure we don't use any settings in the 
optimizer for combining paths.

TASK DETAIL
  https://phabricator.kde.org/T11950

To: ngraham, ndavis
Cc: mglb, #frameworks, mart, trickyricky26, ndavis, #vdg, ngraham, LeGast00n, 
cblack, konkinartem, ian, jguidon, hannahk, Ghost6, jraleigh, MrPepe, 
fbampaloukas, squeakypancakes, alexde, IohannesPetros, GB_2, michaelh, crozbo, 
firef, bruns, skadinna, aaronhoneycutt, mbohlender

Reply via email to