Changeset View
Changeset View
Standalone View
Standalone View
lib/documentview/abstractimageview.h
Show First 20 Lines • Show All 69 Lines • ▼ Show 20 Line(s) | 42 | public: | |||
---|---|---|---|---|---|
70 | Document::Ptr document() const; | 70 | Document::Ptr document() const; | ||
71 | 71 | | |||
72 | qreal computeZoomToFit() const; | 72 | qreal computeZoomToFit() const; | ||
73 | 73 | | |||
74 | qreal computeZoomToFill() const; | 74 | qreal computeZoomToFill() const; | ||
75 | 75 | | |||
76 | QSizeF documentSize() const; | 76 | QSizeF documentSize() const; | ||
77 | 77 | | |||
78 | /** | ||||
79 | * Returns the size of the loaded document in device independent pixels. | ||||
80 | */ | ||||
81 | QSizeF dipDocumentSize() const; | ||||
82 | | ||||
83 | /* | ||||
84 | * The size of the image that is currently visible, | ||||
85 | * in device independent pixels. | ||||
86 | */ | ||||
78 | QSizeF visibleImageSize() const; | 87 | QSizeF visibleImageSize() const; | ||
79 | 88 | | |||
80 | /** | 89 | /** | ||
81 | * If the image is smaller than the view, imageOffset is the distance from | 90 | * If the image is smaller than the view, imageOffset is the distance from | ||
82 | * the topleft corner of the view to the topleft corner of the image. | 91 | * the topleft corner of the view to the topleft corner of the image. | ||
83 | * Neither x nor y can be negative. | 92 | * Neither x nor y can be negative. | ||
93 | * This is in device independent pixels. | ||||
84 | */ | 94 | */ | ||
rkflx: Nit: `coordinats` → `coordinates` | |||||
85 | QPointF imageOffset() const; | 95 | QPointF imageOffset() const; | ||
86 | 96 | | |||
87 | /** | 97 | /** | ||
88 | * The scroll position, in zoomed image coordinates. | 98 | * The scroll position, in zoomed image coordinates. | ||
89 | * x and y are always between 0 and (docsize * zoom - viewsize) | 99 | * x and y are always between 0 and (docsize * zoom - viewsize) | ||
90 | */ | 100 | */ | ||
91 | QPointF scrollPos() const; | 101 | QPointF scrollPos() const; | ||
92 | void setScrollPos(const QPointF& pos); | 102 | void setScrollPos(const QPointF& pos); | ||
93 | 103 | | |||
104 | qreal devicePixelRatio() const; | ||||
105 | | ||||
94 | QPointF mapToView(const QPointF& imagePos) const; | 106 | QPointF mapToView(const QPointF& imagePos) const; | ||
95 | QPoint mapToView(const QPoint& imagePos) const; | 107 | QPoint mapToView(const QPoint& imagePos) const; | ||
96 | QRectF mapToView(const QRectF& imageRect) const; | 108 | QRectF mapToView(const QRectF& imageRect) const; | ||
97 | QRect mapToView(const QRect& imageRect) const; | 109 | QRect mapToView(const QRect& imageRect) const; | ||
98 | 110 | | |||
99 | QPointF mapToImage(const QPointF& viewPos) const; | 111 | QPointF mapToImage(const QPointF& viewPos) const; | ||
100 | QPoint mapToImage(const QPoint& viewPos) const; | 112 | QPoint mapToImage(const QPoint& viewPos) const; | ||
101 | QRectF mapToImage(const QRectF& viewRect) const; | 113 | QRectF mapToImage(const QRectF& viewRect) const; | ||
▲ Show 20 Lines • Show All 59 Lines • Show Last 20 Lines |
Nit: coordinats → coordinates