OpenTTD Source: OptionData Struct Reference

OpenTTD Source 15.3

Data Fields
OptionData Struct Reference

Data of an option. More...

`#include <getoptdata.h>`

## Data Fields
OptionDataType | type
| The type of option.
char | id
| Unique identification of this option data, often the same as shortname.
char | shortname = '\0'
| Short option letter if available, else use `'\0'`.
std::string_view | longname {}
| Long option name including '-'/'–' prefix, leave empty if not available.

## Detailed Description

Data of an option.

Definition at line 21 of file getoptdata.h.

## Field Documentation

## ◆ id

char OptionData::id

Unique identification of this option data, often the same as shortname.

Definition at line 23 of file getoptdata.h.

## ◆ longname

std::string_view OptionData::longname {}

Long option name including '-'/'–' prefix, leave empty if not available.

Definition at line 25 of file getoptdata.h.

## ◆ shortname

char OptionData::shortname = '\0'

Short option letter if available, else use `'\0'`.

Definition at line 24 of file getoptdata.h.

## ◆ type

OptionDataType OptionData::type

The type of option.

Definition at line 22 of file getoptdata.h.

The documentation for this struct was generated from the following file:

- src/misc/getoptdata.h