OpenTTD
Macros | Typedefs | Enumerations | Variables
zoom_type.h File Reference

Types related to zooming in and out. More...

#include "core/enum_type.hpp"

Go to the source code of this file.

Macros

#define ZOOM_LVL_GUI   (_gui_zoom)

Typedefs

typedef SimpleTinyEnumT
< ZoomLevel, byte > 
ZoomLevelByte
 Type for storing the zoom level in a byte.

Enumerations

enum  ZoomLevel {
  ZOOM_LVL_BEGIN = 0, ZOOM_LVL_NORMAL = 0, ZOOM_LVL_OUT_2X, ZOOM_LVL_OUT_4X,
  ZOOM_LVL_OUT_8X, ZOOM_LVL_OUT_16X, ZOOM_LVL_OUT_32X, ZOOM_LVL_END,
  ZOOM_LVL_COUNT = ZOOM_LVL_END - ZOOM_LVL_BEGIN, ZOOM_LVL_VIEWPORT = ZOOM_LVL_OUT_4X, ZOOM_LVL_NEWS = ZOOM_LVL_OUT_4X, ZOOM_LVL_INDUSTRY = ZOOM_LVL_OUT_8X,
  ZOOM_LVL_TOWN = ZOOM_LVL_OUT_8X, ZOOM_LVL_AIRCRAFT = ZOOM_LVL_OUT_4X, ZOOM_LVL_SHIP = ZOOM_LVL_OUT_4X, ZOOM_LVL_TRAIN = ZOOM_LVL_OUT_4X,
  ZOOM_LVL_ROADVEH = ZOOM_LVL_OUT_4X, ZOOM_LVL_WORLD_SCREENSHOT = ZOOM_LVL_OUT_4X, ZOOM_LVL_DETAIL = ZOOM_LVL_OUT_8X, ZOOM_LVL_MIN = ZOOM_LVL_NORMAL,
  ZOOM_LVL_MAX = ZOOM_LVL_OUT_32X
}
 All zoom levels we know. More...

Variables

static int const ZOOM_LVL_SHIFT = 2
static int const ZOOM_LVL_BASE = 1 << ZOOM_LVL_SHIFT
ZoomLevelByte _gui_zoom
 GUI Zoom level.

Detailed Description

Types related to zooming in and out.

Definition in file zoom_type.h.

Typedef Documentation

Type for storing the zoom level in a byte.

Definition at line 53 of file zoom_type.h.

Enumeration Type Documentation

enum ZoomLevel

All zoom levels we know.

Enumerator:
ZOOM_LVL_BEGIN 

Begin for iteration.

ZOOM_LVL_NORMAL 

The normal zoom level.

ZOOM_LVL_OUT_2X 

Zoomed 2 times out.

ZOOM_LVL_OUT_4X 

Zoomed 4 times out.

ZOOM_LVL_OUT_8X 

Zoomed 8 times out.

ZOOM_LVL_OUT_16X 

Zoomed 16 times out.

ZOOM_LVL_OUT_32X 

Zoomed 32 times out.

ZOOM_LVL_END 

End for iteration.

ZOOM_LVL_COUNT 

Number of zoom levels.

ZOOM_LVL_VIEWPORT 

Default zoom level for viewports.

ZOOM_LVL_NEWS 

Default zoom level for the news messages.

ZOOM_LVL_INDUSTRY 

Default zoom level for the industry view.

ZOOM_LVL_TOWN 

Default zoom level for the town view.

ZOOM_LVL_AIRCRAFT 

Default zoom level for the aircraft view.

ZOOM_LVL_SHIP 

Default zoom level for the ship view.

ZOOM_LVL_TRAIN 

Default zoom level for the train view.

ZOOM_LVL_ROADVEH 

Default zoom level for the road vehicle view.

ZOOM_LVL_WORLD_SCREENSHOT 

Default zoom level for the world screen shot.

ZOOM_LVL_DETAIL 

All zoomlevels below or equal to this, will result in details on the screen, like road-work, ...

ZOOM_LVL_MIN 

Minimum zoom level.

ZOOM_LVL_MAX 

Maximum zoom level.

Definition at line 21 of file zoom_type.h.