Blender  V3.3
Functions | Variables
#include <stdlib.h>
#include "DNA_screen_types.h"
#include "DNA_space_types.h"
#include "DNA_userdef_types.h"
#include "DNA_windowmanager_types.h"
#include "BLI_utildefines.h"
#include "BLT_translation.h"
#include "BKE_keyconfig.h"
#include "BKE_workspace.h"
#include "RNA_access.h"
#include "RNA_define.h"
#include "RNA_enum_types.h"
#include "rna_internal.h"
#include "WM_api.h"
#include "WM_types.h"

Go to the source code of this file.

Functions

static void rna_def_operator_options_runtime (BlenderRNA *brna)
 
static void rna_def_operator_common (StructRNA *srna)
 
static void rna_def_operator (BlenderRNA *brna)
 
static void rna_def_macro_operator (BlenderRNA *brna)
 
static void rna_def_operator_type_macro (BlenderRNA *brna)
 
static void rna_def_operator_utils (BlenderRNA *brna)
 
static void rna_def_operator_filelist_element (BlenderRNA *brna)
 
static void rna_def_event (BlenderRNA *brna)
 
static void rna_def_timer (BlenderRNA *brna)
 
static void rna_def_popup_menu_wrapper (BlenderRNA *brna, const char *rna_type, const char *c_type, const char *layout_get_fn)
 
static void rna_def_popupmenu (BlenderRNA *brna)
 
static void rna_def_popovermenu (BlenderRNA *brna)
 
static void rna_def_piemenu (BlenderRNA *brna)
 
static void rna_def_window_stereo3d (BlenderRNA *brna)
 
static void rna_def_window (BlenderRNA *brna)
 
static void rna_def_wm_keyconfigs (BlenderRNA *brna, PropertyRNA *cprop)
 
static void rna_def_windowmanager (BlenderRNA *brna)
 
static void rna_def_keymap_items (BlenderRNA *brna, PropertyRNA *cprop)
 
static void rna_def_wm_keymaps (BlenderRNA *brna, PropertyRNA *cprop)
 
static void rna_def_keyconfig_prefs (BlenderRNA *brna)
 
static void rna_def_keyconfig (BlenderRNA *brna)
 
void RNA_def_wm (BlenderRNA *brna)
 

Variables

const EnumPropertyItem rna_enum_wm_job_type_items []
 
const EnumPropertyItem rna_enum_event_type_items []
 
const EnumPropertyItem rna_enum_event_value_items []
 
const EnumPropertyItem rna_enum_event_direction_items []
 
const EnumPropertyItem rna_enum_keymap_propvalue_items []
 
const EnumPropertyItem rna_enum_event_type_mask_items []
 
const EnumPropertyItem rna_enum_operator_type_flag_items []
 
const EnumPropertyItem rna_enum_operator_return_items []
 
const EnumPropertyItem rna_enum_operator_property_tags []
 
const EnumPropertyItem rna_enum_wm_report_items []
 

Function Documentation

◆ rna_def_event()

static void rna_def_event ( BlenderRNA brna)
static

◆ rna_def_keyconfig()

static void rna_def_keyconfig ( BlenderRNA brna)
static

Definition at line 2537 of file rna_wm.c.

References BLT_I18NCONTEXT_ID_WINDOWMANAGER, BLT_I18NCONTEXT_UI_EVENTS, KEYCONF_USER, KEYMAP_CHILDREN_EXPANDED, KEYMAP_EXPANDED, KEYMAP_MODAL, KEYMAP_USER_MODIFIED, KM_ANY, KM_MOD_HELD, KMI_EXPANDED, KMI_INACTIVE, KMI_REPEAT_IGNORE, KMI_TYPE_KEYBOARD, KMI_TYPE_MOUSE, KMI_TYPE_NDOF, KMI_TYPE_TEXTINPUT, KMI_TYPE_TIMER, KMI_USER_MODIFIED, NULL, PROP_BOOLEAN, PROP_COLLECTION, PROP_EDITABLE, PROP_ENUM, PROP_INT, PROP_NO_DEG_UPDATE, PROP_NONE, PROP_POINTER, PROP_STRING, PROP_STRING_SEARCH_SORT, PROP_STRING_SEARCH_SUGGESTION, RNA_api_keyconfig(), RNA_api_keymap(), RNA_api_keymapitem(), rna_def_keymap_items(), RNA_def_property(), RNA_def_property_boolean_funcs(), RNA_def_property_boolean_negative_sdna(), RNA_def_property_boolean_sdna(), RNA_def_property_clear_flag(), RNA_def_property_collection_funcs(), RNA_def_property_collection_sdna(), RNA_def_property_enum_funcs(), RNA_def_property_enum_items(), RNA_def_property_enum_sdna(), RNA_def_property_flag(), RNA_def_property_int_sdna(), RNA_def_property_pointer_funcs(), RNA_def_property_range(), RNA_def_property_string_funcs(), RNA_def_property_string_sdna(), RNA_def_property_string_search_func(), RNA_def_property_struct_type(), RNA_def_property_translation_context(), RNA_def_property_ui_icon(), RNA_def_property_ui_text(), RNA_def_property_update(), RNA_def_struct(), RNA_def_struct_name_property(), RNA_def_struct_sdna(), RNA_def_struct_ui_text(), rna_def_wm_keymaps(), rna_enum_event_direction_items, rna_enum_event_type_items, rna_enum_event_value_items, rna_enum_keymap_propvalue_items, rna_enum_region_type_items, and rna_enum_space_type_items.

Referenced by RNA_def_wm().

◆ rna_def_keyconfig_prefs()

static void rna_def_keyconfig_prefs ( BlenderRNA brna)
static

◆ rna_def_keymap_items()

static void rna_def_keymap_items ( BlenderRNA brna,
PropertyRNA cprop 
)
static

◆ rna_def_macro_operator()

static void rna_def_macro_operator ( BlenderRNA brna)
static

◆ rna_def_operator()

static void rna_def_operator ( BlenderRNA brna)
static

◆ rna_def_operator_common()

static void rna_def_operator_common ( StructRNA srna)
static

◆ rna_def_operator_filelist_element()

static void rna_def_operator_filelist_element ( BlenderRNA brna)
static

◆ rna_def_operator_options_runtime()

static void rna_def_operator_options_runtime ( BlenderRNA brna)
static

◆ rna_def_operator_type_macro()

static void rna_def_operator_type_macro ( BlenderRNA brna)
static

◆ rna_def_operator_utils()

static void rna_def_operator_utils ( BlenderRNA brna)
static

◆ rna_def_piemenu()

static void rna_def_piemenu ( BlenderRNA brna)
static

Definition at line 2286 of file rna_wm.c.

References rna_def_popup_menu_wrapper().

Referenced by RNA_def_wm().

◆ rna_def_popovermenu()

static void rna_def_popovermenu ( BlenderRNA brna)
static

Definition at line 2281 of file rna_wm.c.

References rna_def_popup_menu_wrapper().

Referenced by RNA_def_wm().

◆ rna_def_popup_menu_wrapper()

static void rna_def_popup_menu_wrapper ( BlenderRNA brna,
const char *  rna_type,
const char *  c_type,
const char *  layout_get_fn 
)
static

◆ rna_def_popupmenu()

static void rna_def_popupmenu ( BlenderRNA brna)
static

Definition at line 2276 of file rna_wm.c.

References rna_def_popup_menu_wrapper().

Referenced by RNA_def_wm().

◆ rna_def_timer()

static void rna_def_timer ( BlenderRNA brna)
static

◆ rna_def_window()

static void rna_def_window ( BlenderRNA brna)
static

◆ rna_def_window_stereo3d()

static void rna_def_window_stereo3d ( BlenderRNA brna)
static

◆ rna_def_windowmanager()

static void rna_def_windowmanager ( BlenderRNA brna)
static

◆ RNA_def_wm()

void RNA_def_wm ( BlenderRNA brna)

◆ rna_def_wm_keyconfigs()

static void rna_def_wm_keyconfigs ( BlenderRNA brna,
PropertyRNA cprop 
)
static

◆ rna_def_wm_keymaps()

static void rna_def_wm_keymaps ( BlenderRNA brna,
PropertyRNA cprop 
)
static

Variable Documentation

◆ rna_enum_event_direction_items

const EnumPropertyItem rna_enum_event_direction_items[]
Initial value:
= {
{KM_ANY, "ANY", 0, "Any", ""},
{KM_DIRECTION_N, "NORTH", 0, "North", ""},
{KM_DIRECTION_NE, "NORTH_EAST", 0, "North-East", ""},
{KM_DIRECTION_E, "EAST", 0, "East", ""},
{KM_DIRECTION_SE, "SOUTH_EAST", 0, "South-East", ""},
{KM_DIRECTION_S, "SOUTH", 0, "South", ""},
{KM_DIRECTION_SW, "SOUTH_WEST", 0, "South-West", ""},
{KM_DIRECTION_W, "WEST", 0, "West", ""},
{KM_DIRECTION_NW, "NORTH_WEST", 0, "North-West", ""},
{0, NULL, 0, NULL, NULL},
}
@ KM_ANY
Definition: WM_types.h:265
@ KM_DIRECTION_NW
Definition: WM_types.h:291
@ KM_DIRECTION_N
Definition: WM_types.h:284
@ KM_DIRECTION_SW
Definition: WM_types.h:289
@ KM_DIRECTION_NE
Definition: WM_types.h:285
@ KM_DIRECTION_E
Definition: WM_types.h:286
@ KM_DIRECTION_W
Definition: WM_types.h:290
@ KM_DIRECTION_SE
Definition: WM_types.h:287
@ KM_DIRECTION_S
Definition: WM_types.h:288

Definition at line 389 of file rna_wm.c.

Referenced by RNA_api_keymapitems(), rna_def_event(), and rna_def_keyconfig().

◆ rna_enum_event_type_items

const EnumPropertyItem rna_enum_event_type_items[]

◆ rna_enum_event_type_mask_items

const EnumPropertyItem rna_enum_event_type_mask_items[]
Initial value:
= {
{EVT_TYPE_MASK_KEYBOARD_MODIFIER, "KEYBOARD_MODIFIER", 0, "Keyboard Modifier", ""},
{EVT_TYPE_MASK_KEYBOARD, "KEYBOARD", 0, "Keyboard", ""},
{EVT_TYPE_MASK_MOUSE_WHEEL, "MOUSE_WHEEL", 0, "Mouse Wheel", ""},
{EVT_TYPE_MASK_MOUSE_GESTURE, "MOUSE_GESTURE", 0, "Mouse Gesture", ""},
{EVT_TYPE_MASK_MOUSE_BUTTON, "MOUSE_BUTTON", 0, "Mouse Button", ""},
{EVT_TYPE_MASK_MOUSE, "MOUSE", 0, "Mouse", ""},
{EVT_TYPE_MASK_NDOF, "NDOF", 0, "NDOF", ""},
{EVT_TYPE_MASK_ACTIONZONE, "ACTIONZONE", 0, "Action Zone", ""},
{0, NULL, 0, NULL, NULL},
}
@ EVT_TYPE_MASK_ACTIONZONE
@ EVT_TYPE_MASK_KEYBOARD_MODIFIER
@ EVT_TYPE_MASK_NDOF
@ EVT_TYPE_MASK_MOUSE_WHEEL
@ EVT_TYPE_MASK_MOUSE_GESTURE
@ EVT_TYPE_MASK_MOUSE_BUTTON
@ EVT_TYPE_MASK_MOUSE
@ EVT_TYPE_MASK_KEYBOARD

Definition at line 408 of file rna_wm.c.

Referenced by RNA_api_keyconfigs(), and RNA_api_keymapitems().

◆ rna_enum_event_value_items

const EnumPropertyItem rna_enum_event_value_items[]
Initial value:
= {
{KM_ANY, "ANY", 0, "Any", ""},
{KM_PRESS, "PRESS", 0, "Press", ""},
{KM_RELEASE, "RELEASE", 0, "Release", ""},
{KM_CLICK, "CLICK", 0, "Click", ""},
{KM_DBL_CLICK, "DOUBLE_CLICK", 0, "Double Click", ""},
{KM_CLICK_DRAG, "CLICK_DRAG", 0, "Click Drag", ""},
{KM_NOTHING, "NOTHING", 0, "Nothing", ""},
{0, NULL, 0, NULL, NULL},
}
@ KM_NOTHING
Definition: WM_types.h:266
@ KM_PRESS
Definition: WM_types.h:267
@ KM_CLICK_DRAG
Definition: WM_types.h:275
@ KM_DBL_CLICK
Definition: WM_types.h:270
@ KM_RELEASE
Definition: WM_types.h:268
@ KM_CLICK
Definition: WM_types.h:269
Note
This contains overlapping items from:
  • #rna_enum_event_value_keymouse_items
  • #rna_enum_event_value_tweak_items

This is needed for km.keymap_items.new value argument, to accept values from different types.

Definition at line 377 of file rna_wm.c.

Referenced by event_ids_from_type_and_value(), RNA_api_keymapitems(), RNA_api_window(), rna_def_event(), and rna_def_keyconfig().

◆ rna_enum_keymap_propvalue_items

const EnumPropertyItem rna_enum_keymap_propvalue_items[]
Initial value:
= {
{0, "NONE", 0, "", ""},
{0, NULL, 0, NULL, NULL},
}

Definition at line 402 of file rna_wm.c.

Referenced by rna_def_keyconfig().

◆ rna_enum_operator_property_tags

const EnumPropertyItem rna_enum_operator_property_tags[]
Initial value:
= {
"ADVANCED",
0,
"Advanced",
"The property is advanced so UI is suggested to hide it"},
{0, NULL, 0, NULL, NULL},
}
@ OP_PROP_TAG_ADVANCED
Definition: WM_types.h:224

Definition at line 485 of file rna_wm.c.

Referenced by rna_def_operator(), and wm_operatortype_append__begin().

◆ rna_enum_operator_return_items

const EnumPropertyItem rna_enum_operator_return_items[]
Initial value:
= {
"RUNNING_MODAL",
0,
"Running Modal",
"Keep the operator running with blender"},
"CANCELLED",
0,
"Cancelled",
"The operator exited without doing anything, so no undo entry should be pushed"},
"FINISHED",
0,
"Finished",
"The operator exited after completing its action"},
{OPERATOR_PASS_THROUGH, "PASS_THROUGH", 0, "Pass Through", "Do nothing and pass the event on"},
{OPERATOR_INTERFACE, "INTERFACE", 0, "Interface", "Handled but not executed (popup menus)"},
{0, NULL, 0, NULL, NULL},
}
@ OPERATOR_CANCELLED
@ OPERATOR_INTERFACE
@ OPERATOR_FINISHED
@ OPERATOR_RUNNING_MODAL
@ OPERATOR_PASS_THROUGH

Definition at line 463 of file rna_wm.c.

Referenced by pyop_call(), RNA_api_operator(), rna_def_gizmo(), and rna_generic_op_invoke().

◆ rna_enum_operator_type_flag_items

const EnumPropertyItem rna_enum_operator_type_flag_items[]

Definition at line 429 of file rna_wm.c.

Referenced by rna_def_operator_common().

◆ rna_enum_wm_job_type_items

const EnumPropertyItem rna_enum_wm_job_type_items[]
Initial value:
= {
{WM_JOB_TYPE_RENDER, "RENDER", 0, "Regular rendering", ""},
{WM_JOB_TYPE_RENDER_PREVIEW, "RENDER_PREVIEW", 0, "Rendering previews", ""},
{WM_JOB_TYPE_OBJECT_BAKE, "OBJECT_BAKE", 0, "Object Baking", ""},
{WM_JOB_TYPE_COMPOSITE, "COMPOSITE", 0, "Compositing", ""},
{WM_JOB_TYPE_SHADER_COMPILATION, "SHADER_COMPILATION", 0, "Shader compilation", ""},
{0, NULL, 0, NULL, NULL},
}
@ WM_JOB_TYPE_COMPOSITE
Definition: WM_api.h:1348
@ WM_JOB_TYPE_OBJECT_BAKE
Definition: WM_api.h:1356
@ WM_JOB_TYPE_RENDER_PREVIEW
Definition: WM_api.h:1350
@ WM_JOB_TYPE_RENDER
Definition: WM_api.h:1349
@ WM_JOB_TYPE_SHADER_COMPILATION
Definition: WM_api.h:1367

Job types for use in the bpy.app.is_job_running(job_type) call.

This is a subset of the WM_JOB_TYPE_... anonymous enum defined in WM_api.h. It is intentionally kept as a subset, such that by default how jobs are handled is kept as an "internal implementation detail" of Blender, rather than a public, reliable part of the API.

This array can be expanded on a case-by-case basis, when there is a clear and testable use case.

Definition at line 136 of file rna_wm.c.

Referenced by bpy_app_is_job_running().

◆ rna_enum_wm_report_items

const EnumPropertyItem rna_enum_wm_report_items[]
Initial value:
= {
{RPT_DEBUG, "DEBUG", 0, "Debug", ""},
{RPT_INFO, "INFO", 0, "Info", ""},
{RPT_OPERATOR, "OPERATOR", 0, "Operator", ""},
{RPT_PROPERTY, "PROPERTY", 0, "Property", ""},
{RPT_WARNING, "WARNING", 0, "Warning", ""},
{RPT_ERROR, "ERROR", 0, "Error", ""},
{RPT_ERROR_INVALID_INPUT, "ERROR_INVALID_INPUT", 0, "Invalid Input", ""},
{RPT_ERROR_INVALID_CONTEXT, "ERROR_INVALID_CONTEXT", 0, "Invalid Context", ""},
{RPT_ERROR_OUT_OF_MEMORY, "ERROR_OUT_OF_MEMORY", 0, "Out of Memory", ""},
{0, NULL, 0, NULL, NULL},
}
@ RPT_ERROR_OUT_OF_MEMORY
@ RPT_ERROR_INVALID_INPUT
@ RPT_ERROR_INVALID_CONTEXT

Definition at line 495 of file rna_wm.c.

Referenced by RNA_api_macro(), RNA_api_operator(), and rna_def_render_engine().