Odamex
Setting the Standard in Multiplayer Doom
textscreen/txt_window_action.h File Reference

Window action widget. More...

Go to the source code of this file.

Data Structures

struct  txt_window_action_s

Typedefs

typedef struct txt_window_action_s txt_window_action_t
 Window action widget.

Functions

txt_window_action_tTXT_NewWindowAction (int key, const char *label)
 Create a new window action.
txt_window_action_tTXT_NewWindowEscapeAction (txt_window_t *window)
 Create a new window action that closes the window when the escape key is pressed.
txt_window_action_tTXT_NewWindowAbortAction (txt_window_t *window)
 Create a new window action that closes the window when the escape key is pressed.
txt_window_action_tTXT_NewWindowSelectAction (txt_window_t *window)
 Create a new "select" window action.

Detailed Description

Window action widget.


Typedef Documentation

Window action widget.

A window action is attached to a window and corresponds to a keyboard shortcut that is active within that window. When the key is pressed, the action is triggered.

When a window action is triggered, the "pressed" signal is emitted.


Function Documentation

txt_window_action_t* TXT_NewWindowAbortAction ( txt_window_t window)

Create a new window action that closes the window when the escape key is pressed.

The label "Abort" is used.

Parameters:
windowThe window to close.
Returns:
Pointer to the new window action widget.
txt_window_action_t* TXT_NewWindowAction ( int  key,
const char *  label 
)

Create a new window action.

Parameters:
keyThe keyboard key that triggers this action.
labelLabel to display for this action in the tray at the bottom of the window.
Returns:
Pointer to the new window action widget.
txt_window_action_t* TXT_NewWindowEscapeAction ( txt_window_t window)

Create a new window action that closes the window when the escape key is pressed.

The label "Close" is used.

Parameters:
windowThe window to close.
Returns:
Pointer to the new window action widget.
txt_window_action_t* TXT_NewWindowSelectAction ( txt_window_t window)

Create a new "select" window action.

This does not really do anything, but reminds the user that "enter" can be pressed to activate the currently-selected widget.

Parameters:
windowThe window.
Returns:
Pointer to the new window action widget.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends