diff options
author | Javier <dev.git@javispedro.com> | 2015-06-13 04:24:21 +0200 |
---|---|---|
committer | Javier <dev.git@javispedro.com> | 2015-06-13 04:24:21 +0200 |
commit | 41f9a9b0563c3bd523bd534b854e50161a2626b3 (patch) | |
tree | 8c30aacdb80e26fd4202d345b30cab84ba437437 /afdnotebook.h | |
parent | 6cb50e66f3c196a2a4bcc95a419260d6b8c2461f (diff) | |
download | scribiu-41f9a9b0563c3bd523bd534b854e50161a2626b3.tar.gz scribiu-41f9a9b0563c3bd523bd534b854e50161a2626b3.zip |
continue with paperreplay loading changes
Diffstat (limited to 'afdnotebook.h')
-rw-r--r-- | afdnotebook.h | 41 |
1 files changed, 22 insertions, 19 deletions
diff --git a/afdnotebook.h b/afdnotebook.h index 38f926f..737196e 100644 --- a/afdnotebook.h +++ b/afdnotebook.h @@ -15,10 +15,31 @@ public: AfdNotebook(QObject *parent = 0); ~AfdNotebook(); + struct PageAddress { + PageAddress(); + explicit PageAddress(uint shelf, uint segment, uint book, uint page); + explicit PageAddress(uint series, uint shelf, uint segment, uint book, uint page); + explicit PageAddress(quint64 addr); + explicit PageAddress(const QString &str); + + QString toString() const; + quint64 toUInt64() const; + + bool operator<(const PageAddress& o) const; + bool operator==(const PageAddress& o) const; + + uint series : 12; + uint shelf : 12; + uint segment : 16; + uint book : 12; + uint page : 12; + }; + bool open(const QString &path); void close(); QString title() const; + quint64 guid() const; int numPages() const; @@ -36,25 +57,6 @@ public: bool readStrokes(const QString &penSerial, int page, StfReader::StrokeHandler *handler); private: - struct PageAddress { - PageAddress(); - explicit PageAddress(uint shelf, uint segment, uint book, uint page); - explicit PageAddress(uint series, uint shelf, uint segment, uint book, uint page); - explicit PageAddress(quint64 addr); - explicit PageAddress(const QString &str); - - QString toString() const; - - bool operator<(const PageAddress& o) const; - bool operator==(const PageAddress& o) const; - - uint series : 12; - uint shelf : 12; - uint segment : 16; - uint book : 12; - uint page : 12; - }; - struct Gfx { QString basename; }; @@ -89,6 +91,7 @@ private: private: QDir _dir; QString _title; + quint64 _guid; PageAddress _firstPage, _lastPage; uint _pagesPerBook; QMap<QString, Gfx> _gfx; |