---
name: "CL_GRect"
section: "3"
platform: "linux"
package: "clanlib0-common-dev"
version: "0.4.4-8"
release: "Debian 3.0 (Woody)"
platforms: ["linux"]
url: "https://new.carta.tech/CL_GRect"
---

# CL\_GRect(3)

## NAME

CL\_GRect

## DESCRIPTION

/

## CLASS MEMBERS

- **CL\_GRect**()

  - **CL\_GRect**(

  ```
   int x,
  int y,
  int w,
  int h)
  ```

- **CL\_GRect**(

  ```
   const CL_GPoint& upperLeft,
  const CL_GPoint& lowerRight)
  ```

- virtual **~CL\_GRect**()

  - static CL\_GRect **invalid**

  - static CL\_GRect **empty**

  - bool **isEmpty**()

  - bool **isValid**()

  - bool **contains**(

  ```
   const CL_GRect &r )
  ```

- bool **contains**(

  ```
   const CL_GRect &r )
  ```

- virtual void **translate**(

  ```
   int dx,
  int dy )
  ```

- virtual void **warp**(

  ```
  const CL_GPoint &newUpperLeft)
  ```

- virtual void **resize**(

  ```
  int w,
  int h)
  ```

- CL\_GRect **unite**(

  ```
   const CL_GRect &r )
  ```

- CL\_GRect **intersect**(

  ```
   const CL_GRect &r)
  ```

- CL\_GPoint **upperLeft**()

  - CL\_GPoint **lowerRight**()

  - int **width**()

  - int **height**()

  ## MEMBERS WITH DESCRIPTIONS

- **CL\_GRect**()

  ```
  Description:
  ```

  /

- **CL\_GRect**(

  ```
   int x,
  int y,
  int w,
  int h)
  ```

  ```
  Description:
  ```

  /

- **CL\_GRect**(

  ```
   const CL_GPoint& upperLeft,
  const CL_GPoint& lowerRight)
  ```

  ```
  Description:
  ```

  /

- virtual **~CL\_GRect**()

  ```
  Description:
  ```

  /

- static CL\_GRect **invalid**

  ```
  Description:
  ```

  /

- static CL\_GRect **empty**

  ```
  Description:
  ```

  /

- bool **isEmpty**()

  ```
  Description:
  ```

  /

- bool **isValid**()

  ```
  Description:
  ```

  /

- bool **contains**(

  ```
   const CL_GRect &r )
  ```

  ```
  Description:
  ```

  / /move the rectangle by (dx, dy)

- bool **contains**(

  ```
   const CL_GRect &r )
  ```

  ```
  Description:
  ```

  / /move the rectangle by (dx, dy)

- virtual void **translate**(

  ```
   int dx,
  int dy )
  ```

  ```
  Description:
  ```

  /move the rectangle, specifying new upperleft corner

- virtual void **warp**(

  ```
  const CL_GPoint &newUpperLeft)
  ```

  ```
  Description:
  ```

  /this keeps the upper left corner and moves the lower right one

- virtual void **resize**(

  ```
  int w,
  int h)
  ```

  ```
  Description:
  ```

  /

- CL\_GRect **unite**(

  ```
   const CL_GRect &r )
  ```

  ```
  Description:
  ```

  /

- CL\_GRect **intersect**(

  ```
   const CL_GRect &r)
  ```

  ```
  Description:
  ```

  /

- CL\_GPoint **upperLeft**()

  ```
  Description:
  ```

  /

- CL\_GPoint **lowerRight**()

  ```
  Description:
  ```

  /

- int **width**()

  ```
  Description:
  ```

  /

- int **height**()

  ```
  Description:
  ```

  /

## SEE ALSO

All ClanLib API classes can be found in **clanlib (3)**.

## AUTHORS

Originally written by Magnus Norddahl \<*mbn@dark.x.dtu.dk*\> and Martin Starch \<*starch@dark.x.dtu.dk*\>. ClanLib is now developed by the ClanLib Development team as an Open Source project.

The ClanLib man pages was created using the Perceps documentation system (another excellent piece of Open Source software, available at **http://somewhere.in.the.world.org**).

See **clanlib (3)** to find out how to get a full list of contributors and details on how to submit bug reports, comments etc.
