---
name: "XmToggleButtonGetState"
section: "3"
platform: "linux"
package: "openmotif"
version: "2.3.8-4"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/XmToggleButtonGetState"
---

# XmToggleButtonGetState(3)

A ToggleButton function that obtains the state of a ToggleButton

## NAME

**XmToggleButtonGetState** — A ToggleButton function that obtains the state of a ToggleButton

## SYNOPSIS

```
#include <Xm/ToggleB.h>
Boolean XmToggleButtonGetState(
Widget widget);
```

## DESCRIPTION

**XmToggleButtonGetState** obtains the state of a ToggleButton.

- *widget*

  Specifies the ToggleButton widget ID

For a complete definition of ToggleButton and its associated resources, see [**XmToggleButton**(3)](/XmToggleButton/3.md).

## RETURN

Returns True if the button is selected and False if the button is unselected.

## RELATED

[**XmToggleButton**(3)](/XmToggleButton/3.md).
