title: Reverse fill order for histogram bars in ggplot2
body: <p>I have noticed that the default for filling the bars in a histogram created using plot is the reverse alphabetical, while the legend in ordered alphabetically. I there any way to get both to order alphabetically? Problem is apparent in example plot below. Bonus question: how I change the left to right bar order from alphabetical to decreasing count total? Thanks</p>
  
  <pre><code>df &lt;- data.frame(
    Site=c("A05","R17","R01","A05","R17","R01"),
    Group=c("Fungia","Fungia","Acro","Acro","Porites","Porites"),
    Count=c(6,8,6,7,2,9),
    Total=c(13,10,15,13,10,15)
  )
  
    Site   Group Count Total
  1  A05  Fungia     6    13
  2  R17  Fungia     8    10
  3  R01    Acro     6    15
  4  A05    Acro     7    13
  5  R17 Porites     2    10
  6  R01 Porites     9    15
  
  qplot(df$Site,data=df,weight=df$Count,geom="histogram", fill=df$Group, ylim = c(0,16)) + 
    xlab("Sites") + 
    ylab("Counts") + 
    scale_fill_hue(h=c(0,360), l=70, c=70,name = "Emergent Groups")
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/Gouyh.png" alt="enter image description here"></p>
  
  <p>I am trying to order the counts from high to low and the fill colours so that they match the alphabetic ordering of the legend. I have been trying to adjust it for a few hours with the tips from the initial posts but without sucess. Any help on this would be most appreciated!!! </p>