root/trunk/src/DocumentRectangle.h
| Revision 163, 1.9 kB (checked in by jordi, 2 years ago) |
|---|
| Line | |
|---|---|
| 1 | // ePDFView - A lightweight PDF Viewer. |
| 2 | // Copyright (C) 2006 Emma's Software. |
| 3 | // |
| 4 | // This program is free software; you can redistribute it and/or modify |
| 5 | // it under the terms of the GNU General Public License as published by |
| 6 | // the Free Software Foundation; either version 2 of the License, or |
| 7 | // (at your option) any later version. |
| 8 | // |
| 9 | // This program is distributed in the hope that it will be useful, |
| 10 | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | // GNU General Public License for more details. |
| 13 | // |
| 14 | // You should have received a copy of the GNU General Public License |
| 15 | // along with this program; if not, write to the Free Software |
| 16 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 17 | |
| 18 | #if !defined (__DOCUMENT_RECTANGLE_H__) |
| 19 | #define __DOCUMENT_RECTANGLE_H__ |
| 20 | |
| 21 | namespace ePDFView |
| 22 | { |
| 23 | /// |
| 24 | /// @class DocumentRectangle. |
| 25 | /// @brief A rectangle on a page. |
| 26 | /// |
| 27 | /// This class is just to hold the coordinates of a rectangle on a document. |
| 28 | /// It is used as a way to know where are the document's link or the |
| 29 | /// text that has been searched. |
| 30 | /// |
| 31 | class DocumentRectangle |
| 32 | { |
| 33 | public: |
| 34 | DocumentRectangle (gdouble x1, gdouble y1, gdouble x2, gdouble y2); |
| 35 | DocumentRectangle (DocumentRectangle &original); |
| 36 | ~DocumentRectangle (void); |
| 37 | |
| 38 | gdouble getX1 (void); |
| 39 | gdouble getX2 (void); |
| 40 | gdouble getY1 (void); |
| 41 | gdouble getY2 (void); |
| 42 | |
| 43 | protected: |
| 44 | /// The X coordinate of the link's top-left corner. |
| 45 | gdouble m_X1; |
| 46 | /// The X coordinate of the link's bottom-right corner. |
| 47 | gdouble m_X2; |
| 48 | /// The Y coordinate of the link's top-left corner. |
| 49 | gdouble m_Y1; |
| 50 | /// The Y coordinate of the link's bottom-right corner. |
| 51 | gdouble m_Y2; |
| 52 | |
| 53 | }; |
| 54 | } |
| 55 | |
| 56 | #endif // !__DOCUMENT_RECTANGLE_H__ |
Note: See TracBrowser
for help on using the browser.
