Changeset View
Changeset View
Standalone View
Standalone View
src/wrtembed/KReportDpi.cpp
Show All 13 Lines | 1 | /* This file is part of the KDE project | |||
---|---|---|---|---|---|
14 | Library General Public License for more details. | 14 | Library General Public License for more details. | ||
15 | 15 | | |||
16 | You should have received a copy of the GNU Library General Public License | 16 | You should have received a copy of the GNU Library General Public License | ||
17 | along with this library; see the file COPYING.LIB. If not, write to | 17 | along with this library; see the file COPYING.LIB. If not, write to | ||
18 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 18 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
19 | * Boston, MA 02110-1301, USA. | 19 | * Boston, MA 02110-1301, USA. | ||
20 | */ | 20 | */ | ||
21 | 21 | | |||
22 | #include "KReportDpi.h" | 22 | #include "KReportDpi_p.h" | ||
23 | 23 | | |||
24 | #ifdef Q_WS_X11 | 24 | #ifdef Q_WS_X11 | ||
25 | #include <QX11Info> | 25 | #include <QX11Info> | ||
26 | #else | 26 | #else | ||
27 | #include <QApplication> | 27 | #include <QApplication> | ||
28 | #include <QDesktopWidget> | 28 | #include <QDesktopWidget> | ||
29 | #endif | 29 | #endif | ||
30 | #include <QGlobalStatic> | 30 | #include <QGlobalStatic> | ||
Show All 38 Lines | 68 | { | |||
69 | return s_instance->m_dpiX; | 69 | return s_instance->m_dpiX; | ||
70 | } | 70 | } | ||
71 | 71 | | |||
72 | int dpiY() | 72 | int dpiY() | ||
73 | { | 73 | { | ||
74 | return s_instance->m_dpiY; | 74 | return s_instance->m_dpiY; | ||
75 | } | 75 | } | ||
76 | 76 | | |||
77 | void setDpi(int x, int y) | | |||
78 | { | | |||
79 | s_instance->m_dpiX = x; | | |||
80 | s_instance->m_dpiY = y; | | |||
81 | } | | |||
82 | | ||||
83 | } | 77 | } |