From an accounting standpoint, stockholders' investment and revenues increase the assets of the company without adding to the liabilities. Therefore according to the equation (A = L + E), equity must increase.
Similarly, issuing dividends and paying expenses pays cash out of the company, which decreases assets without changing liabilities. Therefore equity must decrease.
Another way to think of it is: what contributes to the company's profit and/or value, and what decreases these things? Well, revenues and people investing in the company are good (and therefore good for stockholders), and giving cash out and paying expenses are costs to the company (and therefore decrease value for stockholders).