Bug 387097 - Need ability to read client.maximizeMode since it's currently not a property
Summary: Need ability to read client.maximizeMode since it's currently not a property
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: scripting (other bugs)
Version First Reported In: 5.25.1
Platform: Other Linux
: NOR wishlist
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
: 392279 (view as bug list)
Depends on:
Blocks:
 
Reported: 2017-11-19 06:40 UTC by Chris Holland
Modified: 2025-07-03 20:11 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Holland 2017-11-19 06:40:00 UTC
I need to know if the client is maximized during workspace.clientAdded for my script. New Firefox windows can start maximized, which means my script isn't able to hide the titlebar until the user un-maximizes then maximizes (triggering client.clientMaximizedStateChanged).
Comment 1 Lionel Chauvin 2018-03-12 20:01:12 UTC
(In reply to Chris Holland from comment #0)
> I need to know if the client is maximized during workspace.clientAdded for
> my script. New Firefox windows can start maximized, which means my script
> isn't able to hide the titlebar until the user un-maximizes then maximizes
> (triggering client.clientMaximizedStateChanged).

Hi,

client.minimized is exposed but not client.maximized :D

As a workaround, did you try to check if the geometry is equal to the WorkArea ?
Comment 2 Martin Flöser 2018-03-24 19:31:20 UTC
*** Bug 392279 has been marked as a duplicate of this bug. ***
Comment 3 Piotr Dobrogost 2025-07-03 07:44:01 UTC
At matrix channel #plasma-dev:kde.org Devin Lin made a remark that it's already exposed and pointed to https://invent.kde.org/plasma/kwin/-/blob/master/src/window.h#L483

     * Whether the window is maximized horizontally, vertically or fully.
     * This is read only, in order to maximize from a script use
     * the setMaximize function
     * @see setMaximize
     */
    Q_PROPERTY(KWin::MaximizeMode maximizeMode READ maximizeMode NOTIFY maximizedChanged)

It looks like this issue is resolved and can be closed.
Comment 4 Piotr Dobrogost 2025-07-03 20:11:15 UTC
It seems this property is not documented at https://develop.kde.org/docs/plasma/kwin/api/