79 xcb_window_t frameId()
const;
80 xcb_window_t window()
const;
81 xcb_window_t wrapperId()
const;
84 return m_decoInputExtent;
87 int desktopId()
const;
88 QByteArray sessionId()
const;
89 xcb_window_t wmClientLeader()
const;
92 QPointF framePosToClientPos(
const QPointF &point)
const override;
93 QPointF clientPosToFramePos(
const QPointF &point)
const override;
94 QSizeF frameSizeToClientSize(
const QSizeF &size)
const override;
95 QSizeF clientSizeToFrameSize(
const QSizeF &size)
const override;
96 QRectF frameRectToBufferRect(
const QRectF &rect)
const;
97 QPointF wrapperPos()
const;
98 QSizeF implicitSize()
const;
100 xcb_visualid_t visual()
const;
102 bool hasAlpha()
const;
103 QRegion opaqueRegion()
const;
104 QList<QRectF> shapeRegion()
const;
106 pid_t pid()
const override;
107 QString windowRole()
const override;
109 bool isTransient()
const override;
110 bool groupTransient()
const override;
111 QList<Window *> mainWindows()
const override;
112 bool hasTransient(
const Window *c,
bool indirect)
const override;
113 void checkTransient(xcb_window_t w);
114 Window *findModal(
bool allow_itself =
false)
override;
115 const Group *group()
const override;
116 Group *group()
override;
117 void checkGroup(
Group *gr =
nullptr,
bool force =
false);
118 void changeClientLeaderGroup(
Group *gr);
119 bool supportsWindowRules()
const override;
120 void updateWindowRules(Rules::Types selection)
override;
121 void applyWindowRules()
override;
122 void updateFullscreenMonitors(NETFullscreenMonitors topology);
124 bool hasNETSupport()
const;
126 QSizeF minSize()
const override;
127 QSizeF maxSize()
const override;
128 QSizeF basicUnit()
const;
134 bool windowEvent(xcb_generic_event_t *e);
135 NET::WindowType windowType()
const override;
137 bool track(xcb_window_t w);
138 bool manage(xcb_window_t w,
bool isMapped);
140 void releaseWindow(
bool on_shutdown =
false);
141 bool hasScheduledRelease()
const;
143 void destroyWindow()
override;
145 QStringList activities()
const override;
146 void doSetOnActivities(
const QStringList &newActivitiesList)
override;
147 void updateActivities(
bool includeTransients)
override;
149 bool isShadeable()
const override;
150 bool isMaximizable()
const override;
154 bool isMinimizable()
const override;
155 QRectF iconGeometry()
const override;
157 bool isFullScreenable()
const override;
158 void setFullScreen(
bool set)
override;
159 bool isFullScreen()
const override;
162 return m_fullscreenMode;
165 bool userNoBorder()
const;
166 bool noBorder()
const override;
167 void setNoBorder(
bool set)
override;
168 bool userCanSetNoBorder()
const override;
169 void checkNoBorder()
override;
170 void checkActivities()
override;
172 int sessionStackingOrder()
const;
175 bool wantsInput()
const override;
177 bool isResizable()
const override;
178 bool isMovable()
const override;
179 bool isMovableAcrossScreens()
const override;
180 bool isCloseable()
const override;
182 bool takeFocus()
override;
184 void invalidateDecoration()
override;
190 QRectF resizeWithChecks(
const QRectF &geometry,
const QSizeF &size)
override;
191 QRectF resizeWithChecks(
const QRectF &geometry, qreal w, qreal h, xcb_gravity_t gravity);
192 QRectF resizeWithChecks(
const QRectF &geometry,
const QSizeF &s, xcb_gravity_t gravity);
193 QSizeF constrainClientSize(
const QSizeF &size, SizeMode mode = SizeModeAny)
const override;
195 bool providesContextHelp()
const override;
198 void updateVisibility();
199 bool hiddenPreview()
const;
201 bool setupCompositing()
override;
202 void finishCompositing()
override;
203 void setBlockingCompositing(
bool block);
204 void blockCompositing();
205 void unblockCompositing();
216 using Window::keyPressEvent;
217 void keyPressEvent(uint key_code, xcb_timestamp_t time);
218 void updateMouseGrab()
override;
219 xcb_window_t moveResizeGrabWindow()
const;
221 QPointF gravityAdjustment(xcb_gravity_t gravity)
const;
222 const QPointF calculateGravitation(
bool invert)
const;
224 void NETMoveResize(qreal x_root, qreal y_root, NET::Direction direction, xcb_button_t button);
225 void NETMoveResizeWindow(
int flags, qreal x, qreal y, qreal width, qreal height);
226 void GTKShowWindowMenu(qreal x_root, qreal y_root);
227 void restackWindow(xcb_window_t above,
int detail, NET::RequestSource source, xcb_timestamp_t timestamp,
228 bool send_event =
false);
230 void gotPing(xcb_timestamp_t timestamp);
232 void updateUserTime(xcb_timestamp_t time = XCB_TIME_CURRENT_TIME);
233 xcb_timestamp_t userTime()
const override;
234 bool hasUserTimeSupport()
const;
239 static bool belongToSameApplication(
const X11Window *c1,
const X11Window *c2, SameApplicationChecks checks = SameApplicationChecks());
240 static bool sameAppWindowRoleMatch(
const X11Window *c1,
const X11Window *c2,
bool active_hack);
242 void killWindow()
override;
243 void showContextHelp()
override;
244 void checkActiveModal();
247 bool hasStrut()
const override;
249 bool isClientSideDecorated()
const;
253 QString preferredColorScheme()
const override;
256 void setSessionActivityOverride(
bool needed);
257 bool isClient()
const override;
258 bool isOutline()
const override;
259 bool isUnmanaged()
const override;
261 void cancelFocusOutTimer();
267 void showOnScreenEdge()
override;
271 void checkApplicationMenuServiceName();
275 void checkApplicationMenuObjectPath();
289 return m_syncRequest;
291 bool wantsSyncCounter()
const;
293 void handleSyncTimeout();
295 bool allowWindowActivation(xcb_timestamp_t time = -1U,
bool focus_in =
false);
297 static void cleanupX11();
299 quint64 surfaceSerial()
const;
300 quint32 pendingSurfaceId()
const;
303 void closeWindow()
override;
304 void updateCaption()
override;
308 bool mapRequestEvent(xcb_map_request_event_t *e);
309 void unmapNotifyEvent(xcb_unmap_notify_event_t *e);
310 void destroyNotifyEvent(xcb_destroy_notify_event_t *e);
311 void configureNotifyEvent(xcb_configure_notify_event_t *e);
312 void configureRequestEvent(xcb_configure_request_event_t *e);
313 void propertyNotifyEvent(xcb_property_notify_event_t *e);
314 void clientMessageEvent(xcb_client_message_event_t *e);
315 void enterNotifyEvent(xcb_enter_notify_event_t *e);
316 void leaveNotifyEvent(xcb_leave_notify_event_t *e);
317 void focusInEvent(xcb_focus_in_event_t *e);
318 void focusOutEvent(xcb_focus_out_event_t *e);
319 void damageNotifyEvent();
321 bool buttonPressEvent(xcb_window_t w,
int button,
int state,
int x,
int y,
int x_root,
int y_root, xcb_timestamp_t time = XCB_CURRENT_TIME);
322 bool buttonReleaseEvent(xcb_window_t w,
int button,
int state,
int x,
int y,
int x_root,
int y_root);
323 bool motionNotifyEvent(xcb_window_t w,
int state,
int x,
int y,
int x_root,
int y_root);
326 bool belongsToSameApplication(
const Window *other, SameApplicationChecks checks)
const override;
327 void doSetActive()
override;
328 void doSetKeepAbove()
override;
329 void doSetKeepBelow()
override;
330 void doSetShade(
ShadeMode previousShadeMode)
override;
331 void doSetDesktop()
override;
332 void doMinimize()
override;
333 void doSetSkipPager()
override;
334 void doSetSkipTaskbar()
override;
335 void doSetSkipSwitcher()
override;
336 void doSetDemandsAttention()
override;
337 void doSetHidden()
override;
338 void doSetHiddenByShowDesktop()
override;
339 bool belongsToDesktop()
const override;
340 bool doStartInteractiveMoveResize()
override;
341 bool isWaitingForInteractiveMoveResizeSync()
const override;
342 void doInteractiveResizeSync(
const QRectF &rect)
override;
343 QSizeF resizeIncrements()
const override;
344 bool acceptsFocus()
const override;
345 void moveResizeInternal(
const QRectF &rect, MoveResizeMode mode)
override;
346 std::unique_ptr<WindowItem> createItem(
Scene *scene)
override;
352 void exportMappingState(
int s);
353 bool isManaged()
const;
354 void updateAllowedActions(
bool force =
false);
355 QRect fullscreenMonitorsArea(NETFullscreenMonitors topology)
const;
356 void getResourceClass();
357 void getWmNormalHints();
358 void getWmClientMachine();
359 void getMotifHints();
361 void getWmOpaqueRegion();
362 void discardShapeRegion();
364 void fetchIconicName();
365 QString readName()
const;
366 void setCaption(
const QString &s,
bool force =
false);
367 bool hasTransientInternal(
const X11Window *c,
bool indirect, QList<const X11Window *> &set)
const;
368 void setShortcutInternal()
override;
371 void getWmClientLeader();
374 void getSkipCloseAnimation();
376 void configureRequest(
int value_mask, qreal rx, qreal ry, qreal rw, qreal rh,
int gravity,
bool from_tool);
377 NETExtendedStrut strut()
const;
378 int checkShadeGeometry(
int w,
int h);
379 void getSyncCounter();
380 void sendSyncRequest();
381 void leaveInteractiveMoveResize()
override;
382 void performInteractiveResize();
383 void establishCommandWindowGrab(uint8_t button);
384 void establishCommandAllGrab(uint8_t button);
385 void resizeDecoration();
388 void killProcess(
bool ask, xcb_timestamp_t timestamp = XCB_TIME_CURRENT_TIME);
389 void updateUrgency();
390 static void sendClientMessage(xcb_window_t w, xcb_atom_t a, xcb_atom_t protocol,
391 uint32_t data1 = 0, uint32_t data2 = 0, uint32_t data3 = 0);
393 void embedClient(xcb_window_t w, xcb_visualid_t visualid, xcb_colormap_t colormap, uint8_t depth);
394 void detectNoBorder();
395 void updateFrameExtents();
396 void setClientFrameExtents(
const NETStrut &strut);
403 void updateHiddenPreview();
405 void updateInputShape();
406 void updateServerGeometry();
407 void discardWindowPixmap();
408 void updateWindowPixmap();
410 xcb_timestamp_t readUserTimeMapTimestamp(
const KStartupInfoId *asn_id,
const KStartupInfoData *asn_data,
412 xcb_timestamp_t readUserCreationTime()
const;
413 void startupIdChanged();
415 void updateInputWindow();
423 void updateShowOnScreenEdge();
425 void maybeCreateX11DecorationRenderer();
426 void maybeDestroyX11DecorationRenderer();
427 void updateDecoration(
bool check_workspace_pos,
bool force =
false);
428 void createDecoration();
429 void destroyDecoration();
431 QWindow *findInternalWindow()
const;
434 void handleXwaylandScaleChanged();
439 xcb_window_t m_wmClientLeader = XCB_WINDOW_NONE;
440 int m_activityUpdatesBlocked;
441 bool m_blockedActivityUpdatesRequireTransients;
443 bool move_resize_has_keyboard_grab;
447 void sendSyntheticConfigureNotify();
454 MappingState mapping_state;
458 void readTransient();
459 xcb_window_t verifyTransientFor(xcb_window_t transient_for,
bool set);
460 void addTransient(
Window *cl)
override;
461 void removeFromMainClients();
462 void cleanGrouping();
463 void checkGroupTransients();
464 void setTransient(xcb_window_t new_transient_for_id);
466 NETWinInfo *info =
nullptr;
467 xcb_window_t m_transientForId;
468 xcb_window_t m_originalTransientForId;
472 uint app_noborder : 1;
473 uint ignore_focus_stealing : 1;
474 bool blocks_compositing;
475 bool is_shape =
false;
477 enum FullScreenMode {
482 MaximizeMode max_mode;
483 QString cap_normal, cap_iconic, cap_suffix;
486 std::unique_ptr<KillPrompt> m_killPrompt;
487 xcb_timestamp_t m_pingTimestamp;
488 xcb_timestamp_t m_userTime;
489 NET::Actions allowed_actions;
490 bool shade_geometry_change;
491 SyncRequest m_syncRequest;
492 static bool check_active_modal;
493 int sm_stacking_order;
494 xcb_visualid_t m_visual = XCB_NONE;
496 QRegion opaque_region;
497 mutable QList<QRectF> m_shapeRegion;
498 mutable bool m_shapeRegionIsValid =
false;
499 friend struct ResetupRulesProcedure;
505 bool activitiesDefined;
507 bool sessionActivityOverride;
510 QPointF input_offset;
512 QTimer *m_focusOutTimer;
513 QTimer m_releaseTimer;
515 QMetaObject::Connection m_edgeGeometryTrackingConnection;
517 QMarginsF m_clientFrameExtents;
518 Output *m_lastOutput =
nullptr;
519 QRectF m_lastBufferGeometry;
520 QRectF m_lastFrameGeometry;
521 QRectF m_lastClientGeometry;
522 std::unique_ptr<X11DecorationRenderer> m_decorationRenderer;
524 bool m_unmanaged =
false;
525 bool m_outline =
false;
526 quint32 m_pendingSurfaceId = 0;
527 quint64 m_surfaceSerial = 0;