Changeset View
Changeset View
Standalone View
Standalone View
screens.h
Show First 20 Lines • Show All 82 Lines • ▼ Show 20 Line(s) | 47 | public: | |||
---|---|---|---|---|---|
83 | /** | 83 | /** | ||
84 | * @returns size of the @p screen. | 84 | * @returns size of the @p screen. | ||
85 | * | 85 | * | ||
86 | * To get the size of all screens combined use size(). | 86 | * To get the size of all screens combined use size(). | ||
87 | * @see size() | 87 | * @see size() | ||
88 | **/ | 88 | **/ | ||
89 | virtual QSize size(int screen) const = 0; | 89 | virtual QSize size(int screen) const = 0; | ||
90 | 90 | | |||
91 | /** | ||||
92 | * The highest scale() of all connected screens | ||||
93 | * for use when deciding what scale to load global assets at | ||||
94 | * Similar to QGuiApplication::scale | ||||
95 | * @see scale | ||||
96 | */ | ||||
97 | qreal maxScale() const; | ||||
98 | | ||||
91 | /* | 99 | /* | ||
92 | * The output scale for this display, for use by high DPI displays | 100 | * The output scale for this display, for use by high DPI displays | ||
93 | */ | 101 | */ | ||
94 | virtual qreal scale(int screen) const; | 102 | virtual qreal scale(int screen) const; | ||
95 | /** | 103 | /** | ||
96 | * The bounding size of all screens combined. Overlapping areas | 104 | * The bounding size of all screens combined. Overlapping areas | ||
97 | * are not counted multiple times. | 105 | * are not counted multiple times. | ||
98 | * | 106 | * | ||
▲ Show 20 Lines • Show All 67 Lines • ▼ Show 20 Line(s) | 163 | Q_SIGNALS: | |||
166 | **/ | 174 | **/ | ||
167 | void geometryChanged(); | 175 | void geometryChanged(); | ||
168 | /** | 176 | /** | ||
169 | * Emitted when the size of all screens combined changes. | 177 | * Emitted when the size of all screens combined changes. | ||
170 | * Not emitted when the size of an individual screen changes. | 178 | * Not emitted when the size of an individual screen changes. | ||
171 | * @see size() | 179 | * @see size() | ||
172 | **/ | 180 | **/ | ||
173 | void sizeChanged(); | 181 | void sizeChanged(); | ||
182 | /** | ||||
183 | * Emitted when the maximum scale of all attached screens changes | ||||
184 | * @see maxScale | ||||
185 | */ | ||||
186 | void maxScaleChanged(); | ||||
174 | 187 | | |||
175 | protected Q_SLOTS: | 188 | protected Q_SLOTS: | ||
176 | void setCount(int count); | 189 | void setCount(int count); | ||
177 | void startChangedTimer(); | 190 | void startChangedTimer(); | ||
178 | virtual void updateCount() = 0; | 191 | virtual void updateCount() = 0; | ||
179 | 192 | | |||
180 | protected: | 193 | protected: | ||
181 | /** | 194 | /** | ||
Show All 9 Lines | |||||
191 | private: | 204 | private: | ||
192 | int m_count; | 205 | int m_count; | ||
193 | int m_current; | 206 | int m_current; | ||
194 | bool m_currentFollowsMouse; | 207 | bool m_currentFollowsMouse; | ||
195 | QTimer *m_changedTimer; | 208 | QTimer *m_changedTimer; | ||
196 | KSharedConfig::Ptr m_config; | 209 | KSharedConfig::Ptr m_config; | ||
197 | QSize m_boundingSize; | 210 | QSize m_boundingSize; | ||
198 | OrientationSensor *m_orientationSensor; | 211 | OrientationSensor *m_orientationSensor; | ||
212 | qreal m_maxScale; | ||||
199 | 213 | | |||
200 | KWIN_SINGLETON(Screens) | 214 | KWIN_SINGLETON(Screens) | ||
201 | }; | 215 | }; | ||
202 | 216 | | |||
203 | /** | 217 | /** | ||
204 | * @brief A base implementation for backends with just a (nested) window | 218 | * @brief A base implementation for backends with just a (nested) window | ||
205 | **/ | 219 | **/ | ||
206 | class KWIN_EXPORT BasicScreens : public Screens | 220 | class KWIN_EXPORT BasicScreens : public Screens | ||
▲ Show 20 Lines • Show All 58 Lines • Show Last 20 Lines |