pagesizelabel.h 1.21 KB
Newer Older
Albert Astals Cid's avatar
Albert Astals Cid committed
1 2 3 4 5 6 7 8 9 10 11 12
/***************************************************************************
 *   Copyright (C) 2006 by Albert Astals Cid <aacid@kde.org>               *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 ***************************************************************************/

#ifndef _OKULAR_PAGESIZELABEL_H_
#define _OKULAR_PAGESIZELABEL_H_

13
#include <ksqueezedtextlabel.h>
Albert Astals Cid's avatar
Albert Astals Cid committed
14 15 16 17 18 19 20 21 22 23

#include "core/observer.h"

namespace Okular {
class Document;
}

/**
 * @short A widget to display page size.
 */
24
class PageSizeLabel : public KSqueezedTextLabel, public Okular::DocumentObserver
Albert Astals Cid's avatar
Albert Astals Cid committed
25
{
Pino Toscano's avatar
Pino Toscano committed
26 27
    Q_OBJECT

Albert Astals Cid's avatar
Albert Astals Cid committed
28 29
    public:
        PageSizeLabel( QWidget *parent, Okular::Document * document );
30
        ~PageSizeLabel() override;
Albert Astals Cid's avatar
Albert Astals Cid committed
31 32

        // [INHERITED] from DocumentObserver
33
        void notifyCurrentPageChanged( int previous, int current ) override;
Albert Astals Cid's avatar
Albert Astals Cid committed
34 35 36 37 38 39 40

    private:
        Okular::Document * m_document;
};

#endif