title: ggplot2 coord_polar preserve order when using fill
body: <p>Specifying the <code>fill</code> argument for <code>aes</code> results in a reverse order of the pie chart, so the breaks/labels wont match with pie pieces anymore. Please see the example and resulting plots below. </p>
  
  <pre><code>df = data.frame(Var1 = letters[1:5], Var2 = c(6, 31, 34, 66, 77))    
  df$Var1 = factor(df$Var1, levels = df$Var1, ordered = T)
  
  # just fine, but no colors
  ggplot(df, aes(x = 1,
                 y = Var2)) +
    geom_bar(width = 1, stat = "identity") +
    coord_polar(theta = "y") +
    scale_fill_manual(values = c("red","green","yellow","black","white"),
                      guide_legend(title = "My_Title")) +
    scale_y_continuous(breaks = (cumsum(df$Var2) -
                                   df$Var2 / 2),
                       labels = df$Var1)
  
  # reverse order appears
  ggplot(df, aes(x = 1,
                 y = Var2,
                 fill = Var1)) +
    geom_bar(width = 1, stat = "identity") +
    coord_polar(theta = "y") +
    scale_fill_manual(values = c("red","green","yellow","black","white"),
                      guide_legend(title = "My_Title")) +
    scale_y_continuous(breaks = (cumsum(df$Var2) -
                                   df$Var2 / 2),
                       labels = df$Var1)
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/dHUPt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dHUPt.png" alt="just fine"></a>
  <a href="https://i.stack.imgur.com/lhJYu.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/lhJYu.png" alt="reverse order"></a></p>