Retained earnings reports the sum of a company’s net income since its founding less all amounts distributed in the form of dividends and transfers to the paid-in capital accounts, which equals the amount kept in the firm.  As with all profits, earnings that are retained are taxed at the Commercial level when recognized.  When net income is recognized, revenues have exceeded the expenses to produce those earnings.  If assets have increased without an increase in liabilities or paid-in capital, retained earnings must have grown and equity must have also increased.

Retained Earnings and Cash Dividend Payment (Example)
MyCo has 10,000 shares of common stock issued and outstanding.  A €10 dividend is declared on 1 July and paid on 14 July 2017.
1 Jul 17 Retained Earnings 100,000
Dividends Payable 100,000
To record the declaration of a cash dividend on 1 Jul 2017
14 Jul 17 Dividends Payable 100,000
Cash 100,000
To record the payment of a cash dividend on 14 Jul 2017

Appropriated retained earnings are an amount of retained earnings in the balance sheet that is segregated for a specific purpose and reported separately to inform shareholders of the amount appropriated for funding needs.  A company that undertakes a special project (e.g., building a plant) may be required by a major creditor to limit dividend payments until the project is completed or simply in order to conserve cash for expansion.

Comprehensive income is all income and expenses recognized during an accounting period as a result of all changes in equity except those due to investments by owners (capital increase) and distributions to owners (dividends).  Comprehensive income includes revenue, finance costs, tax expenses, discontinued operations, profit share and profit.  The difference between net income reported in the income statement and comprehensive income is other comprehensive income (OCI).  OCI includes unrealized gains and losses on available for sale securities, gains and losses on derivatives held as cash flow hedges, gains and losses due to translating the financial statements of foreign subsidiaries, actuarial gains and losses on defined benefit plans recognized, and changes in revaluation surplus.

Other Comprehensive Income – Unrealized Loss (Example)
OurCo purchased a five-year bond on 1 February 2017 for $5m with a coupon and effective rate of 5% payable annually on 31 December.  At the reporting date, 5% interest was received and the market rate of interest has increased to 6%.  With a carrying value of $5,000,000 and the fair value of $4,952,830, an unrealized loss of 47,170 (fair value − carrying value) is recognized.
31 Dec 17 Cash 250,000
Interest Income 250,000
Unrealized Loss – OCI 47,170
Investment 47,170
To record receipt of interest income and FV decrease

Accumulated other comprehensive income is shown as a separate line item in shareholders’ equity that reports the accounting entity’s cumulative income that has not been reported as part of net income in the income statement.  Revaluation surplus represents amounts credited due to the increase in the carrying value of an asset.

Revaluation Surplus – US GAAP vs. IFRS
US GAAP IFRS
The revaluation of assets is not permitted. A revaluation surplus reflects the revaluation of assets to their fair value.