World of Might and Magic  0.2.0
Open reimplementation of Might and Magic 6 7 8 game engine
Файл SDL_hints.h

См. исходные тексты.

Определения типов

typedef void(SDLCALL * SDL_HintCallback) (void *userdata, const char *name, const char *oldValue, const char *newValue)
 type definition of the hint callback function. Подробнее...
 

Перечисления

enum  SDL_HintPriority { SDL_HINT_DEFAULT, SDL_HINT_NORMAL, SDL_HINT_OVERRIDE }
 An enumeration of hint priorities. Подробнее...
 

Функции

DECLSPEC SDL_bool SDLCALL SDL_SetHintWithPriority (const char *name, const char *value, SDL_HintPriority priority)
 Set a hint with a specific priority. Подробнее...
 
DECLSPEC SDL_bool SDLCALL SDL_SetHint (const char *name, const char *value)
 Set a hint with normal priority. Подробнее...
 
const DECLSPEC char *SDLCALL SDL_GetHint (const char *name)
 Get a hint. Подробнее...
 
DECLSPEC SDL_bool SDLCALL SDL_GetHintBoolean (const char *name, SDL_bool default_value)
 Get a hint. Подробнее...
 
DECLSPEC void SDLCALL SDL_AddHintCallback (const char *name, SDL_HintCallback callback, void *userdata)
 Add a function to watch a particular hint. Подробнее...
 
DECLSPEC void SDLCALL SDL_DelHintCallback (const char *name, SDL_HintCallback callback, void *userdata)
 Remove a function watching a particular hint. Подробнее...
 
DECLSPEC void SDLCALL SDL_ClearHints (void)
 Clear all hints. Подробнее...
 

Подробное описание

Official documentation for SDL configuration variables

This file contains functions to set and get configuration hints, as well as listing each of them alphabetically.

The convention for naming hints is SDL_HINT_X, where "SDL_X" is the environment variable that can be used to override the default.

In general these hints are just that - they may or may not be supported or applicable on any given platform, but they provide a way for an application or user to give the library a hint as to how they would like the library to work.

См. определение в файле SDL_hints.h

Типы

◆ SDL_HintCallback

typedef void(SDLCALL * SDL_HintCallback) (void *userdata, const char *name, const char *oldValue, const char *newValue)

type definition of the hint callback function.

См. определение в файле SDL_hints.h строка 1324

Перечисления

◆ SDL_HintPriority

An enumeration of hint priorities.

Элементы перечислений
SDL_HINT_DEFAULT 
SDL_HINT_NORMAL 
SDL_HINT_OVERRIDE 

См. определение в файле SDL_hints.h строка 1278

1279 {

Функции

◆ SDL_SetHintWithPriority()

DECLSPEC SDL_bool SDLCALL SDL_SetHintWithPriority ( const char *  name,
const char *  value,
SDL_HintPriority  priority 
)

Set a hint with a specific priority.

The priority controls the behavior when setting a hint that already has a value. Hints will replace existing hints of their priority and lower. Environment variables are considered to have override priority.

Возвращает
SDL_TRUE if the hint was set, SDL_FALSE otherwise

◆ SDL_SetHint()

DECLSPEC SDL_bool SDLCALL SDL_SetHint ( const char *  name,
const char *  value 
)

Set a hint with normal priority.

Возвращает
SDL_TRUE if the hint was set, SDL_FALSE otherwise

◆ SDL_GetHint()

const DECLSPEC char* SDLCALL SDL_GetHint ( const char *  name)

Get a hint.

Возвращает
The string value of a hint variable.

◆ SDL_GetHintBoolean()

DECLSPEC SDL_bool SDLCALL SDL_GetHintBoolean ( const char *  name,
SDL_bool  default_value 
)

Get a hint.

Возвращает
The boolean value of a hint variable.

◆ SDL_AddHintCallback()

DECLSPEC void SDLCALL SDL_AddHintCallback ( const char *  name,
SDL_HintCallback  callback,
void userdata 
)

Add a function to watch a particular hint.

Аргументы
nameThe hint to watch
callbackThe function to call when the hint value changes
userdataA pointer to pass to the callback function

◆ SDL_DelHintCallback()

DECLSPEC void SDLCALL SDL_DelHintCallback ( const char *  name,
SDL_HintCallback  callback,
void userdata 
)

Remove a function watching a particular hint.

Аргументы
nameThe hint being watched
callbackThe function being called when the hint value changes
userdataA pointer being passed to the callback function

◆ SDL_ClearHints()

DECLSPEC void SDLCALL SDL_ClearHints ( void  )

Clear all hints.

This function is called during SDL_Quit() to free stored hints.

SDL_HintPriority
SDL_HintPriority
An enumeration of hint priorities.
Definition: SDL_hints.h:1278
SDL_HINT_DEFAULT
@ SDL_HINT_DEFAULT
Definition: SDL_hints.h:1280
SDL_HINT_OVERRIDE
@ SDL_HINT_OVERRIDE
Definition: SDL_hints.h:1282
SDL_HINT_NORMAL
@ SDL_HINT_NORMAL
Definition: SDL_hints.h:1281