Mir
Loading...
Searching...
No Matches
zone.h
Go to the documentation of this file.
1/*
2 * Copyright © 2019 Canonical Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License version 2 or 3 as
6 * published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * Authored by: William Wold <william.wold@canonical.com>
17 */
18
19#ifndef MIRAL_ZONE_H
20#define MIRAL_ZONE_H
21
22#include <mir_toolkit/common.h>
23
25#include <mir/int_wrapper.h>
26
27#include <memory>
28
29namespace miral
30{
31using namespace mir::geometry;
32
35class Zone
36{
37public:
38
40 Zone(Zone const& other);
41 Zone& operator=(Zone const& other);
43
46 auto operator==(Zone const& other) const -> bool;
47
51 auto is_same_zone(Zone const& other) const -> bool;
52
54 auto extents() const -> Rectangle;
55
59
60private:
61 class Self;
62 std::unique_ptr<Self> self;
63};
64}
65
66#endif // MIRAL_ZONE_H
auto is_same_zone(Zone const &other) const -> bool
Multiple zone objects with different extents may be the "same" zone. For example, the arguments of mi...
auto extents() const -> Rectangle
The area of this zone in global display coordinates.
Zone & operator=(Zone const &other)
Copies private data by value.
Zone(Rectangle const &extents)
Create a new zone with the given extents.
Zone(Zone const &other)
Makes a copy of the underlying private data.
auto operator==(Zone const &other) const -> bool
Returns false if any properties are different (even if they are the same zone) Will always return fal...
Mir Abstraction Layer.
Definition floating_window_manager.h:29
STL namespace.
Definition rectangle.h:34

Copyright © 2012-2026 Canonical Ltd.
Generated on Sun Mar 15 06:10:58 UTC 2026
This documentation is licensed under the GPL version 2 or 3.