Get your taxes done using TurboTax

If you bought and then sold a mutual fund within a year for a gain, then that would be a short term capital gain that could be offset by long term loss.

However, if the Mutual Fund distributes a short term capital gain, then that is treated as a dividend on your 1099.

One way of thinking about it is that the Mutual Fund is the one who experienced the short term gain and is just distributing that income to the fund holder.  The tax code specifies that the distributed short term gains cannot be used to offset by long term losses and should be treated as nonqualified dividends.