diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-09-15 17:20:18 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-09-15 17:20:18 +0400 |
commit | 0eda51f2eabe24016efdc8f07825f1ba667cac33 (patch) | |
tree | 03d6f876da6b1256b8890b89db09b63952fa544f /source/blender/editors | |
parent | 30293dc2ca8052ad0c7113c77365feca590f4d05 (diff) |
Fixing issues with i18n stuff:
- Make gettext stuff draw-time. so switching between languages
can happens without restart now.
- Added option to translate visible interface (menus, buttons, labels)
and tooltips. Now it's possible to have english UI and localized tooltips.
- Clean-up sources, do not use gettext stuff for things which can be
collected with RNA.
- Fix issues with windows 64bit and ru_RU locale on my desktop
(it was codepage issue).
- Added operator "Get Messages" which generates new text block with
with all strings collected from RNA.
- Changed script for updating blender.pot so now it appends
messages collected from rna to automatically gathered messages.
To update .pot you have to re-generate messages.txt using "Get Messages"
operator and then run update_pot script.
- Clean up old translation stuff which wasn't used and most probably
wouldn't be used.
- Return back "International Fonts" option, so if it's disabled, no
gettext lookups happens on draw.
- Merged read_homefile function back. No need in splitting it.
TODO:
- Custom fonts and font size.
Current font isn't nice at least for russian locale, it's
difficult to read it.
- Put references to messages.txt so gettext can merge translation when
name/description of some property changes.
Diffstat (limited to 'source/blender/editors')
138 files changed, 2896 insertions, 3103 deletions
diff --git a/source/blender/editors/animation/CMakeLists.txt b/source/blender/editors/animation/CMakeLists.txt index 6195289f2a6..83fe91d6f76 100644 --- a/source/blender/editors/animation/CMakeLists.txt +++ b/source/blender/editors/animation/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/animation/SConscript b/source/blender/editors/animation/SConscript index 61cf0890bc7..96b05b8bccc 100644 --- a/source/blender/editors/animation/SConscript +++ b/source/blender/editors/animation/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include ../../blenloader' env.BlenderLib ( 'bf_editors_animation', sources, Split(incs), [], libtype=['core'], priority=[125] ) diff --git a/source/blender/editors/animation/anim_channels_edit.c b/source/blender/editors/animation/anim_channels_edit.c index f2311dc5536..d58d51c8e08 100644 --- a/source/blender/editors/animation/anim_channels_edit.c +++ b/source/blender/editors/animation/anim_channels_edit.c @@ -38,8 +38,6 @@ #include "BLI_utildefines.h" #include "BKE_library.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" @@ -611,10 +609,10 @@ enum { /* defines for rearranging channels */ static EnumPropertyItem prop_animchannel_rearrange_types[] = { - {REARRANGE_ANIMCHAN_TOP, "TOP", 0, N_("To Top"), ""}, - {REARRANGE_ANIMCHAN_UP, "UP", 0, N_("Up"), ""}, - {REARRANGE_ANIMCHAN_DOWN, "DOWN", 0, N_("Down"), ""}, - {REARRANGE_ANIMCHAN_BOTTOM, "BOTTOM", 0, N_("To Bottom"), ""}, + {REARRANGE_ANIMCHAN_TOP, "TOP", 0, "To Top", ""}, + {REARRANGE_ANIMCHAN_UP, "UP", 0, "Up", ""}, + {REARRANGE_ANIMCHAN_DOWN, "DOWN", 0, "Down", ""}, + {REARRANGE_ANIMCHAN_BOTTOM, "BOTTOM", 0, "To Bottom", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1107,9 +1105,9 @@ static int animchannels_rearrange_exec(bContext *C, wmOperator *op) static void ANIM_OT_channels_move (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Channels"); + ot->name= "Move Channels"; ot->idname= "ANIM_OT_channels_move"; - ot->description = _("Rearrange selected animation channels"); + ot->description = "Rearrange selected animation channels"; /* api callbacks */ ot->exec= animchannels_rearrange_exec; @@ -1119,7 +1117,7 @@ static void ANIM_OT_channels_move (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(prop_animchannel_rearrange_types), REARRANGE_ANIMCHAN_DOWN, _("Direction"), ""); + ot->prop= RNA_def_enum(ot->srna, "direction", prop_animchannel_rearrange_types, REARRANGE_ANIMCHAN_DOWN, "Direction", ""); } /* ******************** Delete Channel Operator *********************** */ @@ -1223,9 +1221,9 @@ static int animchannels_delete_exec(bContext *C, wmOperator *UNUSED(op)) static void ANIM_OT_channels_delete (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Channels"); + ot->name= "Delete Channels"; ot->idname= "ANIM_OT_channels_delete"; - ot->description= _("Delete all selected animation channels"); + ot->description= "Delete all selected animation channels"; /* api callbacks */ ot->exec= animchannels_delete_exec; @@ -1315,9 +1313,9 @@ static int animchannels_visibility_set_exec(bContext *C, wmOperator *UNUSED(op)) static void ANIM_OT_channels_visibility_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Visibility"); + ot->name= "Set Visibility"; ot->idname= "ANIM_OT_channels_visibility_set"; - ot->description= _("Make only the selected animation channels visible in the Graph Editor"); + ot->description= "Make only the selected animation channels visible in the Graph Editor"; /* api callbacks */ ot->exec= animchannels_visibility_set_exec; @@ -1392,9 +1390,9 @@ static int animchannels_visibility_toggle_exec(bContext *C, wmOperator *UNUSED(o static void ANIM_OT_channels_visibility_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Visibility"); + ot->name= "Toggle Visibility"; ot->idname= "ANIM_OT_channels_visibility_toggle"; - ot->description= _("Toggle visibility in Graph Editor of all selected animation channels"); + ot->description= "Toggle visibility in Graph Editor of all selected animation channels"; /* api callbacks */ ot->exec= animchannels_visibility_toggle_exec; @@ -1408,18 +1406,18 @@ static void ANIM_OT_channels_visibility_toggle (wmOperatorType *ot) /* defines for setting animation-channel flags */ static EnumPropertyItem prop_animchannel_setflag_types[] = { - {ACHANNEL_SETFLAG_TOGGLE, "TOGGLE", 0, N_("Toggle"), ""}, - {ACHANNEL_SETFLAG_CLEAR, "DISABLE", 0, N_("Disable"), ""}, - {ACHANNEL_SETFLAG_ADD, "ENABLE", 0, N_("Enable"), ""}, - {ACHANNEL_SETFLAG_INVERT, "INVERT", 0, N_("Invert"), ""}, + {ACHANNEL_SETFLAG_TOGGLE, "TOGGLE", 0, "Toggle", ""}, + {ACHANNEL_SETFLAG_CLEAR, "DISABLE", 0, "Disable", ""}, + {ACHANNEL_SETFLAG_ADD, "ENABLE", 0, "Enable", ""}, + {ACHANNEL_SETFLAG_INVERT, "INVERT", 0, "Invert", ""}, {0, NULL, 0, NULL, NULL} }; /* defines for set animation-channel settings */ // TODO: could add some more types, but those are really quite dependent on the mode... static EnumPropertyItem prop_animchannel_settings_types[] = { - {ACHANNEL_SETTING_PROTECT, "PROTECT", 0, N_("Protect"), ""}, - {ACHANNEL_SETTING_MUTE, "MUTE", 0, N_("Mute"), ""}, + {ACHANNEL_SETTING_PROTECT, "PROTECT", 0, "Protect", ""}, + {ACHANNEL_SETTING_MUTE, "MUTE", 0, "Mute", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1535,9 +1533,9 @@ static int animchannels_setflag_exec(bContext *C, wmOperator *op) static void ANIM_OT_channels_setting_enable (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Enable Channel Setting"); + ot->name= "Enable Channel Setting"; ot->idname= "ANIM_OT_channels_setting_enable"; - ot->description= _("Enable specified setting on all selected animation channels"); + ot->description= "Enable specified setting on all selected animation channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1549,17 +1547,17 @@ static void ANIM_OT_channels_setting_enable (wmOperatorType *ot) /* props */ /* flag-setting mode */ - RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_animchannel_setflag_types), ACHANNEL_SETFLAG_ADD, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_ADD, "Mode", ""); /* setting to set */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_animchannel_settings_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } static void ANIM_OT_channels_setting_disable (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Disable Channel Setting"); + ot->name= "Disable Channel Setting"; ot->idname= "ANIM_OT_channels_setting_disable"; - ot->description= _("Disable specified setting on all selected animation channels"); + ot->description= "Disable specified setting on all selected animation channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1571,17 +1569,17 @@ static void ANIM_OT_channels_setting_disable (wmOperatorType *ot) /* props */ /* flag-setting mode */ - RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_CLEAR, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_CLEAR, "Mode", ""); /* setting to set */ - ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } static void ANIM_OT_channels_setting_invert (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Invert Channel Setting"); + ot->name= "Invert Channel Setting"; ot->idname= "ANIM_OT_channels_setting_toggle"; - ot->description= _("Invert specified setting on all selected animation channels"); + ot->description= "Invert specified setting on all selected animation channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1593,17 +1591,17 @@ static void ANIM_OT_channels_setting_invert (wmOperatorType *ot) /* props */ /* flag-setting mode */ - RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_INVERT, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_INVERT, "Mode", ""); /* setting to set */ - ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } static void ANIM_OT_channels_setting_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Channel Setting"); + ot->name= "Toggle Channel Setting"; ot->idname= "ANIM_OT_channels_setting_toggle"; - ot->description= _("Toggle specified setting on all selected animation channels"); + ot->description= "Toggle specified setting on all selected animation channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1615,17 +1613,17 @@ static void ANIM_OT_channels_setting_toggle (wmOperatorType *ot) /* props */ /* flag-setting mode */ - RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_TOGGLE, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_TOGGLE, "Mode", ""); /* setting to set */ - ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } static void ANIM_OT_channels_editable_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Channel Editability"); + ot->name= "Toggle Channel Editability"; ot->idname= "ANIM_OT_channels_editable_toggle"; - ot->description= _("Toggle editability of selected channels"); + ot->description= "Toggle editability of selected channels"; /* api callbacks */ ot->exec= animchannels_setflag_exec; @@ -1636,9 +1634,9 @@ static void ANIM_OT_channels_editable_toggle (wmOperatorType *ot) /* props */ /* flag-setting mode */ - RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_TOGGLE, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", prop_animchannel_setflag_types, ACHANNEL_SETFLAG_TOGGLE, "Mode", ""); /* setting to set */ - RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, ACHANNEL_SETTING_PROTECT, _("Type"), ""); + RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, ACHANNEL_SETTING_PROTECT, "Type", ""); } /* ********************** Expand Channels Operator *********************** */ @@ -1668,9 +1666,9 @@ static int animchannels_expand_exec (bContext *C, wmOperator *op) static void ANIM_OT_channels_expand (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Expand Channels"); + ot->name= "Expand Channels"; ot->idname= "ANIM_OT_channels_expand"; - ot->description= _("Expand (i.e. open) all selected expandable animation channels"); + ot->description= "Expand (i.e. open) all selected expandable animation channels"; /* api callbacks */ ot->exec= animchannels_expand_exec; @@ -1680,7 +1678,7 @@ static void ANIM_OT_channels_expand (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Expand all channels (not just selected ones)")); + ot->prop= RNA_def_boolean(ot->srna, "all", 1, "All", "Expand all channels (not just selected ones)"); } /* ********************** Collapse Channels Operator *********************** */ @@ -1710,9 +1708,9 @@ static int animchannels_collapse_exec (bContext *C, wmOperator *op) static void ANIM_OT_channels_collapse (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Collapse Channels"); + ot->name= "Collapse Channels"; ot->idname= "ANIM_OT_channels_collapse"; - ot->description= _("Collapse (i.e. close) all selected expandable animation channels"); + ot->description= "Collapse (i.e. close) all selected expandable animation channels"; /* api callbacks */ ot->exec= animchannels_collapse_exec; @@ -1722,7 +1720,7 @@ static void ANIM_OT_channels_collapse (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Collapse all channels (not just selected ones)")); + ot->prop= RNA_def_boolean(ot->srna, "all", 1, "All", "Collapse all channels (not just selected ones)"); } /* ******************* Reenable Disabled Operator ******************* */ @@ -1786,9 +1784,9 @@ static int animchannels_enable_exec (bContext *C, wmOperator *UNUSED(op)) static void ANIM_OT_channels_fcurves_enable (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Revive Disabled F-Curves"); + ot->name= "Revive Disabled F-Curves"; ot->idname= "ANIM_OT_channels_fcurves_enable"; - ot->description= _("Clears 'disabled' tag from all F-Curves to get broken F-Curves working again"); + ot->description= "Clears 'disabled' tag from all F-Curves to get broken F-Curves working again"; /* api callbacks */ ot->exec= animchannels_enable_exec; @@ -1823,9 +1821,9 @@ static int animchannels_deselectall_exec (bContext *C, wmOperator *op) static void ANIM_OT_channels_select_all_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "ANIM_OT_channels_select_all_toggle"; - ot->description= _("Toggle selection of all animation channels"); + ot->description= "Toggle selection of all animation channels"; /* api callbacks */ ot->exec= animchannels_deselectall_exec; @@ -1835,7 +1833,7 @@ static void ANIM_OT_channels_select_all_toggle (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_boolean(ot->srna, "invert", 0, _("Invert"), ""); + ot->prop= RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); } /* ******************** Borderselect Operator *********************** */ @@ -1949,9 +1947,9 @@ static int animchannels_borderselect_exec(bContext *C, wmOperator *op) static void ANIM_OT_channels_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "ANIM_OT_channels_select_border"; - ot->description= _("Select all animation channels within the specified region"); + ot->description= "Select all animation channels within the specified region"; /* api callbacks */ ot->invoke= WM_border_select_invoke; @@ -2369,9 +2367,9 @@ static int animchannels_mouseclick_invoke(bContext *C, wmOperator *op, wmEvent * static void ANIM_OT_channels_click (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mouse Click on Channels"); + ot->name= "Mouse Click on Channels"; ot->idname= "ANIM_OT_channels_click"; - ot->description= _("Handle mouse-clicks over animation channels"); + ot->description= "Handle mouse-clicks over animation channels"; /* api callbacks */ ot->invoke= animchannels_mouseclick_invoke; @@ -2381,8 +2379,8 @@ static void ANIM_OT_channels_click (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); // SHIFTKEY - RNA_def_boolean(ot->srna, "children_only", 0, _("Select Children Only"), ""); // CTRLKEY|SHIFTKEY + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY + RNA_def_boolean(ot->srna, "children_only", 0, "Select Children Only", ""); // CTRLKEY|SHIFTKEY } /* ************************************************************************** */ diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c index ab38723bbcc..5345fcd756d 100644 --- a/source/blender/editors/animation/anim_markers.c +++ b/source/blender/editors/animation/anim_markers.c @@ -43,8 +43,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_fcurve.h" #include "BKE_main.h" @@ -577,8 +575,8 @@ static int ed_marker_add(bContext *C, wmOperator *UNUSED(op)) static void MARKER_OT_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Time Marker"); - ot->description= _("Add a new time marker"); + ot->name= "Add Time Marker"; + ot->description= "Add a new time marker"; ot->idname= "MARKER_OT_add"; /* api callbacks */ @@ -880,8 +878,8 @@ static int ed_marker_move_exec(bContext *C, wmOperator *op) static void MARKER_OT_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Time Marker"); - ot->description= _("Move selected time marker(s)"); + ot->name= "Move Time Marker"; + ot->description= "Move selected time marker(s)"; ot->idname= "MARKER_OT_move"; /* api callbacks */ @@ -895,7 +893,7 @@ static void MARKER_OT_move(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER; /* rna storage */ - RNA_def_int(ot->srna, "frames", 0, INT_MIN, INT_MAX, _("Frames"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "frames", 0, INT_MIN, INT_MAX, "Frames", "", INT_MIN, INT_MAX); } /* ************************** duplicate markers *************************** */ @@ -975,8 +973,8 @@ static int ed_marker_duplicate_invoke_wrapper(bContext *C, wmOperator *op, wmEve static void MARKER_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Time Marker"); - ot->description= _("Duplicate selected time marker(s)"); + ot->name= "Duplicate Time Marker"; + ot->description= "Duplicate selected time marker(s)"; ot->idname= "MARKER_OT_duplicate"; /* api callbacks */ @@ -990,7 +988,7 @@ static void MARKER_OT_duplicate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* rna storage */ - RNA_def_int(ot->srna, "frames", 0, INT_MIN, INT_MAX, _("Frames"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "frames", 0, INT_MIN, INT_MAX, "Frames", "", INT_MIN, INT_MAX); } /* ************************** selection ************************************/ @@ -1098,8 +1096,8 @@ static int ed_marker_select_invoke_wrapper(bContext *C, wmOperator *op, wmEvent static void MARKER_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Time Marker"); - ot->description= _("Select time marker(s)"); + ot->name= "Select Time Marker"; + ot->description= "Select time marker(s)"; ot->idname= "MARKER_OT_select"; /* api callbacks */ @@ -1109,9 +1107,9 @@ static void MARKER_OT_select(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("extend the selection")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "extend the selection"); #ifdef DURIAN_CAMERA_SWITCH - RNA_def_boolean(ot->srna, "camera", 0, _("Camera"), _("Select the camera")); + RNA_def_boolean(ot->srna, "camera", 0, "Camera", "Select the camera"); #endif } @@ -1182,8 +1180,8 @@ static int ed_marker_select_border_invoke_wrapper(bContext *C, wmOperator *op, w static void MARKER_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Marker Border select"); - ot->description= _("Select all time markers using border selection"); + ot->name= "Marker Border select"; + ot->description= "Select all time markers using border selection"; ot->idname= "MARKER_OT_select_border"; /* api callbacks */ @@ -1239,8 +1237,8 @@ static int ed_marker_select_all_exec(bContext *C, wmOperator *op) static void MARKER_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("(De)select all markers"); - ot->description= _("Change selection of all time markers"); + ot->name= "(De)select all markers"; + ot->description= "Change selection of all time markers"; ot->idname= "MARKER_OT_select_all"; /* api callbacks */ @@ -1292,8 +1290,8 @@ static int ed_marker_delete_invoke_wrapper(bContext *C, wmOperator *op, wmEvent static void MARKER_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Markers"); - ot->description= _("Delete selected time marker(s)"); + ot->name= "Delete Markers"; + ot->description= "Delete selected time marker(s)"; ot->idname= "MARKER_OT_delete"; /* api callbacks */ @@ -1340,8 +1338,8 @@ static int ed_marker_rename_invoke_wrapper(bContext *C, wmOperator *op, wmEvent static void MARKER_OT_rename(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rename Marker"); - ot->description= _("Rename first selected time marker"); + ot->name= "Rename Marker"; + ot->description= "Rename first selected time marker"; ot->idname= "MARKER_OT_rename"; /* api callbacks */ @@ -1353,7 +1351,7 @@ static void MARKER_OT_rename(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop = RNA_def_string(ot->srna, "name", "RenamedMarker", sizeof(((TimeMarker *)NULL)->name), _("Name"), _("New name for marker")); + ot->prop = RNA_def_string(ot->srna, "name", "RenamedMarker", sizeof(((TimeMarker *)NULL)->name), "Name", "New name for marker"); //RNA_def_boolean(ot->srna, "ensure_unique", 0, "Ensure Unique", "Ensure that new name is unique within collection of markers"); } @@ -1393,8 +1391,8 @@ static void MARKER_OT_make_links_scene(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Make Links to Scene"); - ot->description= _("Copy selected markers to another scene"); + ot->name= "Make Links to Scene"; + ot->description= "Copy selected markers to another scene"; ot->idname= "MARKER_OT_make_links_scene"; /* api callbacks */ @@ -1406,7 +1404,7 @@ static void MARKER_OT_make_links_scene(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, _("Scene"), ""); + prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, "Scene", ""); RNA_def_enum_funcs(prop, RNA_scene_itemf); ot->prop= prop; @@ -1443,8 +1441,8 @@ static int ed_marker_camera_bind_exec(bContext *C, wmOperator *UNUSED(op)) static void MARKER_OT_camera_bind(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bind Camera to Markers"); - ot->description= _("Bind the active camera to selected markers(s)"); + ot->name= "Bind Camera to Markers"; + ot->description= "Bind the active camera to selected markers(s)"; ot->idname= "MARKER_OT_camera_bind"; /* api callbacks */ diff --git a/source/blender/editors/animation/anim_ops.c b/source/blender/editors/animation/anim_ops.c index 3cb4cbe30c4..aa61afbac78 100644 --- a/source/blender/editors/animation/anim_ops.c +++ b/source/blender/editors/animation/anim_ops.c @@ -35,7 +35,6 @@ #include "BLO_sys_types.h" #include "BLI_utildefines.h" -#include "BLF_api.h" #include "DNA_anim_types.h" #include "DNA_scene_types.h" @@ -162,9 +161,9 @@ static int change_frame_modal(bContext *C, wmOperator *op, wmEvent *event) static void ANIM_OT_change_frame(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change frame"); + ot->name= "Change frame"; ot->idname= "ANIM_OT_change_frame"; - ot->description= _("Interactively change the current frame number"); + ot->description= "Interactively change the current frame number"; /* api callbacks */ ot->exec= change_frame_exec; @@ -176,7 +175,7 @@ static void ANIM_OT_change_frame(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING|OPTYPE_UNDO; /* rna */ - RNA_def_int(ot->srna, "frame", 0, MINAFRAME, MAXFRAME, _("Frame"), "", MINAFRAME, MAXFRAME); + RNA_def_int(ot->srna, "frame", 0, MINAFRAME, MAXFRAME, "Frame", "", MINAFRAME, MAXFRAME); } /* ****************** set preview range operator ****************************/ @@ -217,9 +216,9 @@ static int previewrange_define_exec(bContext *C, wmOperator *op) static void ANIM_OT_previewrange_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Preview Range"); + ot->name= "Set Preview Range"; ot->idname= "ANIM_OT_previewrange_set"; - ot->description= _("Interactively define frame range used for playback"); + ot->description= "Interactively define frame range used for playback"; /* api callbacks */ ot->invoke= WM_border_select_invoke; @@ -234,11 +233,11 @@ static void ANIM_OT_previewrange_set(wmOperatorType *ot) /* rna */ /* used to define frame range */ - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, "X Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, "X Max", "", INT_MIN, INT_MAX); /* these are not used, but are needed by borderselect gesture operator stuff */ - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, "Y Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, "Y Max", "", INT_MIN, INT_MAX); } /* ****************** clear preview range operator ****************************/ @@ -265,9 +264,9 @@ static int previewrange_clear_exec(bContext *C, wmOperator *UNUSED(op)) static void ANIM_OT_previewrange_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Preview Range"); + ot->name= "Clear Preview Range"; ot->idname= "ANIM_OT_previewrange_clear"; - ot->description= _("Clear Preview Range"); + ot->description= "Clear Preview Range"; /* api callbacks */ ot->exec= previewrange_clear_exec; @@ -333,9 +332,9 @@ static int toggle_time_exec(bContext *C, wmOperator *UNUSED(op)) static void ANIM_OT_time_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Frames/Seconds"); + ot->name= "Toggle Frames/Seconds"; ot->idname= "ANIM_OT_time_toggle"; - ot->description= _("Toggle whether timing is displayed in frames or seconds for active timeline view"); + ot->description= "Toggle whether timing is displayed in frames or seconds for active timeline view"; /* api callbacks */ ot->exec= toggle_time_exec; diff --git a/source/blender/editors/animation/drivers.c b/source/blender/editors/animation/drivers.c index 5943eb9500e..6ebe488d2c8 100644 --- a/source/blender/editors/animation/drivers.c +++ b/source/blender/editors/animation/drivers.c @@ -38,8 +38,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_object_types.h" #include "DNA_material_types.h" @@ -529,7 +527,7 @@ void ANIM_OT_driver_button_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Create drivers for all elements of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Create drivers for all elements of the array."); } /* Remove Driver Button Operator ------------------------ */ @@ -581,7 +579,7 @@ void ANIM_OT_driver_button_remove (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Delete drivers for all elements of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Delete drivers for all elements of the array."); } /* Copy Driver Button Operator ------------------------ */ diff --git a/source/blender/editors/animation/keyframing.c b/source/blender/editors/animation/keyframing.c index 8f6f7c6fac6..1e7c18dc6ac 100644 --- a/source/blender/editors/animation/keyframing.c +++ b/source/blender/editors/animation/keyframing.c @@ -43,8 +43,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_armature_types.h" #include "DNA_constraint_types.h" @@ -1180,9 +1178,9 @@ void ANIM_OT_keyframe_insert (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Insert Keyframe"); + ot->name= "Insert Keyframe"; ot->idname= "ANIM_OT_keyframe_insert"; - ot->description= _("Insert keyframes on the current frame for all properties in the specified Keying Set"); + ot->description= "Insert keyframes on the current frame for all properties in the specified Keying Set"; /* callbacks */ ot->exec= insert_key_exec; @@ -1192,7 +1190,7 @@ void ANIM_OT_keyframe_insert (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* keyingset to use (dynamic enum) */ - prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, _("Keying Set"), _("The Keying Set to use")); + prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, "Keying Set", "The Keying Set to use"); RNA_def_enum_funcs(prop, ANIM_keying_sets_enum_itemf); RNA_def_property_flag(prop, PROP_HIDDEN); ot->prop= prop; @@ -1200,7 +1198,7 @@ void ANIM_OT_keyframe_insert (wmOperatorType *ot) /* confirm whether a keyframe was added by showing a popup * - by default, this is enabled, since this operator is assumed to be called independently */ - prop= RNA_def_boolean(ot->srna, "confirm_success", 1, _("Confirm Successful Insert"), _("Show a popup when the keyframes get successfully added")); + prop= RNA_def_boolean(ot->srna, "confirm_success", 1, "Confirm Successful Insert", "Show a popup when the keyframes get successfully added"); RNA_def_property_flag(prop, PROP_HIDDEN); } @@ -1233,9 +1231,9 @@ void ANIM_OT_keyframe_insert_menu (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Insert Keyframe Menu"); + ot->name= "Insert Keyframe Menu"; ot->idname= "ANIM_OT_keyframe_insert_menu"; - ot->description= _("Insert Keyframes for specified Keying Set, with menu of available Keying Sets if undefined"); + ot->description= "Insert Keyframes for specified Keying Set, with menu of available Keying Sets if undefined"; /* callbacks */ ot->invoke= insert_key_menu_invoke; @@ -1246,7 +1244,7 @@ void ANIM_OT_keyframe_insert_menu (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* keyingset to use (dynamic enum) */ - prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, _("Keying Set"), _("The Keying Set to use")); + prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, "Keying Set", "The Keying Set to use"); RNA_def_enum_funcs(prop, ANIM_keying_sets_enum_itemf); RNA_def_property_flag(prop, PROP_HIDDEN); ot->prop= prop; @@ -1255,14 +1253,14 @@ void ANIM_OT_keyframe_insert_menu (wmOperatorType *ot) * - by default, this is disabled so that if a menu is shown, this doesn't come up too */ // XXX should this just be always on? - prop= RNA_def_boolean(ot->srna, "confirm_success", 0, _("Confirm Successful Insert"), _("Show a popup when the keyframes get successfully added")); + prop= RNA_def_boolean(ot->srna, "confirm_success", 0, "Confirm Successful Insert", "Show a popup when the keyframes get successfully added"); RNA_def_property_flag(prop, PROP_HIDDEN); /* whether the menu should always be shown * - by default, the menu should only be shown when there is no active Keying Set (2.5 behaviour), * although in some cases it might be useful to always shown (pre 2.5 behaviour) */ - prop= RNA_def_boolean(ot->srna, "always_prompt", 0, _("Always Show Menu"), ""); + prop= RNA_def_boolean(ot->srna, "always_prompt", 0, "Always Show Menu", ""); RNA_def_property_flag(prop, PROP_HIDDEN); } @@ -1327,9 +1325,9 @@ void ANIM_OT_keyframe_delete (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Delete Keying-Set Keyframe"); + ot->name= "Delete Keying-Set Keyframe"; ot->idname= "ANIM_OT_keyframe_delete"; - ot->description= _("Delete keyframes on the current frame for all properties in the specified Keying Set"); + ot->description= "Delete keyframes on the current frame for all properties in the specified Keying Set"; /* callbacks */ ot->exec= delete_key_exec; @@ -1339,7 +1337,7 @@ void ANIM_OT_keyframe_delete (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* keyingset to use (dynamic enum) */ - prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, _("Keying Set"), _("The Keying Set to use")); + prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, "Keying Set", "The Keying Set to use"); RNA_def_enum_funcs(prop, ANIM_keying_sets_enum_itemf); RNA_def_property_flag(prop, PROP_HIDDEN); ot->prop= prop; @@ -1347,7 +1345,7 @@ void ANIM_OT_keyframe_delete (wmOperatorType *ot) /* confirm whether a keyframe was added by showing a popup * - by default, this is enabled, since this operator is assumed to be called independently */ - RNA_def_boolean(ot->srna, "confirm_success", 1, _("Confirm Successful Insert"), _("Show a popup when the keyframes get successfully added")); + RNA_def_boolean(ot->srna, "confirm_success", 1, "Confirm Successful Insert", "Show a popup when the keyframes get successfully added"); } /* Delete Key Operator ------------------------ */ @@ -1399,8 +1397,8 @@ static int delete_key_v3d_exec (bContext *C, wmOperator *op) void ANIM_OT_keyframe_delete_v3d (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Keyframe"); - ot->description= _("Remove keyframes on current frame for selected object"); + ot->name= "Delete Keyframe"; + ot->description= "Remove keyframes on current frame for selected object"; ot->idname= "ANIM_OT_keyframe_delete_v3d"; /* callbacks */ @@ -1489,7 +1487,7 @@ static int insert_key_button_exec (bContext *C, wmOperator *op) void ANIM_OT_keyframe_insert_button (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert Keyframe (Buttons)"); + ot->name= "Insert Keyframe (Buttons)"; ot->idname= "ANIM_OT_keyframe_insert_button"; /* callbacks */ @@ -1500,7 +1498,7 @@ void ANIM_OT_keyframe_insert_button (wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Insert a keyframe for all element of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Insert a keyframe for all element of the array."); } /* Delete Key Button Operator ------------------------ */ @@ -1561,7 +1559,7 @@ static int delete_key_button_exec (bContext *C, wmOperator *op) void ANIM_OT_keyframe_delete_button (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Keyframe (Buttons)"); + ot->name= "Delete Keyframe (Buttons)"; ot->idname= "ANIM_OT_keyframe_delete_button"; /* callbacks */ @@ -1572,7 +1570,7 @@ void ANIM_OT_keyframe_delete_button (wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Delete keyfames from all elements of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Delete keyfames from all elements of the array."); } /* ******************************************* */ diff --git a/source/blender/editors/animation/keyingsets.c b/source/blender/editors/animation/keyingsets.c index e36045e84cd..dcd1c3abbde 100644 --- a/source/blender/editors/animation/keyingsets.c +++ b/source/blender/editors/animation/keyingsets.c @@ -43,8 +43,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_scene_types.h" #include "DNA_object_types.h" @@ -142,9 +140,9 @@ static int add_default_keyingset_exec (bContext *C, wmOperator *UNUSED(op)) void ANIM_OT_keying_set_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Empty Keying Set"); + ot->name= "Add Empty Keying Set"; ot->idname= "ANIM_OT_keying_set_add"; - ot->description= _("Add a new (empty) Keying Set to the active Scene"); + ot->description= "Add a new (empty) Keying Set to the active Scene"; /* callbacks */ ot->exec= add_default_keyingset_exec; @@ -189,9 +187,9 @@ static int remove_active_keyingset_exec (bContext *C, wmOperator *op) void ANIM_OT_keying_set_remove (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Removed Active Keying Set"); + ot->name= "Removed Active Keying Set"; ot->idname= "ANIM_OT_keying_set_remove"; - ot->description= _("Remove the active Keying Set"); + ot->description= "Remove the active Keying Set"; /* callbacks */ ot->exec= remove_active_keyingset_exec; @@ -232,9 +230,9 @@ static int add_empty_ks_path_exec (bContext *C, wmOperator *op) void ANIM_OT_keying_set_path_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Empty Keying Set Path"); + ot->name= "Add Empty Keying Set Path"; ot->idname= "ANIM_OT_keying_set_path_add"; - ot->description= _("Add empty path to active Keying Set"); + ot->description= "Add empty path to active Keying Set"; /* callbacks */ ot->exec= add_empty_ks_path_exec; @@ -275,9 +273,9 @@ static int remove_active_ks_path_exec (bContext *C, wmOperator *op) void ANIM_OT_keying_set_path_remove (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Active Keying Set Path"); + ot->name= "Remove Active Keying Set Path"; ot->idname= "ANIM_OT_keying_set_path_remove"; - ot->description= _("Remove active Path from active Keying Set"); + ot->description= "Remove active Path from active Keying Set"; /* callbacks */ ot->exec= remove_active_ks_path_exec; @@ -373,7 +371,7 @@ static int add_keyingset_button_exec (bContext *C, wmOperator *op) void ANIM_OT_keyingset_button_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add to Keying Set"); + ot->name= "Add to Keying Set"; ot->idname= "ANIM_OT_keyingset_button_add"; /* callbacks */ @@ -384,7 +382,7 @@ void ANIM_OT_keyingset_button_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Add all elements of the array to a Keying Set.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Add all elements of the array to a Keying Set."); } /* Remove from KeyingSet Button Operator ------------------------ */ @@ -452,7 +450,7 @@ static int remove_keyingset_button_exec (bContext *C, wmOperator *op) void ANIM_OT_keyingset_button_remove (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove from Keying Set"); + ot->name= "Remove from Keying Set"; ot->idname= "ANIM_OT_keyingset_button_remove"; /* callbacks */ @@ -495,7 +493,7 @@ static int keyingset_active_menu_exec (bContext *C, wmOperator *op) void ANIM_OT_keying_set_active_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Active Keying Set"); + ot->name= "Set Active Keying Set"; ot->idname= "ANIM_OT_keying_set_active_set"; /* callbacks */ @@ -509,7 +507,7 @@ void ANIM_OT_keying_set_active_set (wmOperatorType *ot) /* keyingset to use * - here the type is int not enum, since many of the indices here are determined dynamically */ - RNA_def_int(ot->srna, "type", 0, INT_MIN, INT_MAX, _("Keying Set Number"), _("Index (determined internally) of the Keying Set to use"), 0, 1); + RNA_def_int(ot->srna, "type", 0, INT_MIN, INT_MAX, "Keying Set Number", "Index (determined internally) of the Keying Set to use", 0, 1); } /* ******************************************* */ diff --git a/source/blender/editors/armature/armature_ops.c b/source/blender/editors/armature/armature_ops.c index 6369f9280e6..81ece9ddc9a 100644 --- a/source/blender/editors/armature/armature_ops.c +++ b/source/blender/editors/armature/armature_ops.c @@ -37,7 +37,6 @@ #include "BLI_math.h" #include "BLI_blenlib.h" -#include "BLF_api.h" #include "RNA_access.h" @@ -172,14 +171,14 @@ void ED_operatormacros_armature(void) wmOperatorType *ot; wmOperatorTypeMacro *otmacro; - ot= WM_operatortype_append_macro("ARMATURE_OT_duplicate_move", _("Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("ARMATURE_OT_duplicate_move", "Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); if(ot) { WM_operatortype_macro_define(ot, "ARMATURE_OT_duplicate"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); RNA_enum_set(otmacro->ptr, "proportional", 0); } - ot= WM_operatortype_append_macro("ARMATURE_OT_extrude_move", _("Extrude"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("ARMATURE_OT_extrude_move", "Extrude", OPTYPE_UNDO|OPTYPE_REGISTER); if(ot) { otmacro=WM_operatortype_macro_define(ot, "ARMATURE_OT_extrude"); RNA_boolean_set(otmacro->ptr, "forked", 0); @@ -189,7 +188,7 @@ void ED_operatormacros_armature(void) // XXX would it be nicer to just be able to have standard extrude_move, but set the forked property separate? // that would require fixing a properties bug 19733 - ot= WM_operatortype_append_macro("ARMATURE_OT_extrude_forked", _("Extrude Forked"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("ARMATURE_OT_extrude_forked", "Extrude Forked", OPTYPE_UNDO|OPTYPE_REGISTER); if(ot) { otmacro=WM_operatortype_macro_define(ot, "ARMATURE_OT_extrude"); RNA_boolean_set(otmacro->ptr, "forked", 1); diff --git a/source/blender/editors/armature/editarmature.c b/source/blender/editors/armature/editarmature.c index e7ccd8a346b..a4b1e9a6e2c 100644 --- a/source/blender/editors/armature/editarmature.c +++ b/source/blender/editors/armature/editarmature.c @@ -51,8 +51,6 @@ #include "BLI_editVert.h" #include "BLI_ghash.h" -#include "BLF_api.h" - #include "BKE_animsys.h" #include "BKE_action.h" #include "BKE_armature.h" @@ -731,9 +729,9 @@ static int apply_armature_pose2bones_exec (bContext *C, wmOperator *op) void POSE_OT_armature_apply (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Apply Pose as Rest Pose"); + ot->name= "Apply Pose as Rest Pose"; ot->idname= "POSE_OT_armature_apply"; - ot->description= _("Apply the current pose as the new rest pose"); + ot->description= "Apply the current pose as the new rest pose"; /* callbacks */ ot->exec= apply_armature_pose2bones_exec; @@ -782,9 +780,9 @@ static int pose_visual_transform_apply_exec (bContext *C, wmOperator *UNUSED(op) void POSE_OT_visual_transform_apply (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Apply Visual Transform to Pose"); + ot->name= "Apply Visual Transform to Pose"; ot->idname= "POSE_OT_visual_transform_apply"; - ot->description= _("Apply final constrained position of pose bones to their transform."); + ot->description= "Apply final constrained position of pose bones to their transform."; /* callbacks */ ot->exec= pose_visual_transform_apply_exec; @@ -1245,9 +1243,9 @@ static int separate_armature_exec (bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_separate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Separate Bones"); + ot->name= "Separate Bones"; ot->idname= "ARMATURE_OT_separate"; - ot->description= _("Isolate selected bones into a separate armature"); + ot->description= "Isolate selected bones into a separate armature"; /* callbacks */ ot->invoke= WM_operator_confirm; @@ -1469,9 +1467,9 @@ static int pose_select_linked_poll(bContext *C) void POSE_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Connected"); + ot->name= "Select Connected"; ot->idname= "POSE_OT_select_linked"; - ot->description= _("Select bones related to selected ones by parent/child relationships"); + ot->description= "Select bones related to selected ones by parent/child relationships"; /* api callbacks */ ot->exec= NULL; @@ -1482,7 +1480,7 @@ void POSE_OT_select_linked(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); } /* **************** END Posemode stuff ********************** */ @@ -1563,9 +1561,9 @@ static int armature_select_linked_poll(bContext *C) void ARMATURE_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Connected"); + ot->name= "Select Connected"; ot->idname= "ARMATURE_OT_select_linked"; - ot->description= _("Select bones related to selected ones by parent/child relationships"); + ot->description= "Select bones related to selected ones by parent/child relationships"; /* api callbacks */ ot->exec= NULL; @@ -1576,7 +1574,7 @@ void ARMATURE_OT_select_linked(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties s*/ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); } /* does bones and points */ @@ -1748,9 +1746,9 @@ static int armature_delete_selected_exec(bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Selected Bone(s)"); + ot->name= "Delete Selected Bone(s)"; ot->idname= "ARMATURE_OT_delete"; - ot->description= _("Remove selected bones from the armature"); + ot->description= "Remove selected bones from the armature"; /* api callbacks */ ot->invoke = WM_operator_confirm; @@ -1997,12 +1995,12 @@ float ED_rollBoneToVector(EditBone *bone, const float align_axis[3], const short static EnumPropertyItem prop_calc_roll_types[] = { - {0, "X", 0, N_("X Axis"), ""}, - {1, "Y", 0, N_("Y Axis"), ""}, - {2, "Z", 0, N_("Z Axis"), ""}, - {5, "ACTIVE", 0, N_("Active Bone"), ""}, - {6, "VIEW", 0, N_("View Axis"), ""}, - {7, "CURSOR", 0, N_("Cursor"), ""}, + {0, "X", 0, "X Axis", ""}, + {1, "Y", 0, "Y Axis", ""}, + {2, "Z", 0, "Z Axis", ""}, + {5, "ACTIVE", 0, "Active Bone", ""}, + {6, "VIEW", 0, "View Axis", ""}, + {7, "CURSOR", 0, "Cursor", ""}, {0, NULL, 0, NULL, NULL} }; @@ -2103,9 +2101,9 @@ static int armature_calc_roll_exec(bContext *C, wmOperator *op) void ARMATURE_OT_calculate_roll(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Recalculate Roll"); + ot->name= "Recalculate Roll"; ot->idname= "ARMATURE_OT_calculate_roll"; - ot->description= _("Automatically fix alignment of select bones' axes"); + ot->description= "Automatically fix alignment of select bones' axes"; /* api callbacks */ ot->invoke = WM_menu_invoke; @@ -2116,9 +2114,9 @@ void ARMATURE_OT_calculate_roll(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_calc_roll_types), 0, _("Type"), ""); - RNA_def_boolean(ot->srna, "axis_flip", 0, _("Flip Axis"), _("Negate the alignment axis.")); - RNA_def_boolean(ot->srna, "axis_only", 0, _("Shortest Rotation"), _("Ignore the axis direction, use the shortest rotation to align.")); + ot->prop= RNA_def_enum(ot->srna, "type", prop_calc_roll_types, 0, "Type", ""); + RNA_def_boolean(ot->srna, "axis_flip", 0, "Flip Axis", "Negate the alignment axis."); + RNA_def_boolean(ot->srna, "axis_only", 0, "Shortest Rotation", "Ignore the axis direction, use the shortest rotation to align."); } /* **************** undo for armatures ************** */ @@ -2410,9 +2408,9 @@ static int armature_click_extrude_invoke(bContext *C, wmOperator *op, wmEvent *e void ARMATURE_OT_click_extrude(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Click-Extrude"); + ot->name= "Click-Extrude"; ot->idname= "ARMATURE_OT_click_extrude"; - ot->description= _("Create a new bone going from the last selected joint to the mouse position"); + ot->description= "Create a new bone going from the last selected joint to the mouse position"; /* api callbacks */ ot->invoke = armature_click_extrude_invoke; @@ -2679,9 +2677,9 @@ static int armature_duplicate_selected_exec(bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Selected Bone(s)"); + ot->name= "Duplicate Selected Bone(s)"; ot->idname= "ARMATURE_OT_duplicate"; - ot->description= _("Make copies of the selected bones within the same armature"); + ot->description= "Make copies of the selected bones within the same armature"; /* api callbacks */ ot->exec = armature_duplicate_selected_exec; @@ -2953,9 +2951,9 @@ static int armature_fill_bones_exec (bContext *C, wmOperator *op) void ARMATURE_OT_fill (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Fill Between Joints"); + ot->name= "Fill Between Joints"; ot->idname= "ARMATURE_OT_fill"; - ot->description= _("Add bone between selected joint(s) and/or 3D-Cursor"); + ot->description= "Add bone between selected joint(s) and/or 3D-Cursor"; /* callbacks */ ot->exec= armature_fill_bones_exec; @@ -3132,14 +3130,14 @@ static int armature_merge_exec (bContext *C, wmOperator *op) void ARMATURE_OT_merge (wmOperatorType *ot) { static EnumPropertyItem merge_types[] = { - {1, "WITHIN_CHAIN", 0, N_("Within Chains"), ""}, + {1, "WITHIN_CHAIN", 0, "Within Chains", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Merge Bones"); + ot->name= "Merge Bones"; ot->idname= "ARMATURE_OT_merge"; - ot->description= _("Merge continuous chains of selected bones"); + ot->description= "Merge continuous chains of selected bones"; /* callbacks */ ot->invoke= WM_menu_invoke; @@ -3150,7 +3148,7 @@ void ARMATURE_OT_merge (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(merge_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", merge_types, 0, "Type", ""); } /* ************** END Add/Remove stuff in editmode ************ */ @@ -3186,9 +3184,9 @@ static int armature_hide_exec(bContext *C, wmOperator *op) void ARMATURE_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selected Bones"); + ot->name= "Hide Selected Bones"; ot->idname= "ARMATURE_OT_hide"; - ot->description= _("Tag selected bones to not be visible in Edit Mode"); + ot->description= "Tag selected bones to not be visible in Edit Mode"; /* api callbacks */ ot->exec= armature_hide_exec; @@ -3198,7 +3196,7 @@ void ARMATURE_OT_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } static int armature_reveal_exec(bContext *C, wmOperator *UNUSED(op)) @@ -3226,9 +3224,9 @@ static int armature_reveal_exec(bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal Bones"); + ot->name= "Reveal Bones"; ot->idname= "ARMATURE_OT_reveal"; - ot->description= _("Unhide all bones that have been tagged to be hidden in Edit Mode"); + ot->description= "Unhide all bones that have been tagged to be hidden in Edit Mode"; /* api callbacks */ ot->exec= armature_reveal_exec; @@ -3435,9 +3433,9 @@ static int armature_extrude_exec(bContext *C, wmOperator *op) void ARMATURE_OT_extrude(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Extrude"); + ot->name= "Extrude"; ot->idname= "ARMATURE_OT_extrude"; - ot->description= _("Create new bones from the selected joints"); + ot->description= "Create new bones from the selected joints"; /* api callbacks */ ot->exec= armature_extrude_exec; @@ -3447,7 +3445,7 @@ void ARMATURE_OT_extrude(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "forked", 0, _("Forked"), ""); + RNA_def_boolean(ot->srna, "forked", 0, "Forked", ""); } /* ********************** Bone Add ********************/ @@ -3498,9 +3496,9 @@ static int armature_bone_primitive_add_exec(bContext *C, wmOperator *op) void ARMATURE_OT_bone_primitive_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Bone"); + ot->name= "Add Bone"; ot->idname= "ARMATURE_OT_bone_primitive_add"; - ot->description= _("Add a new bone located at the 3D-Cursor"); + ot->description= "Add a new bone located at the 3D-Cursor"; /* api callbacks */ ot->exec = armature_bone_primitive_add_exec; @@ -3509,7 +3507,7 @@ void ARMATURE_OT_bone_primitive_add(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_string(ot->srna, "name", "Bone", 32, _("Name"), _("Name of the newly created bone")); + RNA_def_string(ot->srna, "name", "Bone", 32, "Name", "Name of the newly created bone"); } @@ -3588,9 +3586,9 @@ static int armature_subdivide_exec(bContext *C, wmOperator *op) void ARMATURE_OT_subdivide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Subdivide Multi"); + ot->name= "Subdivide Multi"; ot->idname= "ARMATURE_OT_subdivide"; - ot->description= _("Break selected bones into chains of smaller bones"); + ot->description= "Break selected bones into chains of smaller bones"; /* api callbacks */ ot->exec = armature_subdivide_exec; @@ -3600,7 +3598,7 @@ void ARMATURE_OT_subdivide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* Properties */ - RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, _("Number of Cuts"), "", 1, 10); + RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, "Number of Cuts", "", 1, 10); } /* ----------- */ @@ -3690,9 +3688,9 @@ static int armature_switch_direction_exec(bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_switch_direction(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Switch Direction"); + ot->name= "Switch Direction"; ot->idname= "ARMATURE_OT_switch_direction"; - ot->description= _("Change the direction that a chain of bones points in (head <-> tail swap)"); + ot->description= "Change the direction that a chain of bones points in (head <-> tail swap)"; /* api callbacks */ ot->exec = armature_switch_direction_exec; @@ -3764,8 +3762,8 @@ static void bone_connect_to_new_parent(ListBase *edbo, EditBone *selbone, EditBo } static EnumPropertyItem prop_editarm_make_parent_types[] = { - {ARM_PAR_CONNECT, "CONNECTED", 0, N_("Connected"), ""}, - {ARM_PAR_OFFSET, "OFFSET", 0, N_("Keep Offset"), ""}, + {ARM_PAR_CONNECT, "CONNECTED", 0, "Connected", ""}, + {ARM_PAR_OFFSET, "OFFSET", 0, "Keep Offset", ""}, {0, NULL, 0, NULL, NULL} }; @@ -3865,9 +3863,9 @@ static int armature_parent_set_invoke(bContext *C, wmOperator *UNUSED(op), wmEve void ARMATURE_OT_parent_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Parent"); + ot->name= "Make Parent"; ot->idname= "ARMATURE_OT_parent_set"; - ot->description= _("Set the active bone as the parent of the selected bones"); + ot->description= "Set the active bone as the parent of the selected bones"; /* api callbacks */ ot->invoke = armature_parent_set_invoke; @@ -3877,12 +3875,12 @@ void ARMATURE_OT_parent_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_editarm_make_parent_types), 0, _("ParentType"), _("Type of parenting")); + RNA_def_enum(ot->srna, "type", prop_editarm_make_parent_types, 0, "ParentType", "Type of parenting"); } static EnumPropertyItem prop_editarm_clear_parent_types[] = { - {1, "CLEAR", 0, N_("Clear Parent"), ""}, - {2, "DISCONNECT", 0, N_("Disconnect Bone"), ""}, + {1, "CLEAR", 0, "Clear Parent", ""}, + {2, "DISCONNECT", 0, "Disconnect Bone", ""}, {0, NULL, 0, NULL, NULL} }; @@ -3919,9 +3917,9 @@ static int armature_parent_clear_exec(bContext *C, wmOperator *op) void ARMATURE_OT_parent_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Parent"); + ot->name= "Clear Parent"; ot->idname= "ARMATURE_OT_parent_clear"; - ot->description= _("Remove the parent-child relationship between selected bones and their parents"); + ot->description= "Remove the parent-child relationship between selected bones and their parents"; /* api callbacks */ ot->invoke = WM_menu_invoke; @@ -3931,7 +3929,7 @@ void ARMATURE_OT_parent_clear(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_editarm_clear_parent_types), 0, _("ClearType"), _("What way to clear parenting")); + ot->prop= RNA_def_enum(ot->srna, "type", prop_editarm_clear_parent_types, 0, "ClearType", "What way to clear parenting"); } /* **************** Selections ******************/ @@ -3956,9 +3954,9 @@ static int armature_select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); + ot->name= "Select Inverse"; ot->idname= "ARMATURE_OT_select_inverse"; - ot->description= _("Flip the selection status of bones (selected -> unselected, unselected -> selected)"); + ot->description= "Flip the selection status of bones (selected -> unselected, unselected -> selected)"; /* api callbacks */ ot->exec= armature_select_inverse_exec; @@ -4016,9 +4014,9 @@ static int armature_de_select_all_exec(bContext *C, wmOperator *op) void ARMATURE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); + ot->name= "Select or Deselect All"; ot->idname= "ARMATURE_OT_select_all"; - ot->description= _("Toggle selection status of all bones"); + ot->description= "Toggle selection status of all bones"; /* api callbacks */ ot->exec= armature_de_select_all_exec; @@ -4091,15 +4089,15 @@ static int armature_select_hierarchy_exec(bContext *C, wmOperator *op) void ARMATURE_OT_select_hierarchy(wmOperatorType *ot) { static EnumPropertyItem direction_items[]= { - {BONE_SELECT_PARENT, "PARENT", 0, N_("Select Parent"), ""}, - {BONE_SELECT_CHILD, "CHILD", 0, N_("Select Child"), ""}, + {BONE_SELECT_PARENT, "PARENT", 0, "Select Parent", ""}, + {BONE_SELECT_CHILD, "CHILD", 0, "Select Child", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Select Hierarchy"); + ot->name= "Select Hierarchy"; ot->idname= "ARMATURE_OT_select_hierarchy"; - ot->description= _("Select immediate parent/children of selected bones"); + ot->description= "Select immediate parent/children of selected bones"; /* api callbacks */ ot->exec= armature_select_hierarchy_exec; @@ -4109,9 +4107,9 @@ void ARMATURE_OT_select_hierarchy(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(direction_items), - BONE_SELECT_PARENT, _("Direction"), ""); - RNA_def_boolean(ot->srna, "extend", 0, _("Add to Selection"), ""); + RNA_def_enum(ot->srna, "direction", direction_items, + BONE_SELECT_PARENT, "Direction", ""); + RNA_def_boolean(ot->srna, "extend", 0, "Add to Selection", ""); } /* ***************** EditBone Alignment ********************* */ @@ -4236,9 +4234,9 @@ static int armature_align_bones_exec(bContext *C, wmOperator *op) void ARMATURE_OT_align(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Align Bones"); + ot->name= "Align Bones"; ot->idname= "ARMATURE_OT_align"; - ot->description= _("Align selected bones to the active bone (or to their parent)"); + ot->description= "Align selected bones to the active bone (or to their parent)"; /* api callbacks */ ot->invoke = WM_operator_confirm; @@ -4951,9 +4949,9 @@ static int pose_clear_scale_exec(bContext *C, wmOperator *op) void POSE_OT_scale_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Pose Scale"); + ot->name= "Clear Pose Scale"; ot->idname= "POSE_OT_scale_clear"; - ot->description = _("Reset scaling of selected bones to their default values"); + ot->description = "Reset scaling of selected bones to their default values"; /* api callbacks */ ot->exec = pose_clear_scale_exec; @@ -4972,9 +4970,9 @@ static int pose_clear_rot_exec(bContext *C, wmOperator *op) void POSE_OT_rot_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Pose Rotation"); + ot->name= "Clear Pose Rotation"; ot->idname= "POSE_OT_rot_clear"; - ot->description = _("Reset rotations of selected bones to their default values"); + ot->description = "Reset rotations of selected bones to their default values"; /* api callbacks */ ot->exec = pose_clear_rot_exec; @@ -4993,9 +4991,9 @@ static int pose_clear_loc_exec(bContext *C, wmOperator *op) void POSE_OT_loc_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Pose Location"); + ot->name= "Clear Pose Location"; ot->idname= "POSE_OT_loc_clear"; - ot->description = _("Reset locations of selected bones to their default values"); + ot->description = "Reset locations of selected bones to their default values"; /* api callbacks */ ot->exec = pose_clear_loc_exec; @@ -5014,9 +5012,9 @@ static int pose_clear_transforms_exec(bContext *C, wmOperator *op) void POSE_OT_transforms_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Pose Transforms"); + ot->name= "Clear Pose Transforms"; ot->idname= "POSE_OT_transforms_clear"; - ot->description = _("Reset location, rotation, and scaling of selected bones to their default values"); + ot->description = "Reset location, rotation, and scaling of selected bones to their default values"; /* api callbacks */ ot->exec = pose_clear_transforms_exec; @@ -5048,9 +5046,9 @@ static int pose_select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void POSE_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); + ot->name= "Select Inverse"; ot->idname= "POSE_OT_select_inverse"; - ot->description= _("Flip the selection status of bones (selected -> unselected, unselected -> selected)"); + ot->description= "Flip the selection status of bones (selected -> unselected, unselected -> selected)"; /* api callbacks */ ot->exec= pose_select_inverse_exec; @@ -5099,9 +5097,9 @@ static int pose_de_select_all_exec(bContext *C, wmOperator *op) void POSE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); + ot->name= "Select or Deselect All"; ot->idname= "POSE_OT_select_all"; - ot->description= _("Toggle selection status of all bones"); + ot->description= "Toggle selection status of all bones"; /* api callbacks */ ot->exec= pose_de_select_all_exec; @@ -5143,9 +5141,9 @@ static int pose_select_parent_exec(bContext *C, wmOperator *UNUSED(op)) void POSE_OT_select_parent(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Parent Bone"); + ot->name= "Select Parent Bone"; ot->idname= "POSE_OT_select_parent"; - ot->description= _("Select bones that are parents of the currently selected bones"); + ot->description= "Select bones that are parents of the currently selected bones"; /* api callbacks */ ot->exec= pose_select_parent_exec; @@ -5208,9 +5206,9 @@ static int pose_hide_exec(bContext *C, wmOperator *op) void POSE_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selected"); + ot->name= "Hide Selected"; ot->idname= "POSE_OT_hide"; - ot->description= _("Tag selected bones to not be visible in Pose Mode"); + ot->description= "Tag selected bones to not be visible in Pose Mode"; /* api callbacks */ ot->exec= pose_hide_exec; @@ -5220,7 +5218,7 @@ void POSE_OT_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), ""); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", ""); } static int show_pose_bone_cb(Object *ob, Bone *bone, void *UNUSED(ptr)) @@ -5254,9 +5252,9 @@ static int pose_reveal_exec(bContext *C, wmOperator *UNUSED(op)) void POSE_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal Selected"); + ot->name= "Reveal Selected"; ot->idname= "POSE_OT_reveal"; - ot->description= _("Unhide all bones that have been tagged to be hidden in Pose Mode"); + ot->description= "Unhide all bones that have been tagged to be hidden in Pose Mode"; /* api callbacks */ ot->exec= pose_reveal_exec; @@ -5471,9 +5469,9 @@ static int armature_flip_names_exec (bContext *C, wmOperator *UNUSED(op)) void ARMATURE_OT_flip_names (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Names"); + ot->name= "Flip Names"; ot->idname= "ARMATURE_OT_flip_names"; - ot->description= _("Flips (and corrects) the axis suffixes of the names of selected bones"); + ot->description= "Flips (and corrects) the axis suffixes of the names of selected bones"; /* api callbacks */ ot->exec= armature_flip_names_exec; @@ -5517,15 +5515,15 @@ static int armature_autoside_names_exec (bContext *C, wmOperator *op) void ARMATURE_OT_autoside_names (wmOperatorType *ot) { static EnumPropertyItem axis_items[]= { - {0, "XAXIS", 0, N_("X-Axis"), N_("Left/Right")}, - {1, "YAXIS", 0, N_("Y-Axis"), N_("Front/Back")}, - {2, "ZAXIS", 0, N_("Z-Axis"), N_("Top/Bottom")}, + {0, "XAXIS", 0, "X-Axis", "Left/Right"}, + {1, "YAXIS", 0, "Y-Axis", "Front/Back"}, + {2, "ZAXIS", 0, "Z-Axis", "Top/Bottom"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("AutoName by Axis"); + ot->name= "AutoName by Axis"; ot->idname= "ARMATURE_OT_autoside_names"; - ot->description= _("Automatically renames the selected bones according to which side of the target axis they fall on"); + ot->description= "Automatically renames the selected bones according to which side of the target axis they fall on"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -5536,7 +5534,7 @@ void ARMATURE_OT_autoside_names (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* settings */ - ot->prop= RNA_def_enum(ot->srna, "type", axis_items, 0, _("Axis"), _("Axis tag names with.")); + ot->prop= RNA_def_enum(ot->srna, "type", axis_items, 0, "Axis", "Axis tag names with."); } diff --git a/source/blender/editors/armature/editarmature_sketch.c b/source/blender/editors/armature/editarmature_sketch.c index b238ae3c0c0..bcd9d746a44 100644 --- a/source/blender/editors/armature/editarmature_sketch.c +++ b/source/blender/editors/armature/editarmature_sketch.c @@ -44,8 +44,6 @@ #include "BLI_graph.h" #include "BLI_ghash.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_sketch.h" @@ -2843,7 +2841,7 @@ int ED_operator_sketch_mode(const bContext *C) void SKETCH_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("delete"); + ot->name= "delete"; ot->idname= "SKETCH_OT_delete"; /* api callbacks */ @@ -2858,7 +2856,7 @@ void SKETCH_OT_delete(wmOperatorType *ot) void SKETCH_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("select"); + ot->name= "select"; ot->idname= "SKETCH_OT_select"; /* api callbacks */ @@ -2873,7 +2871,7 @@ void SKETCH_OT_select(wmOperatorType *ot) void SKETCH_OT_cancel_stroke(wmOperatorType *ot) { /* identifiers */ - ot->name= _("cancel stroke"); + ot->name= "cancel stroke"; ot->idname= "SKETCH_OT_cancel_stroke"; /* api callbacks */ @@ -2888,7 +2886,7 @@ void SKETCH_OT_cancel_stroke(wmOperatorType *ot) void SKETCH_OT_convert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("convert"); + ot->name= "convert"; ot->idname= "SKETCH_OT_convert"; /* api callbacks */ @@ -2903,7 +2901,7 @@ void SKETCH_OT_convert(wmOperatorType *ot) void SKETCH_OT_finish_stroke(wmOperatorType *ot) { /* identifiers */ - ot->name= _("end stroke"); + ot->name= "end stroke"; ot->idname= "SKETCH_OT_finish_stroke"; /* api callbacks */ @@ -2918,7 +2916,7 @@ void SKETCH_OT_finish_stroke(wmOperatorType *ot) void SKETCH_OT_draw_preview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("draw preview"); + ot->name= "draw preview"; ot->idname= "SKETCH_OT_draw_preview"; /* api callbacks */ @@ -2926,7 +2924,7 @@ void SKETCH_OT_draw_preview(wmOperatorType *ot) ot->poll= ED_operator_sketch_mode_active_stroke; - RNA_def_boolean(ot->srna, "snap", 0, _("Snap"), ""); + RNA_def_boolean(ot->srna, "snap", 0, "Snap", ""); /* flags */ // ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2935,7 +2933,7 @@ void SKETCH_OT_draw_preview(wmOperatorType *ot) void SKETCH_OT_draw_stroke(wmOperatorType *ot) { /* identifiers */ - ot->name= _("draw stroke"); + ot->name= "draw stroke"; ot->idname= "SKETCH_OT_draw_stroke"; /* api callbacks */ @@ -2945,7 +2943,7 @@ void SKETCH_OT_draw_stroke(wmOperatorType *ot) ot->poll= (int (*)(bContext *))ED_operator_sketch_mode; - RNA_def_boolean(ot->srna, "snap", 0, _("Snap"), ""); + RNA_def_boolean(ot->srna, "snap", 0, "Snap", ""); /* flags */ ot->flag= OPTYPE_BLOCKING; // OPTYPE_REGISTER|OPTYPE_UNDO @@ -2954,7 +2952,7 @@ void SKETCH_OT_draw_stroke(wmOperatorType *ot) void SKETCH_OT_gesture(wmOperatorType *ot) { /* identifiers */ - ot->name= _("gesture"); + ot->name= "gesture"; ot->idname= "SKETCH_OT_gesture"; /* api callbacks */ @@ -2964,7 +2962,7 @@ void SKETCH_OT_gesture(wmOperatorType *ot) ot->poll= ED_operator_sketch_mode_gesture; - RNA_def_boolean(ot->srna, "snap", 0, _("Snap"), ""); + RNA_def_boolean(ot->srna, "snap", 0, "Snap", ""); /* flags */ ot->flag= OPTYPE_BLOCKING; // OPTYPE_UNDO diff --git a/source/blender/editors/armature/poseSlide.c b/source/blender/editors/armature/poseSlide.c index c6927de0f87..16888908bab 100644 --- a/source/blender/editors/armature/poseSlide.c +++ b/source/blender/editors/armature/poseSlide.c @@ -43,8 +43,6 @@ #include "BLI_dlrbTree.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_armature_types.h" #include "DNA_object_types.h" @@ -720,9 +718,9 @@ static int pose_slide_exec_common (bContext *C, wmOperator *op, tPoseSlideOp *ps /* common code for defining RNA properties */ static void pose_slide_opdef_properties (wmOperatorType *ot) { - RNA_def_int(ot->srna, "prev_frame", 0, MINAFRAME, MAXFRAME, _("Previous Keyframe"), _("Frame number of keyframe immediately before the current frame."), 0, 50); - RNA_def_int(ot->srna, "next_frame", 0, MINAFRAME, MAXFRAME, _("Next Keyframe"), _("Frame number of keyframe immediately after the current frame."), 0, 50); - RNA_def_float_percentage(ot->srna, "percentage", 0.5f, 0.0f, 1.0f, _("Percentage"), _("Weighting factor for the sliding operation"), 0.3, 0.7); + RNA_def_int(ot->srna, "prev_frame", 0, MINAFRAME, MAXFRAME, "Previous Keyframe", "Frame number of keyframe immediately before the current frame.", 0, 50); + RNA_def_int(ot->srna, "next_frame", 0, MINAFRAME, MAXFRAME, "Next Keyframe", "Frame number of keyframe immediately after the current frame.", 0, 50); + RNA_def_float_percentage(ot->srna, "percentage", 0.5f, 0.0f, 1.0f, "Percentage", "Weighting factor for the sliding operation", 0.3, 0.7); } /* ------------------------------------ */ @@ -764,9 +762,9 @@ static int pose_slide_push_exec (bContext *C, wmOperator *op) void POSE_OT_push (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Push Pose"); + ot->name= "Push Pose"; ot->idname= "POSE_OT_push"; - ot->description= _("Exaggerate the current pose"); + ot->description= "Exaggerate the current pose"; /* callbacks */ ot->exec= pose_slide_push_exec; @@ -821,9 +819,9 @@ static int pose_slide_relax_exec (bContext *C, wmOperator *op) void POSE_OT_relax (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Relax Pose"); + ot->name= "Relax Pose"; ot->idname= "POSE_OT_relax"; - ot->description= _("Make the current pose more similar to its surrounding ones"); + ot->description= "Make the current pose more similar to its surrounding ones"; /* callbacks */ ot->exec= pose_slide_relax_exec; @@ -878,9 +876,9 @@ static int pose_slide_breakdown_exec (bContext *C, wmOperator *op) void POSE_OT_breakdown (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Pose Breakdowner"); + ot->name= "Pose Breakdowner"; ot->idname= "POSE_OT_breakdown"; - ot->description= _("Create a suitable breakdown pose on the current frame"); + ot->description= "Create a suitable breakdown pose on the current frame"; /* callbacks */ ot->exec= pose_slide_breakdown_exec; @@ -1233,18 +1231,18 @@ static int pose_propagate_exec (bContext *C, wmOperator *op) void POSE_OT_propagate (wmOperatorType *ot) { static EnumPropertyItem terminate_items[]= { - {POSE_PROPAGATE_SMART_HOLDS, "WHILE_HELD", 0, N_("While Held"), N_("Propagate pose to all keyframes after current frame that don't change (Default behaviour)")}, - {POSE_PROPAGATE_NEXT_KEY, "NEXT_KEY", 0, N_("To Next Keyframe"), N_("Propagate pose to first keyframe following the current frame only")}, - {POSE_PROPAGATE_LAST_KEY, "LAST_KEY", 0, N_("To Last Keyframe"), N_("Propagate pose to the last keyframe only (i.e. making action cyclic)")}, - {POSE_PROPAGATE_BEFORE_FRAME, "BEFORE_FRAME", 0, N_("Before Frame"), N_("Propagate pose to all keyframes between current frame and 'Frame' property")}, - {POSE_PROPAGATE_BEFORE_END, "BEFORE_END", 0, N_("Before Last Keyframe"), N_("Propagate pose to all keyframes from current frame until no more are found")}, - {POSE_PROPAGATE_SELECTED_MARKERS, "SELECTED_MARKERS", 0, N_("On Selected Markers"), N_("Propagate pose to all keyframes occurring on frames with Scene Markers after the current frame")}, + {POSE_PROPAGATE_SMART_HOLDS, "WHILE_HELD", 0, "While Held", "Propagate pose to all keyframes after current frame that don't change (Default behaviour)"}, + {POSE_PROPAGATE_NEXT_KEY, "NEXT_KEY", 0, "To Next Keyframe", "Propagate pose to first keyframe following the current frame only"}, + {POSE_PROPAGATE_LAST_KEY, "LAST_KEY", 0, "To Last Keyframe", "Propagate pose to the last keyframe only (i.e. making action cyclic)"}, + {POSE_PROPAGATE_BEFORE_FRAME, "BEFORE_FRAME", 0, "Before Frame", "Propagate pose to all keyframes between current frame and 'Frame' property"}, + {POSE_PROPAGATE_BEFORE_END, "BEFORE_END", 0, "Before Last Keyframe", "Propagate pose to all keyframes from current frame until no more are found"}, + {POSE_PROPAGATE_SELECTED_MARKERS, "SELECTED_MARKERS", 0, "On Selected Markers", "Propagate pose to all keyframes occurring on frames with Scene Markers after the current frame"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Propagate Pose"); + ot->name= "Propagate Pose"; ot->idname= "POSE_OT_propagate"; - ot->description= _("Copy selected aspects of the current pose to subsequent poses already keyframed"); + ot->description= "Copy selected aspects of the current pose to subsequent poses already keyframed"; /* callbacks */ ot->exec= pose_propagate_exec; @@ -1255,8 +1253,8 @@ void POSE_OT_propagate (wmOperatorType *ot) /* properties */ // TODO: add "fade out" control for tapering off amount of propagation as time goes by? - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(terminate_items), POSE_PROPAGATE_SMART_HOLDS, _("Terminate Mode"), _("Method used to determine when to stop propagating pose to keyframes")); - RNA_def_float(ot->srna, "end_frame", 250.0, FLT_MIN, FLT_MAX, _("End Frame"), _("Frame to stop propagating frames to (for 'Before Frame' mode)"), 1.0, 250.0); + ot->prop= RNA_def_enum(ot->srna, "mode", terminate_items, POSE_PROPAGATE_SMART_HOLDS, "Terminate Mode", "Method used to determine when to stop propagating pose to keyframes"); + RNA_def_float(ot->srna, "end_frame", 250.0, FLT_MIN, FLT_MAX, "End Frame", "Frame to stop propagating frames to (for 'Before Frame' mode)", 1.0, 250.0); } /* **************************************************** */ diff --git a/source/blender/editors/armature/poselib.c b/source/blender/editors/armature/poselib.c index 61435602446..81da047df36 100644 --- a/source/blender/editors/armature/poselib.c +++ b/source/blender/editors/armature/poselib.c @@ -234,9 +234,9 @@ static int poselib_new_exec (bContext *C, wmOperator *UNUSED(op)) void POSELIB_OT_new (wmOperatorType *ot) { /* identifiers */ - ot->name = _("New Pose Library"); + ot->name = "New Pose Library"; ot->idname = "POSELIB_OT_new"; - ot->description = _("Add New Pose Library to active Object"); + ot->description = "Add New Pose Library to active Object"; /* callbacks */ ot->exec = poselib_new_exec; @@ -269,9 +269,9 @@ static int poselib_unlink_exec (bContext *C, wmOperator *UNUSED(op)) void POSELIB_OT_unlink (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Unlink Pose Library"); + ot->name = "Unlink Pose Library"; ot->idname = "POSELIB_OT_unlink"; - ot->description = _("Remove Pose Library from active Object"); + ot->description = "Remove Pose Library from active Object"; /* callbacks */ ot->exec = poselib_unlink_exec; @@ -355,9 +355,9 @@ static int poselib_sanitise_exec (bContext *C, wmOperator *op) void POSELIB_OT_action_sanitise (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Sanitise Pose Library Action"); + ot->name = "Sanitise Pose Library Action"; ot->idname = "POSELIB_OT_action_sanitise"; - ot->description = _("Make action suitable for use as a Pose Library"); + ot->description = "Make action suitable for use as a Pose Library"; /* callbacks */ ot->exec = poselib_sanitise_exec; @@ -481,9 +481,9 @@ static int poselib_add_exec (bContext *C, wmOperator *op) void POSELIB_OT_pose_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("PoseLib Add Pose"); + ot->name= "PoseLib Add Pose"; ot->idname= "POSELIB_OT_pose_add"; - ot->description= _("Add the current Pose to the active Pose Library"); + ot->description= "Add the current Pose to the active Pose Library"; /* api callbacks */ ot->invoke= poselib_add_menu_invoke; @@ -494,8 +494,8 @@ void POSELIB_OT_pose_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "frame", 1, 0, INT_MAX, _("Frame"), _("Frame to store pose on"), 0, INT_MAX); - RNA_def_string(ot->srna, "name", "Pose", 64, _("Pose Name"), _("Name of newly added Pose")); + RNA_def_int(ot->srna, "frame", 1, 0, INT_MAX, "Frame", "Frame to store pose on", 0, INT_MAX); + RNA_def_string(ot->srna, "name", "Pose", 64, "Pose Name", "Name of newly added Pose"); } /* ----- */ @@ -587,9 +587,9 @@ void POSELIB_OT_pose_remove (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("PoseLib Remove Pose"); + ot->name= "PoseLib Remove Pose"; ot->idname= "POSELIB_OT_pose_remove"; - ot->description= _("Remove nth pose from the active Pose Library"); + ot->description= "Remove nth pose from the active Pose Library"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -600,7 +600,7 @@ void POSELIB_OT_pose_remove (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "pose", DummyRNA_DEFAULT_items, 0, _("Pose"), _("The pose to remove")); + prop= RNA_def_enum(ot->srna, "pose", DummyRNA_DEFAULT_items, 0, "Pose", "The pose to remove"); RNA_def_enum_funcs(prop, poselib_stored_pose_itemf); ot->prop= prop; } @@ -677,9 +677,9 @@ void POSELIB_OT_pose_rename (wmOperatorType *ot) }; /* identifiers */ - ot->name= _("PoseLib Rename Pose"); + ot->name= "PoseLib Rename Pose"; ot->idname= "POSELIB_OT_pose_rename"; - ot->description= _("Rename specified pose from the active Pose Library"); + ot->description= "Rename specified pose from the active Pose Library"; /* api callbacks */ ot->invoke= poselib_rename_invoke; @@ -1604,9 +1604,9 @@ static int poselib_preview_exec (bContext *C, wmOperator *op) void POSELIB_OT_browse_interactive (wmOperatorType *ot) { /* identifiers */ - ot->name= _("PoseLib Browse Poses"); + ot->name= "PoseLib Browse Poses"; ot->idname= "POSELIB_OT_browse_interactive"; - ot->description= _("Interactively browse poses in 3D-View"); + ot->description= "Interactively browse poses in 3D-View"; /* callbacks */ ot->invoke= poselib_preview_invoke; @@ -1620,7 +1620,7 @@ void POSELIB_OT_browse_interactive (wmOperatorType *ot) /* properties */ // TODO: make the pose_index into a proper enum instead of a cryptic int... - ot->prop= RNA_def_int(ot->srna, "pose_index", -1, -2, INT_MAX, _("Pose"), _("Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose)"), 0, INT_MAX); + ot->prop= RNA_def_int(ot->srna, "pose_index", -1, -2, INT_MAX, "Pose", "Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose)", 0, INT_MAX); // XXX: percentage vs factor? /* not used yet */ @@ -1630,9 +1630,9 @@ void POSELIB_OT_browse_interactive (wmOperatorType *ot) void POSELIB_OT_apply_pose (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Apply Pose Library Pose"); + ot->name = "Apply Pose Library Pose"; ot->idname = "POSELIB_OT_apply_pose"; - ot->description = _("Apply specified Pose Library pose to the rig"); + ot->description = "Apply specified Pose Library pose to the rig"; /* callbacks */ ot->exec= poselib_preview_exec; @@ -1643,5 +1643,5 @@ void POSELIB_OT_apply_pose (wmOperatorType *ot) /* properties */ // TODO: make the pose_index into a proper enum instead of a cryptic int... - ot->prop= RNA_def_int(ot->srna, "pose_index", -1, -2, INT_MAX, _("Pose"), _("Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose)"), 0, INT_MAX); + ot->prop= RNA_def_int(ot->srna, "pose_index", -1, -2, INT_MAX, "Pose", "Index of the pose to apply (-2 for no change to pose, -1 for poselib active pose)", 0, INT_MAX); } diff --git a/source/blender/editors/armature/poseobject.c b/source/blender/editors/armature/poseobject.c index 1c4740a7c4d..83285d3634a 100644 --- a/source/blender/editors/armature/poseobject.c +++ b/source/blender/editors/armature/poseobject.c @@ -41,8 +41,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_armature_types.h" #include "DNA_constraint_types.h" @@ -237,9 +235,9 @@ static int pose_calculate_paths_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_paths_calculate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Calculate Bone Paths"); + ot->name= "Calculate Bone Paths"; ot->idname= "POSE_OT_paths_calculate"; - ot->description= _("Calculate paths for the selected bones"); + ot->description= "Calculate paths for the selected bones"; /* api callbacks */ ot->exec= pose_calculate_paths_exec; @@ -305,9 +303,9 @@ static int pose_clear_paths_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_paths_clear (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Bone Paths"); + ot->name= "Clear Bone Paths"; ot->idname= "POSE_OT_paths_clear"; - ot->description= _("Clear path caches for selected bones"); + ot->description= "Clear path caches for selected bones"; /* api callbacks */ ot->exec= pose_clear_paths_exec; @@ -365,9 +363,9 @@ static int pose_select_constraint_target_exec(bContext *C, wmOperator *UNUSED(op void POSE_OT_select_constraint_target(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Constraint Target"); + ot->name= "Select Constraint Target"; ot->idname= "POSE_OT_select_constraint_target"; - ot->description= _("Select bones used as targets for the currently selected bones"); + ot->description= "Select bones used as targets for the currently selected bones"; /* api callbacks */ ot->exec= pose_select_constraint_target_exec; @@ -436,15 +434,15 @@ static int pose_select_hierarchy_exec(bContext *C, wmOperator *op) void POSE_OT_select_hierarchy(wmOperatorType *ot) { static EnumPropertyItem direction_items[]= { - {BONE_SELECT_PARENT, "PARENT", 0, N_("Select Parent"), ""}, - {BONE_SELECT_CHILD, "CHILD", 0, N_("Select Child"), ""}, + {BONE_SELECT_PARENT, "PARENT", 0, "Select Parent", ""}, + {BONE_SELECT_CHILD, "CHILD", 0, "Select Child", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Select Hierarchy"); + ot->name= "Select Hierarchy"; ot->idname= "POSE_OT_select_hierarchy"; - ot->description= _("Select immediate parent/children of selected bones"); + ot->description= "Select immediate parent/children of selected bones"; /* api callbacks */ ot->exec= pose_select_hierarchy_exec; @@ -454,8 +452,8 @@ void POSE_OT_select_hierarchy(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(direction_items), BONE_SELECT_PARENT, _("Direction"), ""); - RNA_def_boolean(ot->srna, "extend", 0, _("Add to Selection"), ""); + ot->prop= RNA_def_enum(ot->srna, "direction", direction_items, BONE_SELECT_PARENT, "Direction", ""); + RNA_def_boolean(ot->srna, "extend", 0, "Add to Selection", ""); } @@ -655,15 +653,15 @@ static int pose_select_grouped_exec (bContext *C, wmOperator *op) void POSE_OT_select_grouped (wmOperatorType *ot) { static EnumPropertyItem prop_select_grouped_types[] = { - {0, "LAYER", 0, N_("Layer"), N_("Shared layers")}, - {1, "GROUP", 0, N_("Group"), N_("Shared group")}, - {2, "KEYINGSET", 0, N_("Keying Set"), N_("All bones affected by active Keying Set")}, + {0, "LAYER", 0, "Layer", "Shared layers"}, + {1, "GROUP", 0, "Group", "Shared group"}, + {2, "KEYINGSET", 0, "Keying Set", "All bones affected by active Keying Set"}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Select Grouped"); - ot->description = _("Select all visible bones grouped by similar properties"); + ot->name= "Select Grouped"; + ot->description = "Select all visible bones grouped by similar properties"; ot->idname= "POSE_OT_select_grouped"; /* api callbacks */ @@ -675,8 +673,8 @@ void POSE_OT_select_grouped (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_select_grouped_types), 0, _("Type"), ""); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); + ot->prop= RNA_def_enum(ot->srna, "type", prop_select_grouped_types, 0, "Type", ""); } @@ -722,9 +720,9 @@ static int pose_bone_flip_active_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_select_flip_active(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Selected Active Bone"); + ot->name= "Flip Selected Active Bone"; ot->idname= "POSE_OT_select_flip_active"; - ot->description= _("Activate the bone with a flipped name."); + ot->description= "Activate the bone with a flipped name."; /* api callbacks */ ot->exec= pose_bone_flip_active_exec; @@ -1130,9 +1128,9 @@ static int pose_copy_exec (bContext *C, wmOperator *op) void POSE_OT_copy (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Pose"); + ot->name= "Copy Pose"; ot->idname= "POSE_OT_copy"; - ot->description= _("Copies the current pose of the selected bones to copy/paste buffer"); + ot->description= "Copies the current pose of the selected bones to copy/paste buffer"; /* api callbacks */ ot->exec= pose_copy_exec; @@ -1217,9 +1215,9 @@ static int pose_paste_exec (bContext *C, wmOperator *op) void POSE_OT_paste (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Pose"); + ot->name= "Paste Pose"; ot->idname= "POSE_OT_paste"; - ot->description= _("Pastes the stored pose on to the current pose"); + ot->description= "Pastes the stored pose on to the current pose"; /* api callbacks */ ot->exec= pose_paste_exec; @@ -1229,8 +1227,8 @@ void POSE_OT_paste (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "flipped", 0, _("Flipped on X-Axis"), _("Paste the stored pose flipped on to current pose")); - RNA_def_boolean(ot->srna, "selected_mask", 1, _("On Selected Only"), _("Only paste the stored pose on to selected bones in the current pose")); + RNA_def_boolean(ot->srna, "flipped", 0, "Flipped on X-Axis", "Paste the stored pose flipped on to current pose"); + RNA_def_boolean(ot->srna, "selected_mask", 1, "On Selected Only", "Only paste the stored pose on to selected bones in the current pose"); } /* ********************************************** */ @@ -1263,9 +1261,9 @@ static int pose_group_add_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_group_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Bone Group"); + ot->name= "Add Bone Group"; ot->idname= "POSE_OT_group_add"; - ot->description= _("Add a new bone group"); + ot->description= "Add a new bone group"; /* api callbacks */ ot->exec= pose_group_add_exec; @@ -1303,9 +1301,9 @@ static int pose_group_remove_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_group_remove (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Bone Group"); + ot->name= "Remove Bone Group"; ot->idname= "POSE_OT_group_remove"; - ot->description= _("Removes the active bone group"); + ot->description= "Removes the active bone group"; /* api callbacks */ ot->exec= pose_group_remove_exec; @@ -1418,9 +1416,9 @@ static int pose_group_assign_exec (bContext *C, wmOperator *op) void POSE_OT_group_assign (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Selected to Bone Group"); + ot->name= "Add Selected to Bone Group"; ot->idname= "POSE_OT_group_assign"; - ot->description= _("Add selected bones to the chosen bone group"); + ot->description= "Add selected bones to the chosen bone group"; /* api callbacks */ ot->invoke= pose_groups_menu_invoke; @@ -1431,7 +1429,7 @@ void POSE_OT_group_assign (wmOperatorType *ot) ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "type", 0, 0, 10, _("Bone Group Index"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "type", 0, 0, 10, "Bone Group Index", "", 0, INT_MAX); } @@ -1474,9 +1472,9 @@ static int pose_group_unassign_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_group_unassign (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Selected from Bone Groups"); + ot->name= "Remove Selected from Bone Groups"; ot->idname= "POSE_OT_group_unassign"; - ot->description= _("Remove selected bones from all bone groups"); + ot->description= "Remove selected bones from all bone groups"; /* api callbacks */ ot->exec= pose_group_unassign_exec; @@ -1697,9 +1695,9 @@ static int pose_group_select_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_group_select (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Bones of Bone Group"); + ot->name= "Select Bones of Bone Group"; ot->idname= "POSE_OT_group_select"; - ot->description= _("Select bones in active Bone Group"); + ot->description= "Select bones in active Bone Group"; /* api callbacks */ ot->exec= pose_group_select_exec; @@ -1735,9 +1733,9 @@ static int pose_group_deselect_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_group_deselect (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Deselect Bone Group"); + ot->name= "Deselect Bone Group"; ot->idname= "POSE_OT_group_deselect"; - ot->description= _("Deselect bones of active Bone Group"); + ot->description= "Deselect bones of active Bone Group"; /* api callbacks */ ot->exec= pose_group_deselect_exec; @@ -1780,9 +1778,9 @@ static int pose_flip_names_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_flip_names (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Names"); + ot->name= "Flip Names"; ot->idname= "POSE_OT_flip_names"; - ot->description= _("Flips (and corrects) the axis suffixes of the the names of selected bones"); + ot->description= "Flips (and corrects) the axis suffixes of the the names of selected bones"; /* api callbacks */ ot->exec= pose_flip_names_exec; @@ -1827,15 +1825,15 @@ static int pose_autoside_names_exec (bContext *C, wmOperator *op) void POSE_OT_autoside_names (wmOperatorType *ot) { static EnumPropertyItem axis_items[]= { - {0, "XAXIS", 0, N_("X-Axis"), N_("Left/Right")}, - {1, "YAXIS", 0, N_("Y-Axis"), N_("Front/Back")}, - {2, "ZAXIS", 0, N_("Z-Axis"), N_("Top/Bottom")}, + {0, "XAXIS", 0, "X-Axis", "Left/Right"}, + {1, "YAXIS", 0, "Y-Axis", "Front/Back"}, + {2, "ZAXIS", 0, "Z-Axis", "Top/Bottom"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("AutoName by Axis"); + ot->name= "AutoName by Axis"; ot->idname= "POSE_OT_autoside_names"; - ot->description= _("Automatically renames the selected bones according to which side of the target axis they fall on"); + ot->description= "Automatically renames the selected bones according to which side of the target axis they fall on"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1846,7 +1844,7 @@ void POSE_OT_autoside_names (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* settings */ - ot->prop= RNA_def_enum(ot->srna, "axis", RNA_enum_items_gettexted(axis_items), 0, _("Axis"), _("Axis tag names with.")); + ot->prop= RNA_def_enum(ot->srna, "axis", axis_items, 0, "Axis", "Axis tag names with."); } /* ********************************************** */ @@ -1932,9 +1930,9 @@ static int pose_armature_layers_showall_exec (bContext *C, wmOperator *op) void ARMATURE_OT_layers_show_all (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Show All Layers"); + ot->name= "Show All Layers"; ot->idname= "ARMATURE_OT_layers_show_all"; - ot->description= _("Make all armature layers visible"); + ot->description= "Make all armature layers visible"; /* callbacks */ ot->exec= pose_armature_layers_showall_exec; @@ -1944,7 +1942,7 @@ void ARMATURE_OT_layers_show_all (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop = RNA_def_boolean(ot->srna, "all", 1, _("All Layers"), _("Enable all layers or just the first 16 (top row)")); + ot->prop = RNA_def_boolean(ot->srna, "all", 1, "All Layers", "Enable all layers or just the first 16 (top row)"); } /* ------------------- */ @@ -1998,9 +1996,9 @@ static int pose_armature_layers_exec (bContext *C, wmOperator *op) void POSE_OT_armature_layers (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Armature Layers"); + ot->name= "Change Armature Layers"; ot->idname= "POSE_OT_armature_layers"; - ot->description= _("Change the visible armature layers"); + ot->description= "Change the visible armature layers"; /* callbacks */ ot->invoke= pose_armature_layers_invoke; @@ -2011,15 +2009,15 @@ void POSE_OT_armature_layers (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, _("Layer"), _("Armature layers to make visible")); + RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, "Layer", "Armature layers to make visible"); } void ARMATURE_OT_armature_layers (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Armature Layers"); + ot->name= "Change Armature Layers"; ot->idname= "ARMATURE_OT_armature_layers"; - ot->description= _("Change the visible armature layers"); + ot->description= "Change the visible armature layers"; /* callbacks */ ot->invoke= pose_armature_layers_invoke; @@ -2030,7 +2028,7 @@ void ARMATURE_OT_armature_layers (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, _("Layer"), _("Armature layers to make visible")); + RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, "Layer", "Armature layers to make visible"); } /* ------------------- */ @@ -2092,9 +2090,9 @@ static int pose_bone_layers_exec (bContext *C, wmOperator *op) void POSE_OT_bone_layers (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Bone Layers"); + ot->name= "Change Bone Layers"; ot->idname= "POSE_OT_bone_layers"; - ot->description= _("Change the layers that the selected bones belong to"); + ot->description= "Change the layers that the selected bones belong to"; /* callbacks */ ot->invoke= pose_bone_layers_invoke; @@ -2105,7 +2103,7 @@ void POSE_OT_bone_layers (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, _("Layer"), _("Armature layers that bone belongs to")); + RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, "Layer", "Armature layers that bone belongs to"); } /* ------------------- */ @@ -2164,9 +2162,9 @@ static int armature_bone_layers_exec (bContext *C, wmOperator *op) void ARMATURE_OT_bone_layers (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Bone Layers"); + ot->name= "Change Bone Layers"; ot->idname= "ARMATURE_OT_bone_layers"; - ot->description= _("Change the layers that the selected bones belong to"); + ot->description= "Change the layers that the selected bones belong to"; /* callbacks */ ot->invoke= armature_bone_layers_invoke; @@ -2177,7 +2175,7 @@ void ARMATURE_OT_bone_layers (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, _("Layer"), _("Armature layers that bone belongs to")); + RNA_def_boolean_layer_member(ot->srna, "layers", 32, NULL, "Layer", "Armature layers that bone belongs to"); } /* ********************************************** */ @@ -2233,9 +2231,9 @@ static int pose_flip_quats_exec (bContext *C, wmOperator *UNUSED(op)) void POSE_OT_quaternions_flip (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Flip Quats"); + ot->name = "Flip Quats"; ot->idname= "POSE_OT_quaternions_flip"; - ot->description= _("Flip quaternion values to achieve desired rotations, while maintaining the same orientations"); + ot->description= "Flip quaternion values to achieve desired rotations, while maintaining the same orientations"; /* callbacks */ ot->exec= pose_flip_quats_exec; diff --git a/source/blender/editors/curve/CMakeLists.txt b/source/blender/editors/curve/CMakeLists.txt index 6e975e20cd7..9bad02eca1f 100644 --- a/source/blender/editors/curve/CMakeLists.txt +++ b/source/blender/editors/curve/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/curve/SConscript b/source/blender/editors/curve/SConscript index c23773f7fb0..efb56ce5466 100644 --- a/source/blender/editors/curve/SConscript +++ b/source/blender/editors/curve/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../gpu ../../blenloader' incs += ' ../../makesrna ../../render/extern/include #/intern/elbeem/extern' diff --git a/source/blender/editors/curve/editcurve.c b/source/blender/editors/curve/editcurve.c index facd4e8a4a3..b35085ff64d 100644 --- a/source/blender/editors/curve/editcurve.c +++ b/source/blender/editors/curve/editcurve.c @@ -56,8 +56,6 @@ #include "BLI_utildefines.h" #include "BLI_ghash.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_curve.h" #include "BKE_depsgraph.h" @@ -1404,7 +1402,7 @@ static int separate_exec(bContext *C, wmOperator *op) void CURVE_OT_separate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Separate"); + ot->name= "Separate"; ot->idname= "CURVE_OT_separate"; /* api callbacks */ @@ -2012,8 +2010,8 @@ static int switch_direction_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_switch_direction(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Switch Direction"); - ot->description= _("Switch direction of selected splines"); + ot->name= "Switch Direction"; + ot->description= "Switch direction of selected splines"; ot->idname= "CURVE_OT_switch_direction"; /* api callbacks */ @@ -2060,8 +2058,8 @@ static int set_goal_weight_exec(bContext *C, wmOperator *op) void CURVE_OT_spline_weight_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Goal Weight"); - ot->description= _("Set softbody goal weight for selected points"); + ot->name= "Set Goal Weight"; + ot->description= "Set softbody goal weight for selected points"; ot->idname= "CURVE_OT_spline_weight_set"; /* api callbacks */ @@ -2073,7 +2071,7 @@ void CURVE_OT_spline_weight_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_factor(ot->srna, "weight", 1.0f, 0.0f, 1.0f, _("Weight"), "", 0.0f, 1.0f); + RNA_def_float_factor(ot->srna, "weight", 1.0f, 0.0f, 1.0f, "Weight", "", 0.0f, 1.0f); } /******************* set radius operator ******************/ @@ -2112,8 +2110,8 @@ static int set_radius_exec(bContext *C, wmOperator *op) void CURVE_OT_radius_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Curve Radius"); - ot->description= _("Set per-point radius which is used for bevel tapering"); + ot->name= "Set Curve Radius"; + ot->description= "Set per-point radius which is used for bevel tapering"; ot->idname= "CURVE_OT_radius_set"; /* api callbacks */ @@ -2125,7 +2123,7 @@ void CURVE_OT_radius_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float(ot->srna, "radius", 1.0f, 0.0f, FLT_MAX, _("Radius"), "", 0.0001f, 10.0f); + RNA_def_float(ot->srna, "radius", 1.0f, 0.0f, FLT_MAX, "Radius", "", 0.0001f, 10.0f); } /********************* smooth operator ********************/ @@ -2188,8 +2186,8 @@ static int smooth_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_smooth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth"); - ot->description= _("Flatten angles of selected points"); + ot->name= "Smooth"; + ot->description= "Flatten angles of selected points"; ot->idname= "CURVE_OT_smooth"; /* api callbacks */ @@ -2354,8 +2352,8 @@ static int smooth_radius_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_smooth_radius(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth Curve Radius"); - ot->description= _("Flatten radiuses of selected points"); + ot->name= "Smooth Curve Radius"; + ot->description= "Flatten radiuses of selected points"; ot->idname= "CURVE_OT_smooth_radius"; /* api clastbacks */ @@ -2508,7 +2506,7 @@ static int de_select_first_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_de_select_first(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect First"); + ot->name= "Select or Deselect First"; ot->idname= "CURVE_OT_de_select_first"; /* api cfirstbacks */ @@ -2532,7 +2530,7 @@ static int de_select_last_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_de_select_last(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect Last"); + ot->name= "Select or Deselect Last"; ot->idname= "CURVE_OT_de_select_last"; /* api clastbacks */ @@ -2610,7 +2608,7 @@ static int de_select_all_exec(bContext *C, wmOperator *op) void CURVE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); + ot->name= "Select or Deselect All"; ot->idname= "CURVE_OT_select_all"; /* api callbacks */ @@ -2684,7 +2682,7 @@ static int hide_exec(bContext *C, wmOperator *op) void CURVE_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selected"); + ot->name= "Hide Selected"; ot->idname= "CURVE_OT_hide"; /* api callbacks */ @@ -2695,7 +2693,7 @@ void CURVE_OT_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } /********************** reveal operator *********************/ @@ -2744,7 +2742,7 @@ static int reveal_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal Hidden"); + ot->name= "Reveal Hidden"; ot->idname= "CURVE_OT_reveal"; /* api callbacks */ @@ -2802,7 +2800,7 @@ static int select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); + ot->name= "Select Inverse"; ot->idname= "CURVE_OT_select_inverse"; /* api callbacks */ @@ -3241,8 +3239,8 @@ static int subdivide_exec(bContext *C, wmOperator *op) void CURVE_OT_subdivide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Subdivide"); - ot->description= _("Subdivide selected segments"); + ot->name= "Subdivide"; + ot->description= "Subdivide selected segments"; ot->idname= "CURVE_OT_subdivide"; /* api callbacks */ @@ -3252,7 +3250,7 @@ void CURVE_OT_subdivide(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, _("Number of cuts"), "", 1, 10); + RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, "Number of cuts", "", 1, 10); } /******************** find nearest ************************/ @@ -3555,16 +3553,16 @@ static int set_spline_type_exec(bContext *C, wmOperator *op) void CURVE_OT_spline_type_set(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - {CU_POLY, "POLY", 0, N_("Poly"), ""}, - {CU_BEZIER, "BEZIER", 0, N_("Bezier"), ""}, -// {CU_CARDINAL, "CARDINAL", 0, N_("Cardinal"), ""}, -// {CU_BSPLINE, "B_SPLINE", 0, N_("B-Spline"), ""}, - {CU_NURBS, "NURBS", 0, N_("NURBS"), ""}, + {CU_POLY, "POLY", 0, "Poly", ""}, + {CU_BEZIER, "BEZIER", 0, "Bezier", ""}, +// {CU_CARDINAL, "CARDINAL", 0, "Cardinal", ""}, +// {CU_BSPLINE, "B_SPLINE", 0, "B-Spline", ""}, + {CU_NURBS, "NURBS", 0, "NURBS", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Set Spline Type"); - ot->description = _("Set type of active spline"); + ot->name= "Set Spline Type"; + ot->description = "Set type of active spline"; ot->idname= "CURVE_OT_spline_type_set"; /* api callbacks */ @@ -3576,7 +3574,7 @@ void CURVE_OT_spline_type_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), CU_POLY, _("Type"), _("Spline type")); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, CU_POLY, "Type", "Spline type"); } /***************** set handle type operator *******************/ @@ -3598,16 +3596,16 @@ void CURVE_OT_handle_type_set(wmOperatorType *ot) { /* keep in sync with graphkeys_handle_type_items */ static EnumPropertyItem editcurve_handle_type_items[]= { - {HD_AUTO, "AUTOMATIC", 0, N_("Automatic"), ""}, - {HD_VECT, "VECTOR", 0, N_("Vector"), ""}, - {5, "ALIGNED", 0, N_("Aligned"), ""}, - {6, "FREE_ALIGN", 0, N_("Free"), ""}, - {3, "TOGGLE_FREE_ALIGN", 0, N_("Toggle Free/Align"), ""}, + {HD_AUTO, "AUTOMATIC", 0, "Automatic", ""}, + {HD_VECT, "VECTOR", 0, "Vector", ""}, + {5, "ALIGNED", 0, "Aligned", ""}, + {6, "FREE_ALIGN", 0, "Free", ""}, + {3, "TOGGLE_FREE_ALIGN", 0, "Toggle Free/Align", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Set Handle Type"); - ot->description = _("Set type of handles for selected control points"); + ot->name= "Set Handle Type"; + ot->description = "Set type of handles for selected control points"; ot->idname= "CURVE_OT_handle_type_set"; /* api callbacks */ @@ -3619,7 +3617,7 @@ void CURVE_OT_handle_type_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(editcurve_handle_type_items), 1, _("Type"), _("Spline type")); + ot->prop= RNA_def_enum(ot->srna, "type", editcurve_handle_type_items, 1, "Type", "Spline type"); } /***************** make segment operator **********************/ @@ -4141,7 +4139,7 @@ static int make_segment_exec(bContext *C, wmOperator *op) void CURVE_OT_make_segment(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Segment"); + ot->name= "Make Segment"; ot->idname= "CURVE_OT_make_segment"; /* api callbacks */ @@ -4371,7 +4369,7 @@ static int spin_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void CURVE_OT_spin(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Spin"); + ot->name= "Spin"; ot->idname= "CURVE_OT_spin"; /* api callbacks */ @@ -4382,8 +4380,8 @@ void CURVE_OT_spin(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, _("Center"), _("Center in global view space"), -FLT_MAX, FLT_MAX); - RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, _("Axis"), _("Axis in global view space"), -FLT_MAX, FLT_MAX); + RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, "Center", "Center in global view space", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, "Axis", "Axis in global view space", -FLT_MAX, FLT_MAX); } /***************** add vertex operator **********************/ @@ -4682,7 +4680,7 @@ static int add_vertex_invoke(bContext *C, wmOperator *op, wmEvent *event) void CURVE_OT_vertex_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Vertex"); + ot->name= "Add Vertex"; ot->idname= "CURVE_OT_vertex_add"; /* api callbacks */ @@ -4694,7 +4692,7 @@ void CURVE_OT_vertex_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_vector_xyz(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, _("Location"), _("Location to add new vertex at."), -1e4, 1e4); + RNA_def_float_vector_xyz(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, "Location", "Location to add new vertex at.", -1e4, 1e4); } /***************** extrude operator **********************/ @@ -4742,8 +4740,8 @@ static int extrude_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void CURVE_OT_extrude(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Extrude"); - ot->description = _("Extrude selected control point(s) and move"); + ot->name= "Extrude"; + ot->description = "Extrude selected control point(s) and move"; ot->idname= "CURVE_OT_extrude"; /* api callbacks */ @@ -4755,7 +4753,7 @@ void CURVE_OT_extrude(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /***************** make cyclic operator **********************/ @@ -4866,13 +4864,13 @@ static int toggle_cyclic_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(eve void CURVE_OT_cyclic_toggle(wmOperatorType *ot) { static EnumPropertyItem direction_items[]= { - {0, "CYCLIC_U", 0, N_("Cyclic U"), ""}, - {1, "CYCLIC_V", 0, N_("Cyclic V"), ""}, + {0, "CYCLIC_U", 0, "Cyclic U", ""}, + {1, "CYCLIC_V", 0, "Cyclic V", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Toggle Cyclic"); - ot->description = _("Make active spline closed/opened loop"); + ot->name= "Toggle Cyclic"; + ot->description = "Make active spline closed/opened loop"; ot->idname= "CURVE_OT_cyclic_toggle"; /* api callbacks */ @@ -4884,7 +4882,7 @@ void CURVE_OT_cyclic_toggle(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "direction", direction_items, 0, _("Direction"), _("Direction to make surface cyclic in.")); + RNA_def_enum(ot->srna, "direction", direction_items, 0, "Direction", "Direction to make surface cyclic in."); } /***************** select linked operator ******************/ @@ -4948,7 +4946,7 @@ static int select_linked_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(eve void CURVE_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked All"); + ot->name= "Select Linked All"; ot->idname= "CURVE_OT_select_linked"; /* api callbacks */ @@ -5008,7 +5006,7 @@ static int select_linked_pick_invoke(bContext *C, wmOperator *op, wmEvent *event void CURVE_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked"); + ot->name= "Select Linked"; ot->idname= "CURVE_OT_select_linked_pick"; /* api callbacks */ @@ -5019,7 +5017,7 @@ void CURVE_OT_select_linked_pick(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "deselect", 0, _("Deselect"), _("Deselect linked control points rather than selecting them.")); + RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", "Deselect linked control points rather than selecting them."); } /***************** select row operator **********************/ @@ -5086,7 +5084,7 @@ static int select_row_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_row(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Control Point Row"); + ot->name= "Select Control Point Row"; ot->idname= "CURVE_OT_select_row"; /* api callbacks */ @@ -5113,7 +5111,7 @@ static int select_next_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_next(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Next"); + ot->name= "Select Next"; ot->idname= "CURVE_OT_select_next"; /* api callbacks */ @@ -5140,7 +5138,7 @@ static int select_previous_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_previous(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Previous"); + ot->name= "Select Previous"; ot->idname= "CURVE_OT_select_previous"; /* api callbacks */ @@ -5227,7 +5225,7 @@ static int select_more_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_more(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select More"); + ot->name= "Select More"; ot->idname= "CURVE_OT_select_more"; /* api callbacks */ @@ -5388,7 +5386,7 @@ static int select_less_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_select_less(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Less"); + ot->name= "Select Less"; ot->idname= "CURVE_OT_select_less"; /* api callbacks */ @@ -5451,7 +5449,7 @@ static int select_random_exec(bContext *C, wmOperator *op) void CURVE_OT_select_random(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Random"); + ot->name= "Select Random"; ot->idname= "CURVE_OT_select_random"; /* api callbacks */ @@ -5462,8 +5460,8 @@ void CURVE_OT_select_random(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, _("Percent"), _("Percentage of elements to select randomly."), 0.f, 100.0f); - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend Selection"), _("Extend selection instead of deselecting everything first.")); + RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, "Percent", "Percentage of elements to select randomly.", 0.f, 100.0f); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend Selection", "Extend selection instead of deselecting everything first."); } /********************* every nth number of point *******************/ @@ -5576,7 +5574,7 @@ static int select_nth_exec(bContext *C, wmOperator *op) void CURVE_OT_select_nth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Nth"); + ot->name= "Select Nth"; ot->description= ""; ot->idname= "CURVE_OT_select_nth"; @@ -5587,7 +5585,7 @@ void CURVE_OT_select_nth(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "nth", 2, 2, 100, _("Nth Selection"), "", 1, INT_MAX); + RNA_def_int(ot->srna, "nth", 2, 2, 100, "Nth Selection", "", 1, INT_MAX); } /********************** add duplicate operator *********************/ @@ -5615,8 +5613,8 @@ static int duplicate_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void CURVE_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Curve"); - ot->description = _("Duplicate selected control points and segments between them"); + ot->name= "Duplicate Curve"; + ot->description = "Duplicate selected control points and segments between them"; ot->idname= "CURVE_OT_duplicate"; /* api callbacks */ @@ -5628,7 +5626,7 @@ void CURVE_OT_duplicate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /********************** delete operator *********************/ @@ -5975,14 +5973,14 @@ static int delete_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void CURVE_OT_delete(wmOperatorType *ot) { static EnumPropertyItem type_items[] = { - {0, "SELECTED", 0, N_("Select"), ""}, - {1, "SEGMENT", 0, N_("Segment"), ""}, - {2, "ALL", 0, N_("All"), ""}, + {0, "SELECTED", 0, "Select", ""}, + {1, "SEGMENT", 0, "Segment", ""}, + {2, "ALL", 0, "All", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Delete"); - ot->description = _("Delete selected control points or segments"); + ot->name= "Delete"; + ot->description = "Delete selected control points or segments"; ot->idname= "CURVE_OT_delete"; /* api callbacks */ @@ -5994,7 +5992,7 @@ void CURVE_OT_delete(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "type", type_items, 0, _("Type"), _("Which elements to delete.")); + RNA_def_enum(ot->srna, "type", type_items, 0, "Type", "Which elements to delete."); } /********************** shade smooth/flat operator *********************/ @@ -6025,7 +6023,7 @@ static int shade_smooth_exec(bContext *C, wmOperator *op) void CURVE_OT_shade_smooth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Smooth"); + ot->name= "Shade Smooth"; ot->idname= "CURVE_OT_shade_smooth"; /* api callbacks */ @@ -6039,7 +6037,7 @@ void CURVE_OT_shade_smooth(wmOperatorType *ot) void CURVE_OT_shade_flat(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Flat"); + ot->name= "Shade Flat"; ot->idname= "CURVE_OT_shade_flat"; /* api callbacks */ @@ -6621,8 +6619,8 @@ static int add_primitive_bezier_exec(bContext *C, wmOperator *op) void CURVE_OT_primitive_bezier_curve_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Bezier"); - ot->description= _("Construct a Bezier Curve"); + ot->name= "Add Bezier"; + ot->description= "Construct a Bezier Curve"; ot->idname= "CURVE_OT_primitive_bezier_curve_add"; /* api callbacks */ @@ -6644,8 +6642,8 @@ static int add_primitive_bezier_circle_exec(bContext *C, wmOperator *op) void CURVE_OT_primitive_bezier_circle_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Bezier Circle"); - ot->description= _("Construct a Bezier Circle"); + ot->name= "Add Bezier Circle"; + ot->description= "Construct a Bezier Circle"; ot->idname= "CURVE_OT_primitive_bezier_circle_add"; /* api callbacks */ @@ -6667,8 +6665,8 @@ static int add_primitive_nurbs_curve_exec(bContext *C, wmOperator *op) void CURVE_OT_primitive_nurbs_curve_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Nurbs Curve"); - ot->description= _("Construct a Nurbs Curve"); + ot->name= "Add Nurbs Curve"; + ot->description= "Construct a Nurbs Curve"; ot->idname= "CURVE_OT_primitive_nurbs_curve_add"; /* api callbacks */ @@ -6690,8 +6688,8 @@ static int add_primitive_nurbs_circle_exec(bContext *C, wmOperator *op) void CURVE_OT_primitive_nurbs_circle_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Nurbs Circle"); - ot->description= _("Construct a Nurbs Circle"); + ot->name= "Add Nurbs Circle"; + ot->description= "Construct a Nurbs Circle"; ot->idname= "CURVE_OT_primitive_nurbs_circle_add"; /* api callbacks */ @@ -6713,8 +6711,8 @@ static int add_primitive_curve_path_exec(bContext *C, wmOperator *op) void CURVE_OT_primitive_nurbs_path_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Path"); - ot->description= _("Construct a Path"); + ot->name= "Add Path"; + ot->description= "Construct a Path"; ot->idname= "CURVE_OT_primitive_nurbs_path_add"; /* api callbacks */ @@ -6737,8 +6735,8 @@ static int add_primitive_nurbs_surface_curve_exec(bContext *C, wmOperator *op) void SURFACE_OT_primitive_nurbs_surface_curve_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Curve"); - ot->description= _("Construct a Nurbs surface Curve"); + ot->name= "Add Surface Curve"; + ot->description= "Construct a Nurbs surface Curve"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_curve_add"; /* api callbacks */ @@ -6760,8 +6758,8 @@ static int add_primitive_nurbs_surface_circle_exec(bContext *C, wmOperator *op) void SURFACE_OT_primitive_nurbs_surface_circle_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Circle"); - ot->description= _("Construct a Nurbs surface Circle"); + ot->name= "Add Surface Circle"; + ot->description= "Construct a Nurbs surface Circle"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_circle_add"; /* api callbacks */ @@ -6783,8 +6781,8 @@ static int add_primitive_nurbs_surface_surface_exec(bContext *C, wmOperator *op) void SURFACE_OT_primitive_nurbs_surface_surface_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Patch"); - ot->description= _("Construct a Nurbs surface Patch"); + ot->name= "Add Surface Patch"; + ot->description= "Construct a Nurbs surface Patch"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_surface_add"; /* api callbacks */ @@ -6806,8 +6804,8 @@ static int add_primitive_nurbs_surface_cylinder_exec(bContext *C, wmOperator *op void SURFACE_OT_primitive_nurbs_surface_cylinder_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Cylinder"); - ot->description= _("Construct a Nurbs surface Cylinder"); + ot->name= "Add Surface Cylinder"; + ot->description= "Construct a Nurbs surface Cylinder"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_cylinder_add"; /* api callbacks */ @@ -6829,8 +6827,8 @@ static int add_primitive_nurbs_surface_sphere_exec(bContext *C, wmOperator *op) void SURFACE_OT_primitive_nurbs_surface_sphere_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Sphere"); - ot->description= _("Construct a Nurbs surface Sphere"); + ot->name= "Add Surface Sphere"; + ot->description= "Construct a Nurbs surface Sphere"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_sphere_add"; /* api callbacks */ @@ -6852,8 +6850,8 @@ static int add_primitive_nurbs_surface_torus_exec(bContext *C, wmOperator *op) void SURFACE_OT_primitive_nurbs_surface_torus_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Surface Torus"); - ot->description= _("Construct a Nurbs surface Torus"); + ot->name= "Add Surface Torus"; + ot->description= "Construct a Nurbs surface Torus"; ot->idname= "SURFACE_OT_primitive_nurbs_surface_torus_add"; /* api callbacks */ @@ -6907,7 +6905,7 @@ static int clear_tilt_exec(bContext *C, wmOperator *UNUSED(op)) void CURVE_OT_tilt_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Tilt"); + ot->name= "Clear Tilt"; ot->idname= "CURVE_OT_tilt_clear"; /* api callbacks */ diff --git a/source/blender/editors/curve/editfont.c b/source/blender/editors/curve/editfont.c index 0f6b3070008..6c95df53d39 100644 --- a/source/blender/editors/curve/editfont.c +++ b/source/blender/editors/curve/editfont.c @@ -47,8 +47,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_curve_types.h" #include "DNA_object_types.h" #include "DNA_vfont_types.h" @@ -317,8 +315,8 @@ static int insert_lorem_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_insert_lorem(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert Lorem"); - ot->description= _("Insert placeholder text"); + ot->name= "Insert Lorem"; + ot->description= "Insert placeholder text"; ot->idname= "FONT_OT_insert_lorem"; /* api callbacks */ @@ -405,8 +403,8 @@ static int paste_file_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event) void FONT_OT_file_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste File"); - ot->description= _("Paste contents from file"); + ot->name= "Paste File"; + ot->description= "Paste contents from file"; ot->idname= "FONT_OT_file_paste"; /* api callbacks */ @@ -454,8 +452,8 @@ static int paste_buffer_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_buffer_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Buffer"); - ot->description= _("Paste text from OS buffer"); + ot->name= "Paste Buffer"; + ot->description= "Paste text from OS buffer"; ot->idname= "FONT_OT_buffer_paste"; /* api callbacks */ @@ -612,10 +610,10 @@ static int kill_selection(Object *obedit, int ins) /* 1 == new character */ /******************* set style operator ********************/ static EnumPropertyItem style_items[]= { - {CU_CHINFO_BOLD, "BOLD", 0, N_("Bold"), ""}, - {CU_CHINFO_ITALIC, "ITALIC", 0, N_("Italic"), ""}, - {CU_CHINFO_UNDERLINE, "UNDERLINE", 0, N_("Underline"), ""}, - {CU_CHINFO_SMALLCAPS, "SMALL_CAPS", 0, N_("Small Caps"), ""}, + {CU_CHINFO_BOLD, "BOLD", 0, "Bold", ""}, + {CU_CHINFO_ITALIC, "ITALIC", 0, "Italic", ""}, + {CU_CHINFO_UNDERLINE, "UNDERLINE", 0, "Underline", ""}, + {CU_CHINFO_SMALLCAPS, "SMALL_CAPS", 0, "Small Caps", ""}, {0, NULL, 0, NULL, NULL}}; static int set_style(bContext *C, const int style, const int clear) @@ -652,8 +650,8 @@ static int set_style_exec(bContext *C, wmOperator *op) void FONT_OT_style_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Style"); - ot->description= _("Set font style"); + ot->name= "Set Style"; + ot->description= "Set font style"; ot->idname= "FONT_OT_style_set"; /* api callbacks */ @@ -664,8 +662,8 @@ void FONT_OT_style_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "style", RNA_enum_items_gettexted(style_items), CU_CHINFO_BOLD, _("Style"), _("Style to set selection to.")); - RNA_def_boolean(ot->srna, "clear", 0, _("Clear"), _("Clear style rather than setting it.")); + RNA_def_enum(ot->srna, "style", style_items, CU_CHINFO_BOLD, "Style", "Style to set selection to."); + RNA_def_boolean(ot->srna, "clear", 0, "Clear", "Clear style rather than setting it."); } /******************* toggle style operator ********************/ @@ -690,8 +688,8 @@ static int toggle_style_exec(bContext *C, wmOperator *op) void FONT_OT_style_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Style"); - ot->description= _("Toggle font style"); + ot->name= "Toggle Style"; + ot->description= "Toggle font style"; ot->idname= "FONT_OT_style_toggle"; /* api callbacks */ @@ -702,7 +700,7 @@ void FONT_OT_style_toggle(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "style", style_items, CU_CHINFO_BOLD, _("Style"), _("Style to set selection to.")); + RNA_def_enum(ot->srna, "style", style_items, CU_CHINFO_BOLD, "Style", "Style to set selection to."); } /******************* copy text operator ********************/ @@ -733,8 +731,8 @@ static int copy_text_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_text_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Text"); - ot->description= _("Copy selected text to clipboard"); + ot->name= "Copy Text"; + ot->description= "Copy selected text to clipboard"; ot->idname= "FONT_OT_text_copy"; /* api callbacks */ @@ -764,8 +762,8 @@ static int cut_text_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_text_cut(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cut Text"); - ot->description= _("Cut selected text to clipboard"); + ot->name= "Cut Text"; + ot->description= "Cut selected text to clipboard"; ot->idname= "FONT_OT_text_cut"; /* api callbacks */ @@ -822,8 +820,8 @@ static int paste_text_exec(bContext *C, wmOperator *op) void FONT_OT_text_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Text"); - ot->description= _("Paste text from clipboard"); + ot->name= "Paste Text"; + ot->description= "Paste text from clipboard"; ot->idname= "FONT_OT_text_paste"; /* api callbacks */ @@ -837,16 +835,16 @@ void FONT_OT_text_paste(wmOperatorType *ot) /************************ move operator ************************/ static EnumPropertyItem move_type_items[]= { - {LINE_BEGIN, "LINE_BEGIN", 0, N_("Line Begin"), ""}, - {LINE_END, "LINE_END", 0, N_("Line End"), ""}, - {PREV_CHAR, "PREVIOUS_CHARACTER", 0, N_("Previous Character"), ""}, - {NEXT_CHAR, "NEXT_CHARACTER", 0, N_("Next Character"), ""}, - {PREV_WORD, "PREVIOUS_WORD", 0, N_("Previous Word"), ""}, - {NEXT_WORD, "NEXT_WORD", 0, N_("Next Word"), ""}, - {PREV_LINE, "PREVIOUS_LINE", 0, N_("Previous Line"), ""}, - {NEXT_LINE, "NEXT_LINE", 0, N_("Next Line"), ""}, - {PREV_PAGE, "PREVIOUS_PAGE", 0, N_("Previous Page"), ""}, - {NEXT_PAGE, "NEXT_PAGE", 0, N_("Next Page"), ""}, + {LINE_BEGIN, "LINE_BEGIN", 0, "Line Begin", ""}, + {LINE_END, "LINE_END", 0, "Line End", ""}, + {PREV_CHAR, "PREVIOUS_CHARACTER", 0, "Previous Character", ""}, + {NEXT_CHAR, "NEXT_CHARACTER", 0, "Next Character", ""}, + {PREV_WORD, "PREVIOUS_WORD", 0, "Previous Word", ""}, + {NEXT_WORD, "NEXT_WORD", 0, "Next Word", ""}, + {PREV_LINE, "PREVIOUS_LINE", 0, "Previous Line", ""}, + {NEXT_LINE, "NEXT_LINE", 0, "Next Line", ""}, + {PREV_PAGE, "PREVIOUS_PAGE", 0, "Previous Page", ""}, + {NEXT_PAGE, "NEXT_PAGE", 0, "Next Page", ""}, {0, NULL, 0, NULL, NULL}}; static int move_cursor(bContext *C, int type, int select) @@ -958,8 +956,8 @@ static int move_exec(bContext *C, wmOperator *op) void FONT_OT_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Cursor"); - ot->description= _("Move cursor to position type"); + ot->name= "Move Cursor"; + ot->description= "Move cursor to position type"; ot->idname= "FONT_OT_move"; /* api callbacks */ @@ -970,7 +968,7 @@ void FONT_OT_move(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(move_type_items), LINE_BEGIN, _("Type"), _("Where to move cursor to.")); + RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, "Type", "Where to move cursor to."); } /******************* move select operator ********************/ @@ -985,8 +983,8 @@ static int move_select_exec(bContext *C, wmOperator *op) void FONT_OT_move_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Select"); - ot->description= _("Make selection from current cursor position to new cursor position type"); + ot->name= "Move Select"; + ot->description= "Make selection from current cursor position to new cursor position type"; ot->idname= "FONT_OT_move_select"; /* api callbacks */ @@ -997,7 +995,7 @@ void FONT_OT_move_select(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(move_type_items), LINE_BEGIN, _("Type"), _("Where to move cursor to, to make a selection.")); + RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, "Type", "Where to move cursor to, to make a selection."); } /************************* change spacing **********************/ @@ -1027,8 +1025,8 @@ static int change_spacing_exec(bContext *C, wmOperator *op) void FONT_OT_change_spacing(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Spacing"); - ot->description= _("Change font spacing"); + ot->name= "Change Spacing"; + ot->description= "Change font spacing"; ot->idname= "FONT_OT_change_spacing"; /* api callbacks */ @@ -1039,7 +1037,7 @@ void FONT_OT_change_spacing(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "delta", 1, -20, 20, _("Delta"), _("Amount to decrease or increasing character spacing with."), -20, 20); + RNA_def_int(ot->srna, "delta", 1, -20, 20, "Delta", "Amount to decrease or increasing character spacing with.", -20, 20); } /************************* change character **********************/ @@ -1072,8 +1070,8 @@ static int change_character_exec(bContext *C, wmOperator *op) void FONT_OT_change_character(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Change Character"); - ot->description= _("Change font character code"); + ot->name= "Change Character"; + ot->description= "Change font character code"; ot->idname= "FONT_OT_change_character"; /* api callbacks */ @@ -1084,7 +1082,7 @@ void FONT_OT_change_character(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "delta", 1, -255, 255, _("Delta"), _("Number to increase or decrease character code with."), -255, 255); + RNA_def_int(ot->srna, "delta", 1, -255, 255, "Delta", "Number to increase or decrease character code with.", -255, 255); } /******************* line break operator ********************/ @@ -1115,8 +1113,8 @@ static int line_break_exec(bContext *C, wmOperator *op) void FONT_OT_line_break(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Line Break"); - ot->description= _("Insert line break at cursor position"); + ot->name= "Line Break"; + ot->description= "Insert line break at cursor position"; ot->idname= "FONT_OT_line_break"; /* api callbacks */ @@ -1133,12 +1131,12 @@ void FONT_OT_line_break(wmOperatorType *ot) /******************* delete operator **********************/ static EnumPropertyItem delete_type_items[]= { - {DEL_ALL, "ALL", 0, N_("All"), ""}, - {DEL_NEXT_CHAR, "NEXT_CHARACTER", 0, N_("Next Character"), ""}, - {DEL_PREV_CHAR, "PREVIOUS_CHARACTER", 0, N_("Previous Character"), ""}, - {DEL_SELECTION, "SELECTION", 0, N_("Selection"), ""}, - {DEL_NEXT_SEL, "NEXT_OR_SELECTION", 0, N_("Next or Selection"), ""}, - {DEL_PREV_SEL, "PREVIOUS_OR_SELECTION", 0, N_("Previous or Selection"), ""}, + {DEL_ALL, "ALL", 0, "All", ""}, + {DEL_NEXT_CHAR, "NEXT_CHARACTER", 0, "Next Character", ""}, + {DEL_PREV_CHAR, "PREVIOUS_CHARACTER", 0, "Previous Character", ""}, + {DEL_SELECTION, "SELECTION", 0, "Selection", ""}, + {DEL_NEXT_SEL, "NEXT_OR_SELECTION", 0, "Next or Selection", ""}, + {DEL_PREV_SEL, "PREVIOUS_OR_SELECTION", 0, "Previous or Selection", ""}, {0, NULL, 0, NULL, NULL}}; static int delete_exec(bContext *C, wmOperator *op) @@ -1205,8 +1203,8 @@ static int delete_exec(bContext *C, wmOperator *op) void FONT_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description= _("Delete text by cursor position"); + ot->name= "Delete"; + ot->description= "Delete text by cursor position"; ot->idname= "FONT_OT_delete"; /* api callbacks */ @@ -1217,7 +1215,7 @@ void FONT_OT_delete(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(delete_type_items), DEL_ALL, _("Type"), _("Which part of the text to delete.")); + RNA_def_enum(ot->srna, "type", delete_type_items, DEL_ALL, "Type", "Which part of the text to delete."); } /*********************** insert text operator *************************/ @@ -1354,8 +1352,8 @@ static int insert_text_invoke(bContext *C, wmOperator *op, wmEvent *evt) void FONT_OT_text_insert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert Text"); - ot->description= _("Insert text at cursor position"); + ot->name= "Insert Text"; + ot->description= "Insert text at cursor position"; ot->idname= "FONT_OT_text_insert"; /* api callbacks */ @@ -1367,8 +1365,8 @@ void FONT_OT_text_insert(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "text", "", 0, _("Text"), _("Text to insert at the cursor position.")); - RNA_def_boolean(ot->srna, "accent", 0, _("Accent mode"), _("Next typed character will strike through previous, for special character input.")); + RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); + RNA_def_boolean(ot->srna, "accent", 0, "Accent mode", "Next typed character will strike through previous, for special character input."); } @@ -1393,8 +1391,8 @@ static int textbox_add_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_textbox_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Textbox"); - ot->description= _("Add a new text box"); + ot->name= "Add Textbox"; + ot->description= "Add a new text box"; ot->idname= "FONT_OT_textbox_add"; /* api callbacks */ @@ -1436,8 +1434,8 @@ static int textbox_remove_exec(bContext *C, wmOperator *op) void FONT_OT_textbox_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Textbox"); - ot->description= _("Remove the textbox"); + ot->name= "Remove Textbox"; + ot->description= "Remove the textbox"; ot->idname= "FONT_OT_textbox_remove"; /* api callbacks */ @@ -1447,7 +1445,7 @@ void FONT_OT_textbox_remove(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), _("The current text box."), 0, INT_MAX); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "The current text box.", 0, INT_MAX); } @@ -1527,8 +1525,8 @@ void free_editText(Object *obedit) /********************** set case operator *********************/ static EnumPropertyItem case_items[]= { - {CASE_LOWER, "LOWER", 0, N_("Lower"), ""}, - {CASE_UPPER, "UPPER", 0, N_("Upper"), ""}, + {CASE_LOWER, "LOWER", 0, "Lower", ""}, + {CASE_UPPER, "UPPER", 0, "Upper", ""}, {0, NULL, 0, NULL, NULL}}; static int set_case(bContext *C, int ccase) @@ -1574,8 +1572,8 @@ static int set_case_exec(bContext *C, wmOperator *op) void FONT_OT_case_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Case"); - ot->description= _("Set font case"); + ot->name= "Set Case"; + ot->description= "Set font case"; ot->idname= "FONT_OT_case_set"; /* api callbacks */ @@ -1586,7 +1584,7 @@ void FONT_OT_case_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "case", RNA_enum_items_gettexted(case_items), CASE_LOWER, _("Case"), _("Lower or upper case.")); + RNA_def_enum(ot->srna, "case", case_items, CASE_LOWER, "Case", "Lower or upper case."); } /********************** toggle case operator *********************/ @@ -1617,8 +1615,8 @@ static int toggle_case_exec(bContext *C, wmOperator *UNUSED(op)) void FONT_OT_case_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Case"); - ot->description= _("Toggle font case"); + ot->name= "Toggle Case"; + ot->description= "Toggle font case"; ot->idname= "FONT_OT_case_toggle"; /* api callbacks */ @@ -1717,7 +1715,7 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void FONT_OT_open(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Open Font"); + ot->name= "Open Font"; ot->idname= "FONT_OT_open"; /* api callbacks */ @@ -1760,9 +1758,9 @@ static int font_unlink_exec(bContext *C, wmOperator *op) void FONT_OT_unlink(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Unlink"); + ot->name= "Unlink"; ot->idname= "FONT_OT_unlink"; - ot->description= _("Unlink active font data block"); + ot->description= "Unlink active font data block"; /* api callbacks */ ot->exec= font_unlink_exec; diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index 52e50b1b5b0..a23f2064a9e 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -40,8 +40,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_gpencil.h" #include "BKE_context.h" #include "BKE_global.h" @@ -1878,19 +1876,19 @@ static int gpencil_draw_modal (bContext *C, wmOperator *op, wmEvent *event) /* ------------------------------- */ static EnumPropertyItem prop_gpencil_drawmodes[] = { - {GP_PAINTMODE_DRAW, "DRAW", 0, N_("Draw Freehand"), ""}, - {GP_PAINTMODE_DRAW_STRAIGHT, "DRAW_STRAIGHT", 0, N_("Draw Straight Lines"), ""}, - {GP_PAINTMODE_DRAW_POLY, "DRAW_POLY", 0, N_("Dtaw Poly Line"), ""}, - {GP_PAINTMODE_ERASER, "ERASER", 0, N_("Eraser"), ""}, + {GP_PAINTMODE_DRAW, "DRAW", 0, "Draw Freehand", ""}, + {GP_PAINTMODE_DRAW_STRAIGHT, "DRAW_STRAIGHT", 0, "Draw Straight Lines", ""}, + {GP_PAINTMODE_DRAW_POLY, "DRAW_POLY", 0, "Dtaw Poly Line", ""}, + {GP_PAINTMODE_ERASER, "ERASER", 0, "Eraser", ""}, {0, NULL, 0, NULL, NULL} }; void GPENCIL_OT_draw (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Grease Pencil Draw"); + ot->name= "Grease Pencil Draw"; ot->idname= "GPENCIL_OT_draw"; - ot->description= _("Make annotations on the active data"); + ot->description= "Make annotations on the active data"; /* api callbacks */ ot->exec= gpencil_draw_exec; @@ -1903,7 +1901,7 @@ void GPENCIL_OT_draw (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; /* settings for drawing */ - RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_gpencil_drawmodes), 0, _("Mode"), _("Way to intepret mouse movements.")); + RNA_def_enum(ot->srna, "mode", prop_gpencil_drawmodes, 0, "Mode", "Way to intepret mouse movements."); RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, "Stroke", ""); } diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c index c95862c6fdb..0e36e056187 100644 --- a/source/blender/editors/interface/interface.c +++ b/source/blender/editors/interface/interface.c @@ -90,23 +90,6 @@ static void ui_free_but(const bContext *C, uiBut *but); -/* ************* translation ************** */ - -int ui_translate_buttons(void) -{ - return (U.transopts & USER_TR_BUTTONS); -} - -int ui_translate_menus(void) -{ - return (U.transopts & USER_TR_MENUS); -} - -int ui_translate_tooltips(void) -{ - return (U.transopts & USER_TR_TOOLTIPS); -} - /* ************* window matrix ************** */ void ui_block_to_window_fl(const ARegion *ar, uiBlock *block, float *x, float *y) @@ -237,9 +220,6 @@ static void ui_text_bounds_block(uiBlock *block, float offset) for(bt= block->buttons.first; bt; bt= bt->next) { if(bt->type!=SEPR) { - //int transopts= ui_translate_buttons(); - //if(bt->type==TEX || bt->type==IDPOIN) transopts= 0; - j= BLF_width(style->widget.uifont_id, bt->drawstr); if(j > i) i = j; @@ -2030,12 +2010,9 @@ void ui_check_but(uiBut *but) /* if something changed in the button */ double value= UI_BUT_VALUE_UNSET; // float okwidth; // UNUSED -// int transopts= ui_translate_buttons(); ui_is_but_sel(but, &value); -// if(but->type==TEX || but->type==IDPOIN) transopts= 0; - /* only update soft range while not editing */ if(but->rnaprop && !(but->editval || but->editstr || but->editvec)) { UI_GET_BUT_VALUE_INIT(but, value) @@ -2544,7 +2521,7 @@ static uiBut *ui_def_but_rna(uiBlock *block, int type, int retval, const char *s DynStr *dynstr; int i, totitem, value, free; - RNA_property_enum_items(block->evil_C, ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(block->evil_C, ptr, prop, &item, &totitem, &free); value= RNA_property_enum_get(ptr, prop); dynstr= BLI_dynstr_new(); @@ -2579,7 +2556,7 @@ static uiBut *ui_def_but_rna(uiBlock *block, int type, int retval, const char *s EnumPropertyItem *item; int i, totitem, free; - RNA_property_enum_items(block->evil_C, ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(block->evil_C, ptr, prop, &item, &totitem, &free); for(i=0; i<totitem; i++) { if(item[i].identifier[0] && item[i].value == (int)max) { str= item[i].name; @@ -2707,6 +2684,11 @@ static uiBut *ui_def_but_operator(uiBlock *block, int type, const char *opname, if ((!tip || tip[0]=='\0') && ot && ot->description) { tip= ot->description; + +#ifdef INTERNATIONAL + if((U.transopts&USER_DOTRANSLATE) && (U.transopts|USER_TR_TOOLTIPS)) + tip= BLF_gettext(tip); +#endif } but= ui_def_but(block, type, -1, str, x1, y1, x2, y2, NULL, 0, 0, 0, 0, tip); diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h index ebc8725ad5d..72eb869dea0 100644 --- a/source/blender/editors/interface/interface_intern.h +++ b/source/blender/editors/interface/interface_intern.h @@ -347,10 +347,6 @@ typedef struct uiSafetyRct { extern void ui_delete_linkline(uiLinkLine *line, uiBut *but); -extern int ui_translate_buttons(void); -extern int ui_translate_menus(void); -extern int ui_translate_tooltips(void); - void ui_fontscale(short *points, float aspect); extern void ui_block_to_window_fl(const struct ARegion *ar, uiBlock *block, float *x, float *y); diff --git a/source/blender/editors/interface/interface_layout.c b/source/blender/editors/interface/interface_layout.c index 5f15cf7e5f7..161bb11dcef 100644 --- a/source/blender/editors/interface/interface_layout.c +++ b/source/blender/editors/interface/interface_layout.c @@ -477,7 +477,7 @@ static void ui_item_enum_expand(uiLayout *layout, uiBlock *block, PointerRNA *pt const char *name; int a, totitem, itemw, icon, value, free; - RNA_property_enum_items(block->evil_C, ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(block->evil_C, ptr, prop, &item, &totitem, &free); uiBlockSetCurLayout(block, ui_item_local_sublayout(layout, layout, 1)); for(a=0; a<totitem; a++) { @@ -636,8 +636,15 @@ PointerRNA uiItemFullO(uiLayout *layout, const char *opname, const char *name, i return PointerRNA_NULL; } - if(!name) + if(!name) { name= ot->name; + +#ifdef INTERNATIONAL + if((U.transopts&USER_DOTRANSLATE) && (U.transopts&USER_TR_IFACE)) + name= BLF_gettext(name); +#endif + } + if(layout->root->type == UI_LAYOUT_MENU && !icon) icon= ICON_BLANK1; @@ -703,7 +710,7 @@ static const char *ui_menu_enumpropname(uiLayout *layout, const char *opname, co int totitem, free; const char *name; - RNA_property_enum_items(layout->root->block->evil_C, &ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(layout->root->block->evil_C, &ptr, prop, &item, &totitem, &free); if(RNA_enum_name(item, retval, &name)) { if(free) MEM_freeN(item); return name; @@ -755,7 +762,7 @@ void uiItemsFullEnumO(uiLayout *layout, const char *opname, const char *propname uiLayout *split= uiLayoutSplit(layout, 0, 0); uiLayout *column= uiLayoutColumn(split, 0); - RNA_property_enum_items(block->evil_C, &ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(block->evil_C, &ptr, prop, &item, &totitem, &free); for(i=0; i<totitem; i++) { if(item[i].identifier[0]) { @@ -843,7 +850,7 @@ void uiItemEnumO_string(uiLayout *layout, const char *name, int icon, const char /* enum lookup */ if((prop= RNA_struct_find_property(&ptr, propname))) { - RNA_property_enum_items(layout->root->block->evil_C, &ptr, prop, &item, NULL, &free); + RNA_property_enum_items_gettexted(layout->root->block->evil_C, &ptr, prop, &item, NULL, &free); if(item==NULL || RNA_enum_value_from_id(item, value_str, &value)==0) { if(free) MEM_freeN(item); RNA_warning("%s.%s, enum %s not found.", RNA_struct_identifier(ptr.type), propname, value_str); @@ -1093,7 +1100,7 @@ void uiItemEnumR_string(uiLayout *layout, struct PointerRNA *ptr, const char *pr return; } - RNA_property_enum_items(layout->root->block->evil_C, ptr, prop, &item, NULL, &free); + RNA_property_enum_items_gettexted(layout->root->block->evil_C, ptr, prop, &item, NULL, &free); if(!RNA_enum_value_from_id(item, value, &ivalue)) { if(free) MEM_freeN(item); @@ -1137,7 +1144,7 @@ void uiItemsEnumR(uiLayout *layout, struct PointerRNA *ptr, const char *propname uiLayout *split= uiLayoutSplit(layout, 0, 0); uiLayout *column= uiLayoutColumn(split, 0); - RNA_property_enum_items(block->evil_C, ptr, prop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(block->evil_C, ptr, prop, &item, &totitem, &free); for(i=0; i<totitem; i++) { if(item[i].identifier[0]) { @@ -1423,8 +1430,15 @@ void uiItemM(uiLayout *layout, bContext *UNUSED(C), const char *menuname, const return; } - if(!name) + if(!name) { name= mt->label; + +#ifdef INTERNATIONAL + if((U.transopts&USER_DOTRANSLATE) && (U.transopts&USER_TR_IFACE)) + name= BLF_gettext(name); +#endif + } + if(layout->root->type == UI_LAYOUT_MENU && !icon) icon= ICON_BLANK1; diff --git a/source/blender/editors/interface/interface_ops.c b/source/blender/editors/interface/interface_ops.c index 6a35ba9baf1..e9fad382beb 100644 --- a/source/blender/editors/interface/interface_ops.c +++ b/source/blender/editors/interface/interface_ops.c @@ -44,8 +44,6 @@ #include "BLI_math_color.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_global.h" #include "BKE_text.h" /* for UI_OT_reports_to_text */ @@ -217,9 +215,9 @@ static int reset_default_theme_exec(bContext *C, wmOperator *UNUSED(op)) static void UI_OT_reset_default_theme(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset to Default Theme"); + ot->name= "Reset to Default Theme"; ot->idname= "UI_OT_reset_default_theme"; - ot->description= _("Reset to the default theme colors"); + ot->description= "Reset to the default theme colors"; /* callbacks */ ot->exec= reset_default_theme_exec; @@ -307,9 +305,9 @@ static int reset_default_button_exec(bContext *C, wmOperator *op) static void UI_OT_reset_default_button(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset to Default Value"); + ot->name= "Reset to Default Value"; ot->idname= "UI_OT_reset_default_button"; - ot->description= _("Reset this property's value to its default value"); + ot->description= "Reset this property's value to its default value"; /* callbacks */ ot->poll= reset_default_button_poll; @@ -319,7 +317,7 @@ static void UI_OT_reset_default_button(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Reset to default values all elements of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array."); } /* Copy To Selected Operator ------------------------ */ @@ -399,9 +397,9 @@ static int copy_to_selected_button_exec(bContext *C, wmOperator *op) static void UI_OT_copy_to_selected_button(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy To Selected"); + ot->name= "Copy To Selected"; ot->idname= "UI_OT_copy_to_selected_button"; - ot->description= _("Copy property from this object to selected objects or bones"); + ot->description= "Copy property from this object to selected objects or bones"; /* callbacks */ ot->poll= copy_to_selected_button_poll; @@ -411,7 +409,7 @@ static void UI_OT_copy_to_selected_button(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 1, _("All"), _("Reset to default values all elements of the array.")); + RNA_def_boolean(ot->srna, "all", 1, "All", "Reset to default values all elements of the array."); } /* Reports to Textblock Operator ------------------------ */ diff --git a/source/blender/editors/interface/interface_panel.c b/source/blender/editors/interface/interface_panel.c index d4f49d750ac..8fc4904eed4 100644 --- a/source/blender/editors/interface/interface_panel.c +++ b/source/blender/editors/interface/interface_panel.c @@ -53,6 +53,8 @@ #include "BIF_gl.h" #include "BIF_glutil.h" +#include "BLF_api.h" + #include "WM_api.h" #include "WM_types.h" @@ -442,8 +444,13 @@ static void ui_draw_aligned_panel_header(uiStyle *style, uiBlock *block, rcti *r Panel *panel= block->panel; rcti hrect; int pnl_icons; - char *activename= panel->drawname[0]?panel->drawname:panel->panelname; - + const char *activename= panel->drawname[0]?panel->drawname:panel->panelname; + +#ifdef INTERNATIONAL + if((U.transopts&USER_DOTRANSLATE) && (U.transopts&USER_TR_IFACE)) + activename= BLF_gettext(activename); +#endif + /* + 0.001f to avoid flirting with float inaccuracy */ if(panel->control & UI_PNL_CLOSE) pnl_icons=(panel->labelofs+2*PNL_ICON+5)/block->aspect + 0.001f; else pnl_icons= (panel->labelofs+PNL_ICON+5)/block->aspect + 0.001f; diff --git a/source/blender/editors/interface/interface_regions.c b/source/blender/editors/interface/interface_regions.c index f4aaf6212a8..e673add46b1 100644 --- a/source/blender/editors/interface/interface_regions.c +++ b/source/blender/editors/interface/interface_regions.c @@ -374,7 +374,7 @@ ARegion *ui_tooltip_create(bContext *C, ARegion *butregion, uiBut *but) EnumPropertyItem *item; int i, totitem, free; - RNA_property_enum_items(C, &but->rnapoin, but->rnaprop, &item, &totitem, &free); + RNA_property_enum_items_gettexted(C, &but->rnapoin, but->rnaprop, &item, &totitem, &free); for(i=0; i<totitem; i++) { if(item[i].identifier[0] && item[i].value == (int)but->hardmax) { diff --git a/source/blender/editors/interface/interface_widgets.c b/source/blender/editors/interface/interface_widgets.c index 45829646145..d9a5e92a72c 100644 --- a/source/blender/editors/interface/interface_widgets.c +++ b/source/blender/editors/interface/interface_widgets.c @@ -1018,7 +1018,6 @@ static void ui_text_label_rightclip(uiFontStyle *fstyle, uiBut *but, rcti *rect) static void widget_draw_text(uiFontStyle *fstyle, uiWidgetColors *wcol, uiBut *but, rcti *rect) { -// int transopts; char *cpoin = NULL; /* for underline drawing */ @@ -1088,10 +1087,6 @@ static void widget_draw_text(uiFontStyle *fstyle, uiWidgetColors *wcol, uiBut *b if (fstyle->kerning == 1) BLF_disable(fstyle->uifont_id, BLF_KERNING_DEFAULT); - // ui_rasterpos_safe(x, y, but->aspect); -// if(but->type==IDPOIN) transopts= 0; // no translation, of course! -// else transopts= ui_translate_buttons(); - /* cut string in 2 parts - only for menu entries */ if((but->block->flag & UI_BLOCK_LOOP)) { if(ELEM5(but->type, SLI, NUM, TEX, NUMSLI, NUMABS)==0) { diff --git a/source/blender/editors/interface/view2d_ops.c b/source/blender/editors/interface/view2d_ops.c index 8cdb67a13fd..3ecc8cce8b1 100644 --- a/source/blender/editors/interface/view2d_ops.c +++ b/source/blender/editors/interface/view2d_ops.c @@ -39,8 +39,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "RNA_access.h" @@ -295,8 +293,8 @@ static int view_pan_cancel(bContext *UNUSED(C), wmOperator *op) static void VIEW2D_OT_pan(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Pan View"); - ot->description= _("Pan the view"); + ot->name= "Pan View"; + ot->description= "Pan the view"; ot->idname= "VIEW2D_OT_pan"; /* api callbacks */ @@ -309,8 +307,8 @@ static void VIEW2D_OT_pan(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER; /* rna - must keep these in sync with the other operators */ - RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX); } /* ------------------ Scrollwheel Versions (2) ---------------------- */ @@ -345,16 +343,16 @@ static int view_scrollright_exec(bContext *C, wmOperator *op) static void VIEW2D_OT_scroll_right(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroll Right"); - ot->description= _("Scroll the view right"); + ot->name= "Scroll Right"; + ot->description= "Scroll the view right"; ot->idname= "VIEW2D_OT_scroll_right"; /* api callbacks */ ot->exec= view_scrollright_exec; /* rna - must keep these in sync with the other operators */ - RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX); } @@ -389,16 +387,16 @@ static int view_scrollleft_exec(bContext *C, wmOperator *op) static void VIEW2D_OT_scroll_left(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroll Left"); - ot->description= _("Scroll the view left"); + ot->name= "Scroll Left"; + ot->description= "Scroll the view left"; ot->idname= "VIEW2D_OT_scroll_left"; /* api callbacks */ ot->exec= view_scrollleft_exec; /* rna - must keep these in sync with the other operators */ - RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX); } @@ -437,17 +435,17 @@ static int view_scrolldown_exec(bContext *C, wmOperator *op) static void VIEW2D_OT_scroll_down(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroll Down"); - ot->description= _("Scroll the view down"); + ot->name= "Scroll Down"; + ot->description= "Scroll the view down"; ot->idname= "VIEW2D_OT_scroll_down"; /* api callbacks */ ot->exec= view_scrolldown_exec; /* rna - must keep these in sync with the other operators */ - RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX); - RNA_def_boolean(ot->srna, "page", 0, _("Page"), _("Scroll down one page.")); + RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX); + RNA_def_boolean(ot->srna, "page", 0, "Page", "Scroll down one page."); } @@ -487,17 +485,17 @@ static int view_scrollup_exec(bContext *C, wmOperator *op) static void VIEW2D_OT_scroll_up(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroll Up"); - ot->description= _("Scroll the view up"); + ot->name= "Scroll Up"; + ot->description= "Scroll the view up"; ot->idname= "VIEW2D_OT_scroll_up"; /* api callbacks */ ot->exec= view_scrollup_exec; /* rna - must keep these in sync with the other operators */ - RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, _("Delta X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, _("Delta Y"), "", INT_MIN, INT_MAX); - RNA_def_boolean(ot->srna, "page", 0, _("Page"), _("Scroll up one page.")); + RNA_def_int(ot->srna, "deltax", 0, INT_MIN, INT_MAX, "Delta X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "deltay", 0, INT_MIN, INT_MAX, "Delta Y", "", INT_MIN, INT_MAX); + RNA_def_boolean(ot->srna, "page", 0, "Page", "Scroll up one page."); } /* ********************************************************* */ @@ -715,8 +713,8 @@ static int view_zoomin_invoke(bContext *C, wmOperator *op, wmEvent *event) static void VIEW2D_OT_zoom_in(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom In"); - ot->description= _("Zoom in the view"); + ot->name= "Zoom In"; + ot->description= "Zoom in the view"; ot->idname= "VIEW2D_OT_zoom_in"; /* api callbacks */ @@ -725,8 +723,8 @@ static void VIEW2D_OT_zoom_in(wmOperatorType *ot) ot->poll= view_zoom_poll; /* rna - must keep these in sync with the other operators */ - RNA_def_float(ot->srna, "zoomfacx", 0, -FLT_MAX, FLT_MAX, _("Zoom Factor X"), "", -FLT_MAX, FLT_MAX); - RNA_def_float(ot->srna, "zoomfacy", 0, -FLT_MAX, FLT_MAX, _("Zoom Factor Y"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "zoomfacx", 0, -FLT_MAX, FLT_MAX, "Zoom Factor X", "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "zoomfacy", 0, -FLT_MAX, FLT_MAX, "Zoom Factor Y", "", -FLT_MAX, FLT_MAX); } /* this operator only needs this single callback, where it callsthe view_zoom_*() methods */ @@ -772,8 +770,8 @@ static int view_zoomout_invoke(bContext *C, wmOperator *op, wmEvent *event) static void VIEW2D_OT_zoom_out(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom Out"); - ot->description= _("Zoom out the view"); + ot->name= "Zoom Out"; + ot->description= "Zoom out the view"; ot->idname= "VIEW2D_OT_zoom_out"; /* api callbacks */ @@ -782,8 +780,8 @@ static void VIEW2D_OT_zoom_out(wmOperatorType *ot) ot->poll= view_zoom_poll; /* rna - must keep these in sync with the other operators */ - RNA_def_float(ot->srna, "zoomfacx", 0, -FLT_MAX, FLT_MAX, _("Zoom Factor X"), "", -FLT_MAX, FLT_MAX); - RNA_def_float(ot->srna, "zoomfacy", 0, -FLT_MAX, FLT_MAX, _("Zoom Factor Y"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "zoomfacx", 0, -FLT_MAX, FLT_MAX, "Zoom Factor X", "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "zoomfacy", 0, -FLT_MAX, FLT_MAX, "Zoom Factor Y", "", -FLT_MAX, FLT_MAX); } /* ********************************************************* */ @@ -1067,8 +1065,8 @@ static int view_zoomdrag_modal(bContext *C, wmOperator *op, wmEvent *event) static void VIEW2D_OT_zoom(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom 2D View"); - ot->description= _("Zoom in/out the view"); + ot->name= "Zoom 2D View"; + ot->description= "Zoom in/out the view"; ot->idname= "VIEW2D_OT_zoom"; /* api callbacks */ @@ -1083,8 +1081,8 @@ static void VIEW2D_OT_zoom(wmOperatorType *ot) // ot->flag= OPTYPE_BLOCKING; /* rna - must keep these in sync with the other operators */ - RNA_def_float(ot->srna, "deltax", 0, -FLT_MAX, FLT_MAX, _("Delta X"), "", -FLT_MAX, FLT_MAX); - RNA_def_float(ot->srna, "deltay", 0, -FLT_MAX, FLT_MAX, _("Delta Y"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "deltax", 0, -FLT_MAX, FLT_MAX, "Delta X", "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "deltay", 0, -FLT_MAX, FLT_MAX, "Delta Y", "", -FLT_MAX, FLT_MAX); } /* ********************************************************* */ @@ -1168,8 +1166,8 @@ static int view_borderzoom_exec(bContext *C, wmOperator *op) static void VIEW2D_OT_zoom_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom to Border"); - ot->description= _("Zoom in the view to the nearest item contained in the border"); + ot->name= "Zoom to Border"; + ot->description= "Zoom in the view to the nearest item contained in the border"; ot->idname= "VIEW2D_OT_zoom_border"; /* api callbacks */ @@ -1181,11 +1179,11 @@ static void VIEW2D_OT_zoom_border(wmOperatorType *ot) ot->poll= view_zoom_poll; /* rna */ - RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, _("Gesture Mode"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, "Gesture Mode", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, "X Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, "X Max", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, "Y Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, "Y Max", "", INT_MIN, INT_MAX); } /* ********************************************************* */ @@ -1570,8 +1568,8 @@ static int scroller_activate_invoke(bContext *C, wmOperator *op, wmEvent *event) static void VIEW2D_OT_scroller_activate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroller Activate"); - ot->description= _("Scroll view by mouse click and drag"); + ot->name= "Scroller Activate"; + ot->description= "Scroll view by mouse click and drag"; ot->idname= "VIEW2D_OT_scroller_activate"; /* flags */ @@ -1638,8 +1636,8 @@ static int reset_exec(bContext *C, wmOperator *UNUSED(op)) static void VIEW2D_OT_reset(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset View"); - ot->description= _("Reset the view"); + ot->name= "Reset View"; + ot->description= "Reset the view"; ot->idname= "VIEW2D_OT_reset"; /* api callbacks */ diff --git a/source/blender/editors/mesh/CMakeLists.txt b/source/blender/editors/mesh/CMakeLists.txt index 3c78983f82d..02a25a2a122 100644 --- a/source/blender/editors/mesh/CMakeLists.txt +++ b/source/blender/editors/mesh/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/mesh/SConscript b/source/blender/editors/mesh/SConscript index 1c2b9d5d1d6..b992ae5f04c 100644 --- a/source/blender/editors/mesh/SConscript +++ b/source/blender/editors/mesh/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../gpu ../../blenloader' incs += ' ../../makesrna ../../render/extern/include #/intern/elbeem/extern' diff --git a/source/blender/editors/mesh/editmesh.c b/source/blender/editors/mesh/editmesh.c index d6e451a8625..9bf863faae3 100644 --- a/source/blender/editors/mesh/editmesh.c +++ b/source/blender/editors/mesh/editmesh.c @@ -50,8 +50,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_DerivedMesh.h" #include "BKE_context.h" #include "BKE_depsgraph.h" @@ -1314,9 +1312,9 @@ void remake_editMesh(Scene *scene, Object *ob) /* *************** Operator: separate parts *************/ static EnumPropertyItem prop_separate_types[] = { - {0, "SELECTED", 0, N_("Selection"), ""}, - {1, "MATERIAL", 0, N_("By Material"), ""}, - {2, "LOOSE", 0, N_("By loose parts"), ""}, + {0, "SELECTED", 0, "Selection", ""}, + {1, "MATERIAL", 0, "By Material", ""}, + {2, "LOOSE", 0, "By loose parts", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1542,8 +1540,8 @@ static int mesh_separate_exec(bContext *C, wmOperator *op) void MESH_OT_separate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Separate"); - ot->description= _("Separate selected geometry into a new mesh"); + ot->name= "Separate"; + ot->description= "Separate selected geometry into a new mesh"; ot->idname= "MESH_OT_separate"; /* api callbacks */ @@ -1554,7 +1552,7 @@ void MESH_OT_separate(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_separate_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_separate_types, 0, "Type", ""); } diff --git a/source/blender/editors/mesh/editmesh_add.c b/source/blender/editors/mesh/editmesh_add.c index f29c0857dc1..0c819cd7649 100644 --- a/source/blender/editors/mesh/editmesh_add.c +++ b/source/blender/editors/mesh/editmesh_add.c @@ -52,8 +52,6 @@ #include "BLI_editVert.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_library.h" @@ -274,8 +272,8 @@ static int dupli_extrude_cursor(bContext *C, wmOperator *op, wmEvent *event) void MESH_OT_dupli_extrude_cursor(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate or Extrude at 3D Cursor"); - ot->description= _("Duplicate and extrude selected vertices, edges or faces towards 3D Cursor"); + ot->name= "Duplicate or Extrude at 3D Cursor"; + ot->description= "Duplicate and extrude selected vertices, edges or faces towards 3D Cursor"; ot->idname= "MESH_OT_dupli_extrude_cursor"; /* api callbacks */ @@ -285,7 +283,7 @@ void MESH_OT_dupli_extrude_cursor(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "rotate_source", 1, _("Rotate Source"), _("Rotate initial selection giving better shape")); + RNA_def_boolean(ot->srna, "rotate_source", 1, "Rotate Source", "Rotate initial selection giving better shape"); } @@ -407,8 +405,8 @@ static int make_fgon_exec(bContext *C, wmOperator *op) void MESH_OT_fgon_make(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make F-gon"); - ot->description= _("Make fgon from selected faces"); + ot->name= "Make F-gon"; + ot->description= "Make fgon from selected faces"; ot->idname= "MESH_OT_fgon_make"; /* api callbacks */ @@ -439,8 +437,8 @@ static int clear_fgon_exec(bContext *C, wmOperator *op) void MESH_OT_fgon_clear(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear F-gon"); - ot->description= _("Clear fgon from selected face"); + ot->name= "Clear F-gon"; + ot->description= "Clear fgon from selected face"; ot->idname= "MESH_OT_fgon_clear"; /* api callbacks */ @@ -851,8 +849,8 @@ static int addedgeface_mesh_exec(bContext *C, wmOperator *op) void MESH_OT_edge_face_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Edge/Face"); - ot->description= _("Add an edge or face to selected"); + ot->name= "Make Edge/Face"; + ot->description= "Add an edge or face to selected"; ot->idname= "MESH_OT_edge_face_add"; /* api callbacks */ @@ -1407,8 +1405,8 @@ static int add_primitive_plane_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_plane_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Plane"); - ot->description= _("Construct a filled planar mesh with 4 vertices"); + ot->name= "Add Plane"; + ot->description= "Construct a filled planar mesh with 4 vertices"; ot->idname= "MESH_OT_primitive_plane_add"; /* api callbacks */ @@ -1440,8 +1438,8 @@ static int add_primitive_cube_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_cube_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Cube"); - ot->description= _("Construct a cube mesh"); + ot->name= "Add Cube"; + ot->description= "Construct a cube mesh"; ot->idname= "MESH_OT_primitive_cube_add"; /* api callbacks */ @@ -1475,8 +1473,8 @@ static int add_primitive_circle_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_circle_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Circle"); - ot->description= _("Construct a circle mesh"); + ot->name= "Add Circle"; + ot->description= "Construct a circle mesh"; ot->idname= "MESH_OT_primitive_circle_add"; /* api callbacks */ @@ -1488,8 +1486,8 @@ void MESH_OT_primitive_circle_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "vertices", 32, 3, INT_MAX, _("Vertices"), "", 3, 500); - RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, _("Radius"), "", 0.001, 100.00); + RNA_def_int(ot->srna, "vertices", 32, 3, INT_MAX, "Vertices", "", 3, 500); + RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, "Radius", "", 0.001, 100.00); RNA_def_boolean(ot->srna, "fill", 0, "Fill", ""); ED_object_add_generic_props(ot, TRUE); @@ -1516,8 +1514,8 @@ static int add_primitive_cylinder_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_cylinder_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Cylinder"); - ot->description= _("Construct a cylinder mesh"); + ot->name= "Add Cylinder"; + ot->description= "Construct a cylinder mesh"; ot->idname= "MESH_OT_primitive_cylinder_add"; /* api callbacks */ @@ -1529,10 +1527,10 @@ void MESH_OT_primitive_cylinder_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "vertices", 32, 2, INT_MAX, _("Vertices"), "", 2, 500); - RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, _("Radius"), "", 0.001, 100.00); - RNA_def_float(ot->srna, "depth", 2.0f, 0.0, FLT_MAX, _("Depth"), "", 0.001, 100.00); - RNA_def_boolean(ot->srna, "cap_ends", 1, _("Cap Ends"), ""); + RNA_def_int(ot->srna, "vertices", 32, 2, INT_MAX, "Vertices", "", 2, 500); + RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, "Radius", "", 0.001, 100.00); + RNA_def_float(ot->srna, "depth", 2.0f, 0.0, FLT_MAX, "Depth", "", 0.001, 100.00); + RNA_def_boolean(ot->srna, "cap_ends", 1, "Cap Ends", ""); ED_object_add_generic_props(ot, TRUE); } @@ -1557,8 +1555,8 @@ static int add_primitive_cone_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_cone_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Cone"); - ot->description= _("Construct a conic mesh (ends filled)"); + ot->name= "Add Cone"; + ot->description= "Construct a conic mesh (ends filled)"; ot->idname= "MESH_OT_primitive_cone_add"; /* api callbacks */ @@ -1570,10 +1568,10 @@ void MESH_OT_primitive_cone_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "vertices", 32, 2, INT_MAX, _("Vertices"), "", 2, 500); - RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, _("Radius"), "", 0.001, 100.00); - RNA_def_float(ot->srna, "depth", 2.0f, 0.0, FLT_MAX, _("Depth"), "", 0.001, 100.00); - RNA_def_boolean(ot->srna, "cap_end", 1, _("Cap End"), ""); + RNA_def_int(ot->srna, "vertices", 32, 2, INT_MAX, "Vertices", "", 2, 500); + RNA_def_float(ot->srna, "radius", 1.0f, 0.0, FLT_MAX, "Radius", "", 0.001, 100.00); + RNA_def_float(ot->srna, "depth", 2.0f, 0.0, FLT_MAX, "Depth", "", 0.001, 100.00); + RNA_def_boolean(ot->srna, "cap_end", 1, "Cap End", ""); ED_object_add_generic_props(ot, TRUE); } @@ -1598,8 +1596,8 @@ static int add_primitive_grid_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_grid_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Grid"); - ot->description= _("Construct a grid mesh"); + ot->name= "Add Grid"; + ot->description= "Construct a grid mesh"; ot->idname= "MESH_OT_primitive_grid_add"; /* api callbacks */ @@ -1611,9 +1609,9 @@ void MESH_OT_primitive_grid_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "x_subdivisions", 10, 3, INT_MAX, _("X Subdivisions"), "", 3, 1000); - RNA_def_int(ot->srna, "y_subdivisions", 10, 3, INT_MAX, _("Y Subdivisions"), "", 3, 1000); - RNA_def_float(ot->srna, "size", 1.0f, 0.0, FLT_MAX, _("Size"), "", 0.001, FLT_MAX); + RNA_def_int(ot->srna, "x_subdivisions", 10, 3, INT_MAX, "X Subdivisions", "", 3, 1000); + RNA_def_int(ot->srna, "y_subdivisions", 10, 3, INT_MAX, "Y Subdivisions", "", 3, 1000); + RNA_def_float(ot->srna, "size", 1.0f, 0.0, FLT_MAX, "Size", "", 0.001, FLT_MAX); ED_object_add_generic_props(ot, TRUE); } @@ -1636,8 +1634,8 @@ static int add_primitive_monkey_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_monkey_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Monkey"); - ot->description= _("Construct a Suzanne mesh"); + ot->name= "Add Monkey"; + ot->description= "Construct a Suzanne mesh"; ot->idname= "MESH_OT_primitive_monkey_add"; /* api callbacks */ @@ -1671,8 +1669,8 @@ static int add_primitive_uvsphere_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_uv_sphere_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add UV Sphere"); - ot->description= _("Construct a UV sphere mesh"); + ot->name= "Add UV Sphere"; + ot->description= "Construct a UV sphere mesh"; ot->idname= "MESH_OT_primitive_uv_sphere_add"; /* api callbacks */ @@ -1684,9 +1682,9 @@ void MESH_OT_primitive_uv_sphere_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "segments", 32, 3, INT_MAX, _("Segments"), "", 3, 500); - RNA_def_int(ot->srna, "ring_count", 16, 3, INT_MAX, _("Rings"), "", 3, 500); - RNA_def_float(ot->srna, "size", 1.0f, 0.0, FLT_MAX, _("Size"), "", 0.001, 100.00); + RNA_def_int(ot->srna, "segments", 32, 3, INT_MAX, "Segments", "", 3, 500); + RNA_def_int(ot->srna, "ring_count", 16, 3, INT_MAX, "Rings", "", 3, 500); + RNA_def_float(ot->srna, "size", 1.0f, 0.0, FLT_MAX, "Size", "", 0.001, 100.00); ED_object_add_generic_props(ot, TRUE); } @@ -1710,8 +1708,8 @@ static int add_primitive_icosphere_exec(bContext *C, wmOperator *op) void MESH_OT_primitive_ico_sphere_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Ico Sphere"); - ot->description= _("Construct an Icosphere mesh"); + ot->name= "Add Ico Sphere"; + ot->description= "Construct an Icosphere mesh"; ot->idname= "MESH_OT_primitive_ico_sphere_add"; /* api callbacks */ @@ -1723,8 +1721,8 @@ void MESH_OT_primitive_ico_sphere_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "subdivisions", 2, 1, INT_MAX, _("Subdivisions"), "", 1, 8); - RNA_def_float(ot->srna, "size", 1.0f, 0.0f, FLT_MAX, _("Size"), "", 0.001f, 100.00); + RNA_def_int(ot->srna, "subdivisions", 2, 1, INT_MAX, "Subdivisions", "", 1, 8); + RNA_def_float(ot->srna, "size", 1.0f, 0.0f, FLT_MAX, "Size", "", 0.001f, 100.00); ED_object_add_generic_props(ot, TRUE); } @@ -1758,8 +1756,8 @@ static int mesh_duplicate_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(ev void MESH_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Mesh"); - ot->description= _("Duplicate selected vertices, edges or faces"); + ot->name= "Duplicate Mesh"; + ot->description= "Duplicate selected vertices, edges or faces"; ot->idname= "MESH_OT_duplicate"; /* api callbacks */ @@ -1769,6 +1767,6 @@ void MESH_OT_duplicate(wmOperatorType *ot) ot->poll= ED_operator_editmesh; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } diff --git a/source/blender/editors/mesh/editmesh_loop.c b/source/blender/editors/mesh/editmesh_loop.c index fbc531d0e92..acbe5ef2144 100644 --- a/source/blender/editors/mesh/editmesh_loop.c +++ b/source/blender/editors/mesh/editmesh_loop.c @@ -55,8 +55,6 @@ editmesh_loop: tools with own drawing subloops, select, knife, subdiv #include "BLI_editVert.h" #include "BLI_ghash.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_mesh.h" @@ -449,9 +447,9 @@ typedef struct CutCurve { #define KNIFE_MULTICUT 3 static EnumPropertyItem knife_items[]= { - {KNIFE_EXACT, "EXACT", 0, N_("Exact"), ""}, - {KNIFE_MIDPOINT, "MIDPOINTS", 0, N_("Midpoints"), ""}, - {KNIFE_MULTICUT, "MULTICUT", 0, N_("Multicut"), ""}, + {KNIFE_EXACT, "EXACT", 0, "Exact", ""}, + {KNIFE_MIDPOINT, "MIDPOINTS", 0, "Midpoints", ""}, + {KNIFE_MULTICUT, "MULTICUT", 0, "Multicut", ""}, {0, NULL, 0, NULL, NULL} }; @@ -714,8 +712,8 @@ void MESH_OT_knife_cut(wmOperatorType *ot) { PropertyRNA *prop; - ot->name= _("Knife Cut"); - ot->description= _("Cut selected edges and faces into parts"); + ot->name= "Knife Cut"; + ot->description= "Cut selected edges and faces into parts"; ot->idname= "MESH_OT_knife_cut"; ot->invoke= WM_gesture_lines_invoke; @@ -728,14 +726,14 @@ void MESH_OT_knife_cut(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(knife_items), KNIFE_EXACT, _("Type"), ""); + RNA_def_enum(ot->srna, "type", knife_items, KNIFE_EXACT, "Type", ""); prop= RNA_def_property(ot->srna, "path", PROP_COLLECTION, PROP_NONE); RNA_def_property_struct_runtime(prop, &RNA_OperatorMousePath); - RNA_def_int(ot->srna, "num_cuts", 1, 1, MAX_CUTS, _("Number of Cuts"), _("Only for Multi-Cut"), 1, MAX_CUTS); + RNA_def_int(ot->srna, "num_cuts", 1, 1, MAX_CUTS, "Number of Cuts", "Only for Multi-Cut", 1, MAX_CUTS); // doesn't work atm.. RNA_def_enum(ot->srna, "corner_cut_pattern", corner_type_items, SUBDIV_CORNER_INNERVERT, "Corner Cut Pattern", "Topology pattern to use to fill a face after cutting across its corner"); /* internal */ - RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, _("Cursor"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, "Cursor", "", 0, INT_MAX); } /* ******************************************************* */ diff --git a/source/blender/editors/mesh/editmesh_mods.c b/source/blender/editors/mesh/editmesh_mods.c index 945907073cf..7af4ebee3bc 100644 --- a/source/blender/editors/mesh/editmesh_mods.c +++ b/source/blender/editors/mesh/editmesh_mods.c @@ -55,8 +55,6 @@ editmesh_mods.c, UI level access, no geometry changes #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_displist.h" #include "BKE_depsgraph.h" @@ -714,22 +712,22 @@ static int unified_findnearest(ViewContext *vc, EditVert **eve, EditEdge **eed, #define SIMFACE_TOT 207 static EnumPropertyItem prop_similar_types[] = { - {SIMVERT_NORMAL, "NORMAL", 0, N_("Normal"), ""}, - {SIMVERT_FACE, "FACE", 0, N_("Amount of Vertices in Face"), ""}, - {SIMVERT_VGROUP, "VGROUP", 0, N_("Vertex Groups"), ""}, - {SIMEDGE_LENGTH, "LENGTH", 0, N_("Length"), ""}, - {SIMEDGE_DIR, "DIR", 0, N_("Direction"), ""}, - {SIMEDGE_FACE, "FACE", 0, N_("Amount of Vertices in Face"), ""}, - {SIMEDGE_FACE_ANGLE, "FACE_ANGLE", 0, N_("Face Angles"), ""}, - {SIMEDGE_CREASE, "CREASE", 0, N_("Crease"), ""}, - {SIMEDGE_SEAM, "SEAM", 0, N_("Seam"), ""}, - {SIMEDGE_SHARP, "SHARP", 0, N_("Sharpness"), ""}, - {SIMFACE_MATERIAL, "MATERIAL", 0, N_("Material"), ""}, - {SIMFACE_IMAGE, "IMAGE", 0, N_("Image"), ""}, - {SIMFACE_AREA, "AREA", 0, N_("Area"), ""}, - {SIMFACE_PERIMETER, "PERIMETER", 0, N_("Perimeter"), ""}, - {SIMFACE_NORMAL, "NORMAL", 0, N_("Normal"), ""}, - {SIMFACE_COPLANAR, "COPLANAR", 0, N_("Co-planar"), ""}, + {SIMVERT_NORMAL, "NORMAL", 0, "Normal", ""}, + {SIMVERT_FACE, "FACE", 0, "Amount of Vertices in Face", ""}, + {SIMVERT_VGROUP, "VGROUP", 0, "Vertex Groups", ""}, + {SIMEDGE_LENGTH, "LENGTH", 0, "Length", ""}, + {SIMEDGE_DIR, "DIR", 0, "Direction", ""}, + {SIMEDGE_FACE, "FACE", 0, "Amount of Vertices in Face", ""}, + {SIMEDGE_FACE_ANGLE, "FACE_ANGLE", 0, "Face Angles", ""}, + {SIMEDGE_CREASE, "CREASE", 0, "Crease", ""}, + {SIMEDGE_SEAM, "SEAM", 0, "Seam", ""}, + {SIMEDGE_SHARP, "SHARP", 0, "Sharpness", ""}, + {SIMFACE_MATERIAL, "MATERIAL", 0, "Material", ""}, + {SIMFACE_IMAGE, "IMAGE", 0, "Image", ""}, + {SIMFACE_AREA, "AREA", 0, "Area", ""}, + {SIMFACE_PERIMETER, "PERIMETER", 0, "Perimeter", ""}, + {SIMFACE_NORMAL, "NORMAL", 0, "Normal", ""}, + {SIMFACE_COPLANAR, "COPLANAR", 0, "Co-planar", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1290,8 +1288,8 @@ void MESH_OT_select_similar(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Select Similar"); - ot->description= _("Select similar vertices, edges or faces by property types"); + ot->name= "Select Similar"; + ot->description= "Select similar vertices, edges or faces by property types"; ot->idname= "MESH_OT_select_similar"; /* api callbacks */ @@ -1303,10 +1301,10 @@ void MESH_OT_select_similar(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_similar_types), SIMVERT_NORMAL, _("Type"), ""); + prop= RNA_def_enum(ot->srna, "type", prop_similar_types, SIMVERT_NORMAL, "Type", ""); RNA_def_enum_funcs(prop, select_similar_type_itemf); ot->prop= prop; - RNA_def_float(ot->srna, "threshold", 0.01f, 0.0f, FLT_MAX, _("Threshold"), "", 0.0f, 100.f); + RNA_def_float(ot->srna, "threshold", 0.01f, 0.0f, FLT_MAX, "Threshold", "", 0.0f, 100.f); } /* ******************************************* */ @@ -2042,8 +2040,8 @@ static int loop_multiselect(bContext *C, wmOperator *op) void MESH_OT_loop_multi_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Multi Select Loops"); - ot->description= _("Select a loop of connected edges by connection type"); + ot->name= "Multi Select Loops"; + ot->description= "Select a loop of connected edges by connection type"; ot->idname= "MESH_OT_loop_multi_select"; /* api callbacks */ @@ -2054,7 +2052,7 @@ void MESH_OT_loop_multi_select(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "ring", 0, _("Ring"), ""); + RNA_def_boolean(ot->srna, "ring", 0, "Ring", ""); } @@ -2132,8 +2130,8 @@ static int mesh_select_loop_invoke(bContext *C, wmOperator *op, wmEvent *event) void MESH_OT_loop_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Loop Select"); - ot->description= _("Select a loop of connected edges"); + ot->name= "Loop Select"; + ot->description= "Select a loop of connected edges"; ot->idname= "MESH_OT_loop_select"; /* api callbacks */ @@ -2144,8 +2142,8 @@ void MESH_OT_loop_select(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); - RNA_def_boolean(ot->srna, "ring", 0, _("Select Ring"), ""); + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); + RNA_def_boolean(ot->srna, "ring", 0, "Select Ring", ""); } /* ******************* mesh shortest path select, uses prev-selected edge ****************** */ @@ -2263,8 +2261,8 @@ static int mesh_shortest_path_select_poll(bContext *C) void MESH_OT_select_shortest_path(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shortest Path Select"); - ot->description= _("Select shortest path between two selections"); + ot->name= "Shortest Path Select"; + ot->description= "Select shortest path between two selections"; ot->idname= "MESH_OT_select_shortest_path"; /* api callbacks */ @@ -2275,7 +2273,7 @@ void MESH_OT_select_shortest_path(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); } @@ -2571,8 +2569,8 @@ static int select_linked_pick_invoke(bContext *C, wmOperator *op, wmEvent *event void MESH_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked"); - ot->description= _("(un)select all vertices linked to the active mesh"); + ot->name= "Select Linked"; + ot->description= "(un)select all vertices linked to the active mesh"; ot->idname= "MESH_OT_select_linked_pick"; /* api callbacks */ @@ -2582,8 +2580,8 @@ void MESH_OT_select_linked_pick(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "deselect", 0, _("Deselect"), ""); - RNA_def_boolean(ot->srna, "limit", 0, _("Limit by Seams"), _("Limit selection by seam boundaries (faces only)")); + RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", ""); + RNA_def_boolean(ot->srna, "limit", 0, "Limit by Seams", "Limit selection by seam boundaries (faces only)"); } @@ -2660,8 +2658,8 @@ static int select_linked_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(eve void MESH_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked All"); - ot->description= _("Select all vertices linked to the active mesh"); + ot->name= "Select Linked All"; + ot->description= "Select all vertices linked to the active mesh"; ot->idname= "MESH_OT_select_linked"; /* api callbacks */ @@ -2672,7 +2670,7 @@ void MESH_OT_select_linked(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "limit", 0, _("Limit by Seams"), _("Limit selection by seam boundaries (faces only)")); + RNA_def_boolean(ot->srna, "limit", 0, "Limit by Seams", "Limit selection by seam boundaries (faces only)"); } @@ -2797,8 +2795,8 @@ static int hide_mesh_exec(bContext *C, wmOperator *op) void MESH_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selection"); - ot->description= _("Hide (un)selected vertices, edges or faces"); + ot->name= "Hide Selection"; + ot->description= "Hide (un)selected vertices, edges or faces"; ot->idname= "MESH_OT_hide"; /* api callbacks */ @@ -2809,7 +2807,7 @@ void MESH_OT_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } void EM_reveal_mesh(EditMesh *em) @@ -2864,8 +2862,8 @@ static int reveal_mesh_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal Hidden"); - ot->description= _("Reveal all hidden vertices, edges and faces"); + ot->name= "Reveal Hidden"; + ot->description= "Reveal all hidden vertices, edges and faces"; ot->idname= "MESH_OT_reveal"; /* api callbacks */ @@ -2915,14 +2913,14 @@ static int select_by_number_vertices_exec(bContext *C, wmOperator *op) void MESH_OT_select_by_number_vertices(wmOperatorType *ot) { static const EnumPropertyItem type_items[]= { - {3, "TRIANGLES", 0, N_("Triangles"), NULL}, - {4, "QUADS", 0, N_("Quads"), NULL}, - {5, "OTHER", 0, N_("Other"), NULL}, + {3, "TRIANGLES", 0, "Triangles", NULL}, + {4, "QUADS", 0, "Quads", NULL}, + {5, "OTHER", 0, "Other", NULL}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Select by Number of Vertices"); - ot->description= _("Select vertices or faces by vertex count"); + ot->name= "Select by Number of Vertices"; + ot->description= "Select vertices or faces by vertex count"; ot->idname= "MESH_OT_select_by_number_vertices"; /* api callbacks */ @@ -2934,7 +2932,7 @@ void MESH_OT_select_by_number_vertices(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "type", type_items, 3, _("Type"), _("Type of elements to select.")); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, 3, "Type", "Type of elements to select."); } @@ -2955,8 +2953,8 @@ static int select_mirror_exec(bContext *C, wmOperator *op) void MESH_OT_select_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Mirror"); - ot->description= _("Select mesh items at mirrored locations"); + ot->name= "Select Mirror"; + ot->description= "Select mesh items at mirrored locations"; ot->idname= "MESH_OT_select_mirror"; /* api callbacks */ @@ -2967,7 +2965,7 @@ void MESH_OT_select_mirror(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend the existing selection")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend the existing selection"); } static int select_sharp_edges_exec(bContext *C, wmOperator *op) @@ -3076,8 +3074,8 @@ static int select_sharp_edges_exec(bContext *C, wmOperator *op) void MESH_OT_edges_select_sharp(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Sharp Edges"); - ot->description= _("Marked selected edges as sharp"); + ot->name= "Select Sharp Edges"; + ot->description= "Marked selected edges as sharp"; ot->idname= "MESH_OT_edges_select_sharp"; /* api callbacks */ @@ -3088,7 +3086,7 @@ void MESH_OT_edges_select_sharp(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_float(ot->srna, "sharpness", 0.01f, 0.0f, FLT_MAX, _("sharpness"), "", 0.0f, 180.0f); + RNA_def_float(ot->srna, "sharpness", 0.01f, 0.0f, FLT_MAX, "sharpness", "", 0.0f, 180.0f); } @@ -3244,8 +3242,8 @@ static int select_linked_flat_faces_exec(bContext *C, wmOperator *op) void MESH_OT_faces_select_linked_flat(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked Flat Faces"); - ot->description= _("Select linked faces by angle"); + ot->name= "Select Linked Flat Faces"; + ot->description= "Select linked faces by angle"; ot->idname= "MESH_OT_faces_select_linked_flat"; /* api callbacks */ @@ -3256,7 +3254,7 @@ void MESH_OT_faces_select_linked_flat(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_float(ot->srna, "sharpness", 135.0f, 0.0f, FLT_MAX, _("sharpness"), "", 0.0f, 180.0f); + RNA_def_float(ot->srna, "sharpness", 135.0f, 0.0f, FLT_MAX, "sharpness", "", 0.0f, 180.0f); } static void select_non_manifold(EditMesh *em, wmOperator *op ) @@ -3345,8 +3343,8 @@ static int select_non_manifold_exec(bContext *C, wmOperator *op) void MESH_OT_select_non_manifold(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Non Manifold"); - ot->description= _("Select all non-manifold vertices or edges"); + ot->name= "Select Non Manifold"; + ot->description= "Select all non-manifold vertices or edges"; ot->idname= "MESH_OT_select_non_manifold"; /* api callbacks */ @@ -3409,8 +3407,8 @@ static int select_inverse_mesh_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); - ot->description= _("Select inverse of (un)selected vertices, edges or faces"); + ot->name= "Select Inverse"; + ot->description= "Select inverse of (un)selected vertices, edges or faces"; ot->idname= "MESH_OT_select_inverse"; /* api callbacks */ @@ -3471,8 +3469,8 @@ static int select_all_exec(bContext *C, wmOperator *op) void MESH_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); - ot->description= _("Change selection of all vertices, edges or faces"); + ot->name= "Select or Deselect All"; + ot->description= "Change selection of all vertices, edges or faces"; ot->idname= "MESH_OT_select_all"; /* api callbacks */ @@ -3544,8 +3542,8 @@ static int select_more(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_select_more(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select More"); - ot->description= _("Select more vertices, edges or faces connected to initial selection"); + ot->name= "Select More"; + ot->description= "Select more vertices, edges or faces connected to initial selection"; ot->idname= "MESH_OT_select_more"; /* api callbacks */ @@ -3634,8 +3632,8 @@ static int select_less(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_select_less(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Less"); - ot->description= _("Select less vertices, edges or faces connected to initial selection"); + ot->name= "Select Less"; + ot->description= "Select less vertices, edges or faces connected to initial selection"; ot->idname= "MESH_OT_select_less"; /* api callbacks */ @@ -3704,8 +3702,8 @@ static int mesh_select_random_exec(bContext *C, wmOperator *op) void MESH_OT_select_random(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Random"); - ot->description= _("Randomly select vertices"); + ot->name= "Select Random"; + ot->description= "Randomly select vertices"; ot->idname= "MESH_OT_select_random"; /* api callbacks */ @@ -3716,8 +3714,8 @@ void MESH_OT_select_random(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, _("Percent"), _("Percentage of elements to select randomly."), 0.f, 100.0f); - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend Selection"), _("Extend selection instead of deselecting everything first.")); + RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, "Percent", "Percentage of elements to select randomly.", 0.f, 100.0f); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend Selection", "Extend selection instead of deselecting everything first."); } void EM_select_by_material(EditMesh *em, int index) @@ -3799,8 +3797,8 @@ static int editmesh_mark_seam(bContext *C, wmOperator *op) void MESH_OT_mark_seam(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mark Seam"); - ot->description= _("(un)mark selected edges as a seam"); + ot->name= "Mark Seam"; + ot->description= "(un)mark selected edges as a seam"; ot->idname= "MESH_OT_mark_seam"; /* api callbacks */ @@ -3810,7 +3808,7 @@ void MESH_OT_mark_seam(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "clear", 0, _("Clear"), ""); + RNA_def_boolean(ot->srna, "clear", 0, "Clear", ""); } static int editmesh_mark_sharp(bContext *C, wmOperator *op) @@ -3851,8 +3849,8 @@ static int editmesh_mark_sharp(bContext *C, wmOperator *op) void MESH_OT_mark_sharp(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mark Sharp"); - ot->description= _("(un)mark selected edges as sharp"); + ot->name= "Mark Sharp"; + ot->description= "(un)mark selected edges as sharp"; ot->idname= "MESH_OT_mark_sharp"; /* api callbacks */ @@ -3862,7 +3860,7 @@ void MESH_OT_mark_sharp(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "clear", 0, _("Clear"), ""); + RNA_def_boolean(ot->srna, "clear", 0, "Clear", ""); } /* **************** NORMALS ************** */ @@ -4095,8 +4093,8 @@ static int normals_make_consistent_exec(bContext *C, wmOperator *op) void MESH_OT_normals_make_consistent(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Normals Consistent"); - ot->description= _("Flip all selected vertex and face normals in a consistent direction"); + ot->name= "Make Normals Consistent"; + ot->description= "Flip all selected vertex and face normals in a consistent direction"; ot->idname= "MESH_OT_normals_make_consistent"; /* api callbacks */ @@ -4106,7 +4104,7 @@ void MESH_OT_normals_make_consistent(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "inside", 0, _("Inside"), ""); + RNA_def_boolean(ot->srna, "inside", 0, "Inside", ""); } /* **************** VERTEX DEFORMS *************** */ @@ -4273,8 +4271,8 @@ static int smooth_vertex_exec(bContext *C, wmOperator *op) void MESH_OT_vertices_smooth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth Vertex"); - ot->description= _("Flatten angles of selected vertices"); + ot->name= "Smooth Vertex"; + ot->description= "Flatten angles of selected vertices"; ot->idname= "MESH_OT_vertices_smooth"; /* api callbacks */ @@ -4284,10 +4282,10 @@ void MESH_OT_vertices_smooth(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "repeat", 1, 1, 100, _("Smooth Iterations"), "", 1, INT_MAX); - RNA_def_boolean(ot->srna, "xaxis", 1, _("X-Axis"), _("Smooth along the X axis.")); - RNA_def_boolean(ot->srna, "yaxis", 1, _("Y-Axis"), _("Smooth along the Y axis.")); - RNA_def_boolean(ot->srna, "zaxis", 1, _("Z-Axis"), _("Smooth along the Z axis.")); + RNA_def_int(ot->srna, "repeat", 1, 1, 100, "Smooth Iterations", "", 1, INT_MAX); + RNA_def_boolean(ot->srna, "xaxis", 1, "X-Axis", "Smooth along the X axis."); + RNA_def_boolean(ot->srna, "yaxis", 1, "Y-Axis", "Smooth along the Y axis."); + RNA_def_boolean(ot->srna, "zaxis", 1, "Z-Axis", "Smooth along the Z axis."); } static int mesh_noise_exec(bContext *C, wmOperator *op) @@ -4347,8 +4345,8 @@ static int mesh_noise_exec(bContext *C, wmOperator *op) void MESH_OT_noise(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Noise"); - ot->description= _("Use vertex coordinate as texture coordinate"); + ot->name= "Noise"; + ot->description= "Use vertex coordinate as texture coordinate"; ot->idname= "MESH_OT_noise"; /* api callbacks */ @@ -4358,7 +4356,7 @@ void MESH_OT_noise(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float(ot->srna, "factor", 0.1f, -FLT_MAX, FLT_MAX, _("Factor"), "", 0.0f, 1.0f); + RNA_def_float(ot->srna, "factor", 0.1f, -FLT_MAX, FLT_MAX, "Factor", "", 0.0f, 1.0f); } void flipface(EditMesh *em, EditFace *efa) @@ -4409,8 +4407,8 @@ static int flip_normals(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_flip_normals(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Normals"); - ot->description= _("Toggle the direction of selected face's vertex and face normals"); + ot->name= "Flip Normals"; + ot->description= "Toggle the direction of selected face's vertex and face normals"; ot->idname= "MESH_OT_flip_normals"; /* api callbacks */ @@ -4451,8 +4449,8 @@ void MESH_OT_solidify(wmOperatorType *ot) { PropertyRNA *prop; /* identifiers */ - ot->name= _("Solidify"); - ot->description= _("Create a solid skin by extruding, compensating for sharp angles"); + ot->name= "Solidify"; + ot->description= "Create a solid skin by extruding, compensating for sharp angles"; ot->idname= "MESH_OT_solidify"; /* api callbacks */ @@ -4462,7 +4460,7 @@ void MESH_OT_solidify(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - prop= RNA_def_float(ot->srna, "thickness", 0.01f, -FLT_MAX, FLT_MAX, _("Thickness"), "", -10.0f, 10.0f); + prop= RNA_def_float(ot->srna, "thickness", 0.01f, -FLT_MAX, FLT_MAX, "Thickness", "", -10.0f, 10.0f); RNA_def_property_ui_range(prop, -10, 10, 0.1, 4); } @@ -4486,7 +4484,7 @@ static int mesh_select_nth_exec(bContext *C, wmOperator *op) void MESH_OT_select_nth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Nth"); + ot->name= "Select Nth"; ot->description= ""; ot->idname= "MESH_OT_select_nth"; @@ -4497,6 +4495,6 @@ void MESH_OT_select_nth(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "nth", 2, 2, 100, _("Nth Selection"), "", 1, INT_MAX); + RNA_def_int(ot->srna, "nth", 2, 2, 100, "Nth Selection", "", 1, INT_MAX); } diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c index 44412062be3..2dc82ae89fb 100644 --- a/source/blender/editors/mesh/editmesh_tools.c +++ b/source/blender/editors/mesh/editmesh_tools.c @@ -65,8 +65,6 @@ editmesh_tool.c: UI called tools for editmesh, geometry changes here, otherwise #include "BLI_heap.h" #include "BLI_scanfill.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_global.h" @@ -508,8 +506,8 @@ void MESH_OT_remove_doubles(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Remove Doubles"); - ot->description= _("Remove duplicate vertices"); + ot->name= "Remove Doubles"; + ot->description= "Remove duplicate vertices"; ot->idname= "MESH_OT_remove_doubles"; /* api callbacks */ @@ -519,7 +517,7 @@ void MESH_OT_remove_doubles(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - prop= RNA_def_float(ot->srna, "limit", 0.0001f, 0.000001f, 50.0f, _("Merge Threshold"), _("Minimum distance between merged verts"), 0.00001f, 2.0f); + prop= RNA_def_float(ot->srna, "limit", 0.0001f, 0.000001f, 50.0f, "Merge Threshold", "Minimum distance between merged verts", 0.00001f, 2.0f); RNA_def_property_ui_range(prop, 0.000001f, 50.0f, 0.001, 5); } @@ -580,8 +578,8 @@ static int mesh_vertices_sort_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_vertices_sort(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Sort"); - ot->description= _("Sort vertex order"); + ot->name= "Vertex Sort"; + ot->description= "Sort vertex order"; ot->idname= "MESH_OT_vertices_sort"; /* api callbacks */ @@ -663,8 +661,8 @@ static int mesh_vertices_randomize_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_vertices_randomize(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Randomize"); - ot->description= _("Randomize vertex order"); + ot->name= "Vertex Randomize"; + ot->description= "Randomize vertex order"; ot->idname= "MESH_OT_vertices_randomize"; /* api callbacks */ @@ -757,10 +755,10 @@ static int mesh_extrude_exec(bContext *C, wmOperator *op) } static EnumPropertyItem extrude_items[] = { - {1, "REGION", 0, N_("Region"), ""}, - {2, "FACES", 0, N_("Individual Faces"), ""}, - {3, "EDGES", 0, N_("Only Edges"), ""}, - {4, "VERTS", 0, N_("Only Vertices"), ""}, + {1, "REGION", 0, "Region", ""}, + {2, "FACES", 0, "Individual Faces", ""}, + {3, "EDGES", 0, "Only Edges", ""}, + {4, "VERTS", 0, "Only Vertices", ""}, {0, NULL, 0, NULL, NULL}}; @@ -837,8 +835,8 @@ void MESH_OT_extrude(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Extrude"); - ot->description= _("Extrude selected vertices, edges or faces"); + ot->name= "Extrude"; + ot->description= "Extrude selected vertices, edges or faces"; ot->idname= "MESH_OT_extrude"; /* api callbacks */ @@ -850,8 +848,7 @@ void MESH_OT_extrude(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - /* gettext extrude_items will raise segment fault */ - prop= RNA_def_enum(ot->srna, "type", extrude_items, 0, _("Type"), ""); + prop= RNA_def_enum(ot->srna, "type", extrude_items, 0, "Type", ""); RNA_def_property_flag(prop, PROP_HIDDEN); RNA_def_enum_funcs(prop, mesh_extrude_itemf); ot->prop= prop; @@ -882,8 +879,8 @@ static int split_mesh(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_split(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Split"); - ot->description= _("Split selected geometry into separate disconnected mesh"); + ot->name= "Split"; + ot->description= "Split selected geometry into separate disconnected mesh"; ot->idname= "MESH_OT_split"; /* api callbacks */ @@ -949,8 +946,8 @@ static int extrude_repeat_mesh_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void MESH_OT_extrude_repeat(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Extrude Repeat Mesh"); - ot->description= _("Extrude selected vertices, edges or faces repeatedly"); + ot->name= "Extrude Repeat Mesh"; + ot->description= "Extrude selected vertices, edges or faces repeatedly"; ot->idname= "MESH_OT_extrude_repeat"; /* api callbacks */ @@ -962,9 +959,9 @@ void MESH_OT_extrude_repeat(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_float(ot->srna, "offset", 2.0f, 0.0f, 100.0f, _("Offset"), "", 0.0f, 100.0f); - RNA_def_int(ot->srna, "steps", 10, 0, 180, _("Steps"), "", 0, 180); - RNA_def_float_vector(ot->srna, "direction", 3, NULL, -FLT_MAX, FLT_MAX, _("Direction"), _("Direction of extrude"), -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "offset", 2.0f, 0.0f, 100.0f, "Offset", "", 0.0f, 100.0f); + RNA_def_int(ot->srna, "steps", 10, 0, 180, "Steps", "", 0, 180); + RNA_def_float_vector(ot->srna, "direction", 3, NULL, -FLT_MAX, FLT_MAX, "Direction", "Direction of extrude", -FLT_MAX, FLT_MAX); } /* ************************** spin operator ******************** */ @@ -1085,8 +1082,8 @@ static int spin_mesh_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void MESH_OT_spin(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Spin"); - ot->description= _("Extrude selected vertices in a circle around the cursor in indicated viewport"); + ot->name= "Spin"; + ot->description= "Extrude selected vertices in a circle around the cursor in indicated viewport"; ot->idname= "MESH_OT_spin"; /* api callbacks */ @@ -1098,12 +1095,12 @@ void MESH_OT_spin(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_int(ot->srna, "steps", 9, 0, INT_MAX, _("Steps"), _("Steps"), 0, 128); - RNA_def_boolean(ot->srna, "dupli", 0, _("Dupli"), _("Make Duplicates")); - RNA_def_float(ot->srna, "degrees", 90.0f, -FLT_MAX, FLT_MAX, _("Degrees"), _("Degrees"), -360.0f, 360.0f); + RNA_def_int(ot->srna, "steps", 9, 0, INT_MAX, "Steps", "Steps", 0, 128); + RNA_def_boolean(ot->srna, "dupli", 0, "Dupli", "Make Duplicates"); + RNA_def_float(ot->srna, "degrees", 90.0f, -FLT_MAX, FLT_MAX, "Degrees", "Degrees", -360.0f, 360.0f); - RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, _("Center"), _("Center in global view space"), -FLT_MAX, FLT_MAX); - RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, _("Axis"), _("Axis in global view space"), -FLT_MAX, FLT_MAX); + RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, "Center", "Center in global view space", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, "Axis", "Axis in global view space", -FLT_MAX, FLT_MAX); } @@ -1191,8 +1188,8 @@ static int screw_mesh_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event) void MESH_OT_screw(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Screw"); - ot->description= _("Extrude selected vertices in screw-shaped rotation around the cursor in indicated viewport"); + ot->name= "Screw"; + ot->description= "Extrude selected vertices in screw-shaped rotation around the cursor in indicated viewport"; ot->idname= "MESH_OT_screw"; /* api callbacks */ @@ -1204,11 +1201,11 @@ void MESH_OT_screw(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /*props */ - RNA_def_int(ot->srna, "steps", 9, 0, INT_MAX, _("Steps"), _("Steps"), 0, 256); - RNA_def_int(ot->srna, "turns", 1, 0, INT_MAX, _("Turns"), _("Turns"), 0, 256); + RNA_def_int(ot->srna, "steps", 9, 0, INT_MAX, "Steps", "Steps", 0, 256); + RNA_def_int(ot->srna, "turns", 1, 0, INT_MAX, "Turns", "Turns", 0, 256); - RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, _("Center"), _("Center in global view space"), -FLT_MAX, FLT_MAX); - RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, _("Axis"), _("Axis in global view space"), -FLT_MAX, FLT_MAX); + RNA_def_float_vector_xyz(ot->srna, "center", 3, NULL, -FLT_MAX, FLT_MAX, "Center", "Center in global view space", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "axis", 3, NULL, -1.0f, 1.0f, "Axis", "Axis in global view space", -FLT_MAX, FLT_MAX); } static void erase_edges(EditMesh *em, ListBase *l) @@ -1396,13 +1393,13 @@ static void delete_mesh(EditMesh *em, wmOperator *op, int event) /* Note, these values must match delete_mesh() event values */ static EnumPropertyItem prop_mesh_delete_types[] = { - {10,"VERT", 0, N_("Vertices"), ""}, - {1, "EDGE", 0, N_("Edges"), ""}, - {2, "FACE", 0, N_("Faces"), ""}, - {3, "ALL", 0, N_("All"), ""}, - {4, "EDGE_FACE",0, N_("Edges & Faces"), ""}, - {5, "ONLY_FACE",0, N_("Only Faces"), ""}, - {6, "EDGE_LOOP",0, N_("Edge Loop"), ""}, + {10,"VERT", 0, "Vertices", ""}, + {1, "EDGE", 0, "Edges", ""}, + {2, "FACE", 0, "Faces", ""}, + {3, "ALL", 0, "All", ""}, + {4, "EDGE_FACE",0, "Edges & Faces", ""}, + {5, "ONLY_FACE",0, "Only Faces", ""}, + {6, "EDGE_LOOP",0, "Edge Loop", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1427,8 +1424,8 @@ static int delete_mesh_exec(bContext *C, wmOperator *op) void MESH_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description= _("Delete selected vertices, edges or faces"); + ot->name= "Delete"; + ot->description= "Delete selected vertices, edges or faces"; ot->idname= "MESH_OT_delete"; /* api callbacks */ @@ -1441,7 +1438,7 @@ void MESH_OT_delete(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /*props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_mesh_delete_types), 10, _("Type"), _("Method used for deleting mesh data")); + ot->prop= RNA_def_enum(ot->srna, "type", prop_mesh_delete_types, 10, "Type", "Method used for deleting mesh data"); } @@ -5116,8 +5113,8 @@ static int mesh_rip_invoke(bContext *C, wmOperator *op, wmEvent *event) void MESH_OT_rip(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rip"); - ot->description= _("Rip selection from mesh (quads only)"); + ot->name= "Rip"; + ot->description= "Rip selection from mesh (quads only)"; ot->idname= "MESH_OT_rip"; /* api callbacks */ @@ -5197,8 +5194,8 @@ static int shape_propagate_to_all_exec(bContext *C, wmOperator *op) void MESH_OT_shape_propagate_to_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shape Propagate"); - ot->description= _("Apply selected vertex locations to all other shape keys"); + ot->name= "Shape Propagate"; + ot->description= "Apply selected vertex locations to all other shape keys"; ot->idname= "MESH_OT_shape_propagate_to_all"; /* api callbacks */ @@ -5303,8 +5300,8 @@ void MESH_OT_blend_from_shape(wmOperatorType *ot) static EnumPropertyItem shape_items[]= {{0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Blend From Shape"); - ot->description= _("Blend in shape from a shape key"); + ot->name= "Blend From Shape"; + ot->description= "Blend in shape from a shape key"; ot->idname= "MESH_OT_blend_from_shape"; /* api callbacks */ @@ -5316,10 +5313,10 @@ void MESH_OT_blend_from_shape(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "shape", shape_items, 0, _("Shape"), _("Shape key to use for blending.")); + prop= RNA_def_enum(ot->srna, "shape", shape_items, 0, "Shape", "Shape key to use for blending."); RNA_def_enum_funcs(prop, shape_itemf); - RNA_def_float(ot->srna, "blend", 1.0f, -FLT_MAX, FLT_MAX, _("Blend"), _("Blending factor."), -2.0f, 2.0f); - RNA_def_boolean(ot->srna, "add", 0, _("Add"), _("Add rather than blend between shapes.")); + RNA_def_float(ot->srna, "blend", 1.0f, -FLT_MAX, FLT_MAX, "Blend", "Blending factor.", -2.0f, 2.0f); + RNA_def_boolean(ot->srna, "add", 0, "Add", "Add rather than blend between shapes."); } /************************ Merge Operator *************************/ @@ -5971,11 +5968,11 @@ static int merge_exec(bContext *C, wmOperator *op) } static EnumPropertyItem merge_type_items[]= { - {6, "FIRST", 0, N_("At First"), ""}, - {1, "LAST", 0, N_("At Last"), ""}, - {3, "CENTER", 0, N_("At Center"), ""}, - {4, "CURSOR", 0, N_("At Cursor"), ""}, - {5, "COLLAPSE", 0, N_("Collapse"), ""}, + {6, "FIRST", 0, "At First", ""}, + {1, "LAST", 0, "At Last", ""}, + {3, "CENTER", 0, "At Center", ""}, + {4, "CURSOR", 0, "At Cursor", ""}, + {5, "COLLAPSE", 0, "Collapse", ""}, {0, NULL, 0, NULL, NULL}}; static EnumPropertyItem *merge_type_itemf(bContext *C, PointerRNA *UNUSED(ptr), PropertyRNA *UNUSED(prop), int *free) @@ -6019,8 +6016,8 @@ void MESH_OT_merge(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Merge"); - ot->description= _("Merge selected vertices"); + ot->name= "Merge"; + ot->description= "Merge selected vertices"; ot->idname= "MESH_OT_merge"; /* api callbacks */ @@ -6032,10 +6029,10 @@ void MESH_OT_merge(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "type", merge_type_items, 3, _("Type"), _("Merge method to use.")); + prop= RNA_def_enum(ot->srna, "type", merge_type_items, 3, "Type", "Merge method to use."); RNA_def_enum_funcs(prop, merge_type_itemf); ot->prop= prop; - RNA_def_boolean(ot->srna, "uvs", 0, _("UVs"), _("Move UVs according to merge.")); + RNA_def_boolean(ot->srna, "uvs", 0, "UVs", "Move UVs according to merge."); } /************************ Vertex Path Operator *************************/ @@ -6222,13 +6219,13 @@ static int select_vertex_path_exec(bContext *C, wmOperator *op) void MESH_OT_select_vertex_path(wmOperatorType *ot) { static const EnumPropertyItem type_items[] = { - {PATH_SELECT_EDGE_LENGTH, "EDGE_LENGTH", 0, N_("Edge Length"), NULL}, - {PATH_SELECT_TOPOLOGICAL, "TOPOLOGICAL", 0, N_("Topological"), NULL}, + {PATH_SELECT_EDGE_LENGTH, "EDGE_LENGTH", 0, "Edge Length", NULL}, + {PATH_SELECT_TOPOLOGICAL, "TOPOLOGICAL", 0, "Topological", NULL}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Select Vertex Path"); - ot->description= _("Select shortest path between two vertices by distance type"); + ot->name= "Select Vertex Path"; + ot->description= "Select shortest path between two vertices by distance type"; ot->idname= "MESH_OT_select_vertex_path"; /* api callbacks */ @@ -6239,7 +6236,7 @@ void MESH_OT_select_vertex_path(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", type_items, PATH_SELECT_EDGE_LENGTH, _("Type"), _("Method to compute distance.")); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, PATH_SELECT_EDGE_LENGTH, "Type", "Method to compute distance."); } /********************** Region/Loop Operators *************************/ @@ -6289,8 +6286,8 @@ static int region_to_loop(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_region_to_loop(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Region to Loop"); - ot->description= _("Select a region as a loop of connected edges"); + ot->name= "Region to Loop"; + ot->description= "Select a region as a loop of connected edges"; ot->idname= "MESH_OT_region_to_loop"; /* api callbacks */ @@ -6465,8 +6462,8 @@ static int loop_to_region(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_loop_to_region(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Loop to Region"); - ot->description= _("Select a loop of connected edges as a region"); + ot->name= "Loop to Region"; + ot->description= "Select a loop of connected edges as a region"; ot->idname= "MESH_OT_loop_to_region"; /* api callbacks */ @@ -6760,8 +6757,8 @@ static int mesh_mirror_colors(bContext *C, wmOperator *op) void MESH_OT_uvs_rotate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rotate UVs"); - ot->description= _("Rotate selected UVs"); + ot->name= "Rotate UVs"; + ot->description= "Rotate selected UVs"; ot->idname= "MESH_OT_uvs_rotate"; /* api callbacks */ @@ -6772,14 +6769,14 @@ void MESH_OT_uvs_rotate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_enum(ot->srna, "direction", direction_items, DIRECTION_CW, _("Direction"), _("Direction to rotate UVs around.")); + RNA_def_enum(ot->srna, "direction", direction_items, DIRECTION_CW, "Direction", "Direction to rotate UVs around."); } void MESH_OT_uvs_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror UVs"); - ot->description= _("Mirror selected UVs"); + ot->name= "Mirror UVs"; + ot->description= "Mirror selected UVs"; ot->idname= "MESH_OT_uvs_mirror"; /* api callbacks */ @@ -6790,14 +6787,14 @@ void MESH_OT_uvs_mirror(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_enum(ot->srna, "axis", axis_items_xy, DIRECTION_CW, _("Axis"), _("Axis to mirror UVs around.")); + RNA_def_enum(ot->srna, "axis", axis_items_xy, DIRECTION_CW, "Axis", "Axis to mirror UVs around."); } void MESH_OT_colors_rotate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rotate Colors"); - ot->description= _("Rotate UV/image color layer"); + ot->name= "Rotate Colors"; + ot->description= "Rotate UV/image color layer"; ot->idname= "MESH_OT_colors_rotate"; /* api callbacks */ @@ -6808,14 +6805,14 @@ void MESH_OT_colors_rotate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_enum(ot->srna, "direction", direction_items, DIRECTION_CW, _("Direction"), _("Direction to rotate edge around.")); + RNA_def_enum(ot->srna, "direction", direction_items, DIRECTION_CW, "Direction", "Direction to rotate edge around."); } void MESH_OT_colors_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror Colors"); - ot->description= _("Mirror UV/image color layer"); + ot->name= "Mirror Colors"; + ot->description= "Mirror UV/image color layer"; ot->idname= "MESH_OT_colors_mirror"; /* api callbacks */ @@ -6826,7 +6823,7 @@ void MESH_OT_colors_mirror(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_enum(ot->srna, "axis", axis_items_xy, DIRECTION_CW, _("Axis"), _("Axis to mirror colors around.")); + RNA_def_enum(ot->srna, "axis", axis_items_xy, DIRECTION_CW, "Axis", "Axis to mirror colors around."); } /********************** Subdivide Operator *************************/ @@ -6858,8 +6855,8 @@ static int subdivide_exec(bContext *C, wmOperator *op) void MESH_OT_subdivide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Subdivide"); - ot->description= _("Subdivide selected edges"); + ot->name= "Subdivide"; + ot->description= "Subdivide selected edges"; ot->idname= "MESH_OT_subdivide"; /* api callbacks */ @@ -6870,10 +6867,10 @@ void MESH_OT_subdivide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, _("Number of Cuts"), "", 1, 10); - RNA_def_float(ot->srna, "smoothness", 0.0f, 0.0f, FLT_MAX, _("Smoothness"), _("Smoothness factor."), 0.0f, 1.0f); - RNA_def_float(ot->srna, "fractal", 0.0, 0.0f, FLT_MAX, _("Fractal"), _("Fractal randomness factor."), 0.0f, 1000.0f); - RNA_def_enum(ot->srna, "corner_cut_pattern", corner_type_items, SUBDIV_CORNER_INNERVERT, _("Corner Cut Pattern"), _("Topology pattern to use to fill a face after cutting across its corner")); + RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, "Number of Cuts", "", 1, 10); + RNA_def_float(ot->srna, "smoothness", 0.0f, 0.0f, FLT_MAX, "Smoothness", "Smoothness factor.", 0.0f, 1.0f); + RNA_def_float(ot->srna, "fractal", 0.0, 0.0f, FLT_MAX, "Fractal", "Fractal randomness factor.", 0.0f, 1000.0f); + RNA_def_enum(ot->srna, "corner_cut_pattern", corner_type_items, SUBDIV_CORNER_INNERVERT, "Corner Cut Pattern", "Topology pattern to use to fill a face after cutting across its corner"); } /********************** Fill Operators *************************/ @@ -7141,8 +7138,8 @@ static int fill_mesh_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_fill(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Fill"); - ot->description= _("Create a segment, edge or face"); + ot->name= "Fill"; + ot->description= "Create a segment, edge or face"; ot->idname= "MESH_OT_fill"; /* api callbacks */ @@ -7171,8 +7168,8 @@ static int beautify_fill_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_beautify_fill(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Beautify Fill"); - ot->description= _("Rearrange geometry on a selected surface to avoid skinny faces"); + ot->name= "Beautify Fill"; + ot->description= "Rearrange geometry on a selected surface to avoid skinny faces"; ot->idname= "MESH_OT_beautify_fill"; /* api callbacks */ @@ -7337,16 +7334,16 @@ static int sort_faces_exec(bContext *C, wmOperator *op) void MESH_OT_sort_faces(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - { 1, "VIEW_AXIS", 0, N_("View Axis"), "" }, - { 2, "CURSOR_DISTANCE", 0, N_("Cursor Distance"), "" }, - { 3, "MATERIAL", 0, N_("Material"), "" }, - { 4, "SELECTED", 0, N_("Selected"), "" }, - { 5, "RANDOMIZE", 0, N_("Randomize"), "" }, + { 1, "VIEW_AXIS", 0, "View Axis", "" }, + { 2, "CURSOR_DISTANCE", 0, "Cursor Distance", "" }, + { 3, "MATERIAL", 0, "Material", "" }, + { 4, "SELECTED", 0, "Selected", "" }, + { 5, "RANDOMIZE", 0, "Randomize", "" }, { 0, NULL, 0, NULL, NULL }}; /* identifiers */ - ot->name= _("Sort Faces"); // XXX (Ctrl to reverse)%t| - ot->description= _("The faces of the active Mesh Object are sorted, based on the current view."); + ot->name= "Sort Faces"; // XXX (Ctrl to reverse)%t| + ot->description= "The faces of the active Mesh Object are sorted, based on the current view."; ot->idname= "MESH_OT_sort_faces"; /* api callbacks */ @@ -7358,7 +7355,7 @@ void MESH_OT_sort_faces(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, 0, "Type", ""); } /********************** Quad/Tri Operators *************************/ @@ -7380,8 +7377,8 @@ static int quads_convert_to_tris_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_quads_convert_to_tris(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Quads to Tris"); - ot->description= _("Convert selected quads to triangles"); + ot->name= "Quads to Tris"; + ot->description= "Convert selected quads to triangles"; ot->idname= "MESH_OT_quads_convert_to_tris"; /* api callbacks */ @@ -7409,8 +7406,8 @@ static int tris_convert_to_quads_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_tris_convert_to_quads(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Tris to Quads"); - ot->description= _("Convert selected triangles to quads"); + ot->name= "Tris to Quads"; + ot->description= "Convert selected triangles to quads"; ot->idname= "MESH_OT_tris_convert_to_quads"; /* api callbacks */ @@ -7438,8 +7435,8 @@ static int edge_flip_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_edge_flip(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Edge Flip"); - ot->description= _("Flip selected edge or adjoining faces"); + ot->name= "Edge Flip"; + ot->description= "Flip selected edge or adjoining faces"; ot->idname= "MESH_OT_edge_flip"; /* api callbacks */ @@ -7486,8 +7483,8 @@ static int mesh_faces_shade_smooth_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_faces_shade_smooth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Smooth"); - ot->description= _("Display faces 'smooth' (using vertex normals)"); + ot->name= "Shade Smooth"; + ot->description= "Display faces 'smooth' (using vertex normals)"; ot->idname= "MESH_OT_faces_shade_smooth"; /* api callbacks */ @@ -7514,8 +7511,8 @@ static int mesh_faces_shade_flat_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_faces_shade_flat(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Flat"); - ot->description= _("Display faces 'flat'"); + ot->name= "Shade Flat"; + ot->description= "Display faces 'flat'"; ot->idname= "MESH_OT_faces_shade_flat"; /* api callbacks */ @@ -7579,20 +7576,20 @@ static int select_axis_exec(bContext *C, wmOperator *op) void MESH_OT_select_axis(wmOperatorType *ot) { static EnumPropertyItem axis_mode_items[] = { - {0, "POSITIVE", 0, N_("Positive Axis"), ""}, - {1, "NEGATIVE", 0, N_("Negative Axis"), ""}, - {-1, "ALIGNED", 0, N_("Aligned Axis"), ""}, + {0, "POSITIVE", 0, "Positive Axis", ""}, + {1, "NEGATIVE", 0, "Negative Axis", ""}, + {-1, "ALIGNED", 0, "Aligned Axis", ""}, {0, NULL, 0, NULL, NULL}}; static EnumPropertyItem axis_items_xyz[] = { - {0, "X_AXIS", 0, N_("X Axis"), ""}, - {1, "Y_AXIS", 0, N_("Y Axis"), ""}, - {2, "Z_AXIS", 0, N_("Z Axis"), ""}, + {0, "X_AXIS", 0, "X Axis", ""}, + {1, "Y_AXIS", 0, "Y Axis", ""}, + {2, "Z_AXIS", 0, "Z Axis", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Select Axis"); - ot->description= _("Select all data in the mesh on a single axis"); + ot->name= "Select Axis"; + ot->description= "Select all data in the mesh on a single axis"; ot->idname= "MESH_OT_select_axis"; /* api callbacks */ @@ -7603,7 +7600,7 @@ void MESH_OT_select_axis(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(axis_mode_items), 0, _("Axis Mode"), _("Axis side to use when selecting")); - RNA_def_enum(ot->srna, "axis", RNA_enum_items_gettexted(axis_items_xyz), 0, _("Axis"), _("Select the axis to compare each vertex on")); + RNA_def_enum(ot->srna, "mode", axis_mode_items, 0, "Axis Mode", "Axis side to use when selecting"); + RNA_def_enum(ot->srna, "axis", axis_items_xyz, 0, "Axis", "Select the axis to compare each vertex on"); } diff --git a/source/blender/editors/mesh/loopcut.c b/source/blender/editors/mesh/loopcut.c index 62a512fe11a..0ec356a88ae 100644 --- a/source/blender/editors/mesh/loopcut.c +++ b/source/blender/editors/mesh/loopcut.c @@ -53,8 +53,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_blender.h" #include "BKE_context.h" #include "BKE_depsgraph.h" @@ -512,9 +510,9 @@ static int ringcut_modal (bContext *C, wmOperator *op, wmEvent *event) void MESH_OT_edgering_select (wmOperatorType *ot) { /* description */ - ot->name= _("Edge Ring Select"); + ot->name= "Edge Ring Select"; ot->idname= "MESH_OT_edgering_select"; - ot->description= _("Select an edge ring"); + ot->description= "Select an edge ring"; /* callbacks */ ot->invoke= ringsel_invoke; @@ -523,15 +521,15 @@ void MESH_OT_edgering_select (wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend the selection")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend the selection"); } void MESH_OT_loopcut (wmOperatorType *ot) { /* description */ - ot->name= _("Loop Cut"); + ot->name= "Loop Cut"; ot->idname= "MESH_OT_loopcut"; - ot->description= _("Add a new loop between existing loops"); + ot->description= "Add a new loop between existing loops"; /* callbacks */ ot->invoke= ringcut_invoke; @@ -543,5 +541,5 @@ void MESH_OT_loopcut (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; /* properties */ - RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, _("Number of Cuts"), "", 1, 10); + RNA_def_int(ot->srna, "number_cuts", 1, 1, INT_MAX, "Number of Cuts", "", 1, 10); } diff --git a/source/blender/editors/mesh/mesh_data.c b/source/blender/editors/mesh/mesh_data.c index 73c9f817497..c4a302d4d18 100644 --- a/source/blender/editors/mesh/mesh_data.c +++ b/source/blender/editors/mesh/mesh_data.c @@ -48,8 +48,6 @@ #include "BLI_edgehash.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_displist.h" @@ -324,8 +322,8 @@ static int uv_texture_add_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_uv_texture_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add UV Texture"); - ot->description= _("Add UV texture layer"); + ot->name= "Add UV Texture"; + ot->description= "Add UV texture layer"; ot->idname= "MESH_OT_uv_texture_add"; /* api callbacks */ @@ -403,8 +401,8 @@ static int drop_named_image_invoke(bContext *C, wmOperator *op, wmEvent *event) void MESH_OT_drop_named_image(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Assign Image to UV Texture"); - ot->description= _("Assigns Image to active UV layer, or creates a UV layer"); + ot->name= "Assign Image to UV Texture"; + ot->description= "Assigns Image to active UV layer, or creates a UV layer"; ot->idname= "MESH_OT_drop_named_image"; /* api callbacks */ @@ -415,8 +413,8 @@ void MESH_OT_drop_named_image(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "name", "Image", 24, _("Name"), _("Image name to assign.")); - RNA_def_string(ot->srna, "filepath", "Path", FILE_MAX, _("Filepath"), _("Path to image file")); + RNA_def_string(ot->srna, "name", "Image", 24, "Name", "Image name to assign."); + RNA_def_string(ot->srna, "filepath", "Path", FILE_MAX, "Filepath", "Path to image file"); } static int uv_texture_remove_exec(bContext *C, wmOperator *UNUSED(op)) @@ -433,8 +431,8 @@ static int uv_texture_remove_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_uv_texture_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove UV Texture"); - ot->description= _("Remove UV texture layer"); + ot->name= "Remove UV Texture"; + ot->description= "Remove UV texture layer"; ot->idname= "MESH_OT_uv_texture_remove"; /* api callbacks */ @@ -462,8 +460,8 @@ static int vertex_color_add_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_vertex_color_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Vertex Color"); - ot->description= _("Add vertex color layer"); + ot->name= "Add Vertex Color"; + ot->description= "Add vertex color layer"; ot->idname= "MESH_OT_vertex_color_add"; /* api callbacks */ @@ -488,8 +486,8 @@ static int vertex_color_remove_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_vertex_color_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Vertex Color"); - ot->description= _("Remove vertex color layer"); + ot->name= "Remove Vertex Color"; + ot->description= "Remove vertex color layer"; ot->idname= "MESH_OT_vertex_color_remove"; /* api callbacks */ @@ -523,8 +521,8 @@ static int sticky_add_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_sticky_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Sticky"); - ot->description= _("Add sticky UV texture layer"); + ot->name= "Add Sticky"; + ot->description= "Add sticky UV texture layer"; ot->idname= "MESH_OT_sticky_add"; /* api callbacks */ @@ -555,8 +553,8 @@ static int sticky_remove_exec(bContext *C, wmOperator *UNUSED(op)) void MESH_OT_sticky_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Sticky"); - ot->description= _("Remove sticky UV texture layer"); + ot->name= "Remove Sticky"; + ot->description= "Remove sticky UV texture layer"; ot->idname= "MESH_OT_sticky_remove"; /* api callbacks */ diff --git a/source/blender/editors/mesh/mesh_ops.c b/source/blender/editors/mesh/mesh_ops.c index 077ad756150..282eeef906f 100644 --- a/source/blender/editors/mesh/mesh_ops.c +++ b/source/blender/editors/mesh/mesh_ops.c @@ -42,8 +42,6 @@ #include "BLI_blenlib.h" #include "BLI_editVert.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "RNA_access.h" @@ -174,52 +172,52 @@ void ED_operatormacros_mesh(void) wmOperatorType *ot; wmOperatorTypeMacro *otmacro; - ot= WM_operatortype_append_macro("MESH_OT_loopcut_slide", _("Loop Cut and Slide"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Cut mesh loop and slide it"); + ot= WM_operatortype_append_macro("MESH_OT_loopcut_slide", "Loop Cut and Slide", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Cut mesh loop and slide it"; WM_operatortype_macro_define(ot, "MESH_OT_loopcut"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_edge_slide"); RNA_struct_idprops_unset(otmacro->ptr, "release_confirm"); - ot= WM_operatortype_append_macro("MESH_OT_duplicate_move", _("Add Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Duplicate mesh and move"); + ot= WM_operatortype_append_macro("MESH_OT_duplicate_move", "Add Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Duplicate mesh and move"; WM_operatortype_macro_define(ot, "MESH_OT_duplicate"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); RNA_enum_set(otmacro->ptr, "proportional", 0); RNA_boolean_set(otmacro->ptr, "mirror", 0); - ot= WM_operatortype_append_macro("MESH_OT_rip_move", _("Rip"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Rip polygons and move the result"); + ot= WM_operatortype_append_macro("MESH_OT_rip_move", "Rip", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Rip polygons and move the result"; WM_operatortype_macro_define(ot, "MESH_OT_rip"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); RNA_enum_set(otmacro->ptr, "proportional", 0); RNA_boolean_set(otmacro->ptr, "mirror", 0); - ot= WM_operatortype_append_macro("MESH_OT_extrude_region_move", _("Extrude Region and Move"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Extrude region and move result"); + ot= WM_operatortype_append_macro("MESH_OT_extrude_region_move", "Extrude Region and Move", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Extrude region and move result"; otmacro= WM_operatortype_macro_define(ot, "MESH_OT_extrude"); RNA_enum_set(otmacro->ptr, "type", 1); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); RNA_enum_set(otmacro->ptr, "proportional", 0); RNA_boolean_set(otmacro->ptr, "mirror", 0); - ot= WM_operatortype_append_macro("MESH_OT_extrude_faces_move", _("Extrude Individual Faces and Move"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Extrude faces and move result"); + ot= WM_operatortype_append_macro("MESH_OT_extrude_faces_move", "Extrude Individual Faces and Move", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Extrude faces and move result"; otmacro= WM_operatortype_macro_define(ot, "MESH_OT_extrude"); RNA_enum_set(otmacro->ptr, "type", 2); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_shrink_fatten"); RNA_enum_set(otmacro->ptr, "proportional", 0); RNA_boolean_set(otmacro->ptr, "mirror", 0); - ot= WM_operatortype_append_macro("MESH_OT_extrude_edges_move", _("Extrude Only Edges and Move"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Extrude edges and move result"); + ot= WM_operatortype_append_macro("MESH_OT_extrude_edges_move", "Extrude Only Edges and Move", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Extrude edges and move result"; otmacro= WM_operatortype_macro_define(ot, "MESH_OT_extrude"); RNA_enum_set(otmacro->ptr, "type", 3); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); RNA_enum_set(otmacro->ptr, "proportional", 0); RNA_boolean_set(otmacro->ptr, "mirror", 0); - ot= WM_operatortype_append_macro("MESH_OT_extrude_vertices_move", _("Extrude Only Vertices and Move"), OPTYPE_UNDO|OPTYPE_REGISTER); - ot->description = _("Extrude vertices and move result"); + ot= WM_operatortype_append_macro("MESH_OT_extrude_vertices_move", "Extrude Only Vertices and Move", OPTYPE_UNDO|OPTYPE_REGISTER); + ot->description = "Extrude vertices and move result"; otmacro= WM_operatortype_macro_define(ot, "MESH_OT_extrude"); RNA_enum_set(otmacro->ptr, "type", 4); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); diff --git a/source/blender/editors/metaball/CMakeLists.txt b/source/blender/editors/metaball/CMakeLists.txt index 41ed5da4f09..76561b12183 100644 --- a/source/blender/editors/metaball/CMakeLists.txt +++ b/source/blender/editors/metaball/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/metaball/SConscript b/source/blender/editors/metaball/SConscript index 327e85b95f9..b1a1ce935db 100644 --- a/source/blender/editors/metaball/SConscript +++ b/source/blender/editors/metaball/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../gpu ../../blenloader' incs += ' ../../makesrna ../../render/extern/include #/intern/elbeem/extern' diff --git a/source/blender/editors/metaball/mball_edit.c b/source/blender/editors/metaball/mball_edit.c index c14f57d6c8c..b007e30422d 100644 --- a/source/blender/editors/metaball/mball_edit.c +++ b/source/blender/editors/metaball/mball_edit.c @@ -42,8 +42,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_meta_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" @@ -170,8 +168,8 @@ static int select_all_exec(bContext *C, wmOperator *op) void MBALL_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); - ot->description= _("Change selection of all meta elements"); + ot->name= "Select or Deselect All"; + ot->description= "Change selection of all meta elements"; ot->idname= "MBALL_OT_select_all"; /* callback functions */ @@ -211,8 +209,8 @@ static int select_inverse_metaelems_exec(bContext *C, wmOperator *UNUSED(op)) void MBALL_OT_select_inverse_metaelems(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Inverse"); - ot->description= _("Select inverse of (un)selected metaelements"); + ot->name= "Inverse"; + ot->description= "Select inverse of (un)selected metaelements"; ot->idname= "MBALL_OT_select_inverse_metaelems"; /* callback functions */ @@ -257,8 +255,8 @@ static int select_random_metaelems_exec(bContext *C, wmOperator *op) void MBALL_OT_select_random_metaelems(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Random..."); - ot->description= _("Randomly select metaelements"); + ot->name= "Random..."; + ot->description= "Randomly select metaelements"; ot->idname= "MBALL_OT_select_random_metaelems"; /* callback functions */ @@ -270,7 +268,7 @@ void MBALL_OT_select_random_metaelems(struct wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_percentage(ot->srna, "percent", 0.5f, 0.0f, 1.0f, _("Percent"), _("Percentage of metaelems to select randomly."), 0.0001f, 1.0f); + RNA_def_float_percentage(ot->srna, "percent", 0.5f, 0.0f, 1.0f, "Percent", "Percentage of metaelems to select randomly.", 0.0001f, 1.0f); } /***************************** Duplicate operator *****************************/ @@ -316,8 +314,8 @@ static int duplicate_metaelems_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void MBALL_OT_duplicate_metaelems(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Metaelements"); - ot->description= _("Delete selected metaelement(s)"); + ot->name= "Duplicate Metaelements"; + ot->description= "Delete selected metaelement(s)"; ot->idname= "MBALL_OT_duplicate_metaelems"; /* callback functions */ @@ -329,7 +327,7 @@ void MBALL_OT_duplicate_metaelems(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /***************************** Delete operator *****************************/ @@ -362,8 +360,8 @@ static int delete_metaelems_exec(bContext *C, wmOperator *UNUSED(op)) void MBALL_OT_delete_metaelems(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description= _("Delete selected metaelement(s)"); + ot->name= "Delete"; + ot->description= "Delete selected metaelement(s)"; ot->idname= "MBALL_OT_delete_metaelems"; /* callback functions */ @@ -402,8 +400,8 @@ static int hide_metaelems_exec(bContext *C, wmOperator *op) void MBALL_OT_hide_metaelems(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide"); - ot->description= _("Hide (un)selected metaelement(s)"); + ot->name= "Hide"; + ot->description= "Hide (un)selected metaelement(s)"; ot->idname= "MBALL_OT_hide_metaelems"; /* callback functions */ @@ -414,7 +412,7 @@ void MBALL_OT_hide_metaelems(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } /***************************** Unhide operator *****************************/ @@ -443,8 +441,8 @@ static int reveal_metaelems_exec(bContext *C, wmOperator *UNUSED(op)) void MBALL_OT_reveal_metaelems(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal"); - ot->description= _("Reveal all hidden metaelements"); + ot->name= "Reveal"; + ot->description= "Reveal all hidden metaelements"; ot->idname= "MBALL_OT_reveal_metaelems"; /* callback functions */ diff --git a/source/blender/editors/object/CMakeLists.txt b/source/blender/editors/object/CMakeLists.txt index da6b8d997d4..b9b8ddc6305 100644 --- a/source/blender/editors/object/CMakeLists.txt +++ b/source/blender/editors/object/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/object/SConscript b/source/blender/editors/object/SConscript index ba52d1a0edd..cdda16582ef 100644 --- a/source/blender/editors/object/SConscript +++ b/source/blender/editors/object/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') + env.Glob('*.cpp') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc ../../blenloader' incs += ' ../../makesrna ../../python ../../ikplugin' incs += ' ../../render/extern/include ../../gpu' # for object_bake.c diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c index a520536f452..0292977f816 100644 --- a/source/blender/editors/object/object_add.c +++ b/source/blender/editors/object/object_add.c @@ -53,8 +53,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_anim.h" #include "BKE_animsys.h" #include "BKE_armature.h" @@ -182,15 +180,15 @@ void ED_object_add_generic_props(wmOperatorType *ot, int do_editmode) PropertyRNA *prop; /* note: this property gets hidden for add-camera operator */ - RNA_def_boolean(ot->srna, "view_align", 0, _("Align to View"), _("Align the new object to the view")); + RNA_def_boolean(ot->srna, "view_align", 0, "Align to View", "Align the new object to the view"); if(do_editmode) { - prop= RNA_def_boolean(ot->srna, "enter_editmode", 0, _("Enter Editmode"), _("Enter editmode when adding this object")); + prop= RNA_def_boolean(ot->srna, "enter_editmode", 0, "Enter Editmode", "Enter editmode when adding this object"); RNA_def_property_flag(prop, PROP_HIDDEN); } - RNA_def_float_vector_xyz(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, _("Location"), _("Location for the newly added object"), -FLT_MAX, FLT_MAX); - RNA_def_float_rotation(ot->srna, "rotation", 3, NULL, -FLT_MAX, FLT_MAX, _("Rotation"), _("Rotation for the newly added object"), (float)-M_PI * 2.0f, (float)M_PI * 2.0f); + RNA_def_float_vector_xyz(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, "Location", "Location for the newly added object", -FLT_MAX, FLT_MAX); + RNA_def_float_rotation(ot->srna, "rotation", 3, NULL, -FLT_MAX, FLT_MAX, "Rotation", "Rotation for the newly added object", (float)-M_PI * 2.0f, (float)M_PI * 2.0f); prop = RNA_def_boolean_layer_member(ot->srna, "layers", 20, NULL, "Layer", ""); RNA_def_property_flag(prop, PROP_HIDDEN); @@ -346,8 +344,8 @@ static int object_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Object"); - ot->description = _("Add an object to the scene"); + ot->name= "Add Object"; + ot->description = "Add an object to the scene"; ot->idname= "OBJECT_OT_add"; /* api callbacks */ @@ -359,7 +357,7 @@ void OBJECT_OT_add(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(object_type_items), 0, _("Type"), ""); + RNA_def_enum(ot->srna, "type", object_type_items, 0, "Type", ""); ED_object_add_generic_props(ot, TRUE); } @@ -367,18 +365,18 @@ void OBJECT_OT_add(wmOperatorType *ot) /********************* Add Effector Operator ********************/ /* copy from rna_object_force.c*/ static EnumPropertyItem field_type_items[] = { - {PFIELD_FORCE, "FORCE", ICON_FORCE_FORCE, N_("Force"), ""}, - {PFIELD_WIND, "WIND", ICON_FORCE_WIND, N_("Wind"), ""}, - {PFIELD_VORTEX, "VORTEX", ICON_FORCE_VORTEX, N_("Vortex"), ""}, - {PFIELD_MAGNET, "MAGNET", ICON_FORCE_MAGNETIC, N_("Magnetic"), ""}, - {PFIELD_HARMONIC, "HARMONIC", ICON_FORCE_HARMONIC, N_("Harmonic"), ""}, - {PFIELD_CHARGE, "CHARGE", ICON_FORCE_CHARGE, N_("Charge"), ""}, - {PFIELD_LENNARDJ, "LENNARDJ", ICON_FORCE_LENNARDJONES, N_("Lennard-Jones"), ""}, - {PFIELD_TEXTURE, "TEXTURE", ICON_FORCE_TEXTURE, N_("Texture"), ""}, - {PFIELD_GUIDE, "GUIDE", ICON_FORCE_CURVE, N_("Curve Guide"), ""}, - {PFIELD_BOID, "BOID", ICON_FORCE_BOID, N_("Boid"), ""}, - {PFIELD_TURBULENCE, "TURBULENCE", ICON_FORCE_TURBULENCE, N_("Turbulence"), ""}, - {PFIELD_DRAG, "DRAG", ICON_FORCE_DRAG, N_("Drag"), ""}, + {PFIELD_FORCE, "FORCE", ICON_FORCE_FORCE, "Force", ""}, + {PFIELD_WIND, "WIND", ICON_FORCE_WIND, "Wind", ""}, + {PFIELD_VORTEX, "VORTEX", ICON_FORCE_VORTEX, "Vortex", ""}, + {PFIELD_MAGNET, "MAGNET", ICON_FORCE_MAGNETIC, "Magnetic", ""}, + {PFIELD_HARMONIC, "HARMONIC", ICON_FORCE_HARMONIC, "Harmonic", ""}, + {PFIELD_CHARGE, "CHARGE", ICON_FORCE_CHARGE, "Charge", ""}, + {PFIELD_LENNARDJ, "LENNARDJ", ICON_FORCE_LENNARDJONES, "Lennard-Jones", ""}, + {PFIELD_TEXTURE, "TEXTURE", ICON_FORCE_TEXTURE, "Texture", ""}, + {PFIELD_GUIDE, "GUIDE", ICON_FORCE_CURVE, "Curve Guide", ""}, + {PFIELD_BOID, "BOID", ICON_FORCE_BOID, "Boid", ""}, + {PFIELD_TURBULENCE, "TURBULENCE", ICON_FORCE_TURBULENCE, "Turbulence", ""}, + {PFIELD_DRAG, "DRAG", ICON_FORCE_DRAG, "Drag", ""}, {0, NULL, 0, NULL, NULL}}; /* for effector add primitive operators */ @@ -438,8 +436,8 @@ static int effector_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_effector_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Effector"); - ot->description = _("Add an empty object with a physics effector to the scene"); + ot->name= "Add Effector"; + ot->description = "Add an empty object with a physics effector to the scene"; ot->idname= "OBJECT_OT_effector_add"; /* api callbacks */ @@ -451,7 +449,7 @@ void OBJECT_OT_effector_add(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(field_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", field_type_items, 0, "Type", ""); ED_object_add_generic_props(ot, TRUE); } @@ -493,8 +491,8 @@ void OBJECT_OT_camera_add(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Add Camera"); - ot->description = _("Add a camera object to the scene"); + ot->name= "Add Camera"; + ot->description = "Add a camera object to the scene"; ot->idname= "OBJECT_OT_camera_add"; /* api callbacks */ @@ -571,8 +569,8 @@ static int object_metaball_add_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void OBJECT_OT_metaball_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Metaball"); - ot->description= _("Add an metaball object to the scene"); + ot->name= "Add Metaball"; + ot->description= "Add an metaball object to the scene"; ot->idname= "OBJECT_OT_metaball_add"; /* api callbacks */ @@ -583,7 +581,7 @@ void OBJECT_OT_metaball_add(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(metaelem_type_items), 0, _("Primitive"), ""); + RNA_def_enum(ot->srna, "type", metaelem_type_items, 0, "Primitive", ""); ED_object_add_generic_props(ot, TRUE); } @@ -611,8 +609,8 @@ static int object_add_text_exec(bContext *C, wmOperator *op) void OBJECT_OT_text_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Text"); - ot->description = _("Add a text object to the scene"); + ot->name= "Add Text"; + ot->description = "Add a text object to the scene"; ot->idname= "OBJECT_OT_text_add"; /* api callbacks */ @@ -666,8 +664,8 @@ static int object_armature_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_armature_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Armature"); - ot->description = _("Add an armature object to the scene"); + ot->name= "Add Armature"; + ot->description = "Add an armature object to the scene"; ot->idname= "OBJECT_OT_armature_add"; /* api callbacks */ @@ -716,16 +714,16 @@ static int object_lamp_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_lamp_add(wmOperatorType *ot) { static EnumPropertyItem lamp_type_items[] = { - {LA_LOCAL, "POINT", ICON_LAMP_POINT, N_("Point"), N_("Omnidirectional point light source")}, - {LA_SUN, "SUN", ICON_LAMP_SUN, N_("Sun"), N_("Constant direction parallel ray light source")}, - {LA_SPOT, "SPOT", ICON_LAMP_SPOT, N_("Spot"), N_("Directional cone light source")}, - {LA_HEMI, "HEMI", ICON_LAMP_HEMI, N_("Hemi"), N_("180 degree constant light source")}, - {LA_AREA, "AREA", ICON_LAMP_AREA, N_("Area"), N_("Directional area light source")}, + {LA_LOCAL, "POINT", ICON_LAMP_POINT, "Point", "Omnidirectional point light source"}, + {LA_SUN, "SUN", ICON_LAMP_SUN, "Sun", "Constant direction parallel ray light source"}, + {LA_SPOT, "SPOT", ICON_LAMP_SPOT, "Spot", "Directional cone light source"}, + {LA_HEMI, "HEMI", ICON_LAMP_HEMI, "Hemi", "180 degree constant light source"}, + {LA_AREA, "AREA", ICON_LAMP_AREA, "Area", "Directional area light source"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Add Lamp"); - ot->description = _("Add a lamp object to the scene"); + ot->name= "Add Lamp"; + ot->description = "Add a lamp object to the scene"; ot->idname= "OBJECT_OT_lamp_add"; /* api callbacks */ @@ -737,7 +735,7 @@ void OBJECT_OT_lamp_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(lamp_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", lamp_type_items, 0, "Type", ""); ED_object_add_generic_props(ot, FALSE); } @@ -835,8 +833,8 @@ void OBJECT_OT_group_instance_add(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Add Group Instance"); - ot->description = _("Add a dupligroup instance"); + ot->name= "Add Group Instance"; + ot->description = "Add a dupligroup instance"; ot->idname= "OBJECT_OT_group_instance_add"; /* api callbacks */ @@ -849,7 +847,7 @@ void OBJECT_OT_group_instance_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "group", DummyRNA_NULL_items, 0, _("Group"), ""); + prop= RNA_def_enum(ot->srna, "group", DummyRNA_NULL_items, 0, "Group", ""); RNA_def_enum_funcs(prop, RNA_group_itemf); ot->prop= prop; ED_object_add_generic_props(ot, FALSE); @@ -900,8 +898,8 @@ static int object_delete_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description = _("Delete selected objects"); + ot->name= "Delete"; + ot->description = "Delete selected objects"; ot->idname= "OBJECT_OT_delete"; /* api callbacks */ @@ -1080,8 +1078,8 @@ void OBJECT_OT_duplicates_make_real(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Duplicates Real"); - ot->description = _("Make dupli objects attached to this object real"); + ot->name= "Make Duplicates Real"; + ot->description = "Make dupli objects attached to this object real"; ot->idname= "OBJECT_OT_duplicates_make_real"; /* api callbacks */ @@ -1096,8 +1094,8 @@ void OBJECT_OT_duplicates_make_real(wmOperatorType *ot) /**************************** Convert **************************/ static EnumPropertyItem convert_target_items[]= { - {OB_CURVE, "CURVE", ICON_OUTLINER_OB_CURVE, N_("Curve from Mesh/Text"), ""}, - {OB_MESH, "MESH", ICON_OUTLINER_OB_MESH, N_("Mesh from Curve/Meta/Surf/Text"), ""}, + {OB_CURVE, "CURVE", ICON_OUTLINER_OB_CURVE, "Curve from Mesh/Text", ""}, + {OB_MESH, "MESH", ICON_OUTLINER_OB_MESH, "Mesh from Curve/Meta/Surf/Text", ""}, {0, NULL, 0, NULL, NULL}}; static void curvetomesh(Scene *scene, Object *ob) @@ -1445,8 +1443,8 @@ static int convert_exec(bContext *C, wmOperator *op) void OBJECT_OT_convert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Convert to"); - ot->description = _("Convert selected objects to another type"); + ot->name= "Convert to"; + ot->description = "Convert selected objects to another type"; ot->idname= "OBJECT_OT_convert"; /* api callbacks */ @@ -1458,8 +1456,8 @@ void OBJECT_OT_convert(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "target", RNA_enum_items_gettexted(convert_target_items), OB_MESH, _("Target"), _("Type of object to convert to")); - RNA_def_boolean(ot->srna, "keep_original", 0, _("Keep Original"), _("Keep original objects instead of replacing them")); + ot->prop= RNA_def_enum(ot->srna, "target", convert_target_items, OB_MESH, "Target", "Type of object to convert to"); + RNA_def_boolean(ot->srna, "keep_original", 0, "Keep Original", "Keep original objects instead of replacing them"); } /**************************** Duplicate ************************/ @@ -1759,8 +1757,8 @@ void OBJECT_OT_duplicate(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Duplicate Objects"); - ot->description = _("Duplicate selected objects"); + ot->name= "Duplicate Objects"; + ot->description = "Duplicate selected objects"; ot->idname= "OBJECT_OT_duplicate"; /* api callbacks */ @@ -1771,8 +1769,8 @@ void OBJECT_OT_duplicate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_boolean(ot->srna, "linked", 0, _("Linked"), _("Duplicate object but not object data, linking to the original data")); - prop= RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_boolean(ot->srna, "linked", 0, "Linked", "Duplicate object but not object data, linking to the original data"); + prop= RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); RNA_def_property_flag(prop, PROP_HIDDEN); } @@ -1830,8 +1828,8 @@ static int add_named_exec(bContext *C, wmOperator *op) void OBJECT_OT_add_named(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Named Object"); - ot->description = _("Add named object"); + ot->name= "Add Named Object"; + ot->description = "Add named object"; ot->idname= "OBJECT_OT_add_named"; /* api callbacks */ @@ -1841,8 +1839,8 @@ void OBJECT_OT_add_named(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "linked", 0, _("Linked"), _("Duplicate object but not object data, linking to the original data")); - RNA_def_string(ot->srna, "name", "Cube", 24, _("Name"), _("Object name to add")); + RNA_def_boolean(ot->srna, "linked", 0, "Linked", "Duplicate object but not object data, linking to the original data"); + RNA_def_string(ot->srna, "name", "Cube", 24, "Name", "Object name to add"); } @@ -1888,8 +1886,8 @@ static int join_exec(bContext *C, wmOperator *op) void OBJECT_OT_join(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Join"); - ot->description = _("Join selected objects into active object"); + ot->name= "Join"; + ot->description = "Join selected objects into active object"; ot->idname= "OBJECT_OT_join"; /* api callbacks */ @@ -1937,8 +1935,8 @@ static int join_shapes_exec(bContext *C, wmOperator *op) void OBJECT_OT_join_shapes(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Join as Shapes"); - ot->description = _("Merge selected objects to shapes of active object"); + ot->name= "Join as Shapes"; + ot->description = "Merge selected objects to shapes of active object"; ot->idname= "OBJECT_OT_join_shapes"; /* api callbacks */ diff --git a/source/blender/editors/object/object_constraint.c b/source/blender/editors/object/object_constraint.c index 5a30c099592..66db7db5171 100644 --- a/source/blender/editors/object/object_constraint.c +++ b/source/blender/editors/object/object_constraint.c @@ -42,8 +42,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_constraint_types.h" #include "DNA_curve_types.h" #include "DNA_scene_types.h" @@ -486,8 +484,8 @@ void object_test_constraints (Object *owner) #define EDIT_CONSTRAINT_OWNER_BONE 1 static EnumPropertyItem constraint_owner_items[] = { - {EDIT_CONSTRAINT_OWNER_OBJECT, "OBJECT", 0, N_("Object"), N_("Edit a constraint on the active object")}, - {EDIT_CONSTRAINT_OWNER_BONE, "BONE", 0, N_("Bone"), N_("Edit a constraint on the active bone")}, + {EDIT_CONSTRAINT_OWNER_OBJECT, "OBJECT", 0, "Object", "Edit a constraint on the active object"}, + {EDIT_CONSTRAINT_OWNER_BONE, "BONE", 0, "Bone", "Edit a constraint on the active bone"}, {0, NULL, 0, NULL, NULL}}; @@ -509,8 +507,8 @@ static int edit_constraint_poll(bContext *C) static void edit_constraint_properties(wmOperatorType *ot) { - RNA_def_string(ot->srna, "constraint", "", 32, _("Constraint"), _("Name of the constraint to edit")); - RNA_def_enum(ot->srna, "owner", RNA_enum_items_gettexted(constraint_owner_items), 0, _("Owner"), _("The owner of this constraint")); + RNA_def_string(ot->srna, "constraint", "", 32, "Constraint", "Name of the constraint to edit"); + RNA_def_enum(ot->srna, "owner", constraint_owner_items, 0, "Owner", "The owner of this constraint"); } static int edit_constraint_invoke_properties(bContext *C, wmOperator *op) @@ -612,9 +610,9 @@ static int stretchto_reset_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e void CONSTRAINT_OT_stretchto_reset (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset Original Length"); + ot->name= "Reset Original Length"; ot->idname= "CONSTRAINT_OT_stretchto_reset"; - ot->description= _("Reset original length of bone for Stretch To Constraint"); + ot->description= "Reset original length of bone for Stretch To Constraint"; ot->exec= stretchto_reset_exec; ot->invoke= stretchto_reset_invoke; @@ -655,9 +653,9 @@ static int limitdistance_reset_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void CONSTRAINT_OT_limitdistance_reset (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset Distance"); + ot->name= "Reset Distance"; ot->idname= "CONSTRAINT_OT_limitdistance_reset"; - ot->description= _("Reset limiting distance for Limit Distance Constraint"); + ot->description= "Reset limiting distance for Limit Distance Constraint"; ot->exec= limitdistance_reset_exec; ot->invoke= limitdistance_reset_invoke; @@ -745,9 +743,9 @@ static int childof_set_inverse_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void CONSTRAINT_OT_childof_set_inverse (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Inverse"); + ot->name= "Set Inverse"; ot->idname= "CONSTRAINT_OT_childof_set_inverse"; - ot->description= _("Set inverse correction for ChildOf constraint"); + ot->description= "Set inverse correction for ChildOf constraint"; ot->exec= childof_set_inverse_exec; ot->invoke= childof_set_inverse_invoke; @@ -789,9 +787,9 @@ static int childof_clear_inverse_invoke(bContext *C, wmOperator *op, wmEvent *UN void CONSTRAINT_OT_childof_clear_inverse (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Inverse"); + ot->name= "Clear Inverse"; ot->idname= "CONSTRAINT_OT_childof_clear_inverse"; - ot->description= _("Clear inverse correction for ChildOf constraint"); + ot->description= "Clear inverse correction for ChildOf constraint"; ot->exec= childof_clear_inverse_exec; ot->invoke= childof_clear_inverse_invoke; @@ -875,9 +873,9 @@ static int constraint_delete_exec (bContext *C, wmOperator *UNUSED(op)) void CONSTRAINT_OT_delete (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Constraint"); + ot->name= "Delete Constraint"; ot->idname= "CONSTRAINT_OT_delete"; - ot->description= _("Remove constraint from constraint stack"); + ot->description= "Remove constraint from constraint stack"; /* callbacks */ ot->exec= constraint_delete_exec; @@ -920,9 +918,9 @@ static int constraint_move_down_invoke(bContext *C, wmOperator *op, wmEvent *UNU void CONSTRAINT_OT_move_down (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Constraint Down"); + ot->name= "Move Constraint Down"; ot->idname= "CONSTRAINT_OT_move_down"; - ot->description= _("Move constraint down in constraint stack"); + ot->description= "Move constraint down in constraint stack"; /* callbacks */ ot->exec= constraint_move_down_exec; @@ -967,9 +965,9 @@ static int constraint_move_up_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE void CONSTRAINT_OT_move_up (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Constraint Up"); + ot->name= "Move Constraint Up"; ot->idname= "CONSTRAINT_OT_move_up"; - ot->description= _("Move constraint up in constraint stack"); + ot->description= "Move constraint up in constraint stack"; /* callbacks */ ot->exec= constraint_move_up_exec; @@ -1014,9 +1012,9 @@ static int pose_constraints_clear_exec(bContext *C, wmOperator *UNUSED(op)) void POSE_OT_constraints_clear(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Clear Pose Constraints"); + ot->name = "Clear Pose Constraints"; ot->idname= "POSE_OT_constraints_clear"; - ot->description= _("Clear all the constraints for the selected bones"); + ot->description= "Clear all the constraints for the selected bones"; /* callbacks */ ot->exec= pose_constraints_clear_exec; @@ -1049,9 +1047,9 @@ static int object_constraints_clear_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_constraints_clear(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Clear Object Constraints"); + ot->name = "Clear Object Constraints"; ot->idname= "OBJECT_OT_constraints_clear"; - ot->description= _("Clear all the constraints for the active Object only"); + ot->description= "Clear all the constraints for the active Object only"; /* callbacks */ ot->exec= object_constraints_clear_exec; @@ -1095,9 +1093,9 @@ static int pose_constraint_copy_exec(bContext *C, wmOperator *op) void POSE_OT_constraints_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Constraints to Selected"); + ot->name= "Copy Constraints to Selected"; ot->idname= "POSE_OT_constraints_copy"; - ot->description = _("Copy constraints to other selected bones."); + ot->description = "Copy constraints to other selected bones."; /* api callbacks */ ot->exec= pose_constraint_copy_exec; @@ -1136,9 +1134,9 @@ static int object_constraint_copy_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_constraints_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Constraints to Selected"); + ot->name= "Copy Constraints to Selected"; ot->idname= "OBJECT_OT_constraints_copy"; - ot->description = _("Copy constraints to other selected objects."); + ot->description = "Copy constraints to other selected objects."; /* api callbacks */ ot->exec= object_constraint_copy_exec; @@ -1448,8 +1446,8 @@ static int pose_constraint_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_constraint_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Constraint"); - ot->description = _("Add a constraint to the active object"); + ot->name= "Add Constraint"; + ot->description = "Add a constraint to the active object"; ot->idname= "OBJECT_OT_constraint_add"; /* api callbacks */ @@ -1461,14 +1459,14 @@ void OBJECT_OT_constraint_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(constraint_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, "Type", ""); } void OBJECT_OT_constraint_add_with_targets(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Constraint (with Targets)"); - ot->description = _("Add a constraint to the active object, with target (where applicable) set to the selected Objects/Bones"); + ot->name= "Add Constraint (with Targets)"; + ot->description = "Add a constraint to the active object, with target (where applicable) set to the selected Objects/Bones"; ot->idname= "OBJECT_OT_constraint_add_with_targets"; /* api callbacks */ @@ -1480,14 +1478,14 @@ void OBJECT_OT_constraint_add_with_targets(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, "Type", ""); } void POSE_OT_constraint_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Constraint"); - ot->description = _("Add a constraint to the active bone"); + ot->name= "Add Constraint"; + ot->description = "Add a constraint to the active bone"; ot->idname= "POSE_OT_constraint_add"; /* api callbacks */ @@ -1499,14 +1497,14 @@ void POSE_OT_constraint_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, "Type", ""); } void POSE_OT_constraint_add_with_targets(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Constraint (with Targets)"); - ot->description = _("Add a constraint to the active bone, with target (where applicable) set to the selected Objects/Bones"); + ot->name= "Add Constraint (with Targets)"; + ot->description = "Add a constraint to the active bone, with target (where applicable) set to the selected Objects/Bones"; ot->idname= "POSE_OT_constraint_add_with_targets"; /* api callbacks */ @@ -1518,7 +1516,7 @@ void POSE_OT_constraint_add_with_targets(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", constraint_type_items, 0, "Type", ""); } /************************ IK Constraint operators *********************/ @@ -1591,8 +1589,8 @@ static int pose_ik_add_exec(bContext *C, wmOperator *op) void POSE_OT_ik_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add IK to Bone"); - ot->description= _("Add IK Constraint to the active Bone"); + ot->name= "Add IK to Bone"; + ot->description= "Add IK Constraint to the active Bone"; ot->idname= "POSE_OT_ik_add"; /* api callbacks */ @@ -1604,7 +1602,7 @@ void POSE_OT_ik_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "with_targets", 1, _("With Targets"), _("Assign IK Constraint with targets derived from the select bones/objects")); + RNA_def_boolean(ot->srna, "with_targets", 1, "With Targets", "Assign IK Constraint with targets derived from the select bones/objects"); } /* ------------------ */ @@ -1642,8 +1640,8 @@ static int pose_ik_clear_exec(bContext *C, wmOperator *UNUSED(op)) void POSE_OT_ik_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove IK"); - ot->description= _("Remove all IK Constraints from selected bones"); + ot->name= "Remove IK"; + ot->description= "Remove all IK Constraints from selected bones"; ot->idname= "POSE_OT_ik_clear"; /* api callbacks */ diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c index 355f55e3546..79cbfb6574b 100644 --- a/source/blender/editors/object/object_edit.c +++ b/source/blender/editors/object/object_edit.c @@ -46,8 +46,6 @@ #include "BLI_ghash.h" #include "BLI_rand.h" -#include "BLF_api.h" - #include "DNA_armature_types.h" #include "DNA_curve_types.h" #include "DNA_group_types.h" @@ -160,8 +158,8 @@ void OBJECT_OT_hide_view_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Restrict View"); - ot->description = _("Reveal the object by setting the hide flag"); + ot->name= "Clear Restrict View"; + ot->description = "Reveal the object by setting the hide flag"; ot->idname= "OBJECT_OT_hide_view_clear"; /* api callbacks */ @@ -213,8 +211,8 @@ static int object_hide_view_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_hide_view_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Restrict View"); - ot->description = _("Hide the object by setting the hide flag"); + ot->name= "Set Restrict View"; + ot->description = "Hide the object by setting the hide flag"; ot->idname= "OBJECT_OT_hide_view_set"; /* api callbacks */ @@ -224,7 +222,7 @@ void OBJECT_OT_hide_view_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected objects.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected objects."); } @@ -252,8 +250,8 @@ void OBJECT_OT_hide_render_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Restrict Render"); - ot->description = _("Reveal the render object by setting the hide render flag"); + ot->name= "Clear Restrict Render"; + ot->description = "Reveal the render object by setting the hide render flag"; ot->idname= "OBJECT_OT_hide_render_clear"; /* api callbacks */ @@ -288,8 +286,8 @@ static int object_hide_render_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_hide_render_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Restrict Render"); - ot->description = _("Hide the render object by setting the hide render flag"); + ot->name= "Set Restrict Render"; + ot->description = "Hide the render object by setting the hide render flag"; ot->idname= "OBJECT_OT_hide_render_set"; /* api callbacks */ @@ -299,7 +297,7 @@ void OBJECT_OT_hide_render_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected objects.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected objects."); } /* ******************* toggle editmode operator ***************** */ @@ -547,8 +545,8 @@ void OBJECT_OT_editmode_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Editmode"); - ot->description = _("Toggle object's editmode"); + ot->name= "Toggle Editmode"; + ot->description = "Toggle object's editmode"; ot->idname= "OBJECT_OT_editmode_toggle"; /* api callbacks */ @@ -585,9 +583,9 @@ static int posemode_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_posemode_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Pose Mode"); + ot->name= "Toggle Pose Mode"; ot->idname= "OBJECT_OT_posemode_toggle"; - ot->description= _("Enables or disables posing/selecting bones"); + ot->description= "Enables or disables posing/selecting bones"; /* api callbacks */ ot->exec= posemode_exec; @@ -1422,8 +1420,8 @@ void OBJECT_OT_forcefield_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Force Field"); - ot->description = _("Toggle object's force field"); + ot->name= "Toggle Force Field"; + ot->description = "Toggle object's force field"; ot->idname= "OBJECT_OT_forcefield_toggle"; /* api callbacks */ @@ -1488,9 +1486,9 @@ static int object_calculate_paths_exec (bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_paths_calculate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Calculate Object Paths"); + ot->name= "Calculate Object Paths"; ot->idname= "OBJECT_OT_paths_calculate"; - ot->description= _("Calculate paths for the selected bones"); + ot->description= "Calculate paths for the selected bones"; /* api callbacks */ ot->exec= object_calculate_paths_exec; @@ -1532,9 +1530,9 @@ static int object_clear_paths_exec (bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_paths_clear (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Object Paths"); + ot->name= "Clear Object Paths"; ot->idname= "OBJECT_OT_paths_clear"; - ot->description= _("Clear path caches for selected bones"); + ot->description= "Clear path caches for selected bones"; /* api callbacks */ ot->exec= object_clear_paths_exec; @@ -1591,8 +1589,8 @@ static int shade_poll(bContext *C) void OBJECT_OT_shade_flat(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Flat"); - ot->description= _("Display faces 'flat'"); + ot->name= "Shade Flat"; + ot->description= "Display faces 'flat'"; ot->idname= "OBJECT_OT_shade_flat"; /* api callbacks */ @@ -1606,8 +1604,8 @@ void OBJECT_OT_shade_flat(wmOperatorType *ot) void OBJECT_OT_shade_smooth(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Shade Smooth"); - ot->description= _("Display faces 'smooth' (using vertex normals)"); + ot->name= "Shade Smooth"; + ot->description= "Display faces 'smooth' (using vertex normals)"; ot->idname= "OBJECT_OT_shade_smooth"; /* api callbacks */ @@ -1897,8 +1895,8 @@ void OBJECT_OT_mode_set(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Set Object Mode"); - ot->description = _("Sets the object interaction mode"); + ot->name= "Set Object Mode"; + ot->description = "Sets the object interaction mode"; ot->idname= "OBJECT_OT_mode_set"; /* api callbacks */ @@ -1909,10 +1907,10 @@ void OBJECT_OT_mode_set(wmOperatorType *ot) /* flags */ ot->flag= 0; /* no register/undo here, leave it to operators being called */ - prop= RNA_def_enum(ot->srna, "mode", object_mode_items, OB_MODE_OBJECT, _("Mode"), ""); + prop= RNA_def_enum(ot->srna, "mode", object_mode_items, OB_MODE_OBJECT, "Mode", ""); RNA_def_enum_funcs(prop, object_mode_set_itemsf); - RNA_def_boolean(ot->srna, "toggle", 0, _("Toggle"), ""); + RNA_def_boolean(ot->srna, "toggle", 0, "Toggle", ""); } @@ -1957,8 +1955,8 @@ static int game_property_new(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_game_property_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Game Property"); - ot->description= _("Create a new property available to the game engine"); + ot->name= "New Game Property"; + ot->description= "Create a new property available to the game engine"; ot->idname= "OBJECT_OT_game_property_new"; /* api callbacks */ @@ -1995,8 +1993,8 @@ static int game_property_remove(bContext *C, wmOperator *op) void OBJECT_OT_game_property_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Game Property"); - ot->description= _("Remove game property"); + ot->name= "Remove Game Property"; + ot->description= "Remove game property"; ot->idname= "OBJECT_OT_game_property_remove"; /* api callbacks */ @@ -2006,7 +2004,7 @@ void OBJECT_OT_game_property_remove(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), _("Property index to remove "), 0, INT_MAX); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "Property index to remove ", 0, INT_MAX); } #define COPY_PROPERTIES_REPLACE 1 @@ -2014,9 +2012,9 @@ void OBJECT_OT_game_property_remove(wmOperatorType *ot) #define COPY_PROPERTIES_COPY 3 static EnumPropertyItem game_properties_copy_operations[] ={ - {COPY_PROPERTIES_REPLACE, "REPLACE", 0, N_("Replace Properties"), ""}, - {COPY_PROPERTIES_MERGE, "MERGE", 0, N_("Merge Properties"), ""}, - {COPY_PROPERTIES_COPY, "COPY", 0, N_("Copy a Property"), ""}, + {COPY_PROPERTIES_REPLACE, "REPLACE", 0, "Replace Properties", ""}, + {COPY_PROPERTIES_MERGE, "MERGE", 0, "Merge Properties", ""}, + {COPY_PROPERTIES_COPY, "COPY", 0, "Copy a Property", ""}, {0, NULL, 0, NULL, NULL}}; static EnumPropertyItem gameprops_items[]= { @@ -2092,7 +2090,7 @@ void OBJECT_OT_game_property_copy(wmOperatorType *ot) { PropertyRNA *prop; /* identifiers */ - ot->name= _("Copy Game Property"); + ot->name= "Copy Game Property"; ot->idname= "OBJECT_OT_game_property_copy"; /* api callbacks */ @@ -2102,8 +2100,8 @@ void OBJECT_OT_game_property_copy(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "operation", game_properties_copy_operations, 3, _("Operation"), ""); - prop=RNA_def_enum(ot->srna, "property", gameprops_items, 0, _("Property"), _("Properties to copy")); + RNA_def_enum(ot->srna, "operation", game_properties_copy_operations, 3, "Operation", ""); + prop=RNA_def_enum(ot->srna, "property", gameprops_items, 0, "Property", "Properties to copy"); RNA_def_enum_funcs(prop, gameprops_itemf); ot->prop=prop; } @@ -2121,7 +2119,7 @@ static int game_property_clear_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_game_property_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Game Property"); + ot->name= "Clear Game Property"; ot->idname= "OBJECT_OT_game_property_clear"; /* api callbacks */ @@ -2178,8 +2176,8 @@ static int logicbricks_copy_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_logic_bricks_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Logic Bricks to Selected"); - ot->description = _("Copy logic bricks to other selected objects."); + ot->name= "Copy Logic Bricks to Selected"; + ot->description = "Copy logic bricks to other selected objects."; ot->idname= "OBJECT_OT_logic_bricks_copy"; /* api callbacks */ diff --git a/source/blender/editors/object/object_group.c b/source/blender/editors/object/object_group.c index 374f2ff918d..b1ab68ff087 100644 --- a/source/blender/editors/object/object_group.c +++ b/source/blender/editors/object/object_group.c @@ -37,8 +37,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_group_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" @@ -97,8 +95,8 @@ static int objects_add_active_exec(bContext *C, wmOperator *op) void GROUP_OT_objects_add_active(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Selected To Active Group"); - ot->description = _("Add the object to an object group that contains the active object"); + ot->name= "Add Selected To Active Group"; + ot->description = "Add the object to an object group that contains the active object"; ot->idname= "GROUP_OT_objects_add_active"; /* api callbacks */ @@ -144,8 +142,8 @@ static int objects_remove_active_exec(bContext *C, wmOperator *op) void GROUP_OT_objects_remove_active(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Selected From Active Group"); - ot->description = _("Remove the object from an object group that contains the active object"); + ot->name= "Remove Selected From Active Group"; + ot->description = "Remove the object from an object group that contains the active object"; ot->idname= "GROUP_OT_objects_remove_active"; /* api callbacks */ @@ -178,8 +176,8 @@ static int group_objects_remove_exec(bContext *C, wmOperator *UNUSED(op)) void GROUP_OT_objects_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove From Groups"); - ot->description = _("Remove selected objects from all groups"); + ot->name= "Remove From Groups"; + ot->description = "Remove selected objects from all groups"; ot->idname= "GROUP_OT_objects_remove"; /* api callbacks */ @@ -215,8 +213,8 @@ static int group_create_exec(bContext *C, wmOperator *op) void GROUP_OT_create(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Create New Group"); - ot->description = _("Create an object group from selected objects"); + ot->name= "Create New Group"; + ot->description = "Create an object group from selected objects"; ot->idname= "GROUP_OT_create"; /* api callbacks */ @@ -226,7 +224,7 @@ void GROUP_OT_create(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_string(ot->srna, "name", "Group", 32, _("Name"), _("Name of the new group")); + RNA_def_string(ot->srna, "name", "Group", 32, "Name", "Name of the new group"); } /****************** properties window operators *********************/ @@ -251,9 +249,9 @@ static int group_add_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_group_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add to Group"); + ot->name= "Add to Group"; ot->idname= "OBJECT_OT_group_add"; - ot->description = _("Add an object to a new group"); + ot->description = "Add an object to a new group"; /* api callbacks */ ot->exec= group_add_exec; @@ -283,9 +281,9 @@ void OBJECT_OT_group_link(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Link to Group"); + ot->name= "Link to Group"; ot->idname= "OBJECT_OT_group_link"; - ot->description = _("Add an object to an existing group"); + ot->description = "Add an object to an existing group"; /* api callbacks */ ot->exec= group_link_exec; @@ -295,7 +293,7 @@ void OBJECT_OT_group_link(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "group", DummyRNA_NULL_items, 0, _("Group"), ""); + prop= RNA_def_enum(ot->srna, "group", DummyRNA_NULL_items, 0, "Group", ""); RNA_def_enum_funcs(prop, RNA_group_local_itemf); ot->prop= prop; } @@ -319,7 +317,7 @@ static int group_remove_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_group_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Group"); + ot->name= "Remove Group"; ot->idname= "OBJECT_OT_group_remove"; /* api callbacks */ diff --git a/source/blender/editors/object/object_lattice.c b/source/blender/editors/object/object_lattice.c index 688e1209750..14ce223db5e 100644 --- a/source/blender/editors/object/object_lattice.c +++ b/source/blender/editors/object/object_lattice.c @@ -39,8 +39,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_curve_types.h" #include "DNA_key_types.h" #include "DNA_lattice_types.h" @@ -243,8 +241,8 @@ static int select_all_exec(bContext *C, wmOperator *op) void LATTICE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); - ot->description= _("Change selection of all UVW control points"); + ot->name= "Select or Deselect All"; + ot->description= "Change selection of all UVW control points"; ot->idname= "LATTICE_OT_select_all"; /* api callbacks */ @@ -291,8 +289,8 @@ static int make_regular_exec(bContext *C, wmOperator *UNUSED(op)) void LATTICE_OT_make_regular(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Regular"); - ot->description= _("Set UVW control points a uniform distance apart"); + ot->name= "Make Regular"; + ot->description= "Set UVW control points a uniform distance apart"; ot->idname= "LATTICE_OT_make_regular"; /* api callbacks */ diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c index 2daf4a542c4..8813b0027cd 100644 --- a/source/blender/editors/object/object_modifier.c +++ b/source/blender/editors/object/object_modifier.c @@ -50,8 +50,6 @@ #include "BLI_editVert.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_curve.h" #include "BKE_context.h" #include "BKE_depsgraph.h" @@ -645,8 +643,8 @@ void OBJECT_OT_modifier_add(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Add Modifier"); - ot->description = _("Add a modifier to the active object"); + ot->name= "Add Modifier"; + ot->description = "Add a modifier to the active object"; ot->idname= "OBJECT_OT_modifier_add"; /* api callbacks */ @@ -658,7 +656,7 @@ void OBJECT_OT_modifier_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(modifier_type_items), eModifierType_Subsurf, "Type", ""); + prop= RNA_def_enum(ot->srna, "type", modifier_type_items, eModifierType_Subsurf, "Type", ""); RNA_def_enum_funcs(prop, modifier_add_itemf); ot->prop= prop; } @@ -752,8 +750,8 @@ static int modifier_remove_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e void OBJECT_OT_modifier_remove(wmOperatorType *ot) { - ot->name= _("Remove Modifier"); - ot->description= _("Remove a modifier from the active object"); + ot->name= "Remove Modifier"; + ot->description= "Remove a modifier from the active object"; ot->idname= "OBJECT_OT_modifier_remove"; ot->invoke= modifier_remove_invoke; @@ -791,8 +789,8 @@ static int modifier_move_up_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED( void OBJECT_OT_modifier_move_up(wmOperatorType *ot) { - ot->name= _("Move Up Modifier"); - ot->description= _("Move modifier up in the stack"); + ot->name= "Move Up Modifier"; + ot->description= "Move modifier up in the stack"; ot->idname= "OBJECT_OT_modifier_move_up"; ot->invoke= modifier_move_up_invoke; @@ -830,8 +828,8 @@ static int modifier_move_down_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE void OBJECT_OT_modifier_move_down(wmOperatorType *ot) { - ot->name= _("Move Down Modifier"); - ot->description= _("Move modifier down in the stack"); + ot->name= "Move Down Modifier"; + ot->description= "Move modifier down in the stack"; ot->idname= "OBJECT_OT_modifier_move_down"; ot->invoke= modifier_move_down_invoke; @@ -871,14 +869,14 @@ static int modifier_apply_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(ev } static EnumPropertyItem modifier_apply_as_items[] = { - {MODIFIER_APPLY_DATA, "DATA", 0, N_("Object Data"), N_("Apply modifier to the object's data")}, - {MODIFIER_APPLY_SHAPE, "SHAPE", 0, N_("New Shape"), N_("Apply deform-only modifier to a new shape on this object")}, + {MODIFIER_APPLY_DATA, "DATA", 0, "Object Data", "Apply modifier to the object's data"}, + {MODIFIER_APPLY_SHAPE, "SHAPE", 0, "New Shape", "Apply deform-only modifier to a new shape on this object"}, {0, NULL, 0, NULL, NULL}}; void OBJECT_OT_modifier_apply(wmOperatorType *ot) { - ot->name= _("Apply Modifier"); - ot->description= _("Apply modifier and remove from the stack"); + ot->name= "Apply Modifier"; + ot->description= "Apply modifier and remove from the stack"; ot->idname= "OBJECT_OT_modifier_apply"; ot->invoke= modifier_apply_invoke; @@ -888,7 +886,7 @@ void OBJECT_OT_modifier_apply(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "apply_as", RNA_enum_items_gettexted(modifier_apply_as_items), MODIFIER_APPLY_DATA, _("Apply as"), _("How to apply the modifier to the geometry")); + RNA_def_enum(ot->srna, "apply_as", modifier_apply_as_items, MODIFIER_APPLY_DATA, "Apply as", "How to apply the modifier to the geometry"); edit_modifier_properties(ot); } @@ -920,8 +918,8 @@ static int modifier_convert_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED( void OBJECT_OT_modifier_convert(wmOperatorType *ot) { - ot->name= _("Convert Modifier"); - ot->description= _("Convert particles to a mesh object"); + ot->name= "Convert Modifier"; + ot->description= "Convert particles to a mesh object"; ot->idname= "OBJECT_OT_modifier_convert"; ot->invoke= modifier_convert_invoke; @@ -959,8 +957,8 @@ static int modifier_copy_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(eve void OBJECT_OT_modifier_copy(wmOperatorType *ot) { - ot->name= _("Copy Modifier"); - ot->description= _("Duplicate modifier at the same position in the stack"); + ot->name= "Copy Modifier"; + ot->description= "Duplicate modifier at the same position in the stack"; ot->idname= "OBJECT_OT_modifier_copy"; ot->invoke= modifier_copy_invoke; @@ -1004,8 +1002,8 @@ static int multires_higher_levels_delete_invoke(bContext *C, wmOperator *op, wmE void OBJECT_OT_multires_higher_levels_delete(wmOperatorType *ot) { - ot->name= _("Delete Higher Levels"); - ot->description= _("Deletes the higher resolution mesh, potential loss of detail"); + ot->name= "Delete Higher Levels"; + ot->description= "Deletes the higher resolution mesh, potential loss of detail"; ot->idname= "OBJECT_OT_multires_higher_levels_delete"; ot->poll= multires_poll; @@ -1045,8 +1043,8 @@ static int multires_subdivide_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE void OBJECT_OT_multires_subdivide(wmOperatorType *ot) { - ot->name= _("Multires Subdivide"); - ot->description= _("Add a new level of subdivision"); + ot->name= "Multires Subdivide"; + ot->description= "Add a new level of subdivision"; ot->idname= "OBJECT_OT_multires_subdivide"; ot->poll= multires_poll; @@ -1108,8 +1106,8 @@ static int multires_reshape_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED( void OBJECT_OT_multires_reshape(wmOperatorType *ot) { - ot->name= _("Multires Reshape"); - ot->description= _("Copy vertex coordinates from other object"); + ot->name= "Multires Reshape"; + ot->description= "Copy vertex coordinates from other object"; ot->idname= "OBJECT_OT_multires_reshape"; ot->poll= multires_poll; @@ -1183,8 +1181,8 @@ static int multires_external_save_invoke(bContext *C, wmOperator *op, wmEvent *U void OBJECT_OT_multires_external_save(wmOperatorType *ot) { - ot->name= _("Multires Save External"); - ot->description= _("Save displacements to an external file"); + ot->name= "Multires Save External"; + ot->description= "Save displacements to an external file"; ot->idname= "OBJECT_OT_multires_external_save"; // XXX modifier no longer in context after file browser .. ot->poll= multires_poll; @@ -1217,8 +1215,8 @@ static int multires_external_pack_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_multires_external_pack(wmOperatorType *ot) { - ot->name= _("Multires Pack External"); - ot->description= _("Pack displacements from an external file"); + ot->name= "Multires Pack External"; + ot->description= "Pack displacements from an external file"; ot->idname= "OBJECT_OT_multires_external_pack"; ot->poll= multires_poll; @@ -1256,8 +1254,8 @@ static int multires_base_apply_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void OBJECT_OT_multires_base_apply(wmOperatorType *ot) { - ot->name= _("Multires Apply Base"); - ot->description= _("Modify the base mesh to conform to the displaced mesh"); + ot->name= "Multires Apply Base"; + ot->description= "Modify the base mesh to conform to the displaced mesh"; ot->idname= "OBJECT_OT_multires_base_apply"; ot->poll= multires_poll; @@ -1350,8 +1348,8 @@ static int meshdeform_bind_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e void OBJECT_OT_meshdeform_bind(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mesh Deform Bind"); - ot->description = _("Bind mesh to cage in mesh deform modifier"); + ot->name= "Mesh Deform Bind"; + ot->description = "Bind mesh to cage in mesh deform modifier"; ot->idname= "OBJECT_OT_meshdeform_bind"; /* api callbacks */ @@ -1398,8 +1396,8 @@ static int explode_refresh_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e void OBJECT_OT_explode_refresh(wmOperatorType *ot) { - ot->name= _("Explode Refresh"); - ot->description= _("Refresh data in the Explode modifier"); + ot->name= "Explode Refresh"; + ot->description= "Refresh data in the Explode modifier"; ot->idname= "OBJECT_OT_explode_refresh"; ot->poll= explode_poll; diff --git a/source/blender/editors/object/object_ops.c b/source/blender/editors/object/object_ops.c index 931be10a2a1..5eb17268d19 100644 --- a/source/blender/editors/object/object_ops.c +++ b/source/blender/editors/object/object_ops.c @@ -41,8 +41,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "RNA_access.h" @@ -228,7 +226,7 @@ void ED_operatormacros_object(void) wmOperatorType *ot; wmOperatorTypeMacro *otmacro; - ot= WM_operatortype_append_macro("OBJECT_OT_duplicate_move", _("Duplicate Objects"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("OBJECT_OT_duplicate_move", "Duplicate Objects", OPTYPE_UNDO|OPTYPE_REGISTER); if(ot) { WM_operatortype_macro_define(ot, "OBJECT_OT_duplicate"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); @@ -236,7 +234,7 @@ void ED_operatormacros_object(void) } /* grr, should be able to pass options on... */ - ot= WM_operatortype_append_macro("OBJECT_OT_duplicate_move_linked", _("Duplicate Linked"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("OBJECT_OT_duplicate_move_linked", "Duplicate Linked", OPTYPE_UNDO|OPTYPE_REGISTER); if(ot) { otmacro= WM_operatortype_macro_define(ot, "OBJECT_OT_duplicate"); RNA_boolean_set(otmacro->ptr, "linked", 1); diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c index 944124beb17..4d7f6fa9e7a 100644 --- a/source/blender/editors/object/object_relations.c +++ b/source/blender/editors/object/object_relations.c @@ -55,8 +55,6 @@ #include "BLI_string.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_action.h" #include "BKE_animsys.h" #include "BKE_armature.h" @@ -253,8 +251,8 @@ static int vertex_parent_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_parent_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Vertex Parent"); - ot->description = _("Parent selected objects to the selected vertices"); + ot->name= "Make Vertex Parent"; + ot->description = "Parent selected objects to the selected vertices"; ot->idname= "OBJECT_OT_vertex_parent_set"; /* api callbacks */ @@ -393,9 +391,9 @@ void OBJECT_OT_proxy_make (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Make Proxy"); + ot->name= "Make Proxy"; ot->idname= "OBJECT_OT_proxy_make"; - ot->description= _("Add empty object to become local replacement data of a library-linked object"); + ot->description= "Add empty object to become local replacement data of a library-linked object"; /* callbacks */ ot->invoke= make_proxy_invoke; @@ -406,8 +404,8 @@ void OBJECT_OT_proxy_make (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "object", "", MAX_ID_NAME-2, _("Proxy Object"), _("Name of lib-linked/grouped object to make a proxy for.")); - prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, _("Type"), _("Group object")); /* XXX, relies on hard coded ID at the moment */ + RNA_def_string(ot->srna, "object", "", MAX_ID_NAME-2, "Proxy Object", "Name of lib-linked/grouped object to make a proxy for."); + prop= RNA_def_enum(ot->srna, "type", DummyRNA_DEFAULT_items, 0, "Type", "Group object"); /* XXX, relies on hard coded ID at the moment */ RNA_def_enum_funcs(prop, proxy_group_object_itemf); ot->prop= prop; } @@ -415,9 +413,9 @@ void OBJECT_OT_proxy_make (wmOperatorType *ot) /********************** Clear Parent Operator ******************* */ static EnumPropertyItem prop_clear_parent_types[] = { - {0, "CLEAR", 0, N_("Clear Parent"), ""}, - {1, "CLEAR_KEEP_TRANSFORM", 0, N_("Clear and Keep Transformation"), ""}, - {2, "CLEAR_INVERSE", 0, N_("Clear Parent Inverse"), ""}, + {0, "CLEAR", 0, "Clear Parent", ""}, + {1, "CLEAR_KEEP_TRANSFORM", 0, "Clear and Keep Transformation", ""}, + {2, "CLEAR_INVERSE", 0, "Clear Parent Inverse", ""}, {0, NULL, 0, NULL, NULL} }; @@ -458,8 +456,8 @@ static int parent_clear_exec(bContext *C, wmOperator *op) void OBJECT_OT_parent_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Parent"); - ot->description = _("Clear the object's parenting"); + ot->name= "Clear Parent"; + ot->description = "Clear the object's parenting"; ot->idname= "OBJECT_OT_parent_clear"; /* api callbacks */ @@ -471,7 +469,7 @@ void OBJECT_OT_parent_clear(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_clear_parent_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_clear_parent_types, 0, "Type", ""); } /* ******************** Make Parent Operator *********************** */ @@ -490,18 +488,18 @@ void OBJECT_OT_parent_clear(wmOperatorType *ot) #define PAR_TRIA 11 static EnumPropertyItem prop_make_parent_types[] = { - {PAR_OBJECT, "OBJECT", 0, N_("Object"), ""}, - {PAR_ARMATURE, "ARMATURE", 0, N_("Armature Deform"), ""}, - {PAR_ARMATURE_NAME, "ARMATURE_NAME", 0, N_(" With Empty Groups"), ""}, - {PAR_ARMATURE_AUTO, "ARMATURE_AUTO", 0, N_(" With Automatic Weights"), ""}, - {PAR_ARMATURE_ENVELOPE, "ARMATURE_ENVELOPE", 0, N_(" With Envelope Weights"), ""}, - {PAR_BONE, "BONE", 0, N_("Bone"), ""}, - {PAR_CURVE, "CURVE", 0, N_("Curve Deform"), ""}, - {PAR_FOLLOW, "FOLLOW", 0, N_("Follow Path"), ""}, - {PAR_PATH_CONST, "PATH_CONST", 0, N_("Path Constraint"), ""}, - {PAR_LATTICE, "LATTICE", 0, N_("Lattice Deform"), ""}, - {PAR_VERTEX, "VERTEX", 0, N_("Vertex"), ""}, - {PAR_TRIA, "TRIA", 0, N_("Triangle"), ""}, + {PAR_OBJECT, "OBJECT", 0, "Object", ""}, + {PAR_ARMATURE, "ARMATURE", 0, "Armature Deform", ""}, + {PAR_ARMATURE_NAME, "ARMATURE_NAME", 0, " With Empty Groups", ""}, + {PAR_ARMATURE_AUTO, "ARMATURE_AUTO", 0, " With Automatic Weights", ""}, + {PAR_ARMATURE_ENVELOPE, "ARMATURE_ENVELOPE", 0, " With Envelope Weights", ""}, + {PAR_BONE, "BONE", 0, "Bone", ""}, + {PAR_CURVE, "CURVE", 0, "Curve Deform", ""}, + {PAR_FOLLOW, "FOLLOW", 0, "Follow Path", ""}, + {PAR_PATH_CONST, "PATH_CONST", 0, "Path Constraint", ""}, + {PAR_LATTICE, "LATTICE", 0, "Lattice Deform", ""}, + {PAR_VERTEX, "VERTEX", 0, "Vertex", ""}, + {PAR_TRIA, "TRIA", 0, "Triangle", ""}, {0, NULL, 0, NULL, NULL} }; @@ -731,8 +729,8 @@ static int parent_set_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *UNUSE void OBJECT_OT_parent_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Parent"); - ot->description = _("Set the object's parenting"); + ot->name= "Make Parent"; + ot->description = "Set the object's parenting"; ot->idname= "OBJECT_OT_parent_set"; /* api callbacks */ @@ -744,7 +742,7 @@ void OBJECT_OT_parent_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_make_parent_types), 0, _("Type"), ""); + RNA_def_enum(ot->srna, "type", prop_make_parent_types, 0, "Type", ""); } /* ************ Make Parent Without Inverse Operator ******************* */ @@ -788,8 +786,8 @@ static int parent_noinv_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_parent_no_inverse_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Parent without Inverse"); - ot->description = _("Set the object's parenting without setting the inverse parent correction"); + ot->name= "Make Parent without Inverse"; + ot->description = "Set the object's parenting without setting the inverse parent correction"; ot->idname= "OBJECT_OT_parent_no_inverse_set"; /* api callbacks */ @@ -830,8 +828,8 @@ void OBJECT_OT_slow_parent_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Slow Parent"); - ot->description = _("Clear the object's slow parent"); + ot->name= "Clear Slow Parent"; + ot->description = "Clear the object's slow parent"; ot->idname= "OBJECT_OT_slow_parent_clear"; /* api callbacks */ @@ -869,8 +867,8 @@ void OBJECT_OT_slow_parent_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Slow Parent"); - ot->description = _("Set the object's slow parent"); + ot->name= "Set Slow Parent"; + ot->description = "Set the object's slow parent"; ot->idname= "OBJECT_OT_slow_parent_set"; /* api callbacks */ @@ -885,8 +883,8 @@ void OBJECT_OT_slow_parent_set(wmOperatorType *ot) /* ******************** Clear Track Operator ******************* */ static EnumPropertyItem prop_clear_track_types[] = { - {0, "CLEAR", 0, N_("Clear Track"), ""}, - {1, "CLEAR_KEEP_TRANSFORM", 0, N_("Clear and Keep Transformation (Clear Track)"), ""}, + {0, "CLEAR", 0, "Clear Track", ""}, + {1, "CLEAR_KEEP_TRANSFORM", 0, "Clear and Keep Transformation (Clear Track)", ""}, {0, NULL, 0, NULL, NULL} }; @@ -930,8 +928,8 @@ static int object_track_clear_exec(bContext *C, wmOperator *op) void OBJECT_OT_track_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear track"); - ot->description = _("Clear tracking constraint or flag from object"); + ot->name= "Clear track"; + ot->description = "Clear tracking constraint or flag from object"; ot->idname= "OBJECT_OT_track_clear"; /* api callbacks */ @@ -943,15 +941,15 @@ void OBJECT_OT_track_clear(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_clear_track_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_clear_track_types, 0, "Type", ""); } /************************** Make Track Operator *****************************/ static EnumPropertyItem prop_make_track_types[] = { - {1, "DAMPTRACK", 0, N_("Damped Track Constraint"), ""}, - {2, "TRACKTO", 0, N_("Track To Constraint"), ""}, - {3, "LOCKTRACK", 0, N_("Lock Track Constraint"), ""}, + {1, "DAMPTRACK", 0, "Damped Track Constraint", ""}, + {2, "TRACKTO", 0, "Track To Constraint", ""}, + {3, "LOCKTRACK", 0, "Lock Track Constraint", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1035,8 +1033,8 @@ static int track_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_track_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Track"); - ot->description = _("Make the object track another object, either by constraint or old way or locked track"); + ot->name= "Make Track"; + ot->description = "Make the object track another object, either by constraint or old way or locked track"; ot->idname= "OBJECT_OT_track_set"; /* api callbacks */ @@ -1049,7 +1047,7 @@ void OBJECT_OT_track_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_make_track_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_make_track_types, 0, "Type", ""); } /************************** Move to Layer Operator *****************************/ @@ -1146,8 +1144,8 @@ static int move_to_layer_exec(bContext *C, wmOperator *op) void OBJECT_OT_move_to_layer(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move to Layer"); - ot->description = _("Move the object to different layers"); + ot->name= "Move to Layer"; + ot->description = "Move the object to different layers"; ot->idname= "OBJECT_OT_move_to_layer"; /* api callbacks */ @@ -1159,7 +1157,7 @@ void OBJECT_OT_move_to_layer(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean_layer_member(ot->srna, "layers", 20, NULL, _("Layer"), ""); + RNA_def_boolean_layer_member(ot->srna, "layers", 20, NULL, "Layer", ""); } /************************** Link to Scene Operator *****************************/ @@ -1322,8 +1320,8 @@ void OBJECT_OT_make_links_scene(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Link Objects to Scene"); - ot->description = _("Link selection to another scene"); + ot->name= "Link Objects to Scene"; + ot->description = "Link selection to another scene"; ot->idname= "OBJECT_OT_make_links_scene"; /* api callbacks */ @@ -1335,7 +1333,7 @@ void OBJECT_OT_make_links_scene(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, _("Scene"), ""); + prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, "Scene", ""); RNA_def_enum_funcs(prop, RNA_scene_local_itemf); ot->prop= prop; } @@ -1343,16 +1341,16 @@ void OBJECT_OT_make_links_scene(wmOperatorType *ot) void OBJECT_OT_make_links_data(wmOperatorType *ot) { static EnumPropertyItem make_links_items[]= { - {MAKE_LINKS_OBDATA, "OBDATA", 0, N_("Object Data"), ""}, - {MAKE_LINKS_MATERIALS, "MATERIAL", 0, N_("Materials"), ""}, - {MAKE_LINKS_ANIMDATA, "ANIMATION", 0, N_("Animation Data"), ""}, - {MAKE_LINKS_DUPLIGROUP, "DUPLIGROUP", 0, N_("DupliGroup"), ""}, - {MAKE_LINKS_MODIFIERS, "MODIFIERS", 0, N_("Modifiers"), ""}, + {MAKE_LINKS_OBDATA, "OBDATA", 0, "Object Data", ""}, + {MAKE_LINKS_MATERIALS, "MATERIAL", 0, "Materials", ""}, + {MAKE_LINKS_ANIMDATA, "ANIMATION", 0, "Animation Data", ""}, + {MAKE_LINKS_DUPLIGROUP, "DUPLIGROUP", 0, "DupliGroup", ""}, + {MAKE_LINKS_MODIFIERS, "MODIFIERS", 0, "Modifiers", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Link Data"); - ot->description = _("Make links from the active object to other selected objects"); + ot->name= "Link Data"; + ot->description = "Make links from the active object to other selected objects"; ot->idname= "OBJECT_OT_make_links_data"; /* api callbacks */ @@ -1363,7 +1361,7 @@ void OBJECT_OT_make_links_data(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(make_links_items), 0, "Type", ""); + ot->prop= RNA_def_enum(ot->srna, "type", make_links_items, 0, "Type", ""); } @@ -1804,14 +1802,14 @@ static int make_local_exec(bContext *C, wmOperator *op) void OBJECT_OT_make_local(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - {1, "SELECTED_OBJECTS", 0, N_("Selected Objects"), ""}, - {2, "SELECTED_OBJECTS_DATA", 0, N_("Selected Objects and Data"), ""}, - {3, "ALL", 0, N_("All"), ""}, + {1, "SELECTED_OBJECTS", 0, "Selected Objects", ""}, + {2, "SELECTED_OBJECTS_DATA", 0, "Selected Objects and Data", ""}, + {3, "ALL", 0, "All", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Make Local"); - ot->description = _("Make library linked datablocks local to this file"); + ot->name= "Make Local"; + ot->description = "Make library linked datablocks local to this file"; ot->idname= "OBJECT_OT_make_local"; /* api callbacks */ @@ -1823,7 +1821,7 @@ void OBJECT_OT_make_local(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, 0, "Type", ""); } static int make_single_user_exec(bContext *C, wmOperator *op) @@ -1858,13 +1856,13 @@ static int make_single_user_exec(bContext *C, wmOperator *op) void OBJECT_OT_make_single_user(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - {SELECT, "SELECTED_OBJECTS", 0, N_("Selected Objects"), ""}, - {0, "ALL", 0, N_("All"), ""}, + {SELECT, "SELECTED_OBJECTS", 0, "Selected Objects", ""}, + {0, "ALL", 0, "All", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Make Single User"); - ot->description = _("Make linked data local to each object"); + ot->name= "Make Single User"; + ot->description = "Make linked data local to each object"; ot->idname= "OBJECT_OT_make_single_user"; /* api callbacks */ @@ -1876,13 +1874,13 @@ void OBJECT_OT_make_single_user(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), SELECT, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, SELECT, "Type", ""); - RNA_def_boolean(ot->srna, "object", 0, _("Object"), _("Make single user objects")); - RNA_def_boolean(ot->srna, "obdata", 0, _("Object Data"), _("Make single user object data")); - RNA_def_boolean(ot->srna, "material", 0, _("Materials"), _("Make materials local to each datablock")); - RNA_def_boolean(ot->srna, "texture", 0, _("Textures"), _("Make textures local to each material")); - RNA_def_boolean(ot->srna, "animation", 0, _("Object Animation"), _("Make animation data local to each object")); + RNA_def_boolean(ot->srna, "object", 0, "Object", "Make single user objects"); + RNA_def_boolean(ot->srna, "obdata", 0, "Object Data", "Make single user object data"); + RNA_def_boolean(ot->srna, "material", 0, "Materials", "Make materials local to each datablock"); + RNA_def_boolean(ot->srna, "texture", 0, "Textures", "Make textures local to each material"); + RNA_def_boolean(ot->srna, "animation", 0, "Object Animation", "Make animation data local to each object"); } static int drop_named_material_invoke(bContext *C, wmOperator *op, wmEvent *event) @@ -1911,7 +1909,7 @@ void OBJECT_OT_drop_named_material(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Drop Named Material on Object"); + ot->name= "Drop Named Material on Object"; ot->description = ""; ot->idname= "OBJECT_OT_drop_named_material"; @@ -1923,5 +1921,5 @@ void OBJECT_OT_drop_named_material(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "name", "Material", 24, _("Name"), _("Material name to assign.")); + RNA_def_string(ot->srna, "name", "Material", 24, "Name", "Material name to assign."); } diff --git a/source/blender/editors/object/object_select.c b/source/blender/editors/object/object_select.c index 1052fd0cf38..8fdd7a53e91 100644 --- a/source/blender/editors/object/object_select.c +++ b/source/blender/editors/object/object_select.c @@ -50,8 +50,6 @@ #include "BLI_string.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_group.h" #include "BKE_main.h" @@ -168,8 +166,8 @@ static int object_select_by_type_exec(bContext *C, wmOperator *op) void OBJECT_OT_select_by_type(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select By Type"); - ot->description = _("Select all visible objects that are of a type"); + ot->name= "Select By Type"; + ot->description = "Select all visible objects that are of a type"; ot->idname= "OBJECT_OT_select_by_type"; /* api callbacks */ @@ -181,21 +179,21 @@ void OBJECT_OT_select_by_type(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(object_type_items), 1, _("Type"), ""); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); + ot->prop= RNA_def_enum(ot->srna, "type", object_type_items, 1, "Type", ""); } /*********************** Selection by Links *********************/ static EnumPropertyItem prop_select_linked_types[] = { //{1, "IPO", 0, "Object IPO", ""}, // XXX depreceated animation system stuff... - {2, "OBDATA", 0, N_("Object Data"), ""}, - {3, "MATERIAL", 0, N_("Material"), ""}, - {4, "TEXTURE", 0, N_("Texture"), ""}, - {5, "DUPGROUP", 0, N_("Dupligroup"), ""}, - {6, "PARTICLE", 0, N_("Particle System"), ""}, - {7, "LIBRARY", 0, N_("Library"), ""}, - {8, "LIBRARY_OBDATA", 0, N_("Library (Object Data)"), ""}, + {2, "OBDATA", 0, "Object Data", ""}, + {3, "MATERIAL", 0, "Material", ""}, + {4, "TEXTURE", 0, "Texture", ""}, + {5, "DUPGROUP", 0, "Dupligroup", ""}, + {6, "PARTICLE", 0, "Particle System", ""}, + {7, "LIBRARY", 0, "Library", ""}, + {8, "LIBRARY_OBDATA", 0, "Library (Object Data)", ""}, {0, NULL, 0, NULL, NULL} }; @@ -350,8 +348,8 @@ static int object_select_linked_exec(bContext *C, wmOperator *op) void OBJECT_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked"); - ot->description = _("Select all visible objects that are linked"); + ot->name= "Select Linked"; + ot->description = "Select all visible objects that are linked"; ot->idname= "OBJECT_OT_select_linked"; /* api callbacks */ @@ -363,24 +361,24 @@ void OBJECT_OT_select_linked(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_select_linked_types), 0, _("Type"), ""); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); + ot->prop= RNA_def_enum(ot->srna, "type", prop_select_linked_types, 0, "Type", ""); } /*********************** Selected Grouped ********************/ static EnumPropertyItem prop_select_grouped_types[] = { - {1, "CHILDREN_RECURSIVE", 0, N_("Children"), ""}, - {2, "CHILDREN", 0, N_("Immediate Children"), ""}, - {3, "PARENT", 0, N_("Parent"), ""}, - {4, "SIBLINGS", 0, N_("Siblings"), N_("Shared Parent")}, - {5, "TYPE", 0, N_("Type"), N_("Shared object type")}, - {6, "LAYER", 0, N_("Layer"), N_("Shared layers")}, - {7, "GROUP", 0, N_("Group"), N_("Shared group")}, - {8, "HOOK", 0, N_("Hook"), ""}, - {9, "PASS", 0, N_("Pass"), N_("Render pass Index")}, - {10, "COLOR", 0, N_("Color"), N_("Object Color")}, - {11, "PROPERTIES", 0, N_("Properties"), N_("Game Properties")}, + {1, "CHILDREN_RECURSIVE", 0, "Children", ""}, + {2, "CHILDREN", 0, "Immediate Children", ""}, + {3, "PARENT", 0, "Parent", ""}, + {4, "SIBLINGS", 0, "Siblings", "Shared Parent"}, + {5, "TYPE", 0, "Type", "Shared object type"}, + {6, "LAYER", 0, "Layer", "Shared layers"}, + {7, "GROUP", 0, "Group", "Shared group"}, + {8, "HOOK", 0, "Hook", ""}, + {9, "PASS", 0, "Pass", "Render pass Index"}, + {10, "COLOR", 0, "Color", "Object Color"}, + {11, "PROPERTIES", 0, "Properties", "Game Properties"}, {12, "KEYINGSET", 0, "Keying Set", "Objects included in active Keying Set"}, {0, NULL, 0, NULL, NULL} }; @@ -676,8 +674,8 @@ static int object_select_grouped_exec(bContext *C, wmOperator *op) void OBJECT_OT_select_grouped(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Grouped"); - ot->description = _("Select all visible objects grouped by various properties"); + ot->name= "Select Grouped"; + ot->description = "Select all visible objects grouped by various properties"; ot->idname= "OBJECT_OT_select_grouped"; /* api callbacks */ @@ -689,8 +687,8 @@ void OBJECT_OT_select_grouped(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_select_grouped_types), 0, _("Type"), ""); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); + ot->prop= RNA_def_enum(ot->srna, "type", prop_select_grouped_types, 0, "Type", ""); } /************************* Select by Layer **********************/ @@ -725,8 +723,8 @@ static int object_select_by_layer_exec(bContext *C, wmOperator *op) void OBJECT_OT_select_by_layer(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select by Layer"); - ot->description = _("Select all visible objects on a layer"); + ot->name= "Select by Layer"; + ot->description = "Select all visible objects on a layer"; ot->idname= "OBJECT_OT_select_by_layer"; /* api callbacks */ @@ -738,8 +736,8 @@ void OBJECT_OT_select_by_layer(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend"), _("Extend selection instead of deselecting everything first.")); - RNA_def_int(ot->srna, "layers", 1, 1, 20, _("Layer"), "", 1, 20); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend", "Extend selection instead of deselecting everything first."); + RNA_def_int(ot->srna, "layers", 1, 1, 20, "Layer", "", 1, 20); } /************************** Select Inverse *************************/ @@ -764,8 +762,8 @@ void OBJECT_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); - ot->description = _("Invert selection of all visible objects"); + ot->name= "Select Inverse"; + ot->description = "Invert selection of all visible objects"; ot->idname= "OBJECT_OT_select_inverse"; /* api callbacks */ @@ -825,8 +823,8 @@ void OBJECT_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); - ot->description = _("Change selection of all visible objects in scene"); + ot->name= "Select or Deselect All"; + ot->description = "Change selection of all visible objects in scene"; ot->idname= "OBJECT_OT_select_all"; /* api callbacks */ @@ -874,8 +872,8 @@ void OBJECT_OT_select_same_group(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Same Group"); - ot->description = _("Select object in the same group"); + ot->name= "Select Same Group"; + ot->description = "Select object in the same group"; ot->idname= "OBJECT_OT_select_same_group"; /* api callbacks */ @@ -885,7 +883,7 @@ void OBJECT_OT_select_same_group(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_string(ot->srna, "group", "", 32, _("Group"), _("Name of the group to select.")); + RNA_def_string(ot->srna, "group", "", 32, "Group", "Name of the group to select."); } /**************************** Select Mirror ****************************/ @@ -927,8 +925,8 @@ void OBJECT_OT_select_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Mirror"); - ot->description = _("Select the Mirror objects of the selected object eg. L.sword -> R.sword"); + ot->name= "Select Mirror"; + ot->description = "Select the Mirror objects of the selected object eg. L.sword -> R.sword"; ot->idname= "OBJECT_OT_select_mirror"; /* api callbacks */ @@ -938,7 +936,7 @@ void OBJECT_OT_select_mirror(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend selection instead of deselecting everything first.")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend selection instead of deselecting everything first."); } @@ -984,8 +982,8 @@ void OBJECT_OT_select_name(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Name"); - ot->description = _("Select an object with this name"); + ot->name= "Select Name"; + ot->description = "Select an object with this name"; ot->idname= "OBJECT_OT_select_name"; /* api callbacks */ @@ -995,8 +993,8 @@ void OBJECT_OT_select_name(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_string(ot->srna, "name", "", 0, _("Name"), _("Object name to select.")); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend selection instead of deselecting everything first.")); + RNA_def_string(ot->srna, "name", "", 0, "Name", "Object name to select."); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend selection instead of deselecting everything first."); } /**************************** Select Random ****************************/ @@ -1031,8 +1029,8 @@ static int object_select_random_exec(bContext *C, wmOperator *op) void OBJECT_OT_select_random(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Random"); - ot->description = _("Set select on random visible objects"); + ot->name= "Select Random"; + ot->description = "Set select on random visible objects"; ot->idname= "OBJECT_OT_select_random"; /* api callbacks */ @@ -1044,8 +1042,8 @@ void OBJECT_OT_select_random(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, _("Percent"), _("Percentage of objects to select randomly"), 0.f, 100.0f); - RNA_def_boolean(ot->srna, "extend", FALSE, _("Extend Selection"), _("Extend selection instead of deselecting everything first.")); + RNA_def_float_percentage(ot->srna, "percent", 50.f, 0.0f, 100.0f, "Percent", "Percentage of objects to select randomly", 0.f, 100.0f); + RNA_def_boolean(ot->srna, "extend", FALSE, "Extend Selection", "Extend selection instead of deselecting everything first."); } diff --git a/source/blender/editors/object/object_shapekey.c b/source/blender/editors/object/object_shapekey.c index 96988d15ab2..fd2e7fd7c99 100644 --- a/source/blender/editors/object/object_shapekey.c +++ b/source/blender/editors/object/object_shapekey.c @@ -45,8 +45,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_curve_types.h" #include "DNA_key_types.h" #include "DNA_lattice_types.h" @@ -299,9 +297,9 @@ static int shape_key_add_exec(bContext *C, wmOperator *op) void OBJECT_OT_shape_key_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Shape Key"); + ot->name= "Add Shape Key"; ot->idname= "OBJECT_OT_shape_key_add"; - ot->description= _("Add shape key to the object"); + ot->description= "Add shape key to the object"; /* api callbacks */ ot->poll= shape_key_mode_poll; @@ -311,7 +309,7 @@ void OBJECT_OT_shape_key_add(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "from_mix", 1, _("From Mix"), _("Create the new shape key from the existing mix of keys.")); + RNA_def_boolean(ot->srna, "from_mix", 1, "From Mix", "Create the new shape key from the existing mix of keys."); } static int shape_key_remove_exec(bContext *C, wmOperator *UNUSED(op)) @@ -327,9 +325,9 @@ static int shape_key_remove_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_shape_key_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Shape Key"); + ot->name= "Remove Shape Key"; ot->idname= "OBJECT_OT_shape_key_remove"; - ot->description= _("Remove shape key from the object"); + ot->description= "Remove shape key from the object"; /* api callbacks */ ot->poll= shape_key_mode_poll; @@ -360,8 +358,8 @@ static int shape_key_clear_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_shape_key_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Shape Keys"); - ot->description= _("Clear weights for all shape keys"); + ot->name= "Clear Shape Keys"; + ot->description= "Clear weights for all shape keys"; ot->idname= "OBJECT_OT_shape_key_clear"; /* api callbacks */ @@ -385,7 +383,7 @@ static int shape_key_mirror_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_shape_key_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror Shape Key"); + ot->name= "Mirror Shape Key"; ot->idname= "OBJECT_OT_shape_key_mirror"; /* api callbacks */ @@ -448,13 +446,13 @@ static int shape_key_move_exec(bContext *C, wmOperator *op) void OBJECT_OT_shape_key_move(wmOperatorType *ot) { static EnumPropertyItem slot_move[] = { - {-1, "UP", 0, N_("Up"), ""}, - {1, "DOWN", 0, N_("Down"), ""}, + {-1, "UP", 0, "Up", ""}, + {1, "DOWN", 0, "Down", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Move Shape Key"); + ot->name= "Move Shape Key"; ot->idname= "OBJECT_OT_shape_key_move"; /* api callbacks */ @@ -464,6 +462,6 @@ void OBJECT_OT_shape_key_move(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(slot_move), 0, _("Type"), ""); + RNA_def_enum(ot->srna, "type", slot_move, 0, "Type", ""); } diff --git a/source/blender/editors/object/object_transform.c b/source/blender/editors/object/object_transform.c index 1af45add512..78f3537bea9 100644 --- a/source/blender/editors/object/object_transform.c +++ b/source/blender/editors/object/object_transform.c @@ -46,8 +46,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_curve.h" #include "BKE_depsgraph.h" @@ -272,8 +270,8 @@ static int object_location_clear_exec(bContext *C, wmOperator *op) void OBJECT_OT_location_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Location"); - ot->description = _("Clear the object's location"); + ot->name= "Clear Location"; + ot->description = "Clear the object's location"; ot->idname= "OBJECT_OT_location_clear"; /* api callbacks */ @@ -292,8 +290,8 @@ static int object_rotation_clear_exec(bContext *C, wmOperator *op) void OBJECT_OT_rotation_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Rotation"); - ot->description = _("Clear the object's rotation"); + ot->name= "Clear Rotation"; + ot->description = "Clear the object's rotation"; ot->idname= "OBJECT_OT_rotation_clear"; /* api callbacks */ @@ -312,8 +310,8 @@ static int object_scale_clear_exec(bContext *C, wmOperator *op) void OBJECT_OT_scale_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Scale"); - ot->description = _("Clear the object's scale"); + ot->name= "Clear Scale"; + ot->description = "Clear the object's scale"; ot->idname= "OBJECT_OT_scale_clear"; /* api callbacks */ @@ -358,8 +356,8 @@ static int object_origin_clear_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_origin_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Origin"); - ot->description = _("Clear the object's origin"); + ot->name= "Clear Origin"; + ot->description = "Clear the object's origin"; ot->idname= "OBJECT_OT_origin_clear"; /* api callbacks */ @@ -587,8 +585,8 @@ static int visual_transform_apply_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_visual_transform_apply(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Apply Visual Transform"); - ot->description = _("Apply the object's visual transformation to its data"); + ot->name= "Apply Visual Transform"; + ot->description = "Apply the object's visual transformation to its data"; ot->idname= "OBJECT_OT_visual_transform_apply"; /* api callbacks */ @@ -616,8 +614,8 @@ static int object_transform_apply_exec(bContext *C, wmOperator *op) void OBJECT_OT_transform_apply(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Apply Object Transform"); - ot->description = _("Apply the object's transformation to its data"); + ot->name= "Apply Object Transform"; + ot->description = "Apply the object's transformation to its data"; ot->idname= "OBJECT_OT_transform_apply"; /* api callbacks */ @@ -627,9 +625,9 @@ void OBJECT_OT_transform_apply(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "location", 0, _("Location"), ""); - RNA_def_boolean(ot->srna, "rotation", 0, _("Rotation"), ""); - RNA_def_boolean(ot->srna, "scale", 0, _("Scale"), ""); + RNA_def_boolean(ot->srna, "location", 0, "Location", ""); + RNA_def_boolean(ot->srna, "rotation", 0, "Rotation", ""); + RNA_def_boolean(ot->srna, "scale", 0, "Scale", ""); } /********************* Set Object Center ************************/ @@ -917,21 +915,21 @@ static int object_origin_set_exec(bContext *C, wmOperator *op) void OBJECT_OT_origin_set(wmOperatorType *ot) { static EnumPropertyItem prop_set_center_types[] = { - {GEOMETRY_TO_ORIGIN, "GEOMETRY_ORIGIN", 0, N_("Geometry to Origin"), N_("Move object geometry to object origin")}, - {ORIGIN_TO_GEOMETRY, "ORIGIN_GEOMETRY", 0, N_("Origin to Geometry"), N_("Move object origin to center of object geometry")}, - {ORIGIN_TO_CURSOR, "ORIGIN_CURSOR", 0, N_("Origin to 3D Cursor"), N_("Move object origin to position of the 3d cursor")}, + {GEOMETRY_TO_ORIGIN, "GEOMETRY_ORIGIN", 0, "Geometry to Origin", "Move object geometry to object origin"}, + {ORIGIN_TO_GEOMETRY, "ORIGIN_GEOMETRY", 0, "Origin to Geometry", "Move object origin to center of object geometry"}, + {ORIGIN_TO_CURSOR, "ORIGIN_CURSOR", 0, "Origin to 3D Cursor", "Move object origin to position of the 3d cursor"}, {0, NULL, 0, NULL, NULL} }; static EnumPropertyItem prop_set_bounds_types[] = { - {V3D_CENTROID, "MEDIAN", 0, N_("Median Center"), ""}, - {V3D_CENTER, "BOUNDS", 0, N_("Bounds Center"), ""}, + {V3D_CENTROID, "MEDIAN", 0, "Median Center", ""}, + {V3D_CENTER, "BOUNDS", 0, "Bounds Center", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Set Origin"); - ot->description = _("Set the object's origin, by either moving the data, or set to center of data, or use 3d cursor"); + ot->name= "Set Origin"; + ot->description = "Set the object's origin, by either moving the data, or set to center of data, or use 3d cursor"; ot->idname= "OBJECT_OT_origin_set"; /* api callbacks */ @@ -943,7 +941,7 @@ void OBJECT_OT_origin_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_set_center_types), 0, _("Type"), ""); - RNA_def_enum(ot->srna, "center", RNA_enum_items_gettexted(prop_set_bounds_types), V3D_CENTROID, _("Center"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_set_center_types, 0, "Type", ""); + RNA_def_enum(ot->srna, "center", prop_set_bounds_types, V3D_CENTROID, "Center", ""); } diff --git a/source/blender/editors/object/object_vgroup.c b/source/blender/editors/object/object_vgroup.c index 04390612dd0..52ba9460818 100644 --- a/source/blender/editors/object/object_vgroup.c +++ b/source/blender/editors/object/object_vgroup.c @@ -53,8 +53,6 @@ #include "BLI_editVert.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_customdata.h" #include "BKE_deform.h" @@ -1552,7 +1550,7 @@ static int vertex_group_add_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Vertex Group"); + ot->name= "Add Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_add"; /* api callbacks */ @@ -1582,7 +1580,7 @@ static int vertex_group_remove_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Vertex Group"); + ot->name= "Remove Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_remove"; /* api callbacks */ @@ -1593,7 +1591,7 @@ void OBJECT_OT_vertex_group_remove(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 0, _("All"), _("Remove from all vertex groups.")); + RNA_def_boolean(ot->srna, "all", 0, "All", "Remove from all vertex groups."); } static int vertex_group_assign_exec(bContext *C, wmOperator *op) @@ -1614,7 +1612,7 @@ static int vertex_group_assign_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_assign(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Assign Vertex Group"); + ot->name= "Assign Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_assign"; /* api callbacks */ @@ -1625,7 +1623,7 @@ void OBJECT_OT_vertex_group_assign(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "new", 0, _("New"), _("Assign vertex to new vertex group.")); + RNA_def_boolean(ot->srna, "new", 0, "New", "Assign vertex to new vertex group."); } static int vertex_group_remove_from_exec(bContext *C, wmOperator *op) @@ -1653,7 +1651,7 @@ static int vertex_group_remove_from_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_remove_from(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove from Vertex Group"); + ot->name= "Remove from Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_remove_from"; /* api callbacks */ @@ -1664,7 +1662,7 @@ void OBJECT_OT_vertex_group_remove_from(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "all", 0, _("All"), _("Remove from all vertex groups.")); + RNA_def_boolean(ot->srna, "all", 0, "All", "Remove from all vertex groups."); } static int vertex_group_select_exec(bContext *C, wmOperator *UNUSED(op)) @@ -1683,7 +1681,7 @@ static int vertex_group_select_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Vertex Group"); + ot->name= "Select Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_select"; /* api callbacks */ @@ -1707,7 +1705,7 @@ static int vertex_group_deselect_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_deselect(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Deselect Vertex Group"); + ot->name= "Deselect Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_deselect"; /* api callbacks */ @@ -1733,7 +1731,7 @@ static int vertex_group_copy_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Vertex Group"); + ot->name= "Copy Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_copy"; /* api callbacks */ @@ -1763,7 +1761,7 @@ static int vertex_group_levels_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_levels(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Group Levels"); + ot->name= "Vertex Group Levels"; ot->idname= "OBJECT_OT_vertex_group_levels"; /* api callbacks */ @@ -1773,8 +1771,8 @@ void OBJECT_OT_vertex_group_levels(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float(ot->srna, "offset", 0.f, -1.0, 1.0, N_("Offset"), N_("Value to add to weights."), -1.0f, 1.f); - RNA_def_float(ot->srna, "gain", 1.f, 0.f, FLT_MAX, N_("Gain"), N_("Value to multiply weights by."), 0.0f, 10.f); + RNA_def_float(ot->srna, "offset", 0.f, -1.0, 1.0, "Offset", "Value to add to weights.", -1.0f, 1.f); + RNA_def_float(ot->srna, "gain", 1.f, 0.f, FLT_MAX, "Gain", "Value to multiply weights by.", 0.0f, 10.f); } static int vertex_group_normalize_exec(bContext *C, wmOperator *UNUSED(op)) @@ -1793,7 +1791,7 @@ static int vertex_group_normalize_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_normalize(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Normalize Vertex Group"); + ot->name= "Normalize Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_normalize"; /* api callbacks */ @@ -1821,7 +1819,7 @@ static int vertex_group_normalize_all_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_normalize_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Normalize All Vertex Groups"); + ot->name= "Normalize All Vertex Groups"; ot->idname= "OBJECT_OT_vertex_group_normalize_all"; /* api callbacks */ @@ -1831,7 +1829,7 @@ void OBJECT_OT_vertex_group_normalize_all(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "lock_active", TRUE, _("Lock Active"), _("Keep the values of the active group while normalizing others.")); + RNA_def_boolean(ot->srna, "lock_active", TRUE, "Lock Active", "Keep the values of the active group while normalizing others."); } static int vertex_group_invert_exec(bContext *C, wmOperator *op) @@ -1851,7 +1849,7 @@ static int vertex_group_invert_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_invert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Invert Vertex Group"); + ot->name= "Invert Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_invert"; /* api callbacks */ @@ -1861,8 +1859,8 @@ void OBJECT_OT_vertex_group_invert(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "auto_assign", TRUE, _("Add Weights"), _("Add verts from groups that have zero weight before inverting.")); - RNA_def_boolean(ot->srna, "auto_remove", TRUE, _("Remove Weights"), _("Remove verts from groups that have zero weight after inverting.")); + RNA_def_boolean(ot->srna, "auto_assign", TRUE, "Add Weights", "Add verts from groups that have zero weight before inverting."); + RNA_def_boolean(ot->srna, "auto_remove", TRUE, "Remove Weights", "Remove verts from groups that have zero weight after inverting."); } @@ -1882,7 +1880,7 @@ static int vertex_group_blend_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_blend(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Blend Vertex Group"); + ot->name= "Blend Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_blend"; ot->description= ""; @@ -1916,9 +1914,9 @@ static int vertex_group_clean_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_clean(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clean Vertex Group"); + ot->name= "Clean Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_clean"; - ot->description= _("Remove Vertex Group assignments which aren't required"); + ot->description= "Remove Vertex Group assignments which aren't required"; /* api callbacks */ ot->poll= vertex_group_poll; @@ -1927,9 +1925,9 @@ void OBJECT_OT_vertex_group_clean(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float(ot->srna, "limit", 0.01f, 0.0f, 1.0, _("Limit"), _("Remove weights under this limit."), 0.001f, 0.99f); - RNA_def_boolean(ot->srna, "all_groups", FALSE, _("All Groups"), _("Clean all vertex groups.")); - RNA_def_boolean(ot->srna, "keep_single", FALSE, _("Keep Single"), _("Keep verts assigned to at least one group when cleaning.")); + RNA_def_float(ot->srna, "limit", 0.01f, 0.0f, 1.0, "Limit", "Remove weights under this limit.", 0.001f, 0.99f); + RNA_def_boolean(ot->srna, "all_groups", FALSE, "All Groups", "Clean all vertex groups."); + RNA_def_boolean(ot->srna, "keep_single", FALSE, "Keep Single", "Keep verts assigned to at least one group when cleaning."); } @@ -1949,9 +1947,9 @@ static int vertex_group_mirror_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror Vertex Group"); + ot->name= "Mirror Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_mirror"; - ot->description= _("Mirror all vertex groups, flip weights and/or names, editing only selected vertices, flipping when both sides are selected otherwise copy from unselected"); + ot->description= "Mirror all vertex groups, flip weights and/or names, editing only selected vertices, flipping when both sides are selected otherwise copy from unselected"; /* api callbacks */ ot->poll= vertex_group_poll_edit; @@ -1961,8 +1959,8 @@ void OBJECT_OT_vertex_group_mirror(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "mirror_weights", TRUE, _("Mirror Weights"), _("Mirror weights.")); - RNA_def_boolean(ot->srna, "flip_group_names", TRUE, _("Flip Groups"), _("Flip vertex group names.")); + RNA_def_boolean(ot->srna, "mirror_weights", TRUE, "Mirror Weights", "Mirror weights."); + RNA_def_boolean(ot->srna, "flip_group_names", TRUE, "Flip Groups", "Flip vertex group names."); } @@ -1995,9 +1993,9 @@ static int vertex_group_copy_to_linked_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_vertex_group_copy_to_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Vertex Groups to Linked"); + ot->name= "Copy Vertex Groups to Linked"; ot->idname= "OBJECT_OT_vertex_group_copy_to_linked"; - ot->description= _("Copy Vertex Groups to all users of the same Geometry data"); + ot->description= "Copy Vertex Groups to all users of the same Geometry data"; /* api callbacks */ ot->poll= vertex_group_poll; @@ -2033,9 +2031,9 @@ static int vertex_group_copy_to_selected_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_copy_to_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Vertex Group to Selected"); + ot->name= "Copy Vertex Group to Selected"; ot->idname= "OBJECT_OT_vertex_group_copy_to_selected"; - ot->description= _("Copy Vertex Groups to other selected objects with matching indices"); + ot->description= "Copy Vertex Groups to other selected objects with matching indices"; /* api callbacks */ ot->poll= vertex_group_poll; @@ -2091,9 +2089,9 @@ void OBJECT_OT_vertex_group_set_active(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Set Active Vertex Group"); + ot->name= "Set Active Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_set_active"; - ot->description= _("Set the active vertex group"); + ot->description= "Set the active vertex group"; /* api callbacks */ ot->poll= vertex_group_poll; @@ -2104,7 +2102,7 @@ void OBJECT_OT_vertex_group_set_active(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - prop= RNA_def_enum(ot->srna, "group", vgroup_items, 0, _("Group"), _("Vertex group to set as active.")); + prop= RNA_def_enum(ot->srna, "group", vgroup_items, 0, "Group", "Vertex group to set as active."); RNA_def_enum_funcs(prop, vgroup_itemf); ot->prop= prop; } @@ -2223,9 +2221,9 @@ static int vertex_group_sort_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_sort(wmOperatorType *ot) { - ot->name= _("Sort Vertex Groups"); + ot->name= "Sort Vertex Groups"; ot->idname= "OBJECT_OT_vertex_group_sort"; - ot->description= _("Sorts vertex groups alphabetically"); + ot->description= "Sorts vertex groups alphabetically"; /* api callbacks */ ot->poll= vertex_group_poll; @@ -2276,13 +2274,13 @@ static int vgroup_move_exec(bContext *C, wmOperator *op) void OBJECT_OT_vertex_group_move(wmOperatorType *ot) { static EnumPropertyItem vgroup_slot_move[] = { - {1, "UP", 0, N_("Up"), ""}, - {-1, "DOWN", 0, N_("Down"), ""}, + {1, "UP", 0, "Up", ""}, + {-1, "DOWN", 0, "Down", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Move Vertex Group"); + ot->name= "Move Vertex Group"; ot->idname= "OBJECT_OT_vertex_group_move"; /* api callbacks */ @@ -2292,5 +2290,5 @@ void OBJECT_OT_vertex_group_move(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(vgroup_slot_move), 0, _("Direction"), _("Direction to move, UP or DOWN")); + RNA_def_enum(ot->srna, "direction", vgroup_slot_move, 0, "Direction", "Direction to move, UP or DOWN"); } diff --git a/source/blender/editors/physics/CMakeLists.txt b/source/blender/editors/physics/CMakeLists.txt index 931c6f9334f..f32b23cd3ee 100644 --- a/source/blender/editors/physics/CMakeLists.txt +++ b/source/blender/editors/physics/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/physics/SConscript b/source/blender/editors/physics/SConscript index ef82ab2423b..188416eb04c 100644 --- a/source/blender/editors/physics/SConscript +++ b/source/blender/editors/physics/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../gpu ../../blenloader' incs += ' ../../makesrna ../../render/extern/include #/intern/elbeem/extern' diff --git a/source/blender/editors/physics/particle_edit.c b/source/blender/editors/physics/particle_edit.c index 55f8c859a3b..4b0c1cb1222 100644 --- a/source/blender/editors/physics/particle_edit.c +++ b/source/blender/editors/physics/particle_edit.c @@ -53,8 +53,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_DerivedMesh.h" #include "BKE_depsgraph.h" @@ -1358,7 +1356,7 @@ static int select_all_exec(bContext *C, wmOperator *op) void PARTICLE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Selection of all particles"); + ot->name= "Selection of all particles"; ot->idname= "PARTICLE_OT_select_all"; /* api callbacks */ @@ -1432,7 +1430,7 @@ static int select_roots_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_select_roots(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Roots"); + ot->name= "Select Roots"; ot->idname= "PARTICLE_OT_select_roots"; /* api callbacks */ @@ -1472,7 +1470,7 @@ static int select_tips_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_select_tips(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Tips"); + ot->name= "Select Tips"; ot->idname= "PARTICLE_OT_select_tips"; /* api callbacks */ @@ -1516,7 +1514,7 @@ static int select_linked_invoke(bContext *C, wmOperator *op, wmEvent *event) void PARTICLE_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked"); + ot->name= "Select Linked"; ot->idname= "PARTICLE_OT_select_linked"; /* api callbacks */ @@ -1528,8 +1526,8 @@ void PARTICLE_OT_select_linked(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "deselect", 0, _("Deselect"), _("Deselect linked keys rather than selecting them.")); - RNA_def_int_vector(ot->srna, "location", 2, NULL, 0, INT_MAX, _("Location"), "", 0, 16384); + RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", "Deselect linked keys rather than selecting them."); + RNA_def_int_vector(ot->srna, "location", 2, NULL, 0, INT_MAX, "Location", "", 0, 16384); } /************************ border select operator ************************/ @@ -1704,7 +1702,7 @@ static int hide_exec(bContext *C, wmOperator *op) void PARTICLE_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selected"); + ot->name= "Hide Selected"; ot->idname= "PARTICLE_OT_hide"; /* api callbacks */ @@ -1715,7 +1713,7 @@ void PARTICLE_OT_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } /*************************** reveal operator **************************/ @@ -1746,7 +1744,7 @@ static int reveal_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal"); + ot->name= "Reveal"; ot->idname= "PARTICLE_OT_reveal"; /* api callbacks */ @@ -1804,7 +1802,7 @@ static int select_less_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_select_less(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Less"); + ot->name= "Select Less"; ot->idname= "PARTICLE_OT_select_less"; /* api callbacks */ @@ -1865,7 +1863,7 @@ static int select_more_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_select_more(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select More"); + ot->name= "Select More"; ot->idname= "PARTICLE_OT_select_more"; /* api callbacks */ @@ -1902,7 +1900,7 @@ static int select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_select_inverse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); + ot->name= "Select Inverse"; ot->idname= "PARTICLE_OT_select_inverse"; /* api callbacks */ @@ -1998,7 +1996,7 @@ static int rekey_exec(bContext *C, wmOperator *op) void PARTICLE_OT_rekey(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rekey"); + ot->name= "Rekey"; ot->idname= "PARTICLE_OT_rekey"; /* api callbacks */ @@ -2010,7 +2008,7 @@ void PARTICLE_OT_rekey(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "keys", 2, 2, INT_MAX, _("Number of Keys"), "", 2, 100); + RNA_def_int(ot->srna, "keys", 2, 2, INT_MAX, "Number of Keys", "", 2, 100); } static void rekey_particle_to_time(Scene *scene, Object *ob, int pa_index, float path_time) @@ -2328,7 +2326,7 @@ static int subdivide_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_subdivide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Subdivide"); + ot->name= "Subdivide"; ot->idname= "PARTICLE_OT_subdivide"; /* api callbacks */ @@ -2416,7 +2414,7 @@ static int remove_doubles_exec(bContext *C, wmOperator *op) void PARTICLE_OT_remove_doubles(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Doubles"); + ot->name= "Remove Doubles"; ot->idname= "PARTICLE_OT_remove_doubles"; /* api callbacks */ @@ -2427,7 +2425,7 @@ void PARTICLE_OT_remove_doubles(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float(ot->srna, "threshold", 0.0002f, 0.0f, FLT_MAX, _("Threshold"), _("Threshold distance withing which particles are removed"), 0.00001f, 0.1f); + RNA_def_float(ot->srna, "threshold", 0.0002f, 0.0f, FLT_MAX, "Threshold", "Threshold distance withing which particles are removed", 0.00001f, 0.1f); } @@ -2466,7 +2464,7 @@ static int weight_set_exec(bContext *C, wmOperator *op) void PARTICLE_OT_weight_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weight Set"); + ot->name= "Weight Set"; ot->idname= "PARTICLE_OT_weight_set"; /* api callbacks */ @@ -2476,7 +2474,7 @@ void PARTICLE_OT_weight_set(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float(ot->srna, "factor", 1, 0, 1, _("Factor"), "", 0, 1); + RNA_def_float(ot->srna, "factor", 1, 0, 1, "Factor", "", 0, 1); } /************************ cursor drawing *******************************/ @@ -2569,7 +2567,7 @@ static int delete_exec(bContext *C, wmOperator *op) void PARTICLE_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); + ot->name= "Delete"; ot->idname= "PARTICLE_OT_delete"; /* api callbacks */ @@ -2581,7 +2579,7 @@ void PARTICLE_OT_delete(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", delete_type_items, DEL_PARTICLE, _("Type"), _("Delete a full particle or only keys.")); + ot->prop= RNA_def_enum(ot->srna, "type", delete_type_items, DEL_PARTICLE, "Type", "Delete a full particle or only keys."); } /*************************** mirror operator **************************/ @@ -2729,7 +2727,7 @@ static int mirror_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_mirror(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror"); + ot->name= "Mirror"; ot->idname= "PARTICLE_OT_mirror"; /* api callbacks */ @@ -3746,7 +3744,7 @@ static int brush_edit_cancel(bContext *UNUSED(C), wmOperator *op) void PARTICLE_OT_brush_edit(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Brush Edit"); + ot->name= "Brush Edit"; ot->idname= "PARTICLE_OT_brush_edit"; /* api callbacks */ @@ -3760,7 +3758,7 @@ void PARTICLE_OT_brush_edit(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; /* properties */ - RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, _("Stroke"), ""); + RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, "Stroke", ""); } /*********************** undo ***************************/ @@ -4236,7 +4234,7 @@ static int particle_edit_toggle_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_particle_edit_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Particle Edit Toggle"); + ot->name= "Particle Edit Toggle"; ot->idname= "PARTICLE_OT_particle_edit_toggle"; /* api callbacks */ @@ -4285,7 +4283,7 @@ static int clear_edited_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_edited_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Edited"); + ot->name= "Clear Edited"; ot->idname= "PARTICLE_OT_edited_clear"; /* api callbacks */ diff --git a/source/blender/editors/physics/particle_object.c b/source/blender/editors/physics/particle_object.c index 8392c25f46e..8ec95e9b107 100644 --- a/source/blender/editors/physics/particle_object.c +++ b/source/blender/editors/physics/particle_object.c @@ -43,8 +43,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_DerivedMesh.h" @@ -87,9 +85,9 @@ static int particle_system_add_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_particle_system_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Particle System Slot"); + ot->name= "Add Particle System Slot"; ot->idname= "OBJECT_OT_particle_system_add"; - ot->description=_("Add a particle system"); + ot->description="Add a particle system"; /* api callbacks */ ot->poll= ED_operator_object_active_editable; @@ -126,9 +124,9 @@ static int particle_system_remove_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_particle_system_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Particle System Slot"); + ot->name= "Remove Particle System Slot"; ot->idname= "OBJECT_OT_particle_system_remove"; - ot->description=_("Remove the selected particle system"); + ot->description="Remove the selected particle system"; /* api callbacks */ ot->poll= ED_operator_object_active_editable; @@ -185,9 +183,9 @@ static int new_particle_settings_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Particle Settings"); + ot->name= "New Particle Settings"; ot->idname= "PARTICLE_OT_new"; - ot->description=_("Add new particle settings"); + ot->description="Add new particle settings"; /* api callbacks */ ot->exec= new_particle_settings_exec; @@ -234,9 +232,9 @@ static int new_particle_target_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_new_target(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Particle Target"); + ot->name= "New Particle Target"; ot->idname= "PARTICLE_OT_new_target"; - ot->description=_("Add a new particle target"); + ot->description="Add a new particle target"; /* api callbacks */ ot->exec= new_particle_target_exec; @@ -283,9 +281,9 @@ static int remove_particle_target_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_target_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Particle Target"); + ot->name= "Remove Particle Target"; ot->idname= "PARTICLE_OT_target_remove"; - ot->description=_("Remove the selected particle target"); + ot->description="Remove the selected particle target"; /* api callbacks */ ot->exec= remove_particle_target_exec; @@ -323,9 +321,9 @@ static int target_move_up_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_target_move_up(wmOperatorType *ot) { - ot->name= _("Move Up Target"); + ot->name= "Move Up Target"; ot->idname= "PARTICLE_OT_target_move_up"; - ot->description= _("Move particle target up in the list"); + ot->description= "Move particle target up in the list"; ot->exec= target_move_up_exec; @@ -361,9 +359,9 @@ static int target_move_down_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_target_move_down(wmOperatorType *ot) { - ot->name= _("Move Down Target"); + ot->name= "Move Down Target"; ot->idname= "PARTICLE_OT_target_move_down"; - ot->description= _("Move particle target down in the list"); + ot->description= "Move particle target down in the list"; ot->exec= target_move_down_exec; @@ -399,9 +397,9 @@ static int dupliob_move_up_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_dupliob_move_up(wmOperatorType *ot) { - ot->name= _("Move Up Dupli Object"); + ot->name= "Move Up Dupli Object"; ot->idname= "PARTICLE_OT_dupliob_move_up"; - ot->description= _("Move dupli object up in the list"); + ot->description= "Move dupli object up in the list"; ot->exec= dupliob_move_up_exec; @@ -439,9 +437,9 @@ static int copy_particle_dupliob_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_dupliob_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Particle Dupliob"); + ot->name= "Copy Particle Dupliob"; ot->idname= "PARTICLE_OT_dupliob_copy"; - ot->description=_("Duplicate the current dupliobject"); + ot->description="Duplicate the current dupliobject"; /* api callbacks */ ot->exec= copy_particle_dupliob_exec; @@ -482,9 +480,9 @@ static int remove_particle_dupliob_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_dupliob_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Particle Dupliobject"); + ot->name= "Remove Particle Dupliobject"; ot->idname= "PARTICLE_OT_dupliob_remove"; - ot->description=_("Remove the selected dupliobject"); + ot->description="Remove the selected dupliobject"; /* api callbacks */ ot->exec= remove_particle_dupliob_exec; @@ -521,9 +519,9 @@ static int dupliob_move_down_exec(bContext *C, wmOperator *UNUSED(op)) void PARTICLE_OT_dupliob_move_down(wmOperatorType *ot) { - ot->name= _("Move Down Dupli Object"); + ot->name= "Move Down Dupli Object"; ot->idname= "PARTICLE_OT_dupliob_move_down"; - ot->description= _("Move dupli object down in the list"); + ot->description= "Move dupli object down in the list"; ot->exec= dupliob_move_down_exec; @@ -611,8 +609,8 @@ static int disconnect_hair_exec(bContext *C, wmOperator *op) void PARTICLE_OT_disconnect_hair(wmOperatorType *ot) { - ot->name= _("Disconnect Hair"); - ot->description= _("Disconnect hair from the emitter mesh"); + ot->name= "Disconnect Hair"; + ot->description= "Disconnect hair from the emitter mesh"; ot->idname= "PARTICLE_OT_disconnect_hair"; ot->exec= disconnect_hair_exec; @@ -620,7 +618,7 @@ void PARTICLE_OT_disconnect_hair(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "all", 0, _("All hair"), _("Disconnect all hair systems from the emitter mesh")); + RNA_def_boolean(ot->srna, "all", 0, "All hair", "Disconnect all hair systems from the emitter mesh"); } static void connect_hair(Scene *scene, Object *ob, ParticleSystem *psys) @@ -749,8 +747,8 @@ static int connect_hair_exec(bContext *C, wmOperator *op) void PARTICLE_OT_connect_hair(wmOperatorType *ot) { - ot->name= _("Connect Hair"); - ot->description= _("Connect hair to the emitter mesh"); + ot->name= "Connect Hair"; + ot->description= "Connect hair to the emitter mesh"; ot->idname= "PARTICLE_OT_connect_hair"; ot->exec= connect_hair_exec; @@ -758,6 +756,6 @@ void PARTICLE_OT_connect_hair(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "all", 0, _("All hair"), _("Connect all hair systems to the emitter mesh")); + RNA_def_boolean(ot->srna, "all", 0, "All hair", "Connect all hair systems to the emitter mesh"); } diff --git a/source/blender/editors/physics/physics_pointcache.c b/source/blender/editors/physics/physics_pointcache.c index 093e77bfb67..34f4a1e472b 100644 --- a/source/blender/editors/physics/physics_pointcache.c +++ b/source/blender/editors/physics/physics_pointcache.c @@ -39,8 +39,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "BKE_context.h" @@ -157,8 +155,8 @@ static int ptcache_free_bake_all_exec(bContext *C, wmOperator *UNUSED(op)) void PTCACHE_OT_bake_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bake All Physics"); - ot->description= _("Bake all physics"); + ot->name= "Bake All Physics"; + ot->description= "Bake all physics"; ot->idname= "PTCACHE_OT_bake_all"; /* api callbacks */ @@ -168,7 +166,7 @@ void PTCACHE_OT_bake_all(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "bake", 1, _("Bake"), ""); + RNA_def_boolean(ot->srna, "bake", 1, "Bake", ""); } void PTCACHE_OT_free_bake_all(wmOperatorType *ot) { @@ -270,8 +268,8 @@ static int ptcache_bake_from_cache_exec(bContext *C, wmOperator *UNUSED(op)) void PTCACHE_OT_bake(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bake Physics"); - ot->description= _("Bake physics"); + ot->name= "Bake Physics"; + ot->description= "Bake physics"; ot->idname= "PTCACHE_OT_bake"; /* api callbacks */ @@ -281,7 +279,7 @@ void PTCACHE_OT_bake(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "bake", 0, _("Bake"), ""); + RNA_def_boolean(ot->srna, "bake", 0, "Bake", ""); } void PTCACHE_OT_free_bake(wmOperatorType *ot) { diff --git a/source/blender/editors/render/SConscript b/source/blender/editors/render/SConscript index 7d50db14d4f..53418500ea6 100644 --- a/source/blender/editors/render/SConscript +++ b/source/blender/editors/render/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenlib ../../blenfont ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../gpu' incs += ' ../../makesrna ../../render/extern/include #/intern/elbeem/extern' diff --git a/source/blender/editors/render/render_internal.c b/source/blender/editors/render/render_internal.c index 6d3bbb45fb7..42a163d3da5 100644 --- a/source/blender/editors/render/render_internal.c +++ b/source/blender/editors/render/render_internal.c @@ -41,8 +41,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "BKE_blender.h" @@ -602,8 +600,8 @@ static int screen_render_invoke(bContext *C, wmOperator *op, wmEvent *event) void RENDER_OT_render(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Render"); - ot->description= _("Render active scene"); + ot->name= "Render"; + ot->description= "Render active scene"; ot->idname= "RENDER_OT_render"; /* api callbacks */ @@ -613,9 +611,9 @@ void RENDER_OT_render(wmOperatorType *ot) /*ot->poll= ED_operator_screenactive;*/ /* this isnt needed, causes failer in background mode */ - RNA_def_boolean(ot->srna, "animation", 0, _("Animation"), _("Render files from the animation range of this scene")); - RNA_def_boolean(ot->srna, "write_still", 0, _("Write Image"), _("Save rendered the image to the output path (used only when animation is disabled)")); - RNA_def_string(ot->srna, "layer", "", RE_MAXNAME, _("Render Layer"), _("Single render layer to re-render")); - RNA_def_string(ot->srna, "scene", "", MAX_ID_NAME-2, _("Scene"), _("Re-render single layer in this scene")); + RNA_def_boolean(ot->srna, "animation", 0, "Animation", "Render files from the animation range of this scene"); + RNA_def_boolean(ot->srna, "write_still", 0, "Write Image", "Save rendered the image to the output path (used only when animation is disabled)"); + RNA_def_string(ot->srna, "layer", "", RE_MAXNAME, "Render Layer", "Single render layer to re-render"); + RNA_def_string(ot->srna, "scene", "", MAX_ID_NAME-2, "Scene", "Re-render single layer in this scene"); } diff --git a/source/blender/editors/render/render_opengl.c b/source/blender/editors/render/render_opengl.c index deb226e0113..3256112426b 100644 --- a/source/blender/editors/render/render_opengl.c +++ b/source/blender/editors/render/render_opengl.c @@ -43,8 +43,6 @@ #include "BLI_dlrbTree.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "DNA_object_types.h" @@ -599,8 +597,8 @@ static int screen_opengl_render_exec(bContext *C, wmOperator *op) void RENDER_OT_opengl(wmOperatorType *ot) { /* identifiers */ - ot->name= _("OpenGL Render"); - ot->description= _("OpenGL render active viewport"); + ot->name= "OpenGL Render"; + ot->description= "OpenGL render active viewport"; ot->idname= "RENDER_OT_opengl"; /* api callbacks */ @@ -611,9 +609,9 @@ void RENDER_OT_opengl(wmOperatorType *ot) ot->poll= ED_operator_screenactive; - RNA_def_boolean(ot->srna, "animation", 0, _("Animation"), _("Render files from the animation range of this scene")); - RNA_def_boolean(ot->srna, "write_still", 0, _("Write Image"), _("Save rendered the image to the output path (used only when animation is disabled)")); - RNA_def_boolean(ot->srna, "view_context", 1, _("View Context"), _("Use the current 3D view for rendering, else use scene settings.")); + RNA_def_boolean(ot->srna, "animation", 0, "Animation", "Render files from the animation range of this scene"); + RNA_def_boolean(ot->srna, "write_still", 0, "Write Image", "Save rendered the image to the output path (used only when animation is disabled)"); + RNA_def_boolean(ot->srna, "view_context", 1, "View Context", "Use the current 3D view for rendering, else use scene settings."); } /* function for getting an opengl buffer from a View3D, used by sequencer */ diff --git a/source/blender/editors/render/render_shading.c b/source/blender/editors/render/render_shading.c index 6935928c643..6a1eea92563 100644 --- a/source/blender/editors/render/render_shading.c +++ b/source/blender/editors/render/render_shading.c @@ -50,8 +50,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_animsys.h" #include "BKE_context.h" #include "BKE_curve.h" @@ -111,9 +109,9 @@ static int material_slot_add_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_material_slot_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Material Slot"); + ot->name= "Add Material Slot"; ot->idname= "OBJECT_OT_material_slot_add"; - ot->description=_("Add a new material slot"); + ot->description="Add a new material slot"; /* api callbacks */ ot->exec= material_slot_add_exec; @@ -147,9 +145,9 @@ static int material_slot_remove_exec(bContext *C, wmOperator *op) void OBJECT_OT_material_slot_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Material Slot"); + ot->name= "Remove Material Slot"; ot->idname= "OBJECT_OT_material_slot_remove"; - ot->description=_("Remove the selected material slot"); + ot->description="Remove the selected material slot"; /* api callbacks */ ot->exec= material_slot_remove_exec; @@ -207,9 +205,9 @@ static int material_slot_assign_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_material_slot_assign(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Assign Material Slot"); + ot->name= "Assign Material Slot"; ot->idname= "OBJECT_OT_material_slot_assign"; - ot->description=_("Assign the material in the selected material slot to the selected vertices"); + ot->description="Assign the material in the selected material slot to the selected vertices"; /* api callbacks */ ot->exec= material_slot_assign_exec; @@ -294,9 +292,9 @@ static int material_slot_select_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_material_slot_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Material Slot"); + ot->name= "Select Material Slot"; ot->idname= "OBJECT_OT_material_slot_select"; - ot->description=_("Select vertices assigned to the selected material slot"); + ot->description="Select vertices assigned to the selected material slot"; /* api callbacks */ ot->exec= material_slot_select_exec; @@ -313,9 +311,9 @@ static int material_slot_deselect_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_material_slot_deselect(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Deselect Material Slot"); + ot->name= "Deselect Material Slot"; ot->idname= "OBJECT_OT_material_slot_deselect"; - ot->description=_("Deselect vertices assigned to the selected material slot"); + ot->description="Deselect vertices assigned to the selected material slot"; /* api callbacks */ ot->exec= material_slot_deselect_exec; @@ -353,9 +351,9 @@ static int material_slot_copy_exec(bContext *C, wmOperator *UNUSED(op)) void OBJECT_OT_material_slot_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Material to Others"); + ot->name= "Copy Material to Others"; ot->idname= "OBJECT_OT_material_slot_copy"; - ot->description=_("Copies materials to other selected objects"); + ot->description="Copies materials to other selected objects"; /* api callbacks */ ot->exec= material_slot_copy_exec; @@ -399,9 +397,9 @@ static int new_material_exec(bContext *C, wmOperator *UNUSED(op)) void MATERIAL_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Material"); + ot->name= "New Material"; ot->idname= "MATERIAL_OT_new"; - ot->description=_("Add a new material"); + ot->description="Add a new material"; /* api callbacks */ ot->exec= new_material_exec; @@ -445,9 +443,9 @@ static int new_texture_exec(bContext *C, wmOperator *UNUSED(op)) void TEXTURE_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Texture"); + ot->name= "New Texture"; ot->idname= "TEXTURE_OT_new"; - ot->description=_("Add a new texture"); + ot->description="Add a new texture"; /* api callbacks */ ot->exec= new_texture_exec; @@ -491,9 +489,9 @@ static int new_world_exec(bContext *C, wmOperator *UNUSED(op)) void WORLD_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New World"); + ot->name= "New World"; ot->idname= "WORLD_OT_new"; - ot->description= _("Add a new world"); + ot->description= "Add a new world"; /* api callbacks */ ot->exec= new_world_exec; @@ -519,9 +517,9 @@ static int render_layer_add_exec(bContext *C, wmOperator *UNUSED(op)) void SCENE_OT_render_layer_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Render Layer"); + ot->name= "Add Render Layer"; ot->idname= "SCENE_OT_render_layer_add"; - ot->description=_("Add a render layer"); + ot->description="Add a render layer"; /* api callbacks */ ot->exec= render_layer_add_exec; @@ -567,9 +565,9 @@ static int render_layer_remove_exec(bContext *C, wmOperator *UNUSED(op)) void SCENE_OT_render_layer_remove(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Render Layer"); + ot->name= "Remove Render Layer"; ot->idname= "SCENE_OT_render_layer_remove"; - ot->description=_("Remove the selected render layer"); + ot->description="Remove the selected render layer"; /* api callbacks */ ot->exec= render_layer_remove_exec; @@ -645,15 +643,15 @@ static int texture_slot_move(bContext *C, wmOperator *op) void TEXTURE_OT_slot_move(wmOperatorType *ot) { static EnumPropertyItem slot_move[] = { - {-1, "UP", 0, N_("Up"), ""}, - {1, "DOWN", 0, N_("Down"), ""}, + {-1, "UP", 0, "Up", ""}, + {1, "DOWN", 0, "Down", ""}, {0, NULL, 0, NULL, NULL} }; /* identifiers */ - ot->name= _("Move Texture Slot"); + ot->name= "Move Texture Slot"; ot->idname= "TEXTURE_OT_slot_move"; - ot->description=_("Move texture slots up and down"); + ot->description="Move texture slots up and down"; /* api callbacks */ ot->exec= texture_slot_move; @@ -661,7 +659,7 @@ void TEXTURE_OT_slot_move(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(slot_move), 0, _("Type"), ""); + RNA_def_enum(ot->srna, "type", slot_move, 0, "Type", ""); } @@ -745,9 +743,9 @@ void TEXTURE_OT_envmap_save(wmOperatorType *ot) { PropertyRNA *prop; /* identifiers */ - ot->name= _("Save Environment Map"); + ot->name= "Save Environment Map"; ot->idname= "TEXTURE_OT_envmap_save"; - ot->description=_("Save the current generated Environment map to an image file"); + ot->description="Save the current generated Environment map to an image file"; /* api callbacks */ ot->exec= envmap_save_exec; @@ -792,9 +790,9 @@ static int envmap_clear_poll(bContext *C) void TEXTURE_OT_envmap_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Environment Map"); + ot->name= "Clear Environment Map"; ot->idname= "TEXTURE_OT_envmap_clear"; - ot->description=_("Discard the environment map and free it from memory"); + ot->description="Discard the environment map and free it from memory"; /* api callbacks */ ot->exec= envmap_clear_exec; @@ -821,9 +819,9 @@ static int envmap_clear_all_exec(bContext *C, wmOperator *UNUSED(op)) void TEXTURE_OT_envmap_clear_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear All Environment Maps"); + ot->name= "Clear All Environment Maps"; ot->idname= "TEXTURE_OT_envmap_clear_all"; - ot->description=_("Discard all environment maps in the .blend file and free them from memory"); + ot->description="Discard all environment maps in the .blend file and free them from memory"; /* api callbacks */ ot->exec= envmap_clear_all_exec; @@ -851,9 +849,9 @@ static int copy_material_exec(bContext *C, wmOperator *UNUSED(op)) void MATERIAL_OT_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Material"); + ot->name= "Copy Material"; ot->idname= "MATERIAL_OT_copy"; - ot->description=_("Copy the material settings and nodes"); + ot->description="Copy the material settings and nodes"; /* api callbacks */ ot->exec= copy_material_exec; @@ -879,9 +877,9 @@ static int paste_material_exec(bContext *C, wmOperator *UNUSED(op)) void MATERIAL_OT_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Material"); + ot->name= "Paste Material"; ot->idname= "MATERIAL_OT_paste"; - ot->description=_("Paste the material settings and nodes"); + ot->description="Paste the material settings and nodes"; /* api callbacks */ ot->exec= paste_material_exec; @@ -996,9 +994,9 @@ static int copy_mtex_poll(bContext *C) void TEXTURE_OT_slot_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Texture Slot Settings"); + ot->name= "Copy Texture Slot Settings"; ot->idname= "TEXTURE_OT_slot_copy"; - ot->description=_("Copy the material texture settings and nodes"); + ot->description="Copy the material texture settings and nodes"; /* api callbacks */ ot->exec= copy_mtex_exec; @@ -1041,9 +1039,9 @@ static int paste_mtex_exec(bContext *C, wmOperator *UNUSED(op)) void TEXTURE_OT_slot_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Texture Slot Settings"); + ot->name= "Paste Texture Slot Settings"; ot->idname= "TEXTURE_OT_slot_paste"; - ot->description=_("Copy the texture settings and nodes"); + ot->description="Copy the texture settings and nodes"; /* api callbacks */ ot->exec= paste_mtex_exec; diff --git a/source/blender/editors/render/render_view.c b/source/blender/editors/render/render_view.c index 3fa6c2123a8..9dfcde6ed0d 100644 --- a/source/blender/editors/render/render_view.c +++ b/source/blender/editors/render/render_view.c @@ -36,8 +36,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "BKE_blender.h" @@ -282,8 +280,8 @@ static int render_view_cancel_exec(bContext *C, wmOperator *UNUSED(op)) void RENDER_OT_view_cancel(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cancel Render View"); - ot->description= _("Cancel show render view"); + ot->name= "Cancel Render View"; + ot->description= "Cancel show render view"; ot->idname= "RENDER_OT_view_cancel"; /* api callbacks */ @@ -349,8 +347,8 @@ static int render_view_show_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent void RENDER_OT_view_show(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Show/Hide Render View"); - ot->description= _("Toggle show render view"); + ot->name= "Show/Hide Render View"; + ot->description= "Toggle show render view"; ot->idname= "RENDER_OT_view_show"; /* api callbacks */ diff --git a/source/blender/editors/screen/screen_ops.c b/source/blender/editors/screen/screen_ops.c index 9f6aba9fc7b..5cc42e2b6cf 100644 --- a/source/blender/editors/screen/screen_ops.c +++ b/source/blender/editors/screen/screen_ops.c @@ -40,8 +40,6 @@ #include "BLI_dlrbTree.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_armature_types.h" #include "DNA_lattice_types.h" #include "DNA_object_types.h" @@ -640,8 +638,8 @@ static int actionzone_cancel(bContext *UNUSED(C), wmOperator *op) static void SCREEN_OT_actionzone(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Handle area action zones"); - ot->description= _("Handle area action zones for mouse actions/gestures"); + ot->name= "Handle area action zones"; + ot->description= "Handle area action zones for mouse actions/gestures"; ot->idname= "SCREEN_OT_actionzone"; ot->invoke= actionzone_invoke; @@ -651,7 +649,7 @@ static void SCREEN_OT_actionzone(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING; - RNA_def_int(ot->srna, "modifier", 0, 0, 2, _("modifier"), _("modifier state"), 0, 2); + RNA_def_int(ot->srna, "modifier", 0, 0, 2, "modifier", "modifier state", 0, 2); } /* ************** swap area operator *********************************** */ @@ -763,8 +761,8 @@ static int area_swap_modal(bContext *C, wmOperator *op, wmEvent *event) static void SCREEN_OT_area_swap(wmOperatorType *ot) { - ot->name= _("Swap areas"); - ot->description= _("Swap selected areas screen positions"); + ot->name= "Swap areas"; + ot->description= "Swap selected areas screen positions"; ot->idname= "SCREEN_OT_area_swap"; ot->invoke= area_swap_invoke; @@ -831,8 +829,8 @@ static int area_dupli_invoke(bContext *C, wmOperator *op, wmEvent *event) static void SCREEN_OT_area_dupli(wmOperatorType *ot) { - ot->name= _("Duplicate Area into New Window"); - ot->description= _("Duplicate selected area into new window"); + ot->name= "Duplicate Area into New Window"; + ot->description= "Duplicate selected area into new window"; ot->idname= "SCREEN_OT_area_dupli"; ot->invoke= area_dupli_invoke; @@ -1079,8 +1077,8 @@ static int area_move_modal(bContext *C, wmOperator *op, wmEvent *event) static void SCREEN_OT_area_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move area edges"); - ot->description= _("Move selected area edges"); + ot->name= "Move area edges"; + ot->description= "Move selected area edges"; ot->idname= "SCREEN_OT_area_move"; ot->exec= area_move_exec; @@ -1094,7 +1092,7 @@ static void SCREEN_OT_area_move(wmOperatorType *ot) /* rna */ RNA_def_int(ot->srna, "x", 0, INT_MIN, INT_MAX, "X", "", INT_MIN, INT_MAX); RNA_def_int(ot->srna, "y", 0, INT_MIN, INT_MAX, "Y", "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, _("Delta"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, "Delta", "", INT_MIN, INT_MAX); } /* ************** split area operator *********************************** */ @@ -1493,14 +1491,14 @@ static int area_split_modal(bContext *C, wmOperator *op, wmEvent *event) } static EnumPropertyItem prop_direction_items[] = { -{'h', "HORIZONTAL", 0, N_("Horizontal"), ""}, -{'v', "VERTICAL", 0, N_("Vertical"), ""}, +{'h', "HORIZONTAL", 0, "Horizontal", ""}, +{'v', "VERTICAL", 0, "Vertical", ""}, {0, NULL, 0, NULL, NULL}}; static void SCREEN_OT_area_split(wmOperatorType *ot) { - ot->name = _("Split area"); - ot->description= _("Split selected area into new windows"); + ot->name = "Split area"; + ot->description= "Split selected area into new windows"; ot->idname = "SCREEN_OT_area_split"; ot->exec= area_split_exec; @@ -1512,10 +1510,10 @@ static void SCREEN_OT_area_split(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING; /* rna */ - RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(prop_direction_items), 'h', _("Direction"), ""); - RNA_def_float(ot->srna, "factor", 0.5f, 0.0, 1.0, _("Factor"), "", 0.0, 1.0); - RNA_def_int(ot->srna, "mouse_x", -100, INT_MIN, INT_MAX, _("Mouse X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "mouse_y", -100, INT_MIN, INT_MAX, _("Mouse Y"), "", INT_MIN, INT_MAX); + RNA_def_enum(ot->srna, "direction", prop_direction_items, 'h', "Direction", ""); + RNA_def_float(ot->srna, "factor", 0.5f, 0.0, 1.0, "Factor", "", 0.0, 1.0); + RNA_def_int(ot->srna, "mouse_x", -100, INT_MIN, INT_MAX, "Mouse X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mouse_y", -100, INT_MIN, INT_MAX, "Mouse Y", "", INT_MIN, INT_MAX); } @@ -1716,8 +1714,8 @@ static int region_scale_cancel(bContext *UNUSED(C), wmOperator *op) static void SCREEN_OT_region_scale(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scale Region Size"); - ot->description= _("Scale selected area"); + ot->name= "Scale Region Size"; + ot->description= "Scale selected area"; ot->idname= "SCREEN_OT_region_scale"; ot->invoke= region_scale_invoke; @@ -1753,7 +1751,7 @@ static int frame_offset_exec(bContext *C, wmOperator *op) static void SCREEN_OT_frame_offset(wmOperatorType *ot) { - ot->name = _("Frame Offset"); + ot->name = "Frame Offset"; ot->idname = "SCREEN_OT_frame_offset"; ot->exec= frame_offset_exec; @@ -1762,7 +1760,7 @@ static void SCREEN_OT_frame_offset(wmOperatorType *ot) ot->flag= 0; /* rna */ - RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, _("Delta"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, "Delta", "", INT_MIN, INT_MAX); } @@ -1803,8 +1801,8 @@ static int frame_jump_exec(bContext *C, wmOperator *op) static void SCREEN_OT_frame_jump(wmOperatorType *ot) { - ot->name = _("Jump to Endpoint"); - ot->description= _("Jump to first/last frame in frame range"); + ot->name = "Jump to Endpoint"; + ot->description= "Jump to first/last frame in frame range"; ot->idname = "SCREEN_OT_frame_jump"; ot->exec= frame_jump_exec; @@ -1813,7 +1811,7 @@ static void SCREEN_OT_frame_jump(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* rna */ - RNA_def_boolean(ot->srna, "end", 0, _("Last Frame"), _("Jump to the last frame of the frame range.")); + RNA_def_boolean(ot->srna, "end", 0, "Last Frame", "Jump to the last frame of the frame range."); } @@ -1886,8 +1884,8 @@ static int keyframe_jump_exec(bContext *C, wmOperator *op) static void SCREEN_OT_keyframe_jump(wmOperatorType *ot) { - ot->name = _("Jump to Keyframe"); - ot->description= _("Jump to previous/next keyframe"); + ot->name = "Jump to Keyframe"; + ot->description= "Jump to previous/next keyframe"; ot->idname = "SCREEN_OT_keyframe_jump"; ot->exec= keyframe_jump_exec; @@ -1896,7 +1894,7 @@ static void SCREEN_OT_keyframe_jump(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* rna */ - RNA_def_boolean(ot->srna, "next", 1, _("Next Keyframe"), ""); + RNA_def_boolean(ot->srna, "next", 1, "Next Keyframe", ""); } /* ************** switch screen operator ***************************** */ @@ -1950,15 +1948,15 @@ static int screen_set_exec(bContext *C, wmOperator *op) static void SCREEN_OT_screen_set(wmOperatorType *ot) { - ot->name = _("Set Screen"); - ot->description= _("Cycle through available screens"); + ot->name = "Set Screen"; + ot->description= "Cycle through available screens"; ot->idname = "SCREEN_OT_screen_set"; ot->exec= screen_set_exec; ot->poll= ED_operator_screenactive; /* rna */ - RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, _("Delta"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, "Delta", "", INT_MIN, INT_MAX); } /* ************** screen full-area operator ***************************** */ @@ -1984,8 +1982,8 @@ static int screen_full_area_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_screen_full_area(wmOperatorType *ot) { - ot->name = _("Toggle Full Screen"); - ot->description= _("Toggle display selected area as fullscreen"); + ot->name = "Toggle Full Screen"; + ot->description= "Toggle display selected area as fullscreen"; ot->idname = "SCREEN_OT_screen_full_area"; ot->exec= screen_full_area_exec; @@ -2272,8 +2270,8 @@ static int area_join_modal(bContext *C, wmOperator *op, wmEvent *event) static void SCREEN_OT_area_join(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Join area"); - ot->description= _("Join selected areas into new window"); + ot->name= "Join area"; + ot->description= "Join selected areas into new window"; ot->idname= "SCREEN_OT_area_join"; /* api callbacks */ @@ -2331,8 +2329,8 @@ static int screen_area_options_invoke(bContext *C, wmOperator *op, wmEvent *even static void SCREEN_OT_area_options(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Area Options"); - ot->description= _("Operations for splitting and merging"); + ot->name= "Area Options"; + ot->description= "Operations for splitting and merging"; ot->idname= "SCREEN_OT_area_options"; /* api callbacks */ @@ -2372,8 +2370,8 @@ static int spacedata_cleanup(bContext *C, wmOperator *op) static void SCREEN_OT_spacedata_cleanup(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clean-up space-data"); - ot->description= _("Remove unused settings for invisible editors"); + ot->name= "Clean-up space-data"; + ot->description= "Remove unused settings for invisible editors"; ot->idname= "SCREEN_OT_spacedata_cleanup"; /* api callbacks */ @@ -2397,8 +2395,8 @@ static int repeat_last_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_repeat_last(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Repeat Last"); - ot->description= _("Repeat last action"); + ot->name= "Repeat Last"; + ot->description= "Repeat last action"; ot->idname= "SCREEN_OT_repeat_last"; /* api callbacks */ @@ -2450,8 +2448,8 @@ static int repeat_history_exec(bContext *C, wmOperator *op) static void SCREEN_OT_repeat_history(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Repeat History"); - ot->description= _("Display menu for previous actions performed"); + ot->name= "Repeat History"; + ot->description= "Display menu for previous actions performed"; ot->idname= "SCREEN_OT_repeat_history"; /* api callbacks */ @@ -2460,7 +2458,7 @@ static void SCREEN_OT_repeat_history(wmOperatorType *ot) ot->poll= ED_operator_screenactive; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), "", 0, 1000); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "", 0, 1000); } /* ********************** redo operator ***************************** */ @@ -2478,8 +2476,8 @@ static int redo_last_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *UNUSED static void SCREEN_OT_redo_last(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Redo Last"); - ot->description= _("Display menu for last action performed"); + ot->name= "Redo Last"; + ot->description= "Display menu for last action performed"; ot->idname= "SCREEN_OT_redo_last"; /* api callbacks */ @@ -2581,8 +2579,8 @@ static int region_quadview_exec(bContext *C, wmOperator *op) static void SCREEN_OT_region_quadview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Quad View"); - ot->description= _("Split selected area into camera, front, right & top views"); + ot->name= "Toggle Quad View"; + ot->description= "Split selected area into camera, front, right & top views"; ot->idname= "SCREEN_OT_region_quadview"; /* api callbacks */ @@ -2623,7 +2621,7 @@ static int region_flip_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_region_flip(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Region"); + ot->name= "Flip Region"; ot->idname= "SCREEN_OT_region_flip"; /* api callbacks */ @@ -2672,7 +2670,7 @@ static int header_flip_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_header_flip(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Flip Header Region"); + ot->name= "Flip Header Region"; ot->idname= "SCREEN_OT_header_flip"; /* api callbacks */ @@ -2718,8 +2716,8 @@ static int header_toolbox_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *U static void SCREEN_OT_header_toolbox(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Header Toolbox"); - ot->description=_("Display header region toolbox"); + ot->name= "Header Toolbox"; + ot->description="Display header region toolbox"; ot->idname= "SCREEN_OT_header_toolbox"; /* api callbacks */ @@ -2919,8 +2917,8 @@ static int screen_animation_step(bContext *C, wmOperator *UNUSED(op), wmEvent *e static void SCREEN_OT_animation_step(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Animation Step"); - ot->description= _("Step through animation by position"); + ot->name= "Animation Step"; + ot->description= "Step through animation by position"; ot->idname= "SCREEN_OT_animation_step"; /* api callbacks */ @@ -2976,8 +2974,8 @@ static int screen_animation_play_exec(bContext *C, wmOperator *op) static void SCREEN_OT_animation_play(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Play Animation"); - ot->description= _("Play animation"); + ot->name= "Play Animation"; + ot->description= "Play animation"; ot->idname= "SCREEN_OT_animation_play"; /* api callbacks */ @@ -2985,8 +2983,8 @@ static void SCREEN_OT_animation_play(wmOperatorType *ot) ot->poll= ED_operator_screenactive_norender; - RNA_def_boolean(ot->srna, "reverse", 0, _("Play in Reverse"), _("Animation is played backwards")); - RNA_def_boolean(ot->srna, "sync", 0, _("Sync"), _("Drop frames to maintain framerate")); + RNA_def_boolean(ot->srna, "reverse", 0, "Play in Reverse", "Animation is played backwards"); + RNA_def_boolean(ot->srna, "sync", 0, "Sync", "Drop frames to maintain framerate"); } static int screen_animation_cancel_exec(bContext *C, wmOperator *op) @@ -3016,8 +3014,8 @@ static int screen_animation_cancel_exec(bContext *C, wmOperator *op) static void SCREEN_OT_animation_cancel(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cancel Animation"); - ot->description= _("Cancel animation, returning to the original frame"); + ot->name= "Cancel Animation"; + ot->description= "Cancel animation, returning to the original frame"; ot->idname= "SCREEN_OT_animation_cancel"; /* api callbacks */ @@ -3025,7 +3023,7 @@ static void SCREEN_OT_animation_cancel(wmOperatorType *ot) ot->poll= ED_operator_screenactive; - RNA_def_boolean(ot->srna, "restore_frame", TRUE, _("Restore Frame"), _("Restore the frame when animation was initialized.")); + RNA_def_boolean(ot->srna, "restore_frame", TRUE, "Restore Frame", "Restore the frame when animation was initialized."); } /* ************** border select operator (template) ***************************** */ @@ -3066,7 +3064,7 @@ static int border_select_do(bContext *C, wmOperator *op) static void SCREEN_OT_border_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border select"); + ot->name= "Border select"; ot->idname= "SCREEN_OT_border_select"; /* api callbacks */ @@ -3112,8 +3110,8 @@ static int fullscreen_back_exec(bContext *C, wmOperator *op) static void SCREEN_OT_back_to_previous(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Back to Previous Screen"); - ot->description= _("Revert back to the original screen layout, before fullscreen area overlay"); + ot->name= "Back to Previous Screen"; + ot->description= "Revert back to the original screen layout, before fullscreen area overlay"; ot->idname= "SCREEN_OT_back_to_previous"; /* api callbacks */ @@ -3147,8 +3145,8 @@ static int userpref_show_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *ev static void SCREEN_OT_userpref_show(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Show/Hide User Preferences"); - ot->description= _("Show/hide user preferences"); + ot->name= "Show/Hide User Preferences"; + ot->description= "Show/hide user preferences"; ot->idname= "SCREEN_OT_userpref_show"; /* api callbacks */ @@ -3172,8 +3170,8 @@ static int screen_new_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Screen"); - ot->description= _("Add a new screen"); + ot->name= "New Screen"; + ot->description= "Add a new screen"; ot->idname= "SCREEN_OT_new"; /* api callbacks */ @@ -3198,8 +3196,8 @@ static int screen_delete_exec(bContext *C, wmOperator *UNUSED(op)) static void SCREEN_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Screen"); //was scene - ot->description= _("Delete active screen"); + ot->name= "Delete Screen"; //was scene + ot->description= "Delete active screen"; ot->idname= "SCREEN_OT_delete"; /* api callbacks */ @@ -3245,16 +3243,16 @@ static int scene_new_exec(bContext *C, wmOperator *op) static void SCENE_OT_new(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - {SCE_COPY_NEW, "NEW", 0, N_("New"), N_("Add new scene")}, - {SCE_COPY_EMPTY, "EMPTY", 0, N_("Copy Settings"), N_("Make a copy without any objects")}, - {SCE_COPY_LINK_OB, "LINK_OBJECTS", 0, N_("Link Objects"), N_("Link to the objects from the current scene")}, - {SCE_COPY_LINK_DATA, "LINK_OBJECT_DATA", 0, N_("Link Object Data"), N_("Copy objects linked to data from the current scene")}, - {SCE_COPY_FULL, "FULL_COPY", 0, N_("Full Copy"), N_("Make a full copy of the current scene")}, + {SCE_COPY_NEW, "NEW", 0, "New", "Add new scene"}, + {SCE_COPY_EMPTY, "EMPTY", 0, "Copy Settings", "Make a copy without any objects"}, + {SCE_COPY_LINK_OB, "LINK_OBJECTS", 0, "Link Objects", "Link to the objects from the current scene"}, + {SCE_COPY_LINK_DATA, "LINK_OBJECT_DATA", 0, "Link Object Data", "Copy objects linked to data from the current scene"}, + {SCE_COPY_FULL, "FULL_COPY", 0, "Full Copy", "Make a full copy of the current scene"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("New Scene"); - ot->description= _("Add new scene by type"); + ot->name= "New Scene"; + ot->description= "Add new scene by type"; ot->idname= "SCENE_OT_new"; /* api callbacks */ @@ -3265,7 +3263,7 @@ static void SCENE_OT_new(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), 0, "Type", ""); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, 0, "Type", ""); } /********************* delete scene operator *********************/ @@ -3282,8 +3280,8 @@ static int scene_delete_exec(bContext *C, wmOperator *UNUSED(op)) static void SCENE_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Scene"); - ot->description= _("Delete active scene"); + ot->name= "Delete Scene"; + ot->description= "Delete active scene"; ot->idname= "SCENE_OT_delete"; /* api callbacks */ @@ -3351,15 +3349,15 @@ void ED_operatortypes_screen(void) static void keymap_modal_set(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {KM_MODAL_CANCEL, "CANCEL", 0, N_("Cancel"), ""}, - {KM_MODAL_APPLY, "APPLY", 0, N_("Apply"), ""}, - {KM_MODAL_STEP10, "STEP10", 0, N_("Steps on"), ""}, - {KM_MODAL_STEP10_OFF, "STEP10_OFF", 0, N_("Steps off"), ""}, + {KM_MODAL_CANCEL, "CANCEL", 0, "Cancel", ""}, + {KM_MODAL_APPLY, "APPLY", 0, "Apply", ""}, + {KM_MODAL_STEP10, "STEP10", 0, "Steps on", ""}, + {KM_MODAL_STEP10_OFF, "STEP10_OFF", 0, "Steps off", ""}, {0, NULL, 0, NULL, NULL}}; wmKeyMap *keymap; /* Standard Modal keymap ------------------------------------------------ */ - keymap= WM_modalkeymap_add(keyconf, "Standard Modal Map", RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "Standard Modal Map", modal_items); WM_modalkeymap_add_item(keymap, ESCKEY, KM_PRESS, KM_ANY, 0, KM_MODAL_CANCEL); WM_modalkeymap_add_item(keymap, LEFTMOUSE, KM_ANY, KM_ANY, 0, KM_MODAL_APPLY); diff --git a/source/blender/editors/screen/screendump.c b/source/blender/editors/screen/screendump.c index d9b3961c8b8..3010adafe20 100644 --- a/source/blender/editors/screen/screendump.c +++ b/source/blender/editors/screen/screendump.c @@ -38,8 +38,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "IMB_imbuf_types.h" #include "IMB_imbuf.h" @@ -205,7 +203,7 @@ void SCREEN_OT_screenshot(wmOperatorType *ot) { PropertyRNA *prop; - ot->name= _("Save Screenshot"); /* weak: opname starting with 'save' makes filewindow give save-over */ + ot->name= "Save Screenshot"; /* weak: opname starting with 'save' makes filewindow give save-over */ ot->idname= "SCREEN_OT_screenshot"; ot->invoke= screenshot_invoke; @@ -216,7 +214,7 @@ void SCREEN_OT_screenshot(wmOperatorType *ot) ot->flag= 0; WM_operator_properties_filesel(ot, FOLDERFILE|IMAGEFILE, FILE_SPECIAL, FILE_SAVE, WM_FILESEL_FILEPATH); - prop= RNA_def_boolean(ot->srna, "full", 1, _("Full Screen"), ""); + prop= RNA_def_boolean(ot->srna, "full", 1, "Full Screen", ""); RNA_def_property_flag(prop, PROP_HIDDEN); /* hide because once the file sel is displayed, the option no longer does anything */ } @@ -377,7 +375,7 @@ static int screencast_exec(bContext *C, wmOperator *op) void SCREEN_OT_screencast(wmOperatorType *ot) { - ot->name= _("Make Screencast"); + ot->name= "Make Screencast"; ot->idname= "SCREEN_OT_screencast"; ot->invoke= WM_operator_confirm; @@ -386,8 +384,8 @@ void SCREEN_OT_screencast(wmOperatorType *ot) ot->flag= 0; - RNA_def_property(ot->srna, _("filepath"), PROP_STRING, PROP_FILEPATH); - RNA_def_boolean(ot->srna, "full", 1, _("Full Screen"), ""); + RNA_def_property(ot->srna, "filepath", PROP_STRING, PROP_FILEPATH); + RNA_def_boolean(ot->srna, "full", 1, "Full Screen", ""); } diff --git a/source/blender/editors/sculpt_paint/CMakeLists.txt b/source/blender/editors/sculpt_paint/CMakeLists.txt index 4438bb4f035..94e08a020f6 100644 --- a/source/blender/editors/sculpt_paint/CMakeLists.txt +++ b/source/blender/editors/sculpt_paint/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/sculpt_paint/SConscript b/source/blender/editors/sculpt_paint/SConscript index d581c091db1..b3927fcee68 100644 --- a/source/blender/editors/sculpt_paint/SConscript +++ b/source/blender/editors/sculpt_paint/SConscript @@ -5,7 +5,7 @@ sources = env.Glob('*.c') defs = [] -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../render/extern/include' incs += ' ../../gpu ../../makesrna ../../blenloader' diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c index bd4f7b79660..79a3251cdf1 100644 --- a/source/blender/editors/sculpt_paint/paint_image.c +++ b/source/blender/editors/sculpt_paint/paint_image.c @@ -52,8 +52,6 @@ #include "BLI_threads.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "PIL_time.h" #include "IMB_imbuf.h" @@ -4977,7 +4975,7 @@ static int paint_cancel(bContext *C, wmOperator *op) void PAINT_OT_image_paint(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Image Paint"); + ot->name= "Image Paint"; ot->idname= "PAINT_OT_image_paint"; /* api callbacks */ @@ -4991,7 +4989,7 @@ void PAINT_OT_image_paint(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; /* properties */ - RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, _("Stroke"), ""); + RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, "Stroke", ""); } static int get_imapaint_zoom(bContext *C, float *zoomx, float *zoomy) @@ -5166,7 +5164,7 @@ static int grab_clone_cancel(bContext *UNUSED(C), wmOperator *op) void PAINT_OT_grab_clone(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Grab Clone"); + ot->name= "Grab Clone"; ot->idname= "PAINT_OT_grab_clone"; /* api callbacks */ @@ -5180,7 +5178,7 @@ void PAINT_OT_grab_clone(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; /* properties */ - RNA_def_float_vector(ot->srna, "delta", 2, NULL, -FLT_MAX, FLT_MAX, _("Delta"), _("Delta offset of clone image in 0.0..1.0 coordinates."), -1.0f, 1.0f); + RNA_def_float_vector(ot->srna, "delta", 2, NULL, -FLT_MAX, FLT_MAX, "Delta", "Delta offset of clone image in 0.0..1.0 coordinates.", -1.0f, 1.0f); } /******************** sample color operator ********************/ @@ -5248,7 +5246,7 @@ static int image_paint_sample_color_poll(bContext *C) void PAINT_OT_sample_color(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sample Color"); + ot->name= "Sample Color"; ot->idname= "PAINT_OT_sample_color"; /* api callbacks */ @@ -5261,7 +5259,7 @@ void PAINT_OT_sample_color(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int_vector(ot->srna, "location", 2, NULL, 0, INT_MAX, _("Location"), _("Cursor location in region coordinates."), 0, 16384); + RNA_def_int_vector(ot->srna, "location", 2, NULL, 0, INT_MAX, "Location", "Cursor location in region coordinates.", 0, 16384); } /******************** set clone cursor operator ********************/ @@ -5299,7 +5297,7 @@ static int set_clone_cursor_invoke(bContext *C, wmOperator *op, wmEvent *event) void PAINT_OT_clone_cursor_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Clone Cursor"); + ot->name= "Set Clone Cursor"; ot->idname= "PAINT_OT_clone_cursor_set"; /* api callbacks */ @@ -5311,7 +5309,7 @@ void PAINT_OT_clone_cursor_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_vector(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, _("Location"), _("Cursor location in world space coordinates."), -10000.0f, 10000.0f); + RNA_def_float_vector(ot->srna, "location", 3, NULL, -FLT_MAX, FLT_MAX, "Location", "Cursor location in world space coordinates.", -10000.0f, 10000.0f); } /******************** texture paint toggle operator ********************/ @@ -5381,7 +5379,7 @@ static int texture_paint_toggle_exec(bContext *C, wmOperator *op) void PAINT_OT_texture_paint_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Texture Paint Toggle"); + ot->name= "Texture Paint Toggle"; ot->idname= "PAINT_OT_texture_paint_toggle"; /* api callbacks */ @@ -5517,9 +5515,9 @@ void PAINT_OT_project_image(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Project Image"); + ot->name= "Project Image"; ot->idname= "PAINT_OT_project_image"; - ot->description= _("Project an edited render from the active camera back onto the object"); + ot->description= "Project an edited render from the active camera back onto the object"; /* api callbacks */ ot->invoke= WM_enum_search_invoke; @@ -5528,7 +5526,7 @@ void PAINT_OT_project_image(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - prop= RNA_def_enum(ot->srna, "image", DummyRNA_NULL_items, 0, _("Image"), ""); + prop= RNA_def_enum(ot->srna, "image", DummyRNA_NULL_items, 0, "Image", ""); RNA_def_enum_funcs(prop, RNA_image_itemf); ot->prop= prop; } @@ -5596,9 +5594,9 @@ static int texture_paint_image_from_view_exec(bContext *C, wmOperator *op) void PAINT_OT_image_from_view(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Image from View"); + ot->name= "Image from View"; ot->idname= "PAINT_OT_image_from_view"; - ot->description= _("Make an image from the current 3D view for re-projection"); + ot->description= "Make an image from the current 3D view for re-projection"; /* api callbacks */ ot->exec= texture_paint_image_from_view_exec; @@ -5607,5 +5605,5 @@ void PAINT_OT_image_from_view(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER; - RNA_def_string_file_name(ot->srna, "filepath", "", FILE_MAX, _("File Path"), _("Name of the file")); + RNA_def_string_file_name(ot->srna, "filepath", "", FILE_MAX, "File Path", "Name of the file"); } diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c index f53bc4208e0..69af50415cc 100644 --- a/source/blender/editors/sculpt_paint/paint_ops.c +++ b/source/blender/editors/sculpt_paint/paint_ops.c @@ -29,8 +29,6 @@ #include "BLI_string.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_object_types.h" #include "DNA_scene_types.h" #include "DNA_brush_types.h" @@ -78,8 +76,8 @@ static int brush_add_exec(bContext *C, wmOperator *UNUSED(op)) static void BRUSH_OT_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Brush"); - ot->description= _("Add brush by mode type"); + ot->name= "Add Brush"; + ot->description= "Add brush by mode type"; ot->idname= "BRUSH_OT_add"; /* api callbacks */ @@ -133,8 +131,8 @@ static int brush_scale_size_exec(bContext *C, wmOperator *op) static void BRUSH_OT_scale_size(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scale Sculpt/Paint Brush Size"); - ot->description= _("Change brush size by a scalar"); + ot->name= "Scale Sculpt/Paint Brush Size"; + ot->description= "Change brush size by a scalar"; ot->idname= "BRUSH_OT_scale_size"; /* api callbacks */ @@ -143,7 +141,7 @@ static void BRUSH_OT_scale_size(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_float(ot->srna, "scalar", 1, 0, 2, _("Scalar"), _("Factor to scale brush size by"), 0, 2); + RNA_def_float(ot->srna, "scalar", 1, 0, 2, "Scalar", "Factor to scale brush size by", 0, 2); } static int vertex_color_set_exec(bContext *C, wmOperator *UNUSED(op)) @@ -160,7 +158,7 @@ static int vertex_color_set_exec(bContext *C, wmOperator *UNUSED(op)) static void PAINT_OT_vertex_color_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Vertex Colors"); + ot->name= "Set Vertex Colors"; ot->idname= "PAINT_OT_vertex_color_set"; /* api callbacks */ @@ -189,8 +187,8 @@ static int brush_reset_exec(bContext *C, wmOperator *UNUSED(op)) static void BRUSH_OT_reset(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset Brush"); - ot->description= _("Return brush to defaults based on current tool"); + ot->name= "Reset Brush"; + ot->description= "Return brush to defaults based on current tool"; ot->idname= "BRUSH_OT_reset"; /* api callbacks */ @@ -252,8 +250,8 @@ static int brush_sculpt_tool_set_exec(bContext *C, wmOperator *op) static void BRUSH_OT_sculpt_tool_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sculpt Tool Set"); - ot->description= _("Set the sculpt tool"); + ot->name= "Sculpt Tool Set"; + ot->description= "Set the sculpt tool"; ot->idname= "BRUSH_OT_sculpt_tool_set"; /* api callbacks */ @@ -263,7 +261,7 @@ static void BRUSH_OT_sculpt_tool_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "tool", brush_sculpt_tool_items, 0, _("Tool"), ""); + ot->prop= RNA_def_enum(ot->srna, "tool", brush_sculpt_tool_items, 0, "Tool", ""); } static int brush_vertex_tool_set_exec(bContext *C, wmOperator *op) @@ -277,8 +275,8 @@ static int brush_vertex_tool_set_exec(bContext *C, wmOperator *op) static void BRUSH_OT_vertex_tool_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Paint Tool Set"); - ot->description= _("Set the vertex paint tool"); + ot->name= "Vertex Paint Tool Set"; + ot->description= "Set the vertex paint tool"; ot->idname= "BRUSH_OT_vertex_tool_set"; /* api callbacks */ @@ -288,7 +286,7 @@ static void BRUSH_OT_vertex_tool_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "tool", brush_vertex_tool_items, 0, _("Tool"), ""); + ot->prop= RNA_def_enum(ot->srna, "tool", brush_vertex_tool_items, 0, "Tool", ""); } static int brush_weight_tool_set_exec(bContext *C, wmOperator *op) @@ -302,8 +300,8 @@ static int brush_weight_tool_set_exec(bContext *C, wmOperator *op) static void BRUSH_OT_weight_tool_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weight Paint Tool Set"); - ot->description= _("Set the weight paint tool"); + ot->name= "Weight Paint Tool Set"; + ot->description= "Set the weight paint tool"; ot->idname= "BRUSH_OT_weight_tool_set"; /* api callbacks */ @@ -313,7 +311,7 @@ static void BRUSH_OT_weight_tool_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "tool", brush_vertex_tool_items, 0, _("Tool"), ""); + ot->prop= RNA_def_enum(ot->srna, "tool", brush_vertex_tool_items, 0, "Tool", ""); } static int brush_image_tool_set_exec(bContext *C, wmOperator *op) @@ -327,8 +325,8 @@ static int brush_image_tool_set_exec(bContext *C, wmOperator *op) static void BRUSH_OT_image_tool_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Image Paint Tool Set"); - ot->description= _("Set the image tool"); + ot->name= "Image Paint Tool Set"; + ot->description= "Set the image tool"; ot->idname= "BRUSH_OT_image_tool_set"; /* api callbacks */ diff --git a/source/blender/editors/sculpt_paint/paint_utils.c b/source/blender/editors/sculpt_paint/paint_utils.c index a1855f254ef..09f5c32bea0 100644 --- a/source/blender/editors/sculpt_paint/paint_utils.c +++ b/source/blender/editors/sculpt_paint/paint_utils.c @@ -15,8 +15,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_brush.h" #include "BKE_context.h" #include "BKE_DerivedMesh.h" @@ -273,16 +271,16 @@ static int brush_curve_preset_poll(bContext *C) void BRUSH_OT_curve_preset(wmOperatorType *ot) { static EnumPropertyItem prop_shape_items[] = { - {CURVE_PRESET_SHARP, "SHARP", 0, N_("Sharp"), ""}, - {CURVE_PRESET_SMOOTH, "SMOOTH", 0, N_("Smooth"), ""}, - {CURVE_PRESET_MAX, "MAX", 0, N_("Max"), ""}, - {CURVE_PRESET_LINE, "LINE", 0, N_("Line"), ""}, - {CURVE_PRESET_ROUND, "ROUND", 0, N_("Round"), ""}, - {CURVE_PRESET_ROOT, "ROOT", 0, N_("Root"), ""}, + {CURVE_PRESET_SHARP, "SHARP", 0, "Sharp", ""}, + {CURVE_PRESET_SMOOTH, "SMOOTH", 0, "Smooth", ""}, + {CURVE_PRESET_MAX, "MAX", 0, "Max", ""}, + {CURVE_PRESET_LINE, "LINE", 0, "Line", ""}, + {CURVE_PRESET_ROUND, "ROUND", 0, "Round", ""}, + {CURVE_PRESET_ROOT, "ROOT", 0, "Root", ""}, {0, NULL, 0, NULL, NULL}}; - ot->name= _("Preset"); - ot->description= _("Set brush shape"); + ot->name= "Preset"; + ot->description= "Set brush shape"; ot->idname= "BRUSH_OT_curve_preset"; ot->exec= brush_curve_preset_exec; @@ -290,7 +288,7 @@ void BRUSH_OT_curve_preset(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "shape", RNA_enum_items_gettexted(prop_shape_items), CURVE_PRESET_SMOOTH, _("Mode"), ""); + RNA_def_enum(ot->srna, "shape", prop_shape_items, CURVE_PRESET_SMOOTH, "Mode", ""); } @@ -304,8 +302,8 @@ static int paint_select_linked_exec(bContext *C, wmOperator *UNUSED(op)) void PAINT_OT_face_select_linked(wmOperatorType *ot) { - ot->name= _("Select Linked"); - ot->description= _("Select linked faces"); + ot->name= "Select Linked"; + ot->description= "Select linked faces"; ot->idname= "PAINT_OT_face_select_linked"; ot->exec= paint_select_linked_exec; @@ -324,8 +322,8 @@ static int paint_select_linked_pick_invoke(bContext *C, wmOperator *op, wmEvent void PAINT_OT_face_select_linked_pick(wmOperatorType *ot) { - ot->name= _("Select Linked Pick"); - ot->description= _("Select linked faces"); + ot->name= "Select Linked Pick"; + ot->description= "Select linked faces"; ot->idname= "PAINT_OT_face_select_linked_pick"; ot->invoke= paint_select_linked_pick_invoke; @@ -333,7 +331,7 @@ void PAINT_OT_face_select_linked_pick(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend the existing selection")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend the existing selection"); } @@ -348,8 +346,8 @@ static int face_select_all_exec(bContext *C, wmOperator *op) void PAINT_OT_face_select_all(wmOperatorType *ot) { - ot->name= _("Face Selection"); - ot->description= _("Change selection for all faces"); + ot->name= "Face Selection"; + ot->description= "Change selection for all faces"; ot->idname= "PAINT_OT_face_select_all"; ot->exec= face_select_all_exec; @@ -371,8 +369,8 @@ static int face_select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void PAINT_OT_face_select_inverse(wmOperatorType *ot) { - ot->name= _("Face Select Invert"); - ot->description= _("Invert selection of faces"); + ot->name= "Face Select Invert"; + ot->description= "Invert selection of faces"; ot->idname= "PAINT_OT_face_select_inverse"; ot->exec= face_select_inverse_exec; @@ -392,8 +390,8 @@ static int face_select_hide_exec(bContext *C, wmOperator *op) void PAINT_OT_face_select_hide(wmOperatorType *ot) { - ot->name= _("Face Select Hide"); - ot->description= _("Hide selected faces"); + ot->name= "Face Select Hide"; + ot->description= "Hide selected faces"; ot->idname= "PAINT_OT_face_select_hide"; ot->exec= face_select_hide_exec; @@ -401,7 +399,7 @@ void PAINT_OT_face_select_hide(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected objects.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected objects."); } static int face_select_reveal_exec(bContext *C, wmOperator *UNUSED(op)) @@ -414,8 +412,8 @@ static int face_select_reveal_exec(bContext *C, wmOperator *UNUSED(op)) void PAINT_OT_face_select_reveal(wmOperatorType *ot) { - ot->name= _("Face Select Reveal"); - ot->description= _("Reveal hidden faces"); + ot->name= "Face Select Reveal"; + ot->description= "Reveal hidden faces"; ot->idname= "PAINT_OT_face_select_reveal"; ot->exec= face_select_reveal_exec; @@ -423,5 +421,5 @@ void PAINT_OT_face_select_reveal(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected objects.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected objects."); } diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c index 8f4458ff72a..3da19ba7346 100644 --- a/source/blender/editors/sculpt_paint/paint_vertex.c +++ b/source/blender/editors/sculpt_paint/paint_vertex.c @@ -48,8 +48,6 @@ #include "BLI_utildefines.h" #include "BLI_ghash.h" -#include "BLF_api.h" - #include "IMB_imbuf.h" #include "IMB_imbuf_types.h" @@ -948,7 +946,7 @@ static int weight_sample_invoke(bContext *C, wmOperator *op, wmEvent *event) void PAINT_OT_weight_sample(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weight Paint Sample Weight"); + ot->name= "Weight Paint Sample Weight"; ot->idname= "PAINT_OT_weight_sample"; /* api callbacks */ @@ -1046,7 +1044,7 @@ void PAINT_OT_weight_sample_group(wmOperatorType *ot) PropertyRNA *prop= NULL; /* identifiers */ - ot->name= _("Weight Paint Sample Group"); + ot->name= "Weight Paint Sample Group"; ot->idname= "PAINT_OT_weight_sample_group"; /* api callbacks */ @@ -1058,7 +1056,7 @@ void PAINT_OT_weight_sample_group(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* keyingset to use (dynamic enum) */ - prop= RNA_def_enum(ot->srna, "group", DummyRNA_DEFAULT_items, 0, _("Keying Set"), _("The Keying Set to use")); + prop= RNA_def_enum(ot->srna, "group", DummyRNA_DEFAULT_items, 0, "Keying Set", "The Keying Set to use"); RNA_def_enum_funcs(prop, weight_paint_sample_enum_itemf); ot->prop= prop; } @@ -1205,7 +1203,7 @@ void PAINT_OT_weight_paint_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weight Paint Mode"); + ot->name= "Weight Paint Mode"; ot->idname= "PAINT_OT_weight_paint_toggle"; /* api callbacks */ @@ -1613,7 +1611,7 @@ void PAINT_OT_weight_paint(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weight Paint"); + ot->name= "Weight Paint"; ot->idname= "PAINT_OT_weight_paint"; /* api callbacks */ @@ -1626,7 +1624,7 @@ void PAINT_OT_weight_paint(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; - RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, _("Stroke"), ""); + RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, "Stroke", ""); } static int weight_paint_set_exec(bContext *C, wmOperator *UNUSED(op)) @@ -1642,7 +1640,7 @@ static int weight_paint_set_exec(bContext *C, wmOperator *UNUSED(op)) void PAINT_OT_weight_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Weight"); + ot->name= "Set Weight"; ot->idname= "PAINT_OT_weight_set"; /* api callbacks */ @@ -1704,7 +1702,7 @@ void PAINT_OT_vertex_paint_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Paint Mode"); + ot->name= "Vertex Paint Mode"; ot->idname= "PAINT_OT_vertex_paint_toggle"; /* api callbacks */ @@ -1912,7 +1910,7 @@ static int vpaint_cancel(bContext *C, wmOperator *op) void PAINT_OT_vertex_paint(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Vertex Paint"); + ot->name= "Vertex Paint"; ot->idname= "PAINT_OT_vertex_paint"; /* api callbacks */ @@ -1925,7 +1923,7 @@ void PAINT_OT_vertex_paint(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; - RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, _("Stroke"), ""); + RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, "Stroke", ""); } /* ********************** weight from bones operator ******************* */ @@ -1956,12 +1954,12 @@ static int weight_from_bones_exec(bContext *C, wmOperator *op) void PAINT_OT_weight_from_bones(wmOperatorType *ot) { static EnumPropertyItem type_items[]= { - {ARM_GROUPS_AUTO, "AUTOMATIC", 0, N_("Automatic"), N_("Automatic weights froms bones")}, - {ARM_GROUPS_ENVELOPE, "ENVELOPES", 0, N_("From Envelopes"), N_("Weights from envelopes with user defined radius")}, + {ARM_GROUPS_AUTO, "AUTOMATIC", 0, "Automatic", "Automatic weights froms bones"}, + {ARM_GROUPS_ENVELOPE, "ENVELOPES", 0, "From Envelopes", "Weights from envelopes with user defined radius"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Weight from Bones"); + ot->name= "Weight from Bones"; ot->idname= "PAINT_OT_weight_from_bones"; /* api callbacks */ @@ -1973,6 +1971,6 @@ void PAINT_OT_weight_from_bones(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(type_items), 0, _("Type"), _("Method to use for assigning weights.")); + ot->prop= RNA_def_enum(ot->srna, "type", type_items, 0, "Type", "Method to use for assigning weights."); } diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 170924c400d..92bc60e8b77 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -47,8 +47,6 @@ #include "BLI_editVert.h" #include "BLI_rand.h" -#include "BLF_api.h" - #include "DNA_meshdata_types.h" #include "DNA_node_types.h" #include "DNA_object_types.h" @@ -3540,14 +3538,14 @@ static int sculpt_brush_stroke_cancel(bContext *C, wmOperator *op) static void SCULPT_OT_brush_stroke(wmOperatorType *ot) { static EnumPropertyItem stroke_mode_items[] = { - {BRUSH_STROKE_NORMAL, "NORMAL", 0, N_("Normal"), N_("Apply brush normally")}, - {BRUSH_STROKE_INVERT, "INVERT", 0, N_("Invert"), N_("Invert action of brush for duration of stroke")}, - {BRUSH_STROKE_SMOOTH, "SMOOTH", 0, N_("Smooth"), N_("Switch brush to smooth mode for duration of stroke")}, + {BRUSH_STROKE_NORMAL, "NORMAL", 0, "Normal", "Apply brush normally"}, + {BRUSH_STROKE_INVERT, "INVERT", 0, "Invert", "Invert action of brush for duration of stroke"}, + {BRUSH_STROKE_SMOOTH, "SMOOTH", 0, "Smooth", "Switch brush to smooth mode for duration of stroke"}, {0} }; /* identifiers */ - ot->name= _("Sculpt Mode"); + ot->name= "Sculpt Mode"; ot->idname= "SCULPT_OT_brush_stroke"; /* api callbacks */ @@ -3563,15 +3561,15 @@ static void SCULPT_OT_brush_stroke(wmOperatorType *ot) /* properties */ RNA_def_collection_runtime(ot->srna, "stroke", &RNA_OperatorStrokeElement, - _("Stroke"), ""); + "Stroke", ""); - RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(stroke_mode_items), BRUSH_STROKE_NORMAL, - _("Sculpt Stroke Mode"), - _("Action taken when a sculpt stroke is made")); + RNA_def_enum(ot->srna, "mode", stroke_mode_items, BRUSH_STROKE_NORMAL, + "Sculpt Stroke Mode", + "Action taken when a sculpt stroke is made"); RNA_def_boolean(ot->srna, "ignore_background_click", 0, - _("Ignore Background Click"), - _("Clicks on the background do not start the stroke")); + "Ignore Background Click", + "Clicks on the background do not start the stroke"); } /**** Reset the copy of the mesh that is being sculpted on (currently just for the layer brush) ****/ @@ -3592,7 +3590,7 @@ static int sculpt_set_persistent_base(bContext *C, wmOperator *UNUSED(op)) static void SCULPT_OT_set_persistent_base(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Persistent Base"); + ot->name= "Set Persistent Base"; ot->idname= "SCULPT_OT_set_persistent_base"; /* api callbacks */ @@ -3670,7 +3668,7 @@ static int sculpt_toggle_mode(bContext *C, wmOperator *UNUSED(op)) static void SCULPT_OT_sculptmode_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sculpt Mode"); + ot->name= "Sculpt Mode"; ot->idname= "SCULPT_OT_sculptmode_toggle"; /* api callbacks */ diff --git a/source/blender/editors/sound/CMakeLists.txt b/source/blender/editors/sound/CMakeLists.txt index a72efadc5df..11da4165ec8 100644 --- a/source/blender/editors/sound/CMakeLists.txt +++ b/source/blender/editors/sound/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/sound/SConscript b/source/blender/editors/sound/SConscript index e69b27763fd..e17bccdadd9 100644 --- a/source/blender/editors/sound/SConscript +++ b/source/blender/editors/sound/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc' incs += ' ../../makesrna ../../blenloader' incs += ' #/intern/audaspace/intern' diff --git a/source/blender/editors/sound/sound_ops.c b/source/blender/editors/sound/sound_ops.c index 85ae788bcdf..19cae6aa67d 100644 --- a/source/blender/editors/sound/sound_ops.c +++ b/source/blender/editors/sound/sound_ops.c @@ -41,8 +41,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_packedFile_types.h" #include "DNA_scene_types.h" @@ -180,8 +178,8 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *event) void SOUND_OT_open(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Open Sound"); - ot->description= _("Load a sound file"); + ot->name= "Open Sound"; + ot->description= "Load a sound file"; ot->idname= "SOUND_OT_open"; /* api callbacks */ @@ -194,15 +192,15 @@ void SOUND_OT_open(wmOperatorType *ot) /* properties */ WM_operator_properties_filesel(ot, FOLDERFILE|SOUNDFILE|MOVIEFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH | WM_FILESEL_RELPATH); - RNA_def_boolean(ot->srna, "cache", FALSE, _("Cache"), _("Cache the sound in memory.")); - RNA_def_boolean(ot->srna, "mono", FALSE, _("Mono"), _("Mixdown the sound to mono.")); + RNA_def_boolean(ot->srna, "cache", FALSE, "Cache", "Cache the sound in memory."); + RNA_def_boolean(ot->srna, "mono", FALSE, "Mono", "Mixdown the sound to mono."); } void SOUND_OT_open_mono(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Open Sound Mono"); - ot->description= _("Load a sound file as mono"); + ot->name= "Open Sound Mono"; + ot->description= "Load a sound file as mono"; ot->idname= "SOUND_OT_open_mono"; /* api callbacks */ @@ -215,8 +213,8 @@ void SOUND_OT_open_mono(wmOperatorType *ot) /* properties */ WM_operator_properties_filesel(ot, FOLDERFILE|SOUNDFILE|MOVIEFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH | WM_FILESEL_RELPATH); - RNA_def_boolean(ot->srna, "cache", FALSE, _("Cache"), _("Cache the sound in memory.")); - RNA_def_boolean(ot->srna, "mono", TRUE, _("Mono"), _("Mixdown the sound to mono.")); + RNA_def_boolean(ot->srna, "cache", FALSE, "Cache", "Cache the sound in memory."); + RNA_def_boolean(ot->srna, "mono", TRUE, "Mono", "Mixdown the sound to mono."); } /******************** mixdown operator ********************/ @@ -671,8 +669,8 @@ void SOUND_OT_update_animation_flags(wmOperatorType *ot) */ /* identifiers */ - ot->name= _("Update animation"); - ot->description= _("Update animation flags"); + ot->name= "Update animation"; + ot->description= "Update animation flags"; ot->idname= "SOUND_OT_update_animation_flags"; /* api callbacks */ @@ -708,8 +706,8 @@ static int bake_animation_exec(bContext *C, wmOperator *UNUSED(op)) void SOUND_OT_bake_animation(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Update animation cache"); - ot->description= _("Updates the audio animation cache so that it's up to date"); + ot->name= "Update animation cache"; + ot->description= "Updates the audio animation cache so that it's up to date"; ot->idname= "SOUND_OT_bake_animation"; /* api callbacks */ diff --git a/source/blender/editors/space_action/CMakeLists.txt b/source/blender/editors/space_action/CMakeLists.txt index c2e9deca9ac..edebaa8273a 100644 --- a/source/blender/editors/space_action/CMakeLists.txt +++ b/source/blender/editors/space_action/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/space_action/SConscript b/source/blender/editors/space_action/SConscript index e4cec8e70ef..0fee8ff68ab 100644 --- a/source/blender/editors/space_action/SConscript +++ b/source/blender/editors/space_action/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include ../../blenloader' env.BlenderLib ( 'bf_editors_space_action', sources, Split(incs), [], libtype=['core'], priority=[40] ) diff --git a/source/blender/editors/space_action/action_edit.c b/source/blender/editors/space_action/action_edit.c index 5ba061f1b80..b5dfdcdc668 100644 --- a/source/blender/editors/space_action/action_edit.c +++ b/source/blender/editors/space_action/action_edit.c @@ -40,8 +40,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_gpencil_types.h" #include "DNA_object_types.h" @@ -126,9 +124,9 @@ static int act_new_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_new (wmOperatorType *ot) { /* identifiers */ - ot->name= _("New Action"); + ot->name= "New Action"; ot->idname= "ACTION_OT_new"; - ot->description= _("Create new action"); + ot->description= "Create new action"; /* api callbacks */ ot->exec= act_new_exec; @@ -209,9 +207,9 @@ static int act_markers_make_local_exec (bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_markers_make_local (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Markers Local"); + ot->name= "Make Markers Local"; ot->idname= "ACTION_OT_markers_make_local"; - ot->description= _("Move selected scene markers to the active Action as local 'pose' markers"); + ot->description= "Move selected scene markers to the active Action as local 'pose' markers"; /* callbacks */ ot->exec = act_markers_make_local_exec; @@ -311,9 +309,9 @@ static int actkeys_previewrange_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_previewrange_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Auto-Set Preview Range"); + ot->name= "Auto-Set Preview Range"; ot->idname= "ACTION_OT_previewrange_set"; - ot->description= _("Set Preview Range based on extents of selected Keyframes"); + ot->description= "Set Preview Range based on extents of selected Keyframes"; /* api callbacks */ ot->exec= actkeys_previewrange_exec; @@ -373,9 +371,9 @@ static int actkeys_viewsel_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_view_all (wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "ACTION_OT_view_all"; - ot->description= _("Reset viewable area to show full keyframe range"); + ot->description= "Reset viewable area to show full keyframe range"; /* api callbacks */ ot->exec= actkeys_viewall_exec; @@ -388,9 +386,9 @@ void ACTION_OT_view_all (wmOperatorType *ot) void ACTION_OT_view_selected (wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Selected"); + ot->name= "View Selected"; ot->idname= "ACTION_OT_view_selected"; - ot->description= _("Reset viewable area to show selected keyframes range"); + ot->description= "Reset viewable area to show selected keyframes range"; /* api callbacks */ ot->exec= actkeys_viewsel_exec; @@ -474,9 +472,9 @@ static int actkeys_copy_exec(bContext *C, wmOperator *op) void ACTION_OT_copy (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Keyframes"); + ot->name= "Copy Keyframes"; ot->idname= "ACTION_OT_copy"; - ot->description= _("Copy selected keyframes to the copy/paste buffer"); + ot->description= "Copy selected keyframes to the copy/paste buffer"; /* api callbacks */ // ot->invoke= WM_operator_props_popup; // better wait for graph redo panel @@ -525,9 +523,9 @@ static int actkeys_paste_exec(bContext *C, wmOperator *op) void ACTION_OT_paste (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Keyframes"); + ot->name= "Paste Keyframes"; ot->idname= "ACTION_OT_paste"; - ot->description= _("Paste keyframes from copy/paste buffer for the selected channels, starting on the current frame"); + ot->description= "Paste keyframes from copy/paste buffer for the selected channels, starting on the current frame"; /* api callbacks */ ot->exec= actkeys_paste_exec; @@ -536,17 +534,17 @@ void ACTION_OT_paste (wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "offset", keyframe_paste_offset_items, KEYFRAME_PASTE_OFFSET_CFRA_START, _("Offset"), _("Paste time offset of keys")); - RNA_def_enum(ot->srna, "merge", keyframe_paste_merge_items, KEYFRAME_PASTE_MERGE_MIX, _("Type"), _("Method of merking pasted keys and existing")); + RNA_def_enum(ot->srna, "offset", keyframe_paste_offset_items, KEYFRAME_PASTE_OFFSET_CFRA_START, "Offset", "Paste time offset of keys"); + RNA_def_enum(ot->srna, "merge", keyframe_paste_merge_items, KEYFRAME_PASTE_MERGE_MIX, "Type", "Method of merking pasted keys and existing"); } /* ******************** Insert Keyframes Operator ************************* */ /* defines for insert keyframes tool */ static EnumPropertyItem prop_actkeys_insertkey_types[] = { - {1, "ALL", 0, N_("All Channels"), ""}, - {2, "SEL", 0, N_("Only Selected Channels"), ""}, - {3, "GROUP", 0, N_("In Active Group"), ""}, // xxx not in all cases + {1, "ALL", 0, "All Channels", ""}, + {2, "SEL", 0, "Only Selected Channels", ""}, + {3, "GROUP", 0, "In Active Group", ""}, // xxx not in all cases {0, NULL, 0, NULL, NULL} }; @@ -624,9 +622,9 @@ static int actkeys_insertkey_exec(bContext *C, wmOperator *op) void ACTION_OT_keyframe_insert (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert Keyframes"); + ot->name= "Insert Keyframes"; ot->idname= "ACTION_OT_keyframe_insert"; - ot->description= _("Insert keyframes for the specified channels"); + ot->description= "Insert keyframes for the specified channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -637,7 +635,7 @@ void ACTION_OT_keyframe_insert (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_actkeys_insertkey_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_actkeys_insertkey_types, 0, "Type", ""); } /* ******************** Duplicate Keyframes Operator ************************* */ @@ -699,9 +697,9 @@ static int actkeys_duplicate_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED void ACTION_OT_duplicate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Keyframes"); + ot->name= "Duplicate Keyframes"; ot->idname= "ACTION_OT_duplicate"; - ot->description= _("Make a copy of all selected keyframes"); + ot->description= "Make a copy of all selected keyframes"; /* api callbacks */ ot->invoke= actkeys_duplicate_invoke; @@ -712,7 +710,7 @@ void ACTION_OT_duplicate (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /* ******************** Delete Keyframes Operator ************************* */ @@ -776,9 +774,9 @@ static int actkeys_delete_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_delete (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Keyframes"); + ot->name= "Delete Keyframes"; ot->idname= "ACTION_OT_delete"; - ot->description= _("Remove all selected keyframes"); + ot->description= "Remove all selected keyframes"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -840,9 +838,9 @@ static int actkeys_clean_exec(bContext *C, wmOperator *op) void ACTION_OT_clean (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clean Keyframes"); + ot->name= "Clean Keyframes"; ot->idname= "ACTION_OT_clean"; - ot->description= _("Simplify F-Curves by removing closely spaced keyframes"); + ot->description= "Simplify F-Curves by removing closely spaced keyframes"; /* api callbacks */ //ot->invoke= // XXX we need that number popup for this! @@ -853,7 +851,7 @@ void ACTION_OT_clean (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_float(ot->srna, "threshold", 0.001f, 0.0f, FLT_MAX, _("Threshold"), "", 0.0f, 1000.0f); + ot->prop= RNA_def_float(ot->srna, "threshold", 0.001f, 0.0f, FLT_MAX, "Threshold", "", 0.0f, 1000.0f); } /* ******************** Sample Keyframes Operator *********************** */ @@ -904,9 +902,9 @@ static int actkeys_sample_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_sample (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sample Keyframes"); + ot->name= "Sample Keyframes"; ot->idname= "ACTION_OT_sample"; - ot->description= _("Add keyframes on every frame between the selected keyframes"); + ot->description= "Add keyframes on every frame between the selected keyframes"; /* api callbacks */ ot->exec= actkeys_sample_exec; @@ -927,11 +925,11 @@ void ACTION_OT_sample (wmOperatorType *ot) /* defines for set extrapolation-type for selected keyframes tool */ static EnumPropertyItem prop_actkeys_expo_types[] = { - {FCURVE_EXTRAPOLATE_CONSTANT, "CONSTANT", 0, N_("Constant Extrapolation"), ""}, - {FCURVE_EXTRAPOLATE_LINEAR, "LINEAR", 0, N_("Linear Extrapolation"), ""}, + {FCURVE_EXTRAPOLATE_CONSTANT, "CONSTANT", 0, "Constant Extrapolation", ""}, + {FCURVE_EXTRAPOLATE_LINEAR, "LINEAR", 0, "Linear Extrapolation", ""}, - {MAKE_CYCLIC_EXPO, "MAKE_CYCLIC", 0, N_("Make Cyclic (F-Modifier)"), N_("Add Cycles F-Modifier if one doesn't exist already")}, - {CLEAR_CYCLIC_EXPO, "CLEAR_CYCLIC", 0, N_("Clear Cyclic (F-Modifier)"), N_("Remove Cycles F-Modifier if not needed anymore")}, + {MAKE_CYCLIC_EXPO, "MAKE_CYCLIC", 0, "Make Cyclic (F-Modifier)", "Add Cycles F-Modifier if one doesn't exist already"}, + {CLEAR_CYCLIC_EXPO, "CLEAR_CYCLIC", 0, "Clear Cyclic (F-Modifier)", "Remove Cycles F-Modifier if not needed anymore"}, {0, NULL, 0, NULL, NULL} }; @@ -1014,9 +1012,9 @@ static int actkeys_expo_exec(bContext *C, wmOperator *op) void ACTION_OT_extrapolation_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Extrapolation"); + ot->name= "Set Keyframe Extrapolation"; ot->idname= "ACTION_OT_extrapolation_type"; - ot->description= _("Set extrapolation mode for selected F-Curves"); + ot->description= "Set extrapolation mode for selected F-Curves"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1027,7 +1025,7 @@ void ACTION_OT_extrapolation_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_actkeys_expo_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_actkeys_expo_types, 0, "Type", ""); } /* ******************** Set Interpolation-Type Operator *********************** */ @@ -1085,9 +1083,9 @@ static int actkeys_ipo_exec(bContext *C, wmOperator *op) void ACTION_OT_interpolation_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Interpolation"); + ot->name= "Set Keyframe Interpolation"; ot->idname= "ACTION_OT_interpolation_type"; - ot->description= _("Set interpolation mode for the F-Curve segments starting from the selected keyframes"); + ot->description= "Set interpolation mode for the F-Curve segments starting from the selected keyframes"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1098,7 +1096,7 @@ void ACTION_OT_interpolation_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(beztriple_interpolation_mode_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", beztriple_interpolation_mode_items, 0, "Type", ""); } /* ******************** Set Handle-Type Operator *********************** */ @@ -1165,9 +1163,9 @@ static int actkeys_handletype_exec(bContext *C, wmOperator *op) void ACTION_OT_handle_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Handle Type"); + ot->name= "Set Keyframe Handle Type"; ot->idname= "ACTION_OT_handle_type"; - ot->description= _("Set type of handle for selected keyframes"); + ot->description= "Set type of handle for selected keyframes"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1178,7 +1176,7 @@ void ACTION_OT_handle_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(keyframe_handle_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", keyframe_handle_type_items, 0, "Type", ""); } /* ******************** Set Keyframe-Type Operator *********************** */ @@ -1236,9 +1234,9 @@ static int actkeys_keytype_exec(bContext *C, wmOperator *op) void ACTION_OT_keyframe_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Type"); + ot->name= "Set Keyframe Type"; ot->idname= "ACTION_OT_keyframe_type"; - ot->description= _("Set type of keyframe for the selected keyframes"); + ot->description= "Set type of keyframe for the selected keyframes"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1249,7 +1247,7 @@ void ACTION_OT_keyframe_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(beztriple_keyframe_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", beztriple_keyframe_type_items, 0, "Type", ""); } /* ************************************************************************** */ @@ -1304,9 +1302,9 @@ static int actkeys_framejump_exec(bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_frame_jump (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Jump to Frame"); + ot->name= "Jump to Frame"; ot->idname= "ACTION_OT_frame_jump"; - ot->description= _("Set the current frame to the average frame of the selected keyframes"); + ot->description= "Set the current frame to the average frame of the selected keyframes"; /* api callbacks */ ot->exec= actkeys_framejump_exec; @@ -1320,10 +1318,10 @@ void ACTION_OT_frame_jump (wmOperatorType *ot) /* defines for snap keyframes tool */ static EnumPropertyItem prop_actkeys_snap_types[] = { - {ACTKEYS_SNAP_CFRA, "CFRA", 0, N_("Current frame"), ""}, - {ACTKEYS_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, N_("Nearest Frame"), ""}, // XXX as single entry? - {ACTKEYS_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, N_("Nearest Second"), ""}, // XXX as single entry? - {ACTKEYS_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, N_("Nearest Marker"), ""}, + {ACTKEYS_SNAP_CFRA, "CFRA", 0, "Current frame", ""}, + {ACTKEYS_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, "Nearest Frame", ""}, // XXX as single entry? + {ACTKEYS_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, "Nearest Second", ""}, // XXX as single entry? + {ACTKEYS_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, "Nearest Marker", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1400,9 +1398,9 @@ static int actkeys_snap_exec(bContext *C, wmOperator *op) void ACTION_OT_snap (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Snap Keys"); + ot->name= "Snap Keys"; ot->idname= "ACTION_OT_snap"; - ot->description= _("Snap selected keyframes to the times specified"); + ot->description= "Snap selected keyframes to the times specified"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1413,16 +1411,16 @@ void ACTION_OT_snap (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_actkeys_snap_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_actkeys_snap_types, 0, "Type", ""); } /* ******************** Mirror Keyframes Operator *********************** */ /* defines for mirror keyframes tool */ static EnumPropertyItem prop_actkeys_mirror_types[] = { - {ACTKEYS_MIRROR_CFRA, "CFRA", 0, N_("By Times over Current frame"), ""}, - {ACTKEYS_MIRROR_XAXIS, "XAXIS", 0, N_("By Values over Value=0"), ""}, - {ACTKEYS_MIRROR_MARKER, "MARKER", 0, N_("By Times over First Selected Marker"), ""}, + {ACTKEYS_MIRROR_CFRA, "CFRA", 0, "By Times over Current frame", ""}, + {ACTKEYS_MIRROR_XAXIS, "XAXIS", 0, "By Values over Value=0", ""}, + {ACTKEYS_MIRROR_MARKER, "MARKER", 0, "By Times over First Selected Marker", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1510,9 +1508,9 @@ static int actkeys_mirror_exec(bContext *C, wmOperator *op) void ACTION_OT_mirror (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror Keys"); + ot->name= "Mirror Keys"; ot->idname= "ACTION_OT_mirror"; - ot->description= _("Flip selected keyframes over the selected mirror line"); + ot->description= "Flip selected keyframes over the selected mirror line"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1523,7 +1521,7 @@ void ACTION_OT_mirror (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_actkeys_mirror_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_actkeys_mirror_types, 0, "Type", ""); } /* ************************************************************************** */ diff --git a/source/blender/editors/space_action/action_ops.c b/source/blender/editors/space_action/action_ops.c index 8621a56d8f4..491d436741e 100644 --- a/source/blender/editors/space_action/action_ops.c +++ b/source/blender/editors/space_action/action_ops.c @@ -37,8 +37,6 @@ #include "BLI_blenlib.h" -#include "BLF_api.h" - #include "ED_anim_api.h" #include "ED_markers.h" #include "ED_transform.h" @@ -94,7 +92,7 @@ void ED_operatormacros_action(void) wmOperatorType *ot; wmOperatorTypeMacro *otmacro; - ot= WM_operatortype_append_macro("ACTION_OT_duplicate_move", _("Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("ACTION_OT_duplicate_move", "Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); if (ot) { WM_operatortype_macro_define(ot, "ACTION_OT_duplicate"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_transform"); diff --git a/source/blender/editors/space_action/action_select.c b/source/blender/editors/space_action/action_select.c index 2d5e56066a7..aa29e54f436 100644 --- a/source/blender/editors/space_action/action_select.c +++ b/source/blender/editors/space_action/action_select.c @@ -39,8 +39,6 @@ #include "BLI_dlrbTree.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_gpencil_types.h" #include "DNA_object_types.h" @@ -163,9 +161,9 @@ static int actkeys_deselectall_exec(bContext *C, wmOperator *op) void ACTION_OT_select_all_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "ACTION_OT_select_all_toggle"; - ot->description= _("Toggle selection of all keyframes"); + ot->description= "Toggle selection of all keyframes"; /* api callbacks */ ot->exec= actkeys_deselectall_exec; @@ -175,7 +173,7 @@ void ACTION_OT_select_all_toggle (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_boolean(ot->srna, "invert", 0, _("Invert"), ""); + ot->prop= RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); } /* ******************** Border Select Operator **************************** */ @@ -316,9 +314,9 @@ static int actkeys_borderselect_exec(bContext *C, wmOperator *op) void ACTION_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "ACTION_OT_select_border"; - ot->description= _("Select all keyframes within the specified region"); + ot->description= "Select all keyframes within the specified region"; /* api callbacks */ ot->invoke= WM_border_select_invoke; @@ -334,7 +332,7 @@ void ACTION_OT_select_border(wmOperatorType *ot) /* rna */ WM_operator_properties_gesture_border(ot, FALSE); - ot->prop= RNA_def_boolean(ot->srna, "axis_range", 0, _("Axis Range"), ""); + ot->prop= RNA_def_boolean(ot->srna, "axis_range", 0, "Axis Range", ""); } /* ******************** Column Select Operator **************************** */ @@ -347,10 +345,10 @@ void ACTION_OT_select_border(wmOperatorType *ot) /* defines for column-select mode */ static EnumPropertyItem prop_column_select_types[] = { - {ACTKEYS_COLUMNSEL_KEYS, "KEYS", 0, N_("On Selected Keyframes"), ""}, - {ACTKEYS_COLUMNSEL_CFRA, "CFRA", 0, N_("On Current Frame"), ""}, - {ACTKEYS_COLUMNSEL_MARKERS_COLUMN, "MARKERS_COLUMN", 0, N_("On Selected Markers"), ""}, - {ACTKEYS_COLUMNSEL_MARKERS_BETWEEN, "MARKERS_BETWEEN", 0, N_("Between Min/Max Selected Markers"), ""}, + {ACTKEYS_COLUMNSEL_KEYS, "KEYS", 0, "On Selected Keyframes", ""}, + {ACTKEYS_COLUMNSEL_CFRA, "CFRA", 0, "On Current Frame", ""}, + {ACTKEYS_COLUMNSEL_MARKERS_COLUMN, "MARKERS_COLUMN", 0, "On Selected Markers", ""}, + {ACTKEYS_COLUMNSEL_MARKERS_BETWEEN, "MARKERS_BETWEEN", 0, "Between Min/Max Selected Markers", ""}, {0, NULL, 0, NULL, NULL} }; @@ -522,9 +520,9 @@ static int actkeys_columnselect_exec(bContext *C, wmOperator *op) void ACTION_OT_select_column (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "ACTION_OT_select_column"; - ot->description= _("Select all keyframes on the specified frame(s)"); + ot->description= "Select all keyframes on the specified frame(s)"; /* api callbacks */ ot->exec= actkeys_columnselect_exec; @@ -534,7 +532,7 @@ void ACTION_OT_select_column (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_column_select_types), 0, _("Mode"), ""); + ot->prop= RNA_def_enum(ot->srna, "mode", prop_column_select_types, 0, "Mode", ""); } /* ******************** Select Linked Operator *********************** */ @@ -580,9 +578,9 @@ static int actkeys_select_linked_exec (bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_select_linked (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Linked"); + ot->name = "Select Linked"; ot->idname= "ACTION_OT_select_linked"; - ot->description = _("Select keyframes occurring the same F-Curves as selected ones"); + ot->description = "Select keyframes occurring the same F-Curves as selected ones"; /* api callbacks */ ot->exec= actkeys_select_linked_exec; @@ -657,9 +655,9 @@ static int actkeys_select_more_exec (bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_select_more (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select More"); + ot->name = "Select More"; ot->idname= "ACTION_OT_select_more"; - ot->description = _("Select keyframes beside already selected ones"); + ot->description = "Select keyframes beside already selected ones"; /* api callbacks */ ot->exec= actkeys_select_more_exec; @@ -691,9 +689,9 @@ static int actkeys_select_less_exec (bContext *C, wmOperator *UNUSED(op)) void ACTION_OT_select_less (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Less"); + ot->name = "Select Less"; ot->idname= "ACTION_OT_select_less"; - ot->description = _("Deselect keyframes on ends of selection islands"); + ot->description = "Deselect keyframes on ends of selection islands"; /* api callbacks */ ot->exec= actkeys_select_less_exec; @@ -708,9 +706,9 @@ void ACTION_OT_select_less (wmOperatorType *ot) /* defines for left-right select tool */ static EnumPropertyItem prop_actkeys_leftright_select_types[] = { - {ACTKEYS_LRSEL_TEST, "CHECK", 0, N_("Check if Select Left or Right"), ""}, - {ACTKEYS_LRSEL_LEFT, "LEFT", 0, N_("Before current frame"), ""}, - {ACTKEYS_LRSEL_RIGHT, "RIGHT", 0, N_("After current frame"), ""}, + {ACTKEYS_LRSEL_TEST, "CHECK", 0, "Check if Select Left or Right", ""}, + {ACTKEYS_LRSEL_LEFT, "LEFT", 0, "Before current frame", ""}, + {ACTKEYS_LRSEL_RIGHT, "RIGHT", 0, "After current frame", ""}, {0, NULL, 0, NULL, NULL} }; @@ -857,9 +855,9 @@ static int actkeys_select_leftright_invoke (bContext *C, wmOperator *op, wmEvent void ACTION_OT_select_leftright (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Left/Right"); + ot->name= "Select Left/Right"; ot->idname= "ACTION_OT_select_leftright"; - ot->description= _("Select keyframes to the left or the right of the current frame"); + ot->description= "Select keyframes to the left or the right of the current frame"; /* api callbacks */ ot->invoke= actkeys_select_leftright_invoke; @@ -870,8 +868,8 @@ void ACTION_OT_select_leftright (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_actkeys_leftright_select_types), ACTKEYS_LRSEL_TEST, _("Mode"), ""); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); + ot->prop= RNA_def_enum(ot->srna, "mode", prop_actkeys_leftright_select_types, ACTKEYS_LRSEL_TEST, "Mode", ""); + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); } /* ******************** Mouse-Click Select Operator *********************** */ @@ -1173,9 +1171,9 @@ static int actkeys_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *even void ACTION_OT_clickselect (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mouse Select Keys"); + ot->name= "Mouse Select Keys"; ot->idname= "ACTION_OT_clickselect"; - ot->description= _("Select keyframes by clicking on them"); + ot->description= "Select keyframes by clicking on them"; /* api callbacks - absolutely no exec() this yet... */ ot->invoke= actkeys_clickselect_invoke; @@ -1185,8 +1183,8 @@ void ACTION_OT_clickselect (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); // SHIFTKEY - RNA_def_boolean(ot->srna, "column", 0, _("Column Select"), ""); // ALTKEY + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY + RNA_def_boolean(ot->srna, "column", 0, "Column Select", ""); // ALTKEY } /* ************************************************************************** */ diff --git a/source/blender/editors/space_buttons/buttons_header.c b/source/blender/editors/space_buttons/buttons_header.c index 831461e4b82..4c137c6d886 100644 --- a/source/blender/editors/space_buttons/buttons_header.c +++ b/source/blender/editors/space_buttons/buttons_header.c @@ -125,24 +125,24 @@ void buttons_header_buttons(const bContext *C, ARegion *ar) #define BUTTON_HEADER_CTX(_ctx, _icon, _tip) \ if(sbuts->pathflag & (1<<_ctx)) { \ - but= uiDefIconButS(block, ROW, B_CONTEXT_SWITCH, _icon, xco+=BUT_UNIT_X, yco, BUT_UNIT_X, UI_UNIT_Y, &(sbuts->mainb), 0.0, (float)_ctx, 0, 0, _tip); \ + but= uiDefIconButS(block, ROW, B_CONTEXT_SWITCH, _icon, xco+=BUT_UNIT_X, yco, BUT_UNIT_X, UI_UNIT_Y, &(sbuts->mainb), 0.0, (float)_ctx, 0, 0, \ + ((U.transopts&USER_DOTRANSLATE) && (U.transopts&USER_TR_TOOLTIPS)) ? BLF_gettext(_tip) : _tip); \ uiButClearFlag(but, UI_BUT_UNDO); \ } \ - - BUTTON_HEADER_CTX(BCONTEXT_RENDER, ICON_SCENE, _("Render")) - BUTTON_HEADER_CTX(BCONTEXT_SCENE, ICON_SCENE_DATA, _("Scene")); - BUTTON_HEADER_CTX(BCONTEXT_WORLD, ICON_WORLD, _("World")); - BUTTON_HEADER_CTX(BCONTEXT_OBJECT, ICON_OBJECT_DATA, _("Object")); - BUTTON_HEADER_CTX(BCONTEXT_CONSTRAINT, ICON_CONSTRAINT, _("Object Constraints")); - BUTTON_HEADER_CTX(BCONTEXT_MODIFIER, ICON_MODIFIER, _("Object Modifiers")); - BUTTON_HEADER_CTX(BCONTEXT_DATA, sbuts->dataicon, _("Object Data")); - BUTTON_HEADER_CTX(BCONTEXT_BONE, ICON_BONE_DATA, _("Bone")); - BUTTON_HEADER_CTX(BCONTEXT_BONE_CONSTRAINT, ICON_CONSTRAINT_BONE, _("Bone Constraints")); - BUTTON_HEADER_CTX(BCONTEXT_MATERIAL, ICON_MATERIAL, _("Material")); - BUTTON_HEADER_CTX(BCONTEXT_TEXTURE, ICON_TEXTURE, _("Textures")); - BUTTON_HEADER_CTX(BCONTEXT_PARTICLE, ICON_PARTICLES, _("Particles")); - BUTTON_HEADER_CTX(BCONTEXT_PHYSICS, ICON_PHYSICS, _("Physics")); + BUTTON_HEADER_CTX(BCONTEXT_RENDER, ICON_SCENE, N_("Render")) + BUTTON_HEADER_CTX(BCONTEXT_SCENE, ICON_SCENE_DATA, N_("Scene")); + BUTTON_HEADER_CTX(BCONTEXT_WORLD, ICON_WORLD, N_("World")); + BUTTON_HEADER_CTX(BCONTEXT_OBJECT, ICON_OBJECT_DATA, N_("Object")); + BUTTON_HEADER_CTX(BCONTEXT_CONSTRAINT, ICON_CONSTRAINT, N_("Object Constraints")); + BUTTON_HEADER_CTX(BCONTEXT_MODIFIER, ICON_MODIFIER, N_("Object Modifiers")); + BUTTON_HEADER_CTX(BCONTEXT_DATA, sbuts->dataicon, N_("Object Data")); + BUTTON_HEADER_CTX(BCONTEXT_BONE, ICON_BONE_DATA, N_("Bone")); + BUTTON_HEADER_CTX(BCONTEXT_BONE_CONSTRAINT, ICON_CONSTRAINT_BONE, N_("Bone Constraints")); + BUTTON_HEADER_CTX(BCONTEXT_MATERIAL, ICON_MATERIAL, N_("Material")); + BUTTON_HEADER_CTX(BCONTEXT_TEXTURE, ICON_TEXTURE, N_("Textures")); + BUTTON_HEADER_CTX(BCONTEXT_PARTICLE, ICON_PARTICLES, N_("Particles")); + BUTTON_HEADER_CTX(BCONTEXT_PHYSICS, ICON_PHYSICS, N_("Physics")); #undef BUTTON_HEADER_CTX diff --git a/source/blender/editors/space_buttons/buttons_ops.c b/source/blender/editors/space_buttons/buttons_ops.c index 346531b2b11..99e5c6d693e 100644 --- a/source/blender/editors/space_buttons/buttons_ops.c +++ b/source/blender/editors/space_buttons/buttons_ops.c @@ -43,8 +43,6 @@ #include "BLI_string.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_global.h" #include "BKE_main.h" @@ -85,8 +83,8 @@ static int toolbox_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *UNUSED(e void BUTTONS_OT_toolbox(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toolbox"); - ot->description=_("Display button panel toolbox"); + ot->name= "Toolbox"; + ot->description="Display button panel toolbox"; ot->idname= "BUTTONS_OT_toolbox"; /* api callbacks */ @@ -218,8 +216,8 @@ static int file_browse_invoke(bContext *C, wmOperator *op, wmEvent *event) void BUTTONS_OT_file_browse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Accept"); - ot->description=_("Open a file browser, Hold Shift to open the file, Alt to browse containing directory"); + ot->name= "Accept"; + ot->description="Open a file browser, Hold Shift to open the file, Alt to browse containing directory"; ot->idname= "BUTTONS_OT_file_browse"; /* api callbacks */ @@ -235,8 +233,8 @@ void BUTTONS_OT_file_browse(wmOperatorType *ot) void BUTTONS_OT_directory_browse(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Accept"); - ot->description=_("Open a directory browser, Hold Shift to open the file, Alt to browse containing directory"); + ot->name= "Accept"; + ot->description="Open a directory browser, Hold Shift to open the file, Alt to browse containing directory"; ot->idname= "BUTTONS_OT_directory_browse"; /* api callbacks */ diff --git a/source/blender/editors/space_console/console_ops.c b/source/blender/editors/space_console/console_ops.c index a781c69b5a2..4707baa279b 100644 --- a/source/blender/editors/space_console/console_ops.c +++ b/source/blender/editors/space_console/console_ops.c @@ -40,8 +40,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_text.h" /* only for character utility funcs */ @@ -350,8 +348,8 @@ static int move_exec(bContext *C, wmOperator *op) void CONSOLE_OT_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Cursor"); - ot->description= _("Move cursor position"); + ot->name= "Move Cursor"; + ot->description= "Move cursor position"; ot->idname= "CONSOLE_OT_move"; /* api callbacks */ @@ -359,7 +357,7 @@ void CONSOLE_OT_move(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, _("Type"), _("Where to move cursor to.")); + RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, "Type", "Where to move cursor to."); } #define TAB_LENGTH 4 @@ -419,8 +417,8 @@ static int insert_invoke(bContext *C, wmOperator *op, wmEvent *event) void CONSOLE_OT_insert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert"); - ot->description= _("Insert text at cursor position"); + ot->name= "Insert"; + ot->description= "Insert text at cursor position"; ot->idname= "CONSOLE_OT_insert"; /* api callbacks */ @@ -429,7 +427,7 @@ void CONSOLE_OT_insert(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_string(ot->srna, "text", "", 0, _("Text"), _("Text to insert at the cursor position.")); + RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); } @@ -488,8 +486,8 @@ static int delete_exec(bContext *C, wmOperator *op) void CONSOLE_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description= _("Delete text by cursor position"); + ot->name= "Delete"; + ot->description= "Delete text by cursor position"; ot->idname= "CONSOLE_OT_delete"; /* api callbacks */ @@ -497,7 +495,7 @@ void CONSOLE_OT_delete(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_enum(ot->srna, "type", delete_type_items, DEL_NEXT_CHAR, _("Type"), _("Which part of the text to delete.")); + RNA_def_enum(ot->srna, "type", delete_type_items, DEL_NEXT_CHAR, "Type", "Which part of the text to delete."); } @@ -531,8 +529,8 @@ static int clear_exec(bContext *C, wmOperator *op) void CONSOLE_OT_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear"); - ot->description= _("Clear text by type"); + ot->name= "Clear"; + ot->description= "Clear text by type"; ot->idname= "CONSOLE_OT_clear"; /* api callbacks */ @@ -540,8 +538,8 @@ void CONSOLE_OT_clear(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_boolean(ot->srna, "scrollback", 1, _("Scrollback"), _("Clear the scrollback history")); - RNA_def_boolean(ot->srna, "history", 0, _("History"), _("Clear the command history")); + RNA_def_boolean(ot->srna, "scrollback", 1, "Scrollback", "Clear the scrollback history"); + RNA_def_boolean(ot->srna, "history", 0, "History", "Clear the command history"); } @@ -597,8 +595,8 @@ static int history_cycle_exec(bContext *C, wmOperator *op) void CONSOLE_OT_history_cycle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("History Cycle"); - ot->description= _("Cycle through history"); + ot->name= "History Cycle"; + ot->description= "Cycle through history"; ot->idname= "CONSOLE_OT_history_cycle"; /* api callbacks */ @@ -606,7 +604,7 @@ void CONSOLE_OT_history_cycle(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_boolean(ot->srna, "reverse", 0, _("Reverse"), _("reverse cycle history")); + RNA_def_boolean(ot->srna, "reverse", 0, "Reverse", "reverse cycle history"); } @@ -645,8 +643,8 @@ static int history_append_exec(bContext *C, wmOperator *op) void CONSOLE_OT_history_append(wmOperatorType *ot) { /* identifiers */ - ot->name= _("History Append"); - ot->description= _("Append history at cursor position"); + ot->name= "History Append"; + ot->description= "Append history at cursor position"; ot->idname= "CONSOLE_OT_history_append"; /* api callbacks */ @@ -654,9 +652,9 @@ void CONSOLE_OT_history_append(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_string(ot->srna, "text", "", 0, _("Text"), _("Text to insert at the cursor position.")); - RNA_def_int(ot->srna, "current_character", 0, 0, INT_MAX, _("Cursor"), _("The index of the cursor."), 0, 10000); - RNA_def_boolean(ot->srna, "remove_duplicates", 0, _("Remove Duplicates"), _("Remove duplicate items in the history")); + RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); + RNA_def_int(ot->srna, "current_character", 0, 0, INT_MAX, "Cursor", "The index of the cursor.", 0, 10000); + RNA_def_boolean(ot->srna, "remove_duplicates", 0, "Remove Duplicates", "Remove duplicate items in the history"); } @@ -699,8 +697,8 @@ void CONSOLE_OT_scrollback_append(wmOperatorType *ot) {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Scrollback Append"); - ot->description= _("Append scrollback text by type"); + ot->name= "Scrollback Append"; + ot->description= "Append scrollback text by type"; ot->idname= "CONSOLE_OT_scrollback_append"; /* api callbacks */ @@ -708,8 +706,8 @@ void CONSOLE_OT_scrollback_append(wmOperatorType *ot) ot->poll= ED_operator_console_active; /* properties */ - RNA_def_string(ot->srna, "text", "", 0, _("Text"), _("Text to insert at the cursor position.")); - RNA_def_enum(ot->srna, "type", console_line_type_items, CONSOLE_LINE_OUTPUT, _("Type"), _("Console output type.")); + RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); + RNA_def_enum(ot->srna, "type", console_line_type_items, CONSOLE_LINE_OUTPUT, "Type", "Console output type."); } @@ -782,8 +780,8 @@ static int copy_exec(bContext *C, wmOperator *UNUSED(op)) void CONSOLE_OT_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy to Clipboard"); - ot->description= _("Copy selected text to clipboard"); + ot->name= "Copy to Clipboard"; + ot->description= "Copy selected text to clipboard"; ot->idname= "CONSOLE_OT_copy"; /* api callbacks */ @@ -833,8 +831,8 @@ static int paste_exec(bContext *C, wmOperator *UNUSED(op)) void CONSOLE_OT_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste from Clipboard"); - ot->description= _("Paste text from clipboard"); + ot->name= "Paste from Clipboard"; + ot->description= "Paste text from clipboard"; ot->idname= "CONSOLE_OT_paste"; /* api callbacks */ @@ -957,9 +955,9 @@ static int console_modal_select_cancel(bContext *C, wmOperator *op) void CONSOLE_OT_select_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Selection"); + ot->name= "Set Selection"; ot->idname= "CONSOLE_OT_select_set"; - ot->description= _("Set the console selection"); + ot->description= "Set the console selection"; /* api callbacks */ ot->invoke= console_modal_select_invoke; diff --git a/source/blender/editors/space_file/file_ops.c b/source/blender/editors/space_file/file_ops.c index f8a5e4ca1ac..1b0893e50e0 100644 --- a/source/blender/editors/space_file/file_ops.c +++ b/source/blender/editors/space_file/file_ops.c @@ -44,8 +44,6 @@ #include "BLI_winstuff.h" #endif -#include "BLF_api.h" - #include "ED_screen.h" #include "ED_fileselect.h" @@ -296,8 +294,8 @@ static int file_border_select_exec(bContext *C, wmOperator *op) void FILE_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Activate/Select File"); - ot->description= _("Activate/select the file(s) contained in the border"); + ot->name= "Activate/Select File"; + ot->description= "Activate/select the file(s) contained in the border"; ot->idname= "FILE_OT_select_border"; /* api callbacks */ @@ -347,8 +345,8 @@ static int file_select_invoke(bContext *C, wmOperator *op, wmEvent *event) void FILE_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Activate/Select File"); - ot->description= _("Activate/select file"); + ot->name= "Activate/Select File"; + ot->description= "Activate/select file"; ot->idname= "FILE_OT_select"; /* api callbacks */ @@ -356,8 +354,8 @@ void FILE_OT_select(wmOperatorType *ot) ot->poll= ED_operator_file_active; /* rna */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend selection instead of deselecting everything first.")); - RNA_def_boolean(ot->srna, "fill", 0, _("Fill"), _("Select everything beginning with the last selection.")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend selection instead of deselecting everything first."); + RNA_def_boolean(ot->srna, "fill", 0, "Fill", "Select everything beginning with the last selection."); } static int file_select_all_exec(bContext *C, wmOperator *UNUSED(op)) @@ -394,8 +392,8 @@ static int file_select_all_exec(bContext *C, wmOperator *UNUSED(op)) void FILE_OT_select_all_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select/Deselect All Files"); - ot->description= _("Select/deselect all files"); + ot->name= "Select/Deselect All Files"; + ot->description= "Select/deselect all files"; ot->idname= "FILE_OT_select_all_toggle"; /* api callbacks */ @@ -431,8 +429,8 @@ static int bookmark_select_exec(bContext *C, wmOperator *op) void FILE_OT_select_bookmark(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Directory"); - ot->description= _("Select a bookmarked directory"); + ot->name= "Select Directory"; + ot->description= "Select a bookmarked directory"; ot->idname= "FILE_OT_select_bookmark"; /* api callbacks */ @@ -464,8 +462,8 @@ static int bookmark_add_exec(bContext *C, wmOperator *UNUSED(op)) void FILE_OT_bookmark_add(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Bookmark"); - ot->description= _("Add a bookmark for the selected/active directory"); + ot->name= "Add Bookmark"; + ot->description= "Add a bookmark for the selected/active directory"; ot->idname= "FILE_OT_bookmark_add"; /* api callbacks */ @@ -497,15 +495,15 @@ static int bookmark_delete_exec(bContext *C, wmOperator *op) void FILE_OT_delete_bookmark(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Bookmark"); - ot->description= _("Delete selected bookmark"); + ot->name= "Delete Bookmark"; + ot->description= "Delete selected bookmark"; ot->idname= "FILE_OT_delete_bookmark"; /* api callbacks */ ot->exec= bookmark_delete_exec; ot->poll= ED_operator_file_active; - RNA_def_int(ot->srna, "index", -1, -1, 20000, _("Index"), "", -1, 20000); + RNA_def_int(ot->srna, "index", -1, -1, 20000, "Index", "", -1, 20000); } int file_hilight_set(SpaceFile *sfile, ARegion *ar, int mx, int my) @@ -559,8 +557,8 @@ static int file_highlight_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *e void FILE_OT_highlight(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Highlight File"); - ot->description= _("Highlight selected file(s)"); + ot->name= "Highlight File"; + ot->description= "Highlight selected file(s)"; ot->idname= "FILE_OT_highlight"; /* api callbacks */ @@ -593,8 +591,8 @@ static int file_operator_poll(bContext *C) void FILE_OT_cancel(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cancel File Load"); - ot->description= _("Cancel loading of selected file"); + ot->name= "Cancel File Load"; + ot->description= "Cancel loading of selected file"; ot->idname= "FILE_OT_cancel"; /* api callbacks */ @@ -761,15 +759,15 @@ int file_exec(bContext *C, wmOperator *exec_op) void FILE_OT_execute(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Execute File Window"); - ot->description= _("Execute selected file"); + ot->name= "Execute File Window"; + ot->description= "Execute selected file"; ot->idname= "FILE_OT_execute"; /* api callbacks */ ot->exec= file_exec; ot->poll= file_operator_poll; - RNA_def_boolean(ot->srna, "need_active", 0, _("Need Active"), _("Only execute if there's an active selected file in the file list.")); + RNA_def_boolean(ot->srna, "need_active", 0, "Need Active", "Only execute if there's an active selected file in the file list."); } @@ -794,8 +792,8 @@ int file_parent_exec(bContext *C, wmOperator *UNUSED(unused)) void FILE_OT_parent(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Parent File"); - ot->description= _("Move to parent directory"); + ot->name= "Parent File"; + ot->description= "Move to parent directory"; ot->idname= "FILE_OT_parent"; /* api callbacks */ @@ -819,8 +817,8 @@ static int file_refresh_exec(bContext *C, wmOperator *UNUSED(unused)) void FILE_OT_previous(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Previous Folder"); - ot->description= _("Move to previous folder"); + ot->name= "Previous Folder"; + ot->description= "Move to previous folder"; ot->idname= "FILE_OT_previous"; /* api callbacks */ @@ -850,8 +848,8 @@ int file_previous_exec(bContext *C, wmOperator *UNUSED(unused)) void FILE_OT_next(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Next Folder"); - ot->description= _("Move to next folder"); + ot->name= "Next Folder"; + ot->description= "Move to next folder"; ot->idname= "FILE_OT_next"; /* api callbacks */ @@ -977,9 +975,9 @@ void FILE_OT_smoothscroll(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth Scroll"); + ot->name= "Smooth Scroll"; ot->idname= "FILE_OT_smoothscroll"; - ot->description=_("Smooth scroll to make editable file visible."); + ot->description="Smooth scroll to make editable file visible."; /* api callbacks */ ot->invoke= file_smoothscroll_invoke; @@ -1064,8 +1062,8 @@ int file_directory_new_exec(bContext *C, wmOperator *op) void FILE_OT_directory_new(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Create New Directory"); - ot->description= _("Create a new directory"); + ot->name= "Create New Directory"; + ot->description= "Create a new directory"; ot->idname= "FILE_OT_directory_new"; /* api callbacks */ @@ -1073,7 +1071,7 @@ void FILE_OT_directory_new(struct wmOperatorType *ot) ot->exec= file_directory_new_exec; ot->poll= ED_operator_file_active; /* <- important, handler is on window level */ - RNA_def_string_dir_path(ot->srna, "directory", "", FILE_MAX, _("Directory"), _("Name of new directory")); + RNA_def_string_dir_path(ot->srna, "directory", "", FILE_MAX, "Directory", "Name of new directory"); } @@ -1179,8 +1177,8 @@ static int file_directory_poll(bContext *C) void FILE_OT_directory(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Enter Directory Name"); - ot->description= _("Enter a directory name"); + ot->name= "Enter Directory Name"; + ot->description= "Enter a directory name"; ot->idname= "FILE_OT_directory"; /* api callbacks */ @@ -1192,8 +1190,8 @@ void FILE_OT_directory(struct wmOperatorType *ot) void FILE_OT_refresh(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Refresh Filelist"); - ot->description= _("Refresh the file list"); + ot->name= "Refresh Filelist"; + ot->description= "Refresh the file list"; ot->idname= "FILE_OT_refresh"; /* api callbacks */ @@ -1218,8 +1216,8 @@ static int file_hidedot_exec(bContext *C, wmOperator *UNUSED(unused)) void FILE_OT_hidedot(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Hide Dot Files"); - ot->description= _("Toggle hide hidden dot files"); + ot->name= "Toggle Hide Dot Files"; + ot->description= "Toggle hide hidden dot files"; ot->idname= "FILE_OT_hidedot"; /* api callbacks */ @@ -1268,8 +1266,8 @@ static int file_bookmark_toggle_exec(bContext *C, wmOperator *UNUSED(unused)) void FILE_OT_bookmark_toggle(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Bookmarks"); - ot->description= _("Toggle bookmarks display"); + ot->name= "Toggle Bookmarks"; + ot->description= "Toggle bookmarks display"; ot->idname= "FILE_OT_bookmark_toggle"; /* api callbacks */ @@ -1298,8 +1296,8 @@ static int file_filenum_exec(bContext *C, wmOperator *op) void FILE_OT_filenum(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Increment Number in Filename"); - ot->description= _("Increment number in filename"); + ot->name= "Increment Number in Filename"; + ot->description= "Increment number in filename"; ot->idname= "FILE_OT_filenum"; /* api callbacks */ @@ -1307,7 +1305,7 @@ void FILE_OT_filenum(struct wmOperatorType *ot) ot->poll= ED_operator_file_active; /* <- important, handler is on window level */ /* props */ - RNA_def_int(ot->srna, "increment", 1, -100, 100, _("Increment"), "", -100,100); + RNA_def_int(ot->srna, "increment", 1, -100, 100, "Increment", "", -100,100); } static int file_rename_exec(bContext *C, wmOperator *UNUSED(op)) @@ -1352,8 +1350,8 @@ static int file_rename_poll(bContext *C) void FILE_OT_rename(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rename File or Directory"); - ot->description= _("Rename file or file directory"); + ot->name= "Rename File or Directory"; + ot->description= "Rename file or file directory"; ot->idname= "FILE_OT_rename"; /* api callbacks */ @@ -1404,8 +1402,8 @@ int file_delete_exec(bContext *C, wmOperator *UNUSED(op)) void FILE_OT_delete(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete File"); - ot->description= _("Delete selected file"); + ot->name= "Delete File"; + ot->description= "Delete selected file"; ot->idname= "FILE_OT_delete"; /* api callbacks */ diff --git a/source/blender/editors/space_file/file_panels.c b/source/blender/editors/space_file/file_panels.c index f3c38836058..09b90ac4d08 100644 --- a/source/blender/editors/space_file/file_panels.c +++ b/source/blender/editors/space_file/file_panels.c @@ -207,25 +207,25 @@ void file_panels_register(ARegionType *art) pt= MEM_callocN(sizeof(PanelType), "spacetype file system directories"); strcpy(pt->idname, "FILE_PT_system"); - strcpy(pt->label, _("System")); + strcpy(pt->label, "System"); pt->draw= file_panel_system; BLI_addtail(&art->paneltypes, pt); pt= MEM_callocN(sizeof(PanelType), "spacetype file bookmarks"); strcpy(pt->idname, "FILE_PT_bookmarks"); - strcpy(pt->label, _("Bookmarks")); + strcpy(pt->label, "Bookmarks"); pt->draw= file_panel_bookmarks; BLI_addtail(&art->paneltypes, pt); pt= MEM_callocN(sizeof(PanelType), "spacetype file recent directories"); strcpy(pt->idname, "FILE_PT_recent"); - strcpy(pt->label, _("Recent")); + strcpy(pt->label, "Recent"); pt->draw= file_panel_recent; BLI_addtail(&art->paneltypes, pt); pt= MEM_callocN(sizeof(PanelType), "spacetype file operator properties"); strcpy(pt->idname, "FILE_PT_operator"); - strcpy(pt->label, _("Operator")); + strcpy(pt->label, "Operator"); pt->poll= file_panel_operator_poll; pt->draw_header= file_panel_operator_header; pt->draw= file_panel_operator; diff --git a/source/blender/editors/space_graph/graph_buttons.c b/source/blender/editors/space_graph/graph_buttons.c index 1397a5ada94..c7459e8c6b4 100644 --- a/source/blender/editors/space_graph/graph_buttons.c +++ b/source/blender/editors/space_graph/graph_buttons.c @@ -826,9 +826,9 @@ static int graph_properties(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); + ot->name= "Properties"; ot->idname= "GRAPH_OT_properties"; - ot->description= _("Toggle display properties panel"); + ot->description= "Toggle display properties panel"; ot->exec= graph_properties; ot->poll= ED_operator_graphedit_active; diff --git a/source/blender/editors/space_graph/graph_edit.c b/source/blender/editors/space_graph/graph_edit.c index c3a0069a1a1..900aa6f6197 100644 --- a/source/blender/editors/space_graph/graph_edit.c +++ b/source/blender/editors/space_graph/graph_edit.c @@ -47,8 +47,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" @@ -186,9 +184,9 @@ static int graphkeys_previewrange_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_previewrange_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Auto-Set Preview Range"); + ot->name= "Auto-Set Preview Range"; ot->idname= "GRAPH_OT_previewrange_set"; - ot->description= _("Automatically set Preview Range based on range of keyframes"); + ot->description= "Automatically set Preview Range based on range of keyframes"; /* api callbacks */ ot->exec= graphkeys_previewrange_exec; @@ -248,9 +246,9 @@ static int graphkeys_view_selected_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_view_all (wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "GRAPH_OT_view_all"; - ot->description= _("Reset viewable area to show full keyframe range"); + ot->description= "Reset viewable area to show full keyframe range"; /* api callbacks */ ot->exec= graphkeys_viewall_exec; @@ -263,9 +261,9 @@ void GRAPH_OT_view_all (wmOperatorType *ot) void GRAPH_OT_view_selected (wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Selected"); + ot->name= "View Selected"; ot->idname= "GRAPH_OT_view_selected"; - ot->description= _("Reset viewable area to show selected keyframe range"); + ot->description= "Reset viewable area to show selected keyframe range"; /* api callbacks */ ot->exec= graphkeys_view_selected_exec; @@ -378,9 +376,9 @@ static int graphkeys_create_ghostcurves_exec(bContext *C, wmOperator *UNUSED(op) void GRAPH_OT_ghost_curves_create (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Create Ghost Curves"); + ot->name= "Create Ghost Curves"; ot->idname= "GRAPH_OT_ghost_curves_create"; - ot->description= _("Create snapshot (Ghosts) of selected F-Curves as background aid for active Graph Editor"); + ot->description= "Create snapshot (Ghosts) of selected F-Curves as background aid for active Graph Editor"; /* api callbacks */ ot->exec= graphkeys_create_ghostcurves_exec; @@ -421,9 +419,9 @@ static int graphkeys_clear_ghostcurves_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_ghost_curves_clear (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Ghost Curves"); + ot->name= "Clear Ghost Curves"; ot->idname= "GRAPH_OT_ghost_curves_clear"; - ot->description= _("Clear F-Curve snapshots (Ghosts) for active Graph Editor"); + ot->description= "Clear F-Curve snapshots (Ghosts) for active Graph Editor"; /* api callbacks */ ot->exec= graphkeys_clear_ghostcurves_exec; @@ -440,8 +438,8 @@ void GRAPH_OT_ghost_curves_clear (wmOperatorType *ot) /* defines for insert keyframes tool */ static EnumPropertyItem prop_graphkeys_insertkey_types[] = { - {1, "ALL", 0, N_("All Channels"), ""}, - {2, "SEL", 0, N_("Only Selected Channels"), ""}, + {1, "ALL", 0, "All Channels", ""}, + {2, "SEL", 0, "Only Selected Channels", ""}, {0, NULL, 0, NULL, NULL} }; @@ -516,9 +514,9 @@ static int graphkeys_insertkey_exec(bContext *C, wmOperator *op) void GRAPH_OT_keyframe_insert (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert Keyframes"); + ot->name= "Insert Keyframes"; ot->idname= "GRAPH_OT_keyframe_insert"; - ot->description= _("Insert keyframes for the specified channels"); + ot->description= "Insert keyframes for the specified channels"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -529,7 +527,7 @@ void GRAPH_OT_keyframe_insert (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_graphkeys_insertkey_types), 0, "Type", ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_graphkeys_insertkey_types, 0, "Type", ""); } /* ******************** Click-Insert Keyframes Operator ************************* */ @@ -623,9 +621,9 @@ static int graphkeys_click_insert_invoke (bContext *C, wmOperator *op, wmEvent * void GRAPH_OT_click_insert (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Click-Insert Keyframes"); + ot->name= "Click-Insert Keyframes"; ot->idname= "GRAPH_OT_click_insert"; - ot->description= _("Insert new keyframe at the cursor position for the active F-Curve"); + ot->description= "Insert new keyframe at the cursor position for the active F-Curve"; /* api callbacks */ ot->invoke= graphkeys_click_insert_invoke; @@ -636,8 +634,8 @@ void GRAPH_OT_click_insert (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float(ot->srna, "frame", 1.0f, -FLT_MAX, FLT_MAX, _("Frame Number"), _("Frame to insert keyframe on"), 0, 100); - RNA_def_float(ot->srna, "value", 1.0f, -FLT_MAX, FLT_MAX, _("Value"), _("Value for keyframe on"), 0, 100); + RNA_def_float(ot->srna, "frame", 1.0f, -FLT_MAX, FLT_MAX, "Frame Number", "Frame to insert keyframe on", 0, 100); + RNA_def_float(ot->srna, "value", 1.0f, -FLT_MAX, FLT_MAX, "Value", "Value for keyframe on", 0, 100); } /* ******************** Copy/Paste Keyframes Operator ************************* */ @@ -706,9 +704,9 @@ static int graphkeys_copy_exec(bContext *C, wmOperator *op) void GRAPH_OT_copy (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy Keyframes"); + ot->name= "Copy Keyframes"; ot->idname= "GRAPH_OT_copy"; - ot->description= _("Copy selected keyframes to the copy/paste buffer"); + ot->description= "Copy selected keyframes to the copy/paste buffer"; /* api callbacks */ ot->exec= graphkeys_copy_exec; @@ -752,9 +750,9 @@ static int graphkeys_paste_exec(bContext *C, wmOperator *op) void GRAPH_OT_paste (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste Keyframes"); + ot->name= "Paste Keyframes"; ot->idname= "GRAPH_OT_paste"; - ot->description= _("Paste keyframes from copy/paste buffer for the selected channels, starting on the current frame"); + ot->description= "Paste keyframes from copy/paste buffer for the selected channels, starting on the current frame"; /* api callbacks */ // ot->invoke= WM_operator_props_popup; // better wait for graph redo panel @@ -764,8 +762,8 @@ void GRAPH_OT_paste (wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "offset", keyframe_paste_offset_items, KEYFRAME_PASTE_OFFSET_CFRA_START, _("Offset"), _("Paste time offset of keys")); - RNA_def_enum(ot->srna, "merge", keyframe_paste_merge_items, KEYFRAME_PASTE_MERGE_MIX, _("Type"), _("Method of merking pasted keys and existing")); + RNA_def_enum(ot->srna, "offset", keyframe_paste_offset_items, KEYFRAME_PASTE_OFFSET_CFRA_START, "Offset", "Paste time offset of keys"); + RNA_def_enum(ot->srna, "merge", keyframe_paste_merge_items, KEYFRAME_PASTE_MERGE_MIX, "Type", "Method of merking pasted keys and existing"); } /* ******************** Duplicate Keyframes Operator ************************* */ @@ -821,9 +819,9 @@ static int graphkeys_duplicate_invoke(bContext *C, wmOperator *op, wmEvent *UNUS void GRAPH_OT_duplicate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Keyframes"); + ot->name= "Duplicate Keyframes"; ot->idname= "GRAPH_OT_duplicate"; - ot->description= _("Make a copy of all selected keyframes"); + ot->description= "Make a copy of all selected keyframes"; /* api callbacks */ ot->invoke= graphkeys_duplicate_invoke; @@ -834,7 +832,7 @@ void GRAPH_OT_duplicate (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /* ******************** Delete Keyframes Operator ************************* */ @@ -891,9 +889,9 @@ static int graphkeys_delete_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_delete (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Keyframes"); + ot->name= "Delete Keyframes"; ot->idname= "GRAPH_OT_delete"; - ot->description= _("Remove all selected keyframes"); + ot->description= "Remove all selected keyframes"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -953,9 +951,9 @@ static int graphkeys_clean_exec(bContext *C, wmOperator *op) void GRAPH_OT_clean (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clean Keyframes"); + ot->name= "Clean Keyframes"; ot->idname= "GRAPH_OT_clean"; - ot->description= _("Simplify F-Curves by removing closely spaced keyframes"); + ot->description= "Simplify F-Curves by removing closely spaced keyframes"; /* api callbacks */ //ot->invoke= // XXX we need that number popup for this! @@ -966,7 +964,7 @@ void GRAPH_OT_clean (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_float(ot->srna, "threshold", 0.001f, 0.0f, FLT_MAX, _("Threshold"), "", 0.0f, 1000.0f); + ot->prop= RNA_def_float(ot->srna, "threshold", 0.001f, 0.0f, FLT_MAX, "Threshold", "", 0.0f, 1000.0f); } /* ******************** Bake F-Curve Operator *********************** */ @@ -1036,9 +1034,9 @@ static int graphkeys_bake_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_bake (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bake Curve"); + ot->name= "Bake Curve"; ot->idname= "GRAPH_OT_bake"; - ot->description= _("Bake selected F-Curves to a set of sampled points defining a similar curve"); + ot->description= "Bake selected F-Curves to a set of sampled points defining a similar curve"; /* api callbacks */ ot->invoke= WM_operator_confirm; // FIXME... @@ -1179,9 +1177,9 @@ static int graphkeys_sound_bake_invoke (bContext *C, wmOperator *op, wmEvent *ev void GRAPH_OT_sound_bake (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bake Sound to F-Curves"); + ot->name= "Bake Sound to F-Curves"; ot->idname= "GRAPH_OT_sound_bake"; - ot->description= _("Bakes a sound wave to selected F-Curves"); + ot->description= "Bakes a sound wave to selected F-Curves"; /* api callbacks */ ot->invoke= graphkeys_sound_bake_invoke; @@ -1193,15 +1191,15 @@ void GRAPH_OT_sound_bake (wmOperatorType *ot) /* properties */ WM_operator_properties_filesel(ot, FOLDERFILE|SOUNDFILE|MOVIEFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH); - RNA_def_float(ot->srna, "low", 0.0f, 0.0, 100000.0, _("Lowest frequency"), "", 0.1, 1000.00); - RNA_def_float(ot->srna, "high", 100000.0, 0.0, 100000.0, _("Highest frequency"), "", 0.1, 1000.00); - RNA_def_float(ot->srna, "attack", 0.005, 0.0, 2.0, _("Attack time"), "", 0.01, 0.1); - RNA_def_float(ot->srna, "release", 0.2, 0.0, 5.0, _("Release time"), "", 0.01, 0.2); - RNA_def_float(ot->srna, "threshold", 0.0, 0.0, 1.0, _("Threshold"), "", 0.01, 0.1); - RNA_def_boolean(ot->srna, "accumulate", 0, _("Accumulate"), ""); - RNA_def_boolean(ot->srna, "use_additive", 0, _("Additive"), ""); - RNA_def_boolean(ot->srna, "square", 0, _("Square"), ""); - RNA_def_float(ot->srna, "sthreshold", 0.1, 0.0, 1.0, _("Square Threshold"), "", 0.01, 0.1); + RNA_def_float(ot->srna, "low", 0.0f, 0.0, 100000.0, "Lowest frequency", "", 0.1, 1000.00); + RNA_def_float(ot->srna, "high", 100000.0, 0.0, 100000.0, "Highest frequency", "", 0.1, 1000.00); + RNA_def_float(ot->srna, "attack", 0.005, 0.0, 2.0, "Attack time", "", 0.01, 0.1); + RNA_def_float(ot->srna, "release", 0.2, 0.0, 5.0, "Release time", "", 0.01, 0.2); + RNA_def_float(ot->srna, "threshold", 0.0, 0.0, 1.0, "Threshold", "", 0.01, 0.1); + RNA_def_boolean(ot->srna, "accumulate", 0, "Accumulate", ""); + RNA_def_boolean(ot->srna, "use_additive", 0, "Additive", ""); + RNA_def_boolean(ot->srna, "square", 0, "Square", ""); + RNA_def_float(ot->srna, "sthreshold", 0.1, 0.0, 1.0, "Square Threshold", "", 0.01, 0.1); } /* ******************** Sample Keyframes Operator *********************** */ @@ -1253,9 +1251,9 @@ static int graphkeys_sample_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_sample (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sample Keyframes"); + ot->name= "Sample Keyframes"; ot->idname= "GRAPH_OT_sample"; - ot->description= _("Add keyframes on every frame between the selected keyframes"); + ot->description= "Add keyframes on every frame between the selected keyframes"; /* api callbacks */ ot->exec= graphkeys_sample_exec; @@ -1277,8 +1275,8 @@ void GRAPH_OT_sample (wmOperatorType *ot) /* defines for set extrapolation-type for selected keyframes tool */ static EnumPropertyItem prop_graphkeys_expo_types[] = { - {FCURVE_EXTRAPOLATE_CONSTANT, "CONSTANT", 0, N_("Constant Extrapolation"), ""}, - {FCURVE_EXTRAPOLATE_LINEAR, "LINEAR", 0, N_("Linear Extrapolation"), ""}, + {FCURVE_EXTRAPOLATE_CONSTANT, "CONSTANT", 0, "Constant Extrapolation", ""}, + {FCURVE_EXTRAPOLATE_LINEAR, "LINEAR", 0, "Linear Extrapolation", ""}, {MAKE_CYCLIC_EXPO, "MAKE_CYCLIC", 0, "Make Cyclic (F-Modifier)", "Add Cycles F-Modifier if one doesn't exist already"}, {CLEAR_CYCLIC_EXPO, "CLEAR_CYCLIC", 0, "Clear Cyclic (F-Modifier)", "Remove Cycles F-Modifier if not needed anymore"}, @@ -1362,9 +1360,9 @@ static int graphkeys_expo_exec(bContext *C, wmOperator *op) void GRAPH_OT_extrapolation_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Extrapolation"); + ot->name= "Set Keyframe Extrapolation"; ot->idname= "GRAPH_OT_extrapolation_type"; - ot->description= _("Set extrapolation mode for selected F-Curves"); + ot->description= "Set extrapolation mode for selected F-Curves"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1375,7 +1373,7 @@ void GRAPH_OT_extrapolation_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_graphkeys_expo_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_graphkeys_expo_types, 0, "Type", ""); } /* ******************** Set Interpolation-Type Operator *********************** */ @@ -1431,9 +1429,9 @@ static int graphkeys_ipo_exec(bContext *C, wmOperator *op) void GRAPH_OT_interpolation_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Interpolation"); + ot->name= "Set Keyframe Interpolation"; ot->idname= "GRAPH_OT_interpolation_type"; - ot->description= _("Set interpolation mode for the F-Curve segments starting from the selected keyframes"); + ot->description= "Set interpolation mode for the F-Curve segments starting from the selected keyframes"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1444,7 +1442,7 @@ void GRAPH_OT_interpolation_type (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", beztriple_interpolation_mode_items, 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", beztriple_interpolation_mode_items, 0, "Type", ""); } /* ******************** Set Handle-Type Operator *********************** */ @@ -1508,9 +1506,9 @@ static int graphkeys_handletype_exec(bContext *C, wmOperator *op) void GRAPH_OT_handle_type (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Keyframe Handle Type"); + ot->name= "Set Keyframe Handle Type"; ot->idname= "GRAPH_OT_handle_type"; - ot->description= _("Set type of handle for selected keyframes"); + ot->description= "Set type of handle for selected keyframes"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1521,7 +1519,7 @@ static int graphkeys_handletype_exec(bContext *C, wmOperator *op) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(keyframe_handle_type_items), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", keyframe_handle_type_items, 0, "Type", ""); } /* ************************************************************************** */ @@ -1702,9 +1700,9 @@ static int graphkeys_euler_filter_exec (bContext *C, wmOperator *op) void GRAPH_OT_euler_filter (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Euler Discontinuity Filter"); + ot->name= "Euler Discontinuity Filter"; ot->idname= "GRAPH_OT_euler_filter"; - ot->description= _("Fixes the most common causes of gimbal lock in the selected Euler Rotation F-Curves"); + ot->description= "Fixes the most common causes of gimbal lock in the selected Euler Rotation F-Curves"; /* api callbacks */ ot->exec= graphkeys_euler_filter_exec; @@ -1776,9 +1774,9 @@ static int graphkeys_framejump_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_frame_jump (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Jump to Frame"); + ot->name= "Jump to Frame"; ot->idname= "GRAPH_OT_frame_jump"; - ot->description= _("Set the current frame to the average frame of the selected keyframes"); + ot->description= "Set the current frame to the average frame of the selected keyframes"; /* api callbacks */ ot->exec= graphkeys_framejump_exec; @@ -1792,12 +1790,12 @@ void GRAPH_OT_frame_jump (wmOperatorType *ot) /* defines for snap keyframes tool */ static EnumPropertyItem prop_graphkeys_snap_types[] = { - {GRAPHKEYS_SNAP_CFRA, "CFRA", 0, N_("Current Frame"), ""}, - {GRAPHKEYS_SNAP_VALUE, "VALUE", 0, N_("Cursor Value"), ""}, - {GRAPHKEYS_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, N_("Nearest Frame"), ""}, // XXX as single entry? - {GRAPHKEYS_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, N_("Nearest Second"), ""}, // XXX as single entry? - {GRAPHKEYS_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, N_("Nearest Marker"), ""}, - {GRAPHKEYS_SNAP_HORIZONTAL, "HORIZONTAL", 0, N_("Flatten Handles"), ""}, + {GRAPHKEYS_SNAP_CFRA, "CFRA", 0, "Current Frame", ""}, + {GRAPHKEYS_SNAP_VALUE, "VALUE", 0, "Cursor Value", ""}, + {GRAPHKEYS_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, "Nearest Frame", ""}, // XXX as single entry? + {GRAPHKEYS_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, "Nearest Second", ""}, // XXX as single entry? + {GRAPHKEYS_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, "Nearest Marker", ""}, + {GRAPHKEYS_SNAP_HORIZONTAL, "HORIZONTAL", 0, "Flatten Handles", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1880,9 +1878,9 @@ static int graphkeys_snap_exec(bContext *C, wmOperator *op) void GRAPH_OT_snap (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Snap Keys"); + ot->name= "Snap Keys"; ot->idname= "GRAPH_OT_snap"; - ot->description= _("Snap selected keyframes to the chosen times/values"); + ot->description= "Snap selected keyframes to the chosen times/values"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1893,18 +1891,18 @@ void GRAPH_OT_snap (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_graphkeys_snap_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_graphkeys_snap_types, 0, "Type", ""); } /* ******************** Mirror Keyframes Operator *********************** */ /* defines for mirror keyframes tool */ static EnumPropertyItem prop_graphkeys_mirror_types[] = { - {GRAPHKEYS_MIRROR_CFRA, "CFRA", 0, N_("By Times over Current Frame"), ""}, - {GRAPHKEYS_MIRROR_VALUE, "VALUE", 0, N_("By Values over Cursor Value"), ""}, - {GRAPHKEYS_MIRROR_YAXIS, "YAXIS", 0, N_("By Times over Time=0"), ""}, - {GRAPHKEYS_MIRROR_XAXIS, "XAXIS", 0, N_("By Values over Value=0"), ""}, - {GRAPHKEYS_MIRROR_MARKER, "MARKER", 0, N_("By Times over First Selected Marker"), ""}, + {GRAPHKEYS_MIRROR_CFRA, "CFRA", 0, "By Times over Current Frame", ""}, + {GRAPHKEYS_MIRROR_VALUE, "VALUE", 0, "By Values over Cursor Value", ""}, + {GRAPHKEYS_MIRROR_YAXIS, "YAXIS", 0, "By Times over Time=0", ""}, + {GRAPHKEYS_MIRROR_XAXIS, "XAXIS", 0, "By Values over Value=0", ""}, + {GRAPHKEYS_MIRROR_MARKER, "MARKER", 0, "By Times over First Selected Marker", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1998,9 +1996,9 @@ static int graphkeys_mirror_exec(bContext *C, wmOperator *op) void GRAPH_OT_mirror (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mirror Keys"); + ot->name= "Mirror Keys"; ot->idname= "GRAPH_OT_mirror"; - ot->description= _("Flip selected keyframes over the selected mirror line"); + ot->description= "Flip selected keyframes over the selected mirror line"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -2011,7 +2009,7 @@ void GRAPH_OT_mirror (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_graphkeys_mirror_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_graphkeys_mirror_types, 0, "Type", ""); } /* ******************** Smooth Keyframes Operator *********************** */ @@ -2053,9 +2051,9 @@ static int graphkeys_smooth_exec(bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_smooth (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth Keys"); + ot->name= "Smooth Keys"; ot->idname= "GRAPH_OT_smooth"; - ot->description= _("Apply weighted moving means to make selected F-Curves less bumpy"); + ot->description= "Apply weighted moving means to make selected F-Curves less bumpy"; /* api callbacks */ ot->exec= graphkeys_smooth_exec; @@ -2155,9 +2153,9 @@ static int graph_fmodifier_add_exec(bContext *C, wmOperator *op) void GRAPH_OT_fmodifier_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add F-Curve Modifier"); + ot->name= "Add F-Curve Modifier"; ot->idname= "GRAPH_OT_fmodifier_add"; - ot->description= _("Add F-Modifiers to the selected F-Curves"); + ot->description= "Add F-Modifiers to the selected F-Curves"; /* api callbacks */ ot->invoke= graph_fmodifier_add_invoke; @@ -2168,8 +2166,8 @@ void GRAPH_OT_fmodifier_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(fmodifier_type_items), 0, _("Type"), ""); - RNA_def_boolean(ot->srna, "only_active", 1, _("Only Active"), _("Only add F-Modifier to active F-Curve.")); + ot->prop= RNA_def_enum(ot->srna, "type", fmodifier_type_items, 0, "Type", ""); + RNA_def_boolean(ot->srna, "only_active", 1, "Only Active", "Only add F-Modifier to active F-Curve."); } /* ******************** Copy F-Modifiers Operator *********************** */ @@ -2213,9 +2211,9 @@ static int graph_fmodifier_copy_exec(bContext *C, wmOperator *op) void GRAPH_OT_fmodifier_copy (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy F-Modifiers"); + ot->name= "Copy F-Modifiers"; ot->idname= "GRAPH_OT_fmodifier_copy"; - ot->description= _("Copy the F-Modifier(s) of the active F-Curve."); + ot->description= "Copy the F-Modifier(s) of the active F-Curve."; /* api callbacks */ ot->exec= graph_fmodifier_copy_exec; @@ -2275,9 +2273,9 @@ static int graph_fmodifier_paste_exec(bContext *C, wmOperator *op) void GRAPH_OT_fmodifier_paste (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste F-Modifiers"); + ot->name= "Paste F-Modifiers"; ot->idname= "GRAPH_OT_fmodifier_paste"; - ot->description= _("Add copied F-Modifiers to the selected F-Curves"); + ot->description= "Add copied F-Modifiers to the selected F-Curves"; /* api callbacks */ ot->exec= graph_fmodifier_paste_exec; diff --git a/source/blender/editors/space_graph/graph_ops.c b/source/blender/editors/space_graph/graph_ops.c index 00b111f49aa..46918407447 100644 --- a/source/blender/editors/space_graph/graph_ops.c +++ b/source/blender/editors/space_graph/graph_ops.c @@ -40,8 +40,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_main.h" #include "BKE_sound.h" @@ -168,9 +166,9 @@ static int graphview_cursor_modal(bContext *C, wmOperator *op, wmEvent *event) static void GRAPH_OT_cursor_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Cursor"); + ot->name= "Set Cursor"; ot->idname= "GRAPH_OT_cursor_set"; - ot->description= _("Interactively set the current frame number and value cursor"); + ot->description= "Interactively set the current frame number and value cursor"; /* api callbacks */ ot->exec= graphview_cursor_exec; @@ -182,8 +180,8 @@ static void GRAPH_OT_cursor_set(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING|OPTYPE_UNDO; /* rna */ - RNA_def_int(ot->srna, "frame", 0, MINAFRAME, MAXFRAME, _("Frame"), "", MINAFRAME, MAXFRAME); - RNA_def_float(ot->srna, "value", 0, FLT_MIN, FLT_MAX, _("Value"), "", -100.0f, 100.0f); + RNA_def_int(ot->srna, "frame", 0, MINAFRAME, MAXFRAME, "Frame", "", MINAFRAME, MAXFRAME); + RNA_def_float(ot->srna, "value", 0, FLT_MIN, FLT_MAX, "Value", "", -100.0f, 100.0f); } /* Toggle Handles ----------------------------------------------------------------- */ @@ -208,9 +206,9 @@ static int view_toggle_handles_exec (bContext *C, wmOperator *UNUSED(op)) static void GRAPH_OT_view_togglehandles (wmOperatorType *ot) { /* identification */ - ot->name= _("Show/Hide All Handles"); + ot->name= "Show/Hide All Handles"; ot->idname= "GRAPH_OT_handles_view_toggle"; - ot->description= _("Toggle whether handles are drawn on all keyframes that need them"); + ot->description= "Toggle whether handles are drawn on all keyframes that need them"; /* callbacks */ ot->exec= view_toggle_handles_exec; @@ -277,7 +275,7 @@ void ED_operatormacros_graph(void) wmOperatorType *ot; wmOperatorTypeMacro *otmacro; - ot= WM_operatortype_append_macro("GRAPH_OT_duplicate_move", _("Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("GRAPH_OT_duplicate_move", "Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); if (ot) { WM_operatortype_macro_define(ot, "GRAPH_OT_duplicate"); otmacro= WM_operatortype_macro_define(ot, "TRANSFORM_OT_transform"); diff --git a/source/blender/editors/space_graph/graph_select.c b/source/blender/editors/space_graph/graph_select.c index 5e256e77c0d..b8c5d79df18 100644 --- a/source/blender/editors/space_graph/graph_select.c +++ b/source/blender/editors/space_graph/graph_select.c @@ -40,8 +40,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_anim_types.h" #include "DNA_object_types.h" #include "DNA_screen_types.h" @@ -169,9 +167,9 @@ static int graphkeys_deselectall_exec(bContext *C, wmOperator *op) void GRAPH_OT_select_all_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "GRAPH_OT_select_all_toggle"; - ot->description= _("Toggle selection of all keyframes"); + ot->description= "Toggle selection of all keyframes"; /* api callbacks */ ot->exec= graphkeys_deselectall_exec; @@ -181,7 +179,7 @@ void GRAPH_OT_select_all_toggle (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; /* props */ - ot->prop= RNA_def_boolean(ot->srna, "invert", 0, _("Invert"), ""); + ot->prop= RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); } /* ******************** Border Select Operator **************************** */ @@ -338,9 +336,9 @@ static int graphkeys_borderselect_exec(bContext *C, wmOperator *op) void GRAPH_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "GRAPH_OT_select_border"; - ot->description= _("Select all keyframes within the specified region"); + ot->description= "Select all keyframes within the specified region"; /* api callbacks */ ot->invoke= WM_border_select_invoke; @@ -356,8 +354,8 @@ void GRAPH_OT_select_border(wmOperatorType *ot) /* rna */ WM_operator_properties_gesture_border(ot, FALSE); - ot->prop= RNA_def_boolean(ot->srna, "axis_range", 0, _("Axis Range"), ""); - RNA_def_boolean(ot->srna, "include_handles", 0, _("Include Handles"), _("Are handles tested individually against the selection criteria")); + ot->prop= RNA_def_boolean(ot->srna, "axis_range", 0, "Axis Range", ""); + RNA_def_boolean(ot->srna, "include_handles", 0, "Include Handles", "Are handles tested individually against the selection criteria"); } /* ******************** Column Select Operator **************************** */ @@ -370,10 +368,10 @@ void GRAPH_OT_select_border(wmOperatorType *ot) /* defines for column-select mode */ static EnumPropertyItem prop_column_select_types[] = { - {GRAPHKEYS_COLUMNSEL_KEYS, "KEYS", 0, N_("On Selected Keyframes"), ""}, - {GRAPHKEYS_COLUMNSEL_CFRA, "CFRA", 0, N_("On Current Frame"), ""}, - {GRAPHKEYS_COLUMNSEL_MARKERS_COLUMN, "MARKERS_COLUMN", 0, N_("On Selected Markers"), ""}, - {GRAPHKEYS_COLUMNSEL_MARKERS_BETWEEN, "MARKERS_BETWEEN", 0, N_("Between Min/Max Selected Markers"), ""}, + {GRAPHKEYS_COLUMNSEL_KEYS, "KEYS", 0, "On Selected Keyframes", ""}, + {GRAPHKEYS_COLUMNSEL_CFRA, "CFRA", 0, "On Current Frame", ""}, + {GRAPHKEYS_COLUMNSEL_MARKERS_COLUMN, "MARKERS_COLUMN", 0, "On Selected Markers", ""}, + {GRAPHKEYS_COLUMNSEL_MARKERS_BETWEEN, "MARKERS_BETWEEN", 0, "Between Min/Max Selected Markers", ""}, {0, NULL, 0, NULL, NULL} }; @@ -527,9 +525,9 @@ static int graphkeys_columnselect_exec(bContext *C, wmOperator *op) void GRAPH_OT_select_column (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "GRAPH_OT_select_column"; - ot->description= _("Select all keyframes on the specified frame(s)"); + ot->description= "Select all keyframes on the specified frame(s)"; /* api callbacks */ ot->exec= graphkeys_columnselect_exec; @@ -539,7 +537,7 @@ void GRAPH_OT_select_column (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; /* props */ - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_column_select_types), 0, _("Mode"), ""); + ot->prop= RNA_def_enum(ot->srna, "mode", prop_column_select_types, 0, "Mode", ""); } /* ******************** Select Linked Operator *********************** */ @@ -585,9 +583,9 @@ static int graphkeys_select_linked_exec (bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_select_linked (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Linked"); + ot->name = "Select Linked"; ot->idname= "GRAPH_OT_select_linked"; - ot->description = _("Select keyframes occurring the same F-Curves as selected ones"); + ot->description = "Select keyframes occurring the same F-Curves as selected ones"; /* api callbacks */ ot->exec= graphkeys_select_linked_exec; @@ -663,9 +661,9 @@ static int graphkeys_select_more_exec (bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_select_more (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select More"); + ot->name = "Select More"; ot->idname= "GRAPH_OT_select_more"; - ot->description = _("Select keyframes beside already selected ones"); + ot->description = "Select keyframes beside already selected ones"; /* api callbacks */ ot->exec= graphkeys_select_more_exec; @@ -697,9 +695,9 @@ static int graphkeys_select_less_exec (bContext *C, wmOperator *UNUSED(op)) void GRAPH_OT_select_less (wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Less"); + ot->name = "Select Less"; ot->idname= "GRAPH_OT_select_less"; - ot->description = _("Deselect keyframes on ends of selection islands"); + ot->description = "Deselect keyframes on ends of selection islands"; /* api callbacks */ ot->exec= graphkeys_select_less_exec; @@ -714,9 +712,9 @@ void GRAPH_OT_select_less (wmOperatorType *ot) /* defines for left-right select tool */ static EnumPropertyItem prop_graphkeys_leftright_select_types[] = { - {GRAPHKEYS_LRSEL_TEST, "CHECK", 0, N_("Check if Select Left or Right"), ""}, - {GRAPHKEYS_LRSEL_LEFT, "LEFT", 0, N_("Before current frame"), ""}, - {GRAPHKEYS_LRSEL_RIGHT, "RIGHT", 0, N_("After current frame"), ""}, + {GRAPHKEYS_LRSEL_TEST, "CHECK", 0, "Check if Select Left or Right", ""}, + {GRAPHKEYS_LRSEL_LEFT, "LEFT", 0, "Before current frame", ""}, + {GRAPHKEYS_LRSEL_RIGHT, "RIGHT", 0, "After current frame", ""}, {0, NULL, 0, NULL, NULL} }; @@ -837,9 +835,9 @@ static int graphkeys_select_leftright_invoke (bContext *C, wmOperator *op, wmEve void GRAPH_OT_select_leftright (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Left/Right"); + ot->name= "Select Left/Right"; ot->idname= "GRAPH_OT_select_leftright"; - ot->description= _("Select keyframes to the left or the right of the current frame"); + ot->description= "Select keyframes to the left or the right of the current frame"; /* api callbacks */ ot->invoke= graphkeys_select_leftright_invoke; @@ -850,8 +848,8 @@ void GRAPH_OT_select_leftright (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_graphkeys_leftright_select_types), GRAPHKEYS_LRSEL_TEST, _("Mode"), ""); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); + ot->prop= RNA_def_enum(ot->srna, "mode", prop_graphkeys_leftright_select_types, GRAPHKEYS_LRSEL_TEST, "Mode", ""); + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); } /* ******************** Mouse-Click Select Operator *********************** */ @@ -1330,18 +1328,18 @@ static int graphkeys_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *ev void GRAPH_OT_clickselect (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mouse Select Keys"); + ot->name= "Mouse Select Keys"; ot->idname= "GRAPH_OT_clickselect"; - ot->description= _("Select keyframes by clicking on them"); + ot->description= "Select keyframes by clicking on them"; /* api callbacks */ ot->invoke= graphkeys_clickselect_invoke; ot->poll= graphop_visible_keyframes_poll; /* id-props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); // SHIFTKEY - RNA_def_boolean(ot->srna, "column", 0, _("Column Select"), _("Select all keyframes that occur on the same frame as the one under the mouse")); // ALTKEY - RNA_def_boolean(ot->srna, "curves", 0, _("Only Curves"), _("Select all the keyframes in the curve")); // CTRLKEY + ALTKEY + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY + RNA_def_boolean(ot->srna, "column", 0, "Column Select", "Select all keyframes that occur on the same frame as the one under the mouse"); // ALTKEY + RNA_def_boolean(ot->srna, "curves", 0, "Only Curves", "Select all the keyframes in the curve"); // CTRLKEY + ALTKEY } /* ************************************************************************** */ diff --git a/source/blender/editors/space_image/image_buttons.c b/source/blender/editors/space_image/image_buttons.c index 60b3b3ddce0..4011f038be8 100644 --- a/source/blender/editors/space_image/image_buttons.c +++ b/source/blender/editors/space_image/image_buttons.c @@ -47,8 +47,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_colortools.h" #include "BKE_context.h" #include "BKE_customdata.h" @@ -865,9 +863,9 @@ static int image_properties(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); + ot->name= "Properties"; ot->idname= "IMAGE_OT_properties"; - ot->description= _("Toggle display properties panel"); + ot->description= "Toggle display properties panel"; ot->exec= image_properties; ot->poll= ED_operator_image_active; @@ -889,9 +887,9 @@ static int image_scopes(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_scopes(wmOperatorType *ot) { - ot->name= _("Scopes"); + ot->name= "Scopes"; ot->idname= "IMAGE_OT_scopes"; - ot->description= _("Toggle display scopes panel"); + ot->description= "Toggle display scopes panel"; ot->exec= image_scopes; ot->poll= ED_operator_image_active; diff --git a/source/blender/editors/space_image/image_ops.c b/source/blender/editors/space_image/image_ops.c index f4427e55a7d..68f9e4d033e 100644 --- a/source/blender/editors/space_image/image_ops.c +++ b/source/blender/editors/space_image/image_ops.c @@ -41,8 +41,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_object_types.h" #include "DNA_node_types.h" #include "DNA_packedFile_types.h" @@ -290,7 +288,7 @@ static int view_pan_cancel(bContext *C, wmOperator *op) void IMAGE_OT_view_pan(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Pan"); + ot->name= "View Pan"; ot->idname= "IMAGE_OT_view_pan"; /* api callbacks */ @@ -305,7 +303,7 @@ void IMAGE_OT_view_pan(wmOperatorType *ot) /* properties */ RNA_def_float_vector(ot->srna, "offset", 2, NULL, -FLT_MAX, FLT_MAX, - _("Offset"), _("Offset in floating point units, 1.0 is the width and height of the image."), -FLT_MAX, FLT_MAX); + "Offset", "Offset in floating point units, 1.0 is the width and height of the image.", -FLT_MAX, FLT_MAX); } /********************** view zoom operator *********************/ @@ -421,7 +419,7 @@ static int view_zoom_cancel(bContext *C, wmOperator *op) void IMAGE_OT_view_zoom(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Zoom"); + ot->name= "View Zoom"; ot->idname= "IMAGE_OT_view_zoom"; /* api callbacks */ @@ -436,7 +434,7 @@ void IMAGE_OT_view_zoom(wmOperatorType *ot) /* properties */ RNA_def_float(ot->srna, "factor", 0.0f, 0.0f, FLT_MAX, - _("Factor"), _("Zoom factor, values higher than 1.0 zoom in, lower values zoom out."), -FLT_MAX, FLT_MAX); + "Factor", "Zoom factor, values higher than 1.0 zoom in, lower values zoom out.", -FLT_MAX, FLT_MAX); } /********************** NDOF operator *********************/ @@ -542,7 +540,7 @@ static int view_all_exec(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_view_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "IMAGE_OT_view_all"; /* api callbacks */ @@ -603,7 +601,7 @@ static int view_selected_poll(bContext *C) void IMAGE_OT_view_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Center"); + ot->name= "View Center"; ot->idname= "IMAGE_OT_view_selected"; /* api callbacks */ @@ -628,7 +626,7 @@ static int view_zoom_in_exec(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_view_zoom_in(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Zoom In"); + ot->name= "View Zoom In"; ot->idname= "IMAGE_OT_view_zoom_in"; /* api callbacks */ @@ -651,7 +649,7 @@ static int view_zoom_out_exec(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_view_zoom_out(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Zoom Out"); + ot->name= "View Zoom Out"; ot->idname= "IMAGE_OT_view_zoom_out"; /* api callbacks */ @@ -689,7 +687,7 @@ static int view_zoom_ratio_exec(bContext *C, wmOperator *op) void IMAGE_OT_view_zoom_ratio(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Zoom Ratio"); + ot->name= "View Zoom Ratio"; ot->idname= "IMAGE_OT_view_zoom_ratio"; /* api callbacks */ @@ -698,18 +696,18 @@ void IMAGE_OT_view_zoom_ratio(wmOperatorType *ot) /* properties */ RNA_def_float(ot->srna, "ratio", 0.0f, 0.0f, FLT_MAX, - _("Ratio"), _("Zoom ratio, 1.0 is 1:1, higher is zoomed in, lower is zoomed out."), -FLT_MAX, FLT_MAX); + "Ratio", "Zoom ratio, 1.0 is 1:1, higher is zoomed in, lower is zoomed out.", -FLT_MAX, FLT_MAX); } /**************** load/replace/save callbacks ******************/ /* XXX make dynamic */ static const EnumPropertyItem image_file_type_items[] = { - {R_TARGA, "TARGA", 0, N_("Targa"), ""}, - {R_RAWTGA, "TARGA RAW", 0, N_("Targa Raw"), ""}, + {R_TARGA, "TARGA", 0, "Targa", ""}, + {R_RAWTGA, "TARGA RAW", 0, "Targa Raw", ""}, {R_PNG, "PNG", 0, "PNG", ""}, #ifdef WITH_DDS - {R_DDS, "DDS", 0, N_("DirectDraw Surface"), ""}, + {R_DDS, "DDS", 0, "DirectDraw Surface", ""}, #endif {R_BMP, "BMP", 0, "BMP", ""}, {R_JPEG90, "JPEG", 0, "Jpeg", ""}, @@ -721,10 +719,10 @@ static const EnumPropertyItem image_file_type_items[] = { {R_TIFF, "TIFF", 0, "Tiff", ""}, #endif #ifdef WITH_DDS - {R_RADHDR, "RADIANCE_HDR", 0, N_("Radiance HDR"), ""}, + {R_RADHDR, "RADIANCE_HDR", 0, "Radiance HDR", ""}, #endif #ifdef WITH_CINEON - {R_CINEON, "CINEON", 0, N_("Cineon"), ""}, + {R_CINEON, "CINEON", 0, "Cineon", ""}, {R_DPX, "DPX", 0, "DPX", ""}, #endif #ifdef WITH_OPENEXR @@ -864,8 +862,8 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void IMAGE_OT_open(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Open Image"); - ot->description= _("Open image"); + ot->name= "Open Image"; + ot->description= "Open image"; ot->idname= "IMAGE_OT_open"; /* api callbacks */ @@ -923,7 +921,7 @@ static int replace_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void IMAGE_OT_replace(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Replace Image"); + ot->name= "Replace Image"; ot->idname= "IMAGE_OT_replace"; /* api callbacks */ @@ -1195,7 +1193,7 @@ void IMAGE_OT_save_as(wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Save As Image"); + ot->name= "Save As Image"; ot->idname= "IMAGE_OT_save_as"; /* api callbacks */ @@ -1210,14 +1208,14 @@ void IMAGE_OT_save_as(wmOperatorType *ot) /* properties */ /* format options */ - RNA_def_enum(ot->srna, "file_format", image_file_type_items, R_PNG, _("File Type"), _("File type to save image as.")); - RNA_def_enum(ot->srna, "color_mode", image_color_mode_items, R_PLANES24, _("Channels"), _("Image channels to save")); - prop= RNA_def_int(ot->srna, "file_quality", 90, 0, 100, _("Quality"), "", 0, 100); + RNA_def_enum(ot->srna, "file_format", image_file_type_items, R_PNG, "File Type", "File type to save image as."); + RNA_def_enum(ot->srna, "color_mode", image_color_mode_items, R_PLANES24, "Channels", "Image channels to save"); + prop= RNA_def_int(ot->srna, "file_quality", 90, 0, 100, "Quality", "", 0, 100); RNA_def_property_subtype(prop, PROP_PERCENTAGE); WM_operator_properties_filesel(ot, FOLDERFILE|IMAGEFILE|MOVIEFILE, FILE_SPECIAL, FILE_SAVE, WM_FILESEL_FILEPATH|WM_FILESEL_RELPATH); - RNA_def_boolean(ot->srna, "copy", 0, _("Copy"), _("Create a new image file without modifying the current image in blender")); + RNA_def_boolean(ot->srna, "copy", 0, "Copy", "Create a new image file without modifying the current image in blender"); } /******************** save image operator ********************/ @@ -1246,7 +1244,7 @@ static int save_exec(bContext *C, wmOperator *op) void IMAGE_OT_save(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Save Image"); + ot->name= "Save Image"; ot->idname= "IMAGE_OT_save"; /* api callbacks */ @@ -1323,7 +1321,7 @@ static int save_sequence_exec(bContext *C, wmOperator *op) void IMAGE_OT_save_sequence(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Save Sequence"); + ot->name= "Save Sequence"; ot->idname= "IMAGE_OT_save_sequence"; /* api callbacks */ @@ -1358,7 +1356,7 @@ static int reload_exec(bContext *C, wmOperator *UNUSED(op)) void IMAGE_OT_reload(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reload Image"); + ot->name= "Reload Image"; ot->idname= "IMAGE_OT_reload"; /* api callbacks */ @@ -1440,8 +1438,8 @@ void IMAGE_OT_new(wmOperatorType *ot) static float default_color[4]= {0.0f, 0.0f, 0.0f, 1.0f}; /* identifiers */ - ot->name= _("New Image"); - ot->description= _("Create a new image"); + ot->name= "New Image"; + ot->description= "Create a new image"; ot->idname= "IMAGE_OT_new"; /* api callbacks */ @@ -1452,14 +1450,14 @@ void IMAGE_OT_new(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_string(ot->srna, "name", "untitled", MAX_ID_NAME-2, _("Name"), _("Image datablock name.")); - RNA_def_int(ot->srna, "width", 1024, 1, INT_MAX, _("Width"), _("Image width."), 1, 16384); - RNA_def_int(ot->srna, "height", 1024, 1, INT_MAX, _("Height"), _("Image height."), 1, 16384); - prop= RNA_def_float_color(ot->srna, "color", 4, NULL, 0.0f, FLT_MAX, _("Color"), _("Default fill color."), 0.0f, 1.0f); + RNA_def_string(ot->srna, "name", "untitled", MAX_ID_NAME-2, "Name", "Image datablock name."); + RNA_def_int(ot->srna, "width", 1024, 1, INT_MAX, "Width", "Image width.", 1, 16384); + RNA_def_int(ot->srna, "height", 1024, 1, INT_MAX, "Height", "Image height.", 1, 16384); + prop= RNA_def_float_color(ot->srna, "color", 4, NULL, 0.0f, FLT_MAX, "Color", "Default fill color.", 0.0f, 1.0f); RNA_def_property_float_array_default(prop, default_color); - RNA_def_boolean(ot->srna, "alpha", 1, _("Alpha"), _("Create an image with an alpha channel.")); - RNA_def_boolean(ot->srna, "uv_test_grid", 0, _("UV Test Grid"), _("Fill the image with a grid for UV map testing.")); - RNA_def_boolean(ot->srna, "float", 0, _("32 bit Float"), _("Create image with 32 bit floating point bit depth.")); + RNA_def_boolean(ot->srna, "alpha", 1, "Alpha", "Create an image with an alpha channel."); + RNA_def_boolean(ot->srna, "uv_test_grid", 0, "UV Test Grid", "Fill the image with a grid for UV map testing."); + RNA_def_boolean(ot->srna, "float", 0, "32 bit Float", "Create image with 32 bit floating point bit depth."); } /********************* invert operators *********************/ @@ -1530,7 +1528,7 @@ static int image_invert_exec(bContext *C, wmOperator *op) void IMAGE_OT_invert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Invert Channels"); + ot->name= "Invert Channels"; ot->idname= "IMAGE_OT_invert"; /* api callbacks */ @@ -1538,10 +1536,10 @@ void IMAGE_OT_invert(wmOperatorType *ot) ot->poll= image_invert_poll; /* properties */ - RNA_def_boolean(ot->srna, "invert_r", 0, _("Red"), _("Invert Red Channel")); - RNA_def_boolean(ot->srna, "invert_g", 0, _("Green"), _("Invert Green Channel")); - RNA_def_boolean(ot->srna, "invert_b", 0, _("Blue"), _("Invert Blue Channel")); - RNA_def_boolean(ot->srna, "invert_a", 0, _("Alpha"), _("Invert Alpha Channel")); + RNA_def_boolean(ot->srna, "invert_r", 0, "Red", "Invert Red Channel"); + RNA_def_boolean(ot->srna, "invert_g", 0, "Green", "Invert Green Channel"); + RNA_def_boolean(ot->srna, "invert_b", 0, "Blue", "Invert Blue Channel"); + RNA_def_boolean(ot->srna, "invert_a", 0, "Alpha", "Invert Alpha Channel"); /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1617,8 +1615,8 @@ static int pack_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void IMAGE_OT_pack(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Pack Image"); - ot->description= _("Pack an image as embedded data into the .blend file"); + ot->name= "Pack Image"; + ot->description= "Pack an image as embedded data into the .blend file"; ot->idname= "IMAGE_OT_pack"; /* api callbacks */ @@ -1629,7 +1627,7 @@ void IMAGE_OT_pack(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "as_png", 0, _("Pack As PNG"), _("Pack image as lossless PNG.")); + RNA_def_boolean(ot->srna, "as_png", 0, "Pack As PNG", "Pack image as lossless PNG."); } /********************* unpack operator *********************/ @@ -1694,8 +1692,8 @@ static int image_unpack_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(even void IMAGE_OT_unpack(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Unpack Image"); - ot->description= _("Save an image packed in the .blend file to disk"); + ot->name= "Unpack Image"; + ot->description= "Save an image packed in the .blend file to disk"; ot->idname= "IMAGE_OT_unpack"; /* api callbacks */ @@ -1706,8 +1704,8 @@ void IMAGE_OT_unpack(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "method", unpack_method_items, PF_USE_LOCAL, _("Method"), _("How to unpack.")); - RNA_def_string(ot->srna, "id", "", MAX_ID_NAME-2, _("Image Name"), _("Image datablock name to unpack.")); /* XXX, weark!, will fail with library, name collisions */ + RNA_def_enum(ot->srna, "method", unpack_method_items, PF_USE_LOCAL, "Method", "How to unpack."); + RNA_def_string(ot->srna, "id", "", MAX_ID_NAME-2, "Image Name", "Image datablock name to unpack."); /* XXX, weark!, will fail with library, name collisions */ } /******************** sample image operator ********************/ @@ -1904,7 +1902,7 @@ static int sample_cancel(bContext *C, wmOperator *op) void IMAGE_OT_sample(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sample Color"); + ot->name= "Sample Color"; ot->idname= "IMAGE_OT_sample"; /* api callbacks */ @@ -2012,7 +2010,7 @@ static int sample_line_invoke(bContext *C, wmOperator *op, wmEvent *event) void IMAGE_OT_sample_line(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sample Line"); + ot->name= "Sample Line"; ot->idname= "IMAGE_OT_sample_line"; /* api callbacks */ @@ -2033,12 +2031,12 @@ void IMAGE_OT_sample_line(wmOperatorType *ot) void IMAGE_OT_curves_point_set(wmOperatorType *ot) { static EnumPropertyItem point_items[]= { - {0, "BLACK_POINT", 0, N_("Black Point"), ""}, - {1, "WHITE_POINT", 0, N_("White Point"), ""}, + {0, "BLACK_POINT", 0, "Black Point", ""}, + {1, "WHITE_POINT", 0, "White Point", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Set Curves Point"); + ot->name= "Set Curves Point"; ot->idname= "IMAGE_OT_curves_point_set"; /* flags */ @@ -2051,7 +2049,7 @@ void IMAGE_OT_curves_point_set(wmOperatorType *ot) ot->poll= space_image_main_area_poll; /* properties */ - RNA_def_enum(ot->srna, "point", RNA_enum_items_gettexted(point_items), 0, _("Point"), _("Set black point or white point for curves.")); + RNA_def_enum(ot->srna, "point", point_items, 0, "Point", "Set black point or white point for curves."); } /******************** record composite operator *********************/ @@ -2192,7 +2190,7 @@ static int record_composite_cancel(bContext *C, wmOperator *op) void IMAGE_OT_record_composite(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Record Composite"); + ot->name= "Record Composite"; ot->idname= "IMAGE_OT_record_composite"; /* api callbacks */ @@ -2247,7 +2245,7 @@ static int cycle_render_slot_exec(bContext *C, wmOperator *op) void IMAGE_OT_cycle_render_slot(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cycle Render Slot"); + ot->name= "Cycle Render Slot"; ot->idname= "IMAGE_OT_cycle_render_slot"; /* api callbacks */ @@ -2257,7 +2255,7 @@ void IMAGE_OT_cycle_render_slot(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "reverse", 0, _("Cycle in Reverse"), ""); + RNA_def_boolean(ot->srna, "reverse", 0, "Cycle in Reverse", ""); } /******************** TODO ********************/ diff --git a/source/blender/editors/space_info/info_ops.c b/source/blender/editors/space_info/info_ops.c index 4aeb75eb7cb..e09565d38e9 100644 --- a/source/blender/editors/space_info/info_ops.c +++ b/source/blender/editors/space_info/info_ops.c @@ -45,8 +45,6 @@ #include "BLI_bpath.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_global.h" #include "BKE_image.h" @@ -213,7 +211,7 @@ static int make_paths_relative_exec(bContext *C, wmOperator *op) void FILE_OT_make_paths_relative(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make All Paths Relative"); + ot->name= "Make All Paths Relative"; ot->idname= "FILE_OT_make_paths_relative"; /* api callbacks */ @@ -245,7 +243,7 @@ static int make_paths_absolute_exec(bContext *C, wmOperator *op) void FILE_OT_make_paths_absolute(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make All Paths Absolute"); + ot->name= "Make All Paths Absolute"; ot->idname= "FILE_OT_make_paths_absolute"; /* api callbacks */ @@ -268,7 +266,7 @@ static int report_missing_files_exec(bContext *UNUSED(C), wmOperator *op) void FILE_OT_report_missing_files(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Report Missing Files"); + ot->name= "Report Missing Files"; ot->idname= "FILE_OT_report_missing_files"; /* api callbacks */ @@ -301,7 +299,7 @@ static int find_missing_files_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE void FILE_OT_find_missing_files(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Find Missing Files"); + ot->name= "Find Missing Files"; ot->idname= "FILE_OT_find_missing_files"; /* api callbacks */ @@ -412,7 +410,7 @@ static int update_reports_display_invoke(bContext *C, wmOperator *UNUSED(op), wm void INFO_OT_reports_display_update(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Update Reports Display"); + ot->name= "Update Reports Display"; ot->idname= "INFO_OT_reports_display_update"; /* api callbacks */ diff --git a/source/blender/editors/space_info/info_report.c b/source/blender/editors/space_info/info_report.c index ed8b66ad23a..c8bda434227 100644 --- a/source/blender/editors/space_info/info_report.c +++ b/source/blender/editors/space_info/info_report.c @@ -37,8 +37,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "WM_api.h" @@ -162,7 +160,7 @@ void INFO_OT_select_pick(wmOperatorType *ot) /* ot->flag= OPTYPE_REGISTER; */ /* properties */ - RNA_def_int(ot->srna, "report_index", 0, 0, INT_MAX, _("Report"), _("The index of the report."), 0, INT_MAX); + RNA_def_int(ot->srna, "report_index", 0, 0, INT_MAX, "Report", "The index of the report.", 0, INT_MAX); } diff --git a/source/blender/editors/space_info/space_info.c b/source/blender/editors/space_info/space_info.c index beb9f7dc589..1e8a90d0904 100644 --- a/source/blender/editors/space_info/space_info.c +++ b/source/blender/editors/space_info/space_info.c @@ -290,7 +290,7 @@ static void recent_files_menu_register(void) mt= MEM_callocN(sizeof(MenuType), "spacetype info menu recent files"); strcpy(mt->idname, "INFO_MT_file_open_recent"); - strcpy(mt->label, _("Open Recent...")); + strcpy(mt->label, "Open Recent..."); mt->draw= recent_files_menu_draw; WM_menutype_add(mt); } diff --git a/source/blender/editors/space_logic/logic_buttons.c b/source/blender/editors/space_logic/logic_buttons.c index dc2c5cb461a..16e916928a9 100644 --- a/source/blender/editors/space_logic/logic_buttons.c +++ b/source/blender/editors/space_logic/logic_buttons.c @@ -35,8 +35,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_screen.h" @@ -120,8 +118,8 @@ static int logic_properties(bContext *C, wmOperator *UNUSED(op)) void LOGIC_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); - ot->description= _("Toggle display properties panel"); + ot->name= "Properties"; + ot->description= "Toggle display properties panel"; ot->idname= "LOGIC_OT_properties"; ot->exec= logic_properties; @@ -201,9 +199,9 @@ void LOGIC_OT_links_cut(wmOperatorType *ot) { PropertyRNA *prop; - ot->name= _("Cut links"); + ot->name= "Cut links"; ot->idname= "LOGIC_OT_links_cut"; - ot->description= _("Remove logic brick connections"); + ot->description= "Remove logic brick connections"; ot->invoke= WM_gesture_lines_invoke; ot->modal= WM_gesture_lines_modal; @@ -218,6 +216,6 @@ void LOGIC_OT_links_cut(wmOperatorType *ot) prop= RNA_def_property(ot->srna, "path", PROP_COLLECTION, PROP_NONE); RNA_def_property_struct_runtime(prop, &RNA_OperatorMousePath); /* internal */ - RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, _("Cursor"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, "Cursor", "", 0, INT_MAX); } diff --git a/source/blender/editors/space_nla/nla_buttons.c b/source/blender/editors/space_nla/nla_buttons.c index afb5027c81e..d10e47962f9 100644 --- a/source/blender/editors/space_nla/nla_buttons.c +++ b/source/blender/editors/space_nla/nla_buttons.c @@ -528,9 +528,9 @@ static int nla_properties(bContext *C, wmOperator *UNUSED(op)) void NLA_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); + ot->name= "Properties"; ot->idname= "NLA_OT_properties"; - ot->description= _("Toggle display properties panel"); + ot->description= "Toggle display properties panel"; ot->exec= nla_properties; ot->poll= ED_operator_nla_active; diff --git a/source/blender/editors/space_nla/nla_channels.c b/source/blender/editors/space_nla/nla_channels.c index b10af5b573d..8775d256b80 100644 --- a/source/blender/editors/space_nla/nla_channels.c +++ b/source/blender/editors/space_nla/nla_channels.c @@ -43,8 +43,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_animsys.h" #include "BKE_nla.h" #include "BKE_context.h" @@ -346,9 +344,9 @@ static int nlachannels_mouseclick_invoke(bContext *C, wmOperator *op, wmEvent *e void NLA_OT_channels_click (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mouse Click on NLA Channels"); + ot->name= "Mouse Click on NLA Channels"; ot->idname= "NLA_OT_channels_click"; - ot->description= _("Handle clicks to select NLA channels"); + ot->description= "Handle clicks to select NLA channels"; /* api callbacks */ ot->invoke= nlachannels_mouseclick_invoke; @@ -358,7 +356,7 @@ void NLA_OT_channels_click (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); // SHIFTKEY + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY } /* *********************************************** */ @@ -420,9 +418,9 @@ static int nlaedit_add_tracks_exec (bContext *C, wmOperator *op) void NLA_OT_tracks_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Track(s)"); + ot->name= "Add Track(s)"; ot->idname= "NLA_OT_tracks_add"; - ot->description= _("Add NLA-Tracks above/after the selected tracks"); + ot->description= "Add NLA-Tracks above/after the selected tracks"; /* api callbacks */ ot->exec= nlaedit_add_tracks_exec; @@ -432,7 +430,7 @@ void NLA_OT_tracks_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "above_selected", 0, _("Above Selected"), _("Add a new NLA Track above every existing selected one.")); + RNA_def_boolean(ot->srna, "above_selected", 0, "Above Selected", "Add a new NLA Track above every existing selected one."); } /* ******************** Delete Tracks Operator ***************************** */ @@ -484,9 +482,9 @@ static int nlaedit_delete_tracks_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_delete_tracks (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Tracks"); + ot->name= "Delete Tracks"; ot->idname= "NLA_OT_delete_tracks"; - ot->description= _("Delete selected NLA-Tracks and the strips they contain"); + ot->description= "Delete selected NLA-Tracks and the strips they contain"; /* api callbacks */ ot->exec= nlaedit_delete_tracks_exec; diff --git a/source/blender/editors/space_nla/nla_edit.c b/source/blender/editors/space_nla/nla_edit.c index 70333fb00dd..08026e8a1d2 100644 --- a/source/blender/editors/space_nla/nla_edit.c +++ b/source/blender/editors/space_nla/nla_edit.c @@ -44,8 +44,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_action.h" #include "BKE_fcurve.h" #include "BKE_nla.h" @@ -160,9 +158,9 @@ static int nlaedit_enable_tweakmode_exec (bContext *C, wmOperator *op) void NLA_OT_tweakmode_enter (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Enter Tweak Mode"); + ot->name= "Enter Tweak Mode"; ot->idname= "NLA_OT_tweakmode_enter"; - ot->description= _("Enter tweaking mode for the action referenced by the active strip"); + ot->description= "Enter tweaking mode for the action referenced by the active strip"; /* api callbacks */ ot->exec= nlaedit_enable_tweakmode_exec; @@ -225,9 +223,9 @@ static int nlaedit_disable_tweakmode_exec (bContext *C, wmOperator *op) void NLA_OT_tweakmode_exit (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Exit Tweak Mode"); + ot->name= "Exit Tweak Mode"; ot->idname= "NLA_OT_tweakmode_exit"; - ot->description= _("Exit tweaking mode for the action referenced by the active strip"); + ot->description= "Exit tweaking mode for the action referenced by the active strip"; /* api callbacks */ ot->exec= nlaedit_disable_tweakmode_exec; @@ -475,9 +473,9 @@ void NLA_OT_actionclip_add (wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Add Action Strip"); + ot->name= "Add Action Strip"; ot->idname= "NLA_OT_actionclip_add"; - ot->description= _("Add an Action-Clip strip (i.e. an NLA Strip referencing an Action) to the active track"); + ot->description= "Add an Action-Clip strip (i.e. an NLA Strip referencing an Action) to the active track"; /* api callbacks */ ot->invoke= WM_enum_search_invoke; @@ -489,7 +487,7 @@ void NLA_OT_actionclip_add (wmOperatorType *ot) /* props */ // TODO: this would be nicer as an ID-pointer... - prop= RNA_def_enum(ot->srna, "action", DummyRNA_NULL_items, 0, _("Action"), ""); + prop= RNA_def_enum(ot->srna, "action", DummyRNA_NULL_items, 0, "Action", ""); RNA_def_enum_funcs(prop, RNA_action_itemf); ot->prop= prop; } @@ -600,9 +598,9 @@ static int nlaedit_add_transition_exec (bContext *C, wmOperator *op) void NLA_OT_transition_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Transition"); + ot->name= "Add Transition"; ot->idname= "NLA_OT_transition_add"; - ot->description= _("Add a transition strip between two adjacent selected strips"); + ot->description= "Add a transition strip between two adjacent selected strips"; /* api callbacks */ ot->exec= nlaedit_add_transition_exec; @@ -747,9 +745,9 @@ static int nlaedit_add_meta_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_meta_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Meta-Strips"); + ot->name= "Add Meta-Strips"; ot->idname= "NLA_OT_meta_add"; - ot->description= _("Add new meta-strips incorporating the selected strips"); + ot->description= "Add new meta-strips incorporating the selected strips"; /* api callbacks */ ot->exec= nlaedit_add_meta_exec; @@ -799,9 +797,9 @@ static int nlaedit_remove_meta_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_meta_remove (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Remove Meta-Strips"); + ot->name= "Remove Meta-Strips"; ot->idname= "NLA_OT_meta_remove"; - ot->description= _("Separate out the strips held by the selected meta-strips"); + ot->description= "Separate out the strips held by the selected meta-strips"; /* api callbacks */ ot->exec= nlaedit_remove_meta_exec; @@ -902,9 +900,9 @@ static int nlaedit_duplicate_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED void NLA_OT_duplicate (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Strips"); + ot->name= "Duplicate Strips"; ot->idname= "NLA_OT_duplicate"; - ot->description= _("Duplicate selected NLA-Strips, adding the new strips in new tracks above the originals"); + ot->description= "Duplicate selected NLA-Strips, adding the new strips in new tracks above the originals"; /* api callbacks */ ot->invoke= nlaedit_duplicate_invoke; @@ -915,7 +913,7 @@ void NLA_OT_duplicate (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /* ******************** Delete Strips Operator ***************************** */ @@ -977,9 +975,9 @@ static int nlaedit_delete_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_delete (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete Strips"); + ot->name= "Delete Strips"; ot->idname= "NLA_OT_delete"; - ot->description= _("Delete selected strips"); + ot->description= "Delete selected strips"; /* api callbacks */ ot->exec= nlaedit_delete_exec; @@ -1122,9 +1120,9 @@ static int nlaedit_split_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_split (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Split Strips"); + ot->name= "Split Strips"; ot->idname= "NLA_OT_split"; - ot->description= _("Split selected strips at their midpoints"); + ot->description= "Split selected strips at their midpoints"; /* api callbacks */ ot->exec= nlaedit_split_exec; @@ -1175,9 +1173,9 @@ static int nlaedit_bake_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_bake (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Bake Strips"); + ot->name= "Bake Strips"; ot->idname= "NLA_OT_bake"; - ot->description= _("Bake all strips of selected AnimData blocks"); + ot->description= "Bake all strips of selected AnimData blocks"; /* api callbacks */ ot->exec= nlaedit_bake_exec; @@ -1237,9 +1235,9 @@ static int nlaedit_toggle_mute_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_mute_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Muting"); + ot->name= "Toggle Muting"; ot->idname= "NLA_OT_mute_toggle"; - ot->description= _("Mute or un-mute selected strips"); + ot->description= "Mute or un-mute selected strips"; /* api callbacks */ ot->exec= nlaedit_toggle_mute_exec; @@ -1395,9 +1393,9 @@ static int nlaedit_swap_exec (bContext *C, wmOperator *op) void NLA_OT_swap (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Swap Strips"); + ot->name= "Swap Strips"; ot->idname= "NLA_OT_swap"; - ot->description= _("Swap order of selected strips within tracks"); + ot->description= "Swap order of selected strips within tracks"; /* api callbacks */ ot->exec= nlaedit_swap_exec; @@ -1469,9 +1467,9 @@ static int nlaedit_move_up_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_move_up (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Strips Up"); + ot->name= "Move Strips Up"; ot->idname= "NLA_OT_move_up"; - ot->description= _("Move selected strips up a track if there's room"); + ot->description= "Move selected strips up a track if there's room"; /* api callbacks */ ot->exec= nlaedit_move_up_exec; @@ -1543,9 +1541,9 @@ static int nlaedit_move_down_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_move_down (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Strips Down"); + ot->name= "Move Strips Down"; ot->idname= "NLA_OT_move_down"; - ot->description= _("Move selected strips down a track if there's room"); + ot->description= "Move selected strips down a track if there's room"; /* api callbacks */ ot->exec= nlaedit_move_down_exec; @@ -1619,9 +1617,9 @@ static int nlaedit_sync_actlen_exec (bContext *C, wmOperator *op) void NLA_OT_action_sync_length (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sync Action Length"); + ot->name= "Sync Action Length"; ot->idname= "NLA_OT_action_sync_length"; - ot->description= _("Synchronise the length of the referenced Action with the lengths used in the strip"); + ot->description= "Synchronise the length of the referenced Action with the lengths used in the strip"; /* api callbacks */ ot->exec= nlaedit_sync_actlen_exec; @@ -1631,7 +1629,7 @@ void NLA_OT_action_sync_length (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_boolean(ot->srna, "active", 1, _("Active Strip Only"), _("Only sync the active length for the active strip.")); + ot->prop= RNA_def_boolean(ot->srna, "active", 1, "Active Strip Only", "Only sync the active length for the active strip."); } /* ******************** Apply Scale Operator ***************************** */ @@ -1719,9 +1717,9 @@ static int nlaedit_apply_scale_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_apply_scale (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Apply Scale"); + ot->name= "Apply Scale"; ot->idname= "NLA_OT_apply_scale"; - ot->description= _("Apply scaling of selected strips to their referenced Actions"); + ot->description= "Apply scaling of selected strips to their referenced Actions"; /* api callbacks */ ot->exec= nlaedit_apply_scale_exec; @@ -1782,9 +1780,9 @@ static int nlaedit_clear_scale_exec (bContext *C, wmOperator *UNUSED(op)) void NLA_OT_clear_scale (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear Scale"); + ot->name= "Clear Scale"; ot->idname= "NLA_OT_clear_scale"; - ot->description= _("Reset scaling of selected strips"); + ot->description= "Reset scaling of selected strips"; /* api callbacks */ ot->exec= nlaedit_clear_scale_exec; @@ -1799,10 +1797,10 @@ void NLA_OT_clear_scale (wmOperatorType *ot) /* defines for snap keyframes tool */ static EnumPropertyItem prop_nlaedit_snap_types[] = { - {NLAEDIT_SNAP_CFRA, "CFRA", 0, N_("Current frame"), ""}, - {NLAEDIT_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, N_("Nearest Frame"), ""}, // XXX as single entry? - {NLAEDIT_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, N_("Nearest Second"), ""}, // XXX as single entry? - {NLAEDIT_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, N_("Nearest Marker"), ""}, + {NLAEDIT_SNAP_CFRA, "CFRA", 0, "Current frame", ""}, + {NLAEDIT_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, "Nearest Frame", ""}, // XXX as single entry? + {NLAEDIT_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, "Nearest Second", ""}, // XXX as single entry? + {NLAEDIT_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, "Nearest Marker", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1923,9 +1921,9 @@ static int nlaedit_snap_exec (bContext *C, wmOperator *op) void NLA_OT_snap (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Snap Strips"); + ot->name= "Snap Strips"; ot->idname= "NLA_OT_snap"; - ot->description= _("Move start of strips to specified time"); + ot->description= "Move start of strips to specified time"; /* api callbacks */ ot->invoke= WM_menu_invoke; @@ -1936,7 +1934,7 @@ void NLA_OT_snap (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_nlaedit_snap_types), 0, _("Type"), ""); + ot->prop= RNA_def_enum(ot->srna, "type", prop_nlaedit_snap_types, 0, "Type", ""); } /* *********************************************** */ @@ -2042,9 +2040,9 @@ static int nla_fmodifier_add_exec(bContext *C, wmOperator *op) void NLA_OT_fmodifier_add (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add F-Modifier"); + ot->name= "Add F-Modifier"; ot->idname= "NLA_OT_fmodifier_add"; - ot->description= _("Add F-Modifier of the specified type to the selected NLA-Strips"); + ot->description= "Add F-Modifier of the specified type to the selected NLA-Strips"; /* api callbacks */ ot->invoke= nla_fmodifier_add_invoke; @@ -2055,8 +2053,8 @@ void NLA_OT_fmodifier_add (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "type", fmodifier_type_items, 0, _("Type"), ""); - RNA_def_boolean(ot->srna, "only_active", 0, _("Only Active"), _("Only add F-Modifier of the specified type to the active strip.")); + ot->prop= RNA_def_enum(ot->srna, "type", fmodifier_type_items, 0, "Type", ""); + RNA_def_boolean(ot->srna, "only_active", 0, "Only Active", "Only add F-Modifier of the specified type to the active strip."); } /* ******************** Copy F-Modifiers Operator *********************** */ @@ -2106,9 +2104,9 @@ static int nla_fmodifier_copy_exec(bContext *C, wmOperator *op) void NLA_OT_fmodifier_copy (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy F-Modifiers"); + ot->name= "Copy F-Modifiers"; ot->idname= "NLA_OT_fmodifier_copy"; - ot->description= _("Copy the F-Modifier(s) of the active NLA-Strip"); + ot->description= "Copy the F-Modifier(s) of the active NLA-Strip"; /* api callbacks */ ot->exec= nla_fmodifier_copy_exec; @@ -2168,9 +2166,9 @@ static int nla_fmodifier_paste_exec(bContext *C, wmOperator *op) void NLA_OT_fmodifier_paste (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste F-Modifiers"); + ot->name= "Paste F-Modifiers"; ot->idname= "NLA_OT_fmodifier_paste"; - ot->description= _("Add copied F-Modifiers to the selected NLA-Strips"); + ot->description= "Add copied F-Modifiers to the selected NLA-Strips"; /* api callbacks */ ot->exec= nla_fmodifier_paste_exec; diff --git a/source/blender/editors/space_nla/nla_select.c b/source/blender/editors/space_nla/nla_select.c index a613f924b89..e9b45da6bce 100644 --- a/source/blender/editors/space_nla/nla_select.c +++ b/source/blender/editors/space_nla/nla_select.c @@ -41,8 +41,6 @@ #include "BLI_math.h" #include "BLI_rand.h" -#include "BLF_api.h" - #include "BKE_nla.h" #include "BKE_context.h" #include "BKE_screen.h" @@ -188,9 +186,9 @@ static int nlaedit_deselectall_exec(bContext *C, wmOperator *op) void NLA_OT_select_all_toggle (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); + ot->name= "Select or Deselect All"; ot->idname= "NLA_OT_select_all_toggle"; - ot->description= _("(De)Select all NLA-Strips"); + ot->description= "(De)Select all NLA-Strips"; /* api callbacks */ ot->exec= nlaedit_deselectall_exec; @@ -200,7 +198,7 @@ void NLA_OT_select_all_toggle (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; /* props */ - RNA_def_boolean(ot->srna, "invert", 0, _("Invert"), ""); + RNA_def_boolean(ot->srna, "invert", 0, "Invert", ""); } /* ******************** Border Select Operator **************************** */ @@ -327,9 +325,9 @@ static int nlaedit_borderselect_exec(bContext *C, wmOperator *op) void NLA_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "NLA_OT_select_border"; - ot->description= _("Use box selection to grab NLA-Strips"); + ot->description= "Use box selection to grab NLA-Strips"; /* api callbacks */ ot->invoke= WM_border_select_invoke; @@ -345,7 +343,7 @@ void NLA_OT_select_border(wmOperatorType *ot) /* rna */ WM_operator_properties_gesture_border(ot, 0); - RNA_def_boolean(ot->srna, "axis_range", 0, _("Axis Range"), ""); + RNA_def_boolean(ot->srna, "axis_range", 0, "Axis Range", ""); } /* ******************** Select Left/Right Operator ************************* */ @@ -353,9 +351,9 @@ void NLA_OT_select_border(wmOperatorType *ot) /* defines for left-right select tool */ static EnumPropertyItem prop_nlaedit_leftright_select_types[] = { - {NLAEDIT_LRSEL_TEST, "CHECK", 0, N_("Check if Select Left or Right"), ""}, - {NLAEDIT_LRSEL_LEFT, "LEFT", 0, N_("Before current frame"), ""}, - {NLAEDIT_LRSEL_RIGHT, "RIGHT", 0, N_("After current frame"), ""}, + {NLAEDIT_LRSEL_TEST, "CHECK", 0, "Check if Select Left or Right", ""}, + {NLAEDIT_LRSEL_LEFT, "LEFT", 0, "Before current frame", ""}, + {NLAEDIT_LRSEL_RIGHT, "RIGHT", 0, "After current frame", ""}, {0, NULL, 0, NULL, NULL} }; @@ -479,9 +477,9 @@ static int nlaedit_select_leftright_invoke (bContext *C, wmOperator *op, wmEvent void NLA_OT_select_leftright (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Left/Right"); + ot->name= "Select Left/Right"; ot->idname= "NLA_OT_select_leftright"; - ot->description= _("Select strips to the left or the right of the current frame "); + ot->description= "Select strips to the left or the right of the current frame "; /* api callbacks */ ot->invoke= nlaedit_select_leftright_invoke; @@ -492,8 +490,8 @@ void NLA_OT_select_leftright (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - ot->prop= RNA_def_enum(ot->srna, "mode", RNA_enum_items_gettexted(prop_nlaedit_leftright_select_types), NLAEDIT_LRSEL_TEST, _("Mode"), ""); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); + ot->prop= RNA_def_enum(ot->srna, "mode", prop_nlaedit_leftright_select_types, NLAEDIT_LRSEL_TEST, "Mode", ""); + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); } @@ -641,9 +639,9 @@ static int nlaedit_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *even void NLA_OT_click_select (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mouse Select"); + ot->name= "Mouse Select"; ot->idname= "NLA_OT_click_select"; - ot->description= _("Handle clicks to select NLA Strips"); + ot->description= "Handle clicks to select NLA Strips"; /* api callbacks - absolutely no exec() this yet... */ ot->invoke= nlaedit_clickselect_invoke; @@ -653,7 +651,7 @@ void NLA_OT_click_select (wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* id-props */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend Select"), ""); // SHIFTKEY + RNA_def_boolean(ot->srna, "extend", 0, "Extend Select", ""); // SHIFTKEY } /* *********************************************** */ diff --git a/source/blender/editors/space_node/node_buttons.c b/source/blender/editors/space_node/node_buttons.c index 95a58402b0a..7b14e35e8fe 100644 --- a/source/blender/editors/space_node/node_buttons.c +++ b/source/blender/editors/space_node/node_buttons.c @@ -46,8 +46,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_node.h" #include "BKE_screen.h" @@ -166,8 +164,8 @@ static int node_properties_poll(bContext *C) void NODE_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); - ot->description= _("Toggles the properties panel display"); + ot->name= "Properties"; + ot->description= "Toggles the properties panel display"; ot->idname= "NODE_OT_properties"; ot->exec= node_properties; diff --git a/source/blender/editors/space_node/node_edit.c b/source/blender/editors/space_node/node_edit.c index 2bec199fe3b..5f58f540aae 100644 --- a/source/blender/editors/space_node/node_edit.c +++ b/source/blender/editors/space_node/node_edit.c @@ -52,8 +52,6 @@ #include "BLI_storage_types.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_depsgraph.h" #include "BKE_global.h" @@ -100,8 +98,8 @@ #include "node_intern.h" static EnumPropertyItem socket_in_out_items[] = { - { SOCK_IN, "SOCK_IN", 0, N_("Input"), "" }, - { SOCK_OUT, "SOCK_OUT", 0, N_("Output"), "" }, + { SOCK_IN, "SOCK_IN", 0, "Input", "" }, + { SOCK_OUT, "SOCK_OUT", 0, "Output", "" }, { 0, NULL, 0, NULL, NULL }, }; @@ -882,8 +880,8 @@ static int node_group_edit_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(e void NODE_OT_group_edit(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Edit Group"); - ot->description = _("Edit node group"); + ot->name = "Edit Group"; + ot->description = "Edit node group"; ot->idname = "NODE_OT_group_edit"; /* api callbacks */ @@ -932,8 +930,8 @@ static int node_group_socket_add_exec(bContext *C, wmOperator *op) void NODE_OT_group_socket_add(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Add Group Socket"); - ot->description = _("Add node group socket"); + ot->name = "Add Group Socket"; + ot->description = "Add node group socket"; ot->idname = "NODE_OT_group_socket_add"; /* api callbacks */ @@ -943,9 +941,9 @@ void NODE_OT_group_socket_add(wmOperatorType *ot) /* flags */ ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, _("Socket Type"), _("Input or Output")); - RNA_def_string(ot->srna, "name", "", 32, _("Name"), _("Group socket name")); - RNA_def_enum(ot->srna, "type", node_socket_type_items, SOCK_FLOAT, _("Type"), _("Type of the group socket")); + RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, "Socket Type", "Input or Output"); + RNA_def_string(ot->srna, "name", "", 32, "Name", "Group socket name"); + RNA_def_enum(ot->srna, "type", node_socket_type_items, SOCK_FLOAT, "Type", "Type of the group socket"); } /* ***************** Remove Group Socket operator ************* */ @@ -984,8 +982,8 @@ static int node_group_socket_remove_exec(bContext *C, wmOperator *op) void NODE_OT_group_socket_remove(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Remove Group Socket"); - ot->description = _("Removed node group socket"); + ot->name = "Remove Group Socket"; + ot->description = "Removed node group socket"; ot->idname = "NODE_OT_group_socket_remove"; /* api callbacks */ @@ -995,8 +993,8 @@ void NODE_OT_group_socket_remove(wmOperatorType *ot) /* flags */ ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), "", 0, INT_MAX); - RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, _("Socket Type"), _("Input or Output")); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "", 0, INT_MAX); + RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, "Socket Type", "Input or Output"); } /* ***************** Move Group Socket Up operator ************* */ @@ -1054,8 +1052,8 @@ static int node_group_socket_move_up_exec(bContext *C, wmOperator *op) void NODE_OT_group_socket_move_up(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Move Group Socket Up"); - ot->description = _("Move up node group socket"); + ot->name = "Move Group Socket Up"; + ot->description = "Move up node group socket"; ot->idname = "NODE_OT_group_socket_move_up"; /* api callbacks */ @@ -1065,8 +1063,8 @@ void NODE_OT_group_socket_move_up(wmOperatorType *ot) /* flags */ ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), "", 0, INT_MAX); - RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, _("Socket Type"), _("Input or Output")); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "", 0, INT_MAX); + RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, "Socket Type", "Input or Output"); } /* ***************** Move Group Socket Up operator ************* */ @@ -1124,8 +1122,8 @@ static int node_group_socket_move_down_exec(bContext *C, wmOperator *op) void NODE_OT_group_socket_move_down(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Move Group Socket Down"); - ot->description = _("Move down node group socket"); + ot->name = "Move Group Socket Down"; + ot->description = "Move down node group socket"; ot->idname = "NODE_OT_group_socket_move_down"; /* api callbacks */ @@ -1135,8 +1133,8 @@ void NODE_OT_group_socket_move_down(wmOperatorType *ot) /* flags */ ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), "", 0, INT_MAX); - RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, _("Socket Type"), _("Input or Output")); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "", 0, INT_MAX); + RNA_def_enum(ot->srna, "in_out", socket_in_out_items, SOCK_IN, "Socket Type", "Input or Output"); } /* ******************** Ungroup operator ********************** */ @@ -1175,8 +1173,8 @@ static int node_group_ungroup_exec(bContext *C, wmOperator *op) void NODE_OT_group_ungroup(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Ungroup"); - ot->description = _("Ungroup selected nodes"); + ot->name = "Ungroup"; + ot->description = "Ungroup selected nodes"; ot->idname = "NODE_OT_group_ungroup"; /* api callbacks */ @@ -1291,8 +1289,8 @@ static int snode_bg_viewmove_cancel(bContext *UNUSED(C), wmOperator *op) void NODE_OT_backimage_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Background Image Move"); - ot->description = _("Move Node backdrop"); + ot->name= "Background Image Move"; + ot->description = "Move Node backdrop"; ot->idname= "NODE_OT_backimage_move"; /* api callbacks */ @@ -1322,7 +1320,7 @@ void NODE_OT_backimage_zoom(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Background Image Zoom"); + ot->name= "Background Image Zoom"; ot->idname= "NODE_OT_backimage_zoom"; /* api callbacks */ @@ -1333,7 +1331,7 @@ void NODE_OT_backimage_zoom(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING; /* internal */ - RNA_def_float(ot->srna, "factor", 1.2f, 0.0f, 10.0f, _("Factor"), "", 0.0f, 10.0f); + RNA_def_float(ot->srna, "factor", 1.2f, 0.0f, 10.0f, "Factor", "", 0.0f, 10.0f); } /******************** sample backdrop operator ********************/ @@ -1485,7 +1483,7 @@ static int sample_cancel(bContext *C, wmOperator *op) void NODE_OT_backimage_sample(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Backimage Sample"); + ot->name= "Backimage Sample"; ot->idname= "NODE_OT_backimage_sample"; /* api callbacks */ @@ -1596,7 +1594,7 @@ static int node_resize_cancel(bContext *UNUSED(C), wmOperator *op) void NODE_OT_resize(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Resize Node"); + ot->name= "Resize Node"; ot->idname= "NODE_OT_resize"; /* api callbacks */ @@ -1803,8 +1801,8 @@ static int node_active_link_viewer(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_link_viewer(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Link to Viewer Node"); - ot->description = _("Link to Viewer Node"); + ot->name= "Link to Viewer Node"; + ot->description = "Link to Viewer Node"; ot->idname= "NODE_OT_link_viewer"; /* api callbacks */ @@ -2273,8 +2271,8 @@ static int node_duplicate_exec(bContext *C, wmOperator *op) void NODE_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Nodes"); - ot->description = _("Duplicate the nodes"); + ot->name= "Duplicate Nodes"; + ot->description = "Duplicate the nodes"; ot->idname= "NODE_OT_duplicate"; /* api callbacks */ @@ -2284,7 +2282,7 @@ void NODE_OT_duplicate(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "keep_inputs", 0, _("Keep Inputs"), _("Keep the input links to duplicated nodes")); + RNA_def_boolean(ot->srna, "keep_inputs", 0, "Keep Inputs", "Keep the input links to duplicated nodes"); } /* *************************** add link op ******************** */ @@ -2567,7 +2565,7 @@ static int node_link_cancel(bContext *C, wmOperator *op) void NODE_OT_link(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Link Nodes"); + ot->name= "Link Nodes"; ot->idname= "NODE_OT_link"; /* api callbacks */ @@ -2603,8 +2601,8 @@ static int node_make_link_exec(bContext *C, wmOperator *op) void NODE_OT_link_make(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Links"); - ot->description= _("Makes a link between selected output in input sockets"); + ot->name= "Make Links"; + ot->description= "Makes a link between selected output in input sockets"; ot->idname= "NODE_OT_link_make"; /* callbacks */ @@ -2614,7 +2612,7 @@ void NODE_OT_link_make(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "replace", 0, _("Replace"), _("Replace socket connections with the new links")); + RNA_def_boolean(ot->srna, "replace", 0, "Replace", "Replace socket connections with the new links"); } /* ********************** Cut Link operator ***************** */ @@ -2681,7 +2679,7 @@ void NODE_OT_links_cut(wmOperatorType *ot) { PropertyRNA *prop; - ot->name= _("Cut links"); + ot->name= "Cut links"; ot->idname= "NODE_OT_links_cut"; ot->invoke= WM_gesture_lines_invoke; @@ -2697,7 +2695,7 @@ void NODE_OT_links_cut(wmOperatorType *ot) prop= RNA_def_property(ot->srna, "path", PROP_COLLECTION, PROP_NONE); RNA_def_property_struct_runtime(prop, &RNA_OperatorMousePath); /* internal */ - RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, _("Cursor"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "cursor", BC_KNIFECURSOR, 0, INT_MAX, "Cursor", "", 0, INT_MAX); } /* ********************* automatic node insert on dragging ******************* */ @@ -2883,7 +2881,7 @@ static int node_read_renderlayers_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_read_renderlayers(wmOperatorType *ot) { - ot->name= _("Read Render Layers"); + ot->name= "Read Render Layers"; ot->idname= "NODE_OT_read_renderlayers"; ot->exec= node_read_renderlayers_exec; @@ -2915,7 +2913,7 @@ static int node_read_fullsamplelayers_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_read_fullsamplelayers(wmOperatorType *ot) { - ot->name= _("Read Full Sample Layers"); + ot->name= "Read Full Sample Layers"; ot->idname= "NODE_OT_read_fullsamplelayers"; ot->exec= node_read_fullsamplelayers_exec; @@ -2963,7 +2961,7 @@ int node_render_changed_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_render_changed(wmOperatorType *ot) { - ot->name= _("Render Changed Layer"); + ot->name= "Render Changed Layer"; ot->idname= "NODE_OT_render_changed"; ot->exec= node_render_changed_exec; @@ -3022,8 +3020,8 @@ static int node_group_make_exec(bContext *C, wmOperator *op) void NODE_OT_group_make(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Group"); - ot->description = _("Make group from selected nodes"); + ot->name = "Group"; + ot->description = "Make group from selected nodes"; ot->idname = "NODE_OT_group_make"; /* api callbacks */ @@ -3085,8 +3083,8 @@ static int node_hide_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_hide_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide"); - ot->description= _("Toggle hiding of selected nodes"); + ot->name= "Hide"; + ot->description= "Toggle hiding of selected nodes"; ot->idname= "NODE_OT_hide_toggle"; /* callbacks */ @@ -3117,8 +3115,8 @@ static int node_preview_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_preview_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Node Preview"); - ot->description= _("Toggle preview display for selected nodes"); + ot->name= "Toggle Node Preview"; + ot->description= "Toggle preview display for selected nodes"; ot->idname= "NODE_OT_preview_toggle"; /* callbacks */ @@ -3166,8 +3164,8 @@ static int node_socket_toggle_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_hide_socket_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Hidden Node Sockets"); - ot->description= _("Toggle unused node socket display"); + ot->name= "Toggle Hidden Node Sockets"; + ot->description= "Toggle unused node socket display"; ot->idname= "NODE_OT_hide_socket_toggle"; /* callbacks */ @@ -3209,8 +3207,8 @@ static int node_mute_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_mute_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Node Mute"); - ot->description= _("Toggle muting of the nodes"); + ot->name= "Toggle Node Mute"; + ot->description= "Toggle muting of the nodes"; ot->idname= "NODE_OT_mute_toggle"; /* callbacks */ @@ -3251,8 +3249,8 @@ static int node_delete_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); - ot->description = _("Delete selected nodes"); + ot->name= "Delete"; + ot->description = "Delete selected nodes"; ot->idname= "NODE_OT_delete"; /* api callbacks */ @@ -3428,8 +3426,8 @@ static int node_show_cycles_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_show_cyclic_dependencies(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Show Cyclic Dependencies"); - ot->description= _("Sort the nodes and show the cyclic dependencies between the nodes"); + ot->name= "Show Cyclic Dependencies"; + ot->description= "Sort the nodes and show the cyclic dependencies between the nodes"; ot->idname= "NODE_OT_show_cyclic_dependencies"; /* callbacks */ @@ -3523,8 +3521,8 @@ static int node_add_file_invoke(bContext *C, wmOperator *op, wmEvent *event) void NODE_OT_add_file(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add File Node"); - ot->description= _("Add a file node to the current node editor"); + ot->name= "Add File Node"; + ot->description= "Add a file node to the current node editor"; ot->idname= "NODE_OT_add_file"; /* callbacks */ @@ -3536,7 +3534,7 @@ void NODE_OT_add_file(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; WM_operator_properties_filesel(ot, FOLDERFILE|IMAGEFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH); //XXX TODO, relative_path - RNA_def_string(ot->srna, "name", "Image", 24, _("Name"), _("Datablock name to assign.")); + RNA_def_string(ot->srna, "name", "Image", 24, "Name", "Datablock name to assign."); } /********************** New node tree operator *********************/ diff --git a/source/blender/editors/space_node/node_header.c b/source/blender/editors/space_node/node_header.c index 7cb3a27d00a..6eccaa2e274 100644 --- a/source/blender/editors/space_node/node_header.c +++ b/source/blender/editors/space_node/node_header.c @@ -267,7 +267,7 @@ void node_menus_register(void) mt= MEM_callocN(sizeof(MenuType), "spacetype node menu add"); strcpy(mt->idname, "NODE_MT_add"); - strcpy(mt->label, _("Add")); + strcpy(mt->label, "Add"); mt->draw= node_menu_add; WM_menutype_add(mt); } diff --git a/source/blender/editors/space_node/node_ops.c b/source/blender/editors/space_node/node_ops.c index 849e67e0431..153d703ddf6 100644 --- a/source/blender/editors/space_node/node_ops.c +++ b/source/blender/editors/space_node/node_ops.c @@ -42,8 +42,6 @@ #include "RNA_access.h" -#include "BLF_api.h" - #include "WM_api.h" #include "WM_types.h" @@ -107,17 +105,17 @@ void ED_operatormacros_node(void) wmOperatorType *ot; wmOperatorTypeMacro *mot; - ot= WM_operatortype_append_macro("NODE_OT_duplicate_move", _("Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("NODE_OT_duplicate_move", "Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); WM_operatortype_macro_define(ot, "NODE_OT_duplicate"); WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); /* modified operator call for duplicating with input links */ - ot= WM_operatortype_append_macro("NODE_OT_duplicate_move_keep_inputs", _("Duplicate"), OPTYPE_UNDO|OPTYPE_REGISTER); + ot= WM_operatortype_append_macro("NODE_OT_duplicate_move_keep_inputs", "Duplicate", OPTYPE_UNDO|OPTYPE_REGISTER); mot = WM_operatortype_macro_define(ot, "NODE_OT_duplicate"); RNA_boolean_set(mot->ptr, "keep_inputs", 1); WM_operatortype_macro_define(ot, "TRANSFORM_OT_translate"); - ot= WM_operatortype_append_macro("NODE_OT_select_link_viewer", _("Link Viewer"), OPTYPE_UNDO); + ot= WM_operatortype_append_macro("NODE_OT_select_link_viewer", "Link Viewer", OPTYPE_UNDO); WM_operatortype_macro_define(ot, "NODE_OT_select"); WM_operatortype_macro_define(ot, "NODE_OT_link_viewer"); } diff --git a/source/blender/editors/space_node/node_select.c b/source/blender/editors/space_node/node_select.c index ccf1752896b..3d8b1676ea5 100644 --- a/source/blender/editors/space_node/node_select.c +++ b/source/blender/editors/space_node/node_select.c @@ -42,8 +42,6 @@ #include "BLI_rect.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "ED_node.h" #include "ED_screen.h" #include "ED_types.h" @@ -141,9 +139,9 @@ static int node_select_invoke(bContext *C, wmOperator *op, wmEvent *event) void NODE_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select"); + ot->name= "Select"; ot->idname= "NODE_OT_select"; - ot->description= _("Select node under cursor"); + ot->description= "Select node under cursor"; /* api callbacks */ ot->invoke= node_select_invoke; @@ -153,9 +151,9 @@ void NODE_OT_select(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int(ot->srna, "mouse_x", 0, INT_MIN, INT_MAX, _("Mouse X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "mouse_y", 0, INT_MIN, INT_MAX, _("Mouse Y"), "", INT_MIN, INT_MAX); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), ""); + RNA_def_int(ot->srna, "mouse_x", 0, INT_MIN, INT_MAX, "Mouse X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mouse_y", 0, INT_MIN, INT_MAX, "Mouse Y", "", INT_MIN, INT_MAX); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", ""); } /* ****** Border Select ****** */ @@ -216,9 +214,9 @@ static int node_border_select_invoke(bContext *C, wmOperator *op, wmEvent *event void NODE_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "NODE_OT_select_border"; - ot->description= _("Use box selection to select nodes"); + ot->description= "Use box selection to select nodes"; /* api callbacks */ ot->invoke= node_border_select_invoke; @@ -233,7 +231,7 @@ void NODE_OT_select_border(wmOperatorType *ot) /* rna */ WM_operator_properties_gesture_border(ot, FALSE); - RNA_def_boolean(ot->srna, "tweak", 0, _("Tweak"), _("Only activate when mouse is not over a node - useful for tweak gesture")); + RNA_def_boolean(ot->srna, "tweak", 0, "Tweak", "Only activate when mouse is not over a node - useful for tweak gesture"); } /* ****** Select/Deselect All ****** */ @@ -267,8 +265,8 @@ static int node_select_all_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select or Deselect All"); - ot->description = _("(De)select all nodes"); + ot->name = "Select or Deselect All"; + ot->description = "(De)select all nodes"; ot->idname = "NODE_OT_select_all"; /* api callbacks */ @@ -309,8 +307,8 @@ static int node_select_linked_to_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_linked_to(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Linked To"); - ot->description = _("Select nodes linked to the selected ones"); + ot->name = "Select Linked To"; + ot->description = "Select nodes linked to the selected ones"; ot->idname = "NODE_OT_select_linked_to"; /* api callbacks */ @@ -351,8 +349,8 @@ static int node_select_linked_from_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_linked_from(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Linked From"); - ot->description = _("Select nodes linked from the selected ones"); + ot->name = "Select Linked From"; + ot->description = "Select nodes linked from the selected ones"; ot->idname = "NODE_OT_select_linked_from"; /* api callbacks */ @@ -380,8 +378,8 @@ static int node_select_same_type_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_same_type(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Same Type"); - ot->description = _("Select all the same type"); + ot->name = "Select Same Type"; + ot->description = "Select all the same type"; ot->idname = "NODE_OT_select_same_type"; /* api callbacks */ @@ -410,8 +408,8 @@ static int node_select_same_type_next_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_same_type_next(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Same Type Next"); - ot->description = _("Select the next node of the same type."); + ot->name = "Select Same Type Next"; + ot->description = "Select the next node of the same type."; ot->idname = "NODE_OT_select_same_type_next"; /* api callbacks */ @@ -437,8 +435,8 @@ static int node_select_same_type_prev_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_select_same_type_prev(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Select Same Type Prev"); - ot->description = _("Select the prev node of the same type."); + ot->name = "Select Same Type Prev"; + ot->description = "Select the prev node of the same type."; ot->idname = "NODE_OT_select_same_type_prev"; /* api callbacks */ diff --git a/source/blender/editors/space_node/node_state.c b/source/blender/editors/space_node/node_state.c index 1c64d09265d..c4567bea648 100644 --- a/source/blender/editors/space_node/node_state.c +++ b/source/blender/editors/space_node/node_state.c @@ -39,8 +39,6 @@ #include "BLI_rect.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_node.h" @@ -196,9 +194,9 @@ static int node_toggle_visibility_invoke(bContext *C, wmOperator *op, wmEvent *e void NODE_OT_visibility_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Visibility"); + ot->name= "Toggle Visibility"; ot->idname= "NODE_OT_visibility_toggle"; - ot->description= _("Handle clicks on node header buttons"); + ot->description= "Handle clicks on node header buttons"; /* api callbacks */ ot->invoke= node_toggle_visibility_invoke; @@ -207,8 +205,8 @@ void NODE_OT_visibility_toggle(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "mouse_x", 0, INT_MIN, INT_MAX, _("Mouse X"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "mouse_y", 0, INT_MIN, INT_MAX, _("Mouse Y"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mouse_x", 0, INT_MIN, INT_MAX, "Mouse X", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mouse_y", 0, INT_MIN, INT_MAX, "Mouse Y", "", INT_MIN, INT_MAX); } /* **************** View All Operator ************** */ @@ -279,9 +277,9 @@ static int node_view_all_exec(bContext *C, wmOperator *UNUSED(op)) void NODE_OT_view_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "NODE_OT_view_all"; - ot->description= _("Resize view so you can see all nodes"); + ot->description= "Resize view so you can see all nodes"; /* api callbacks */ ot->exec= node_view_all_exec; diff --git a/source/blender/editors/space_outliner/CMakeLists.txt b/source/blender/editors/space_outliner/CMakeLists.txt index 3375cb4b420..d969a80a678 100644 --- a/source/blender/editors/space_outliner/CMakeLists.txt +++ b/source/blender/editors/space_outliner/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/space_outliner/SConscript b/source/blender/editors/space_outliner/SConscript index 5e57d9bab85..f451050588b 100644 --- a/source/blender/editors/space_outliner/SConscript +++ b/source/blender/editors/space_outliner/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc ../../makesrna ../../blenloader' incs += ' #/extern/glew/include' diff --git a/source/blender/editors/space_script/CMakeLists.txt b/source/blender/editors/space_script/CMakeLists.txt index c08beed3051..9d3bd4a67aa 100644 --- a/source/blender/editors/space_script/CMakeLists.txt +++ b/source/blender/editors/space_script/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/space_script/SConscript b/source/blender/editors/space_script/SConscript index b718ff59576..c30e204f6f4 100644 --- a/source/blender/editors/space_script/SConscript +++ b/source/blender/editors/space_script/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../makesrna ../../blenloader' incs += ' ../../python' diff --git a/source/blender/editors/space_script/script_edit.c b/source/blender/editors/space_script/script_edit.c index e4cddada224..02cbc81aaa5 100644 --- a/source/blender/editors/space_script/script_edit.c +++ b/source/blender/editors/space_script/script_edit.c @@ -37,8 +37,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "WM_api.h" @@ -75,8 +73,8 @@ static int run_pyfile_exec(bContext *C, wmOperator *op) void SCRIPT_OT_python_file_run(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Run python file"); - ot->description= _("Run Python file"); + ot->name= "Run python file"; + ot->description= "Run Python file"; ot->idname= "SCRIPT_OT_python_file_run"; ot->flag = OPTYPE_UNDO; @@ -84,7 +82,7 @@ void SCRIPT_OT_python_file_run(wmOperatorType *ot) ot->exec= run_pyfile_exec; ot->poll= ED_operator_areaactive; - RNA_def_string_file_path(ot->srna, "filepath", "", 512, _("Path"), ""); + RNA_def_string_file_path(ot->srna, "filepath", "", 512, "Path", ""); } @@ -107,8 +105,8 @@ static int script_reload_exec(bContext *C, wmOperator *UNUSED(op)) void SCRIPT_OT_reload(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reload Scripts"); - ot->description= _("Reload Scripts"); + ot->name= "Reload Scripts"; + ot->description= "Reload Scripts"; ot->idname= "SCRIPT_OT_reload"; /* api callbacks */ diff --git a/source/blender/editors/space_sequencer/CMakeLists.txt b/source/blender/editors/space_sequencer/CMakeLists.txt index 9b978dffc39..9ce5f8e5279 100644 --- a/source/blender/editors/space_sequencer/CMakeLists.txt +++ b/source/blender/editors/space_sequencer/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/space_sequencer/SConscript b/source/blender/editors/space_sequencer/SConscript index 67a6852fedf..3430c10b766 100644 --- a/source/blender/editors/space_sequencer/SConscript +++ b/source/blender/editors/space_sequencer/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../blenfont ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../blenfont ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../makesrna ../../blenloader' incs += ' #/intern/audaspace/intern' diff --git a/source/blender/editors/space_sequencer/sequencer_add.c b/source/blender/editors/space_sequencer/sequencer_add.c index 2a3de6adec4..2fe16b3a85d 100644 --- a/source/blender/editors/space_sequencer/sequencer_add.c +++ b/source/blender/editors/space_sequencer/sequencer_add.c @@ -47,8 +47,6 @@ #include "BLI_storage_types.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "DNA_userdef_types.h" @@ -93,16 +91,16 @@ static void sequencer_generic_props__internal(wmOperatorType *ot, int flag) { if(flag & SEQPROP_STARTFRAME) - RNA_def_int(ot->srna, "frame_start", 0, INT_MIN, INT_MAX, _("Start Frame"), _("Start frame of the sequence strip"), INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "frame_start", 0, INT_MIN, INT_MAX, "Start Frame", "Start frame of the sequence strip", INT_MIN, INT_MAX); if(flag & SEQPROP_ENDFRAME) - RNA_def_int(ot->srna, "frame_end", 0, INT_MIN, INT_MAX, _("End Frame"), _("End frame for the color strip"), INT_MIN, INT_MAX); /* not useual since most strips have a fixed length */ + RNA_def_int(ot->srna, "frame_end", 0, INT_MIN, INT_MAX, "End Frame", "End frame for the color strip", INT_MIN, INT_MAX); /* not useual since most strips have a fixed length */ - RNA_def_int(ot->srna, "channel", 1, 1, MAXSEQ, _("Channel"), _("Channel to place this strip into"), 1, MAXSEQ); + RNA_def_int(ot->srna, "channel", 1, 1, MAXSEQ, "Channel", "Channel to place this strip into", 1, MAXSEQ); - RNA_def_boolean(ot->srna, "replace_sel", 1, _("Replace Selection"), _("replace the current selection")); + RNA_def_boolean(ot->srna, "replace_sel", 1, "Replace Selection", "replace the current selection"); - RNA_def_boolean(ot->srna, "overlap", 0, _("Allow Overlap"), _("Don't correct overlap on new sequence strips")); + RNA_def_boolean(ot->srna, "overlap", 0, "Allow Overlap", "Don't correct overlap on new sequence strips"); } static void sequencer_generic_invoke_path__internal(bContext *C, wmOperator *op, const char *identifier) @@ -283,9 +281,9 @@ void SEQUENCER_OT_scene_strip_add(struct wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name= _("Add Scene Strip"); + ot->name= "Add Scene Strip"; ot->idname= "SEQUENCER_OT_scene_strip_add"; - ot->description= _("Add a strip to the sequencer using a blender scene as a source"); + ot->description= "Add a strip to the sequencer using a blender scene as a source"; /* api callbacks */ ot->invoke= sequencer_add_scene_strip_invoke; @@ -297,7 +295,7 @@ void SEQUENCER_OT_scene_strip_add(struct wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; sequencer_generic_props__internal(ot, SEQPROP_STARTFRAME); - prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, _("Scene"), ""); + prop= RNA_def_enum(ot->srna, "scene", DummyRNA_NULL_items, 0, "Scene", ""); RNA_def_enum_funcs(prop, RNA_scene_itemf); ot->prop= prop; } @@ -396,9 +394,9 @@ void SEQUENCER_OT_movie_strip_add(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Movie Strip"); + ot->name= "Add Movie Strip"; ot->idname= "SEQUENCER_OT_movie_strip_add"; - ot->description= _("Add a movie strip to the sequencer"); + ot->description= "Add a movie strip to the sequencer"; /* api callbacks */ ot->invoke= sequencer_add_movie_strip_invoke; @@ -411,7 +409,7 @@ void SEQUENCER_OT_movie_strip_add(struct wmOperatorType *ot) WM_operator_properties_filesel(ot, FOLDERFILE|MOVIEFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH|WM_FILESEL_RELPATH|WM_FILESEL_FILES); sequencer_generic_props__internal(ot, SEQPROP_STARTFRAME); - RNA_def_boolean(ot->srna, "sound", TRUE, _("Sound"), _("Load sound with the movie")); + RNA_def_boolean(ot->srna, "sound", TRUE, "Sound", "Load sound with the movie"); } /* add sound operator */ @@ -451,9 +449,9 @@ void SEQUENCER_OT_sound_strip_add(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Sound Strip"); + ot->name= "Add Sound Strip"; ot->idname= "SEQUENCER_OT_sound_strip_add"; - ot->description= _("Add a sound strip to the sequencer"); + ot->description= "Add a sound strip to the sequencer"; /* api callbacks */ ot->invoke= sequencer_add_sound_strip_invoke; @@ -466,7 +464,7 @@ void SEQUENCER_OT_sound_strip_add(struct wmOperatorType *ot) WM_operator_properties_filesel(ot, FOLDERFILE|SOUNDFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH|WM_FILESEL_RELPATH|WM_FILESEL_FILES); sequencer_generic_props__internal(ot, SEQPROP_STARTFRAME); - RNA_def_boolean(ot->srna, "cache", FALSE, _("Cache"), _("Cache the sound in memory.")); + RNA_def_boolean(ot->srna, "cache", FALSE, "Cache", "Cache the sound in memory."); } /* add image operator */ @@ -558,9 +556,9 @@ void SEQUENCER_OT_image_strip_add(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Image Strip"); + ot->name= "Add Image Strip"; ot->idname= "SEQUENCER_OT_image_strip_add"; - ot->description= _("Add an image or image sequence to the sequencer"); + ot->description= "Add an image or image sequence to the sequencer"; /* api callbacks */ ot->invoke= sequencer_add_image_strip_invoke; @@ -738,9 +736,9 @@ static int sequencer_add_effect_strip_invoke(bContext *C, wmOperator *op, wmEven void SEQUENCER_OT_effect_strip_add(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Add Effect Strip"); + ot->name= "Add Effect Strip"; ot->idname= "SEQUENCER_OT_effect_strip_add"; - ot->description= _("Add an effect to the sequencer, most are applied on top of existing strips"); + ot->description= "Add an effect to the sequencer, most are applied on top of existing strips"; /* api callbacks */ ot->invoke= sequencer_add_effect_strip_invoke; @@ -753,6 +751,6 @@ void SEQUENCER_OT_effect_strip_add(struct wmOperatorType *ot) WM_operator_properties_filesel(ot, 0, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH|WM_FILESEL_RELPATH); sequencer_generic_props__internal(ot, SEQPROP_STARTFRAME|SEQPROP_ENDFRAME); - RNA_def_enum(ot->srna, "type", sequencer_prop_effect_types, SEQ_CROSS, _("Type"), _("Sequencer effect type")); - RNA_def_float_vector(ot->srna, "color", 3, NULL, 0.0f, 1.0f, _("Color"), _("Initialize the strip with this color (only used when type='COLOR')"), 0.0f, 1.0f); + RNA_def_enum(ot->srna, "type", sequencer_prop_effect_types, SEQ_CROSS, "Type", "Sequencer effect type"); + RNA_def_float_vector(ot->srna, "color", 3, NULL, 0.0f, 1.0f, "Color", "Initialize the strip with this color (only used when type='COLOR')", 0.0f, 1.0f); } diff --git a/source/blender/editors/space_sequencer/sequencer_buttons.c b/source/blender/editors/space_sequencer/sequencer_buttons.c index a2f4e66fe67..01a43fd7fe1 100644 --- a/source/blender/editors/space_sequencer/sequencer_buttons.c +++ b/source/blender/editors/space_sequencer/sequencer_buttons.c @@ -38,8 +38,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_screen.h" @@ -111,9 +109,9 @@ static int sequencer_properties(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); + ot->name= "Properties"; ot->idname= "SEQUENCER_OT_properties"; - ot->description= _("Open sequencer properties panel"); + ot->description= "Open sequencer properties panel"; ot->exec= sequencer_properties; ot->poll= ED_operator_sequencer_active; diff --git a/source/blender/editors/space_sequencer/sequencer_edit.c b/source/blender/editors/space_sequencer/sequencer_edit.c index ac38445267e..e7673651546 100644 --- a/source/blender/editors/space_sequencer/sequencer_edit.c +++ b/source/blender/editors/space_sequencer/sequencer_edit.c @@ -49,8 +49,6 @@ #include "BLI_utildefines.h" #include "BLI_threads.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "DNA_userdef_types.h" @@ -84,37 +82,37 @@ static int okee(const char *UNUSED(dummy)) {return 0;} /* XXX */ /* RNA Enums, used in multiple files */ EnumPropertyItem sequencer_prop_effect_types[] = { - {SEQ_CROSS, "CROSS", 0, N_("Crossfade"), N_("Crossfade effect strip type")}, - {SEQ_ADD, "ADD", 0, N_("Add"), N_("Add effect strip type")}, - {SEQ_SUB, "SUBTRACT", 0, N_("Subtract"), N_("Subtract effect strip type")}, - {SEQ_ALPHAOVER, "ALPHA_OVER", 0, N_("Alpha Over"), N_("Alpha Over effect strip type")}, - {SEQ_ALPHAUNDER, "ALPHA_UNDER", 0, N_("Alpha Under"), N_("Alpha Under effect strip type")}, - {SEQ_GAMCROSS, "GAMMA_CROSS", 0, N_("Gamma Cross"), N_("Gamma Cross effect strip type")}, - {SEQ_MUL, "MULTIPLY", 0, N_("Multiply"), N_("Multiply effect strip type")}, - {SEQ_OVERDROP, "OVER_DROP", 0, N_("Alpha Over Drop"), N_("Alpha Over Drop effect strip type")}, - {SEQ_PLUGIN, "PLUGIN", 0, N_("Plugin"), N_("Plugin effect strip type")}, - {SEQ_WIPE, "WIPE", 0, N_("Wipe"), N_("Wipe effect strip type")}, - {SEQ_GLOW, "GLOW", 0, N_("Glow"), N_("Glow effect strip type")}, - {SEQ_TRANSFORM, "TRANSFORM", 0, N_("Transform"), N_("Transform effect strip type")}, - {SEQ_COLOR, "COLOR", 0, N_("Color"), N_("Color effect strip type")}, - {SEQ_SPEED, "SPEED", 0, N_("Speed"), N_("Color effect strip type")}, - {SEQ_MULTICAM, "MULTICAM", 0, N_("Multicam Selector"), ""}, - {SEQ_ADJUSTMENT, "ADJUSTMENT", 0, N_("Adjustment Layer"), ""}, + {SEQ_CROSS, "CROSS", 0, "Crossfade", "Crossfade effect strip type"}, + {SEQ_ADD, "ADD", 0, "Add", "Add effect strip type"}, + {SEQ_SUB, "SUBTRACT", 0, "Subtract", "Subtract effect strip type"}, + {SEQ_ALPHAOVER, "ALPHA_OVER", 0, "Alpha Over", "Alpha Over effect strip type"}, + {SEQ_ALPHAUNDER, "ALPHA_UNDER", 0, "Alpha Under", "Alpha Under effect strip type"}, + {SEQ_GAMCROSS, "GAMMA_CROSS", 0, "Gamma Cross", "Gamma Cross effect strip type"}, + {SEQ_MUL, "MULTIPLY", 0, "Multiply", "Multiply effect strip type"}, + {SEQ_OVERDROP, "OVER_DROP", 0, "Alpha Over Drop", "Alpha Over Drop effect strip type"}, + {SEQ_PLUGIN, "PLUGIN", 0, "Plugin", "Plugin effect strip type"}, + {SEQ_WIPE, "WIPE", 0, "Wipe", "Wipe effect strip type"}, + {SEQ_GLOW, "GLOW", 0, "Glow", "Glow effect strip type"}, + {SEQ_TRANSFORM, "TRANSFORM", 0, "Transform", "Transform effect strip type"}, + {SEQ_COLOR, "COLOR", 0, "Color", "Color effect strip type"}, + {SEQ_SPEED, "SPEED", 0, "Speed", "Color effect strip type"}, + {SEQ_MULTICAM, "MULTICAM", 0, "Multicam Selector", ""}, + {SEQ_ADJUSTMENT, "ADJUSTMENT", 0, "Adjustment Layer", ""}, {0, NULL, 0, NULL, NULL} }; /* mute operator */ EnumPropertyItem prop_side_types[] = { - {SEQ_SIDE_LEFT, "LEFT", 0, N_("Left"), ""}, - {SEQ_SIDE_RIGHT, "RIGHT", 0, N_("Right"), ""}, - {SEQ_SIDE_BOTH, "BOTH", 0, N_("Both"), ""}, + {SEQ_SIDE_LEFT, "LEFT", 0, "Left", ""}, + {SEQ_SIDE_RIGHT, "RIGHT", 0, "Right", ""}, + {SEQ_SIDE_BOTH, "BOTH", 0, "Both", ""}, {0, NULL, 0, NULL, NULL} }; static EnumPropertyItem prop_side_lr_types[] = { - {SEQ_SIDE_LEFT, "LEFT", 0, N_("Left"), ""}, - {SEQ_SIDE_RIGHT, "RIGHT", 0, N_("Right"), ""}, + {SEQ_SIDE_LEFT, "LEFT", 0, "Left", ""}, + {SEQ_SIDE_RIGHT, "RIGHT", 0, "Right", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1105,9 +1103,9 @@ static int sequencer_snap_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(ev void SEQUENCER_OT_snap(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Snap strips"); + ot->name= "Snap strips"; ot->idname= "SEQUENCER_OT_snap"; - ot->description=_("Frame where selected strips will be snapped"); + ot->description="Frame where selected strips will be snapped"; /* api callbacks */ ot->invoke= sequencer_snap_invoke; @@ -1117,7 +1115,7 @@ void SEQUENCER_OT_snap(struct wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "frame", 0, INT_MIN, INT_MAX, _("Frame"), _("Frame where selected strips will be snapped"), INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "frame", 0, INT_MIN, INT_MAX, "Frame", "Frame where selected strips will be snapped", INT_MIN, INT_MAX); } /* mute operator */ @@ -1152,9 +1150,9 @@ static int sequencer_mute_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_mute(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mute Strips"); + ot->name= "Mute Strips"; ot->idname= "SEQUENCER_OT_mute"; - ot->description=_("Mute selected strips"); + ot->description="Mute selected strips"; /* api callbacks */ ot->exec= sequencer_mute_exec; @@ -1163,7 +1161,7 @@ void SEQUENCER_OT_mute(struct wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Mute unselected rather than selected strips.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Mute unselected rather than selected strips."); } @@ -1199,9 +1197,9 @@ static int sequencer_unmute_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_unmute(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Un-Mute Strips"); + ot->name= "Un-Mute Strips"; ot->idname= "SEQUENCER_OT_unmute"; - ot->description=_("Un-Mute unselected rather than selected strips"); + ot->description="Un-Mute unselected rather than selected strips"; /* api callbacks */ ot->exec= sequencer_unmute_exec; @@ -1210,7 +1208,7 @@ void SEQUENCER_OT_unmute(struct wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("UnMute unselected rather than selected strips.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "UnMute unselected rather than selected strips."); } @@ -1235,9 +1233,9 @@ static int sequencer_lock_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_lock(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Lock Strips"); + ot->name= "Lock Strips"; ot->idname= "SEQUENCER_OT_lock"; - ot->description=_("Lock the active strip so that it can't be transformed"); + ot->description="Lock the active strip so that it can't be transformed"; /* api callbacks */ ot->exec= sequencer_lock_exec; @@ -1268,9 +1266,9 @@ static int sequencer_unlock_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_unlock(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("UnLock Strips"); + ot->name= "UnLock Strips"; ot->idname= "SEQUENCER_OT_unlock"; - ot->description=_("Unlock the active strip so that it can't be transformed"); + ot->description="Unlock the active strip so that it can't be transformed"; /* api callbacks */ ot->exec= sequencer_unlock_exec; @@ -1301,9 +1299,9 @@ static int sequencer_reload_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_reload(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reload Strips"); + ot->name= "Reload Strips"; ot->idname= "SEQUENCER_OT_reload"; - ot->description=_("Reload strips in the sequencer"); + ot->description="Reload strips in the sequencer"; /* api callbacks */ ot->exec= sequencer_reload_exec; @@ -1329,9 +1327,9 @@ static int sequencer_refresh_all_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_refresh_all(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Refresh Sequencer"); + ot->name= "Refresh Sequencer"; ot->idname= "SEQUENCER_OT_refresh_all"; - ot->description=_("Refresh the sequencer editor"); + ot->description="Refresh the sequencer editor"; /* api callbacks */ ot->exec= sequencer_refresh_all_exec; @@ -1386,9 +1384,9 @@ static int sequencer_effect_poll(bContext *C) void SEQUENCER_OT_reassign_inputs(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reassign Inputs"); + ot->name= "Reassign Inputs"; ot->idname= "SEQUENCER_OT_reassign_inputs"; - ot->description=_("Reassign the inputs for the effects strip"); + ot->description="Reassign the inputs for the effects strip"; /* api callbacks */ ot->exec= sequencer_reassign_inputs_exec; @@ -1422,9 +1420,9 @@ static int sequencer_swap_inputs_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_swap_inputs(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Swap Inputs"); + ot->name= "Swap Inputs"; ot->idname= "SEQUENCER_OT_swap_inputs"; - ot->description=_("Swap the first two inputs for the effects strip"); + ot->description="Swap the first two inputs for the effects strip"; /* api callbacks */ ot->exec= sequencer_swap_inputs_exec; @@ -1437,8 +1435,8 @@ void SEQUENCER_OT_swap_inputs(struct wmOperatorType *ot) /* cut operator */ static EnumPropertyItem prop_cut_types[] = { - {SEQ_CUT_SOFT, "SOFT", 0, N_("Soft"), ""}, - {SEQ_CUT_HARD, "HARD", 0, N_("Hard"), ""}, + {SEQ_CUT_SOFT, "SOFT", 0, "Soft", ""}, + {SEQ_CUT_HARD, "HARD", 0, "Hard", ""}, {0, NULL, 0, NULL, NULL} }; @@ -1513,9 +1511,9 @@ static int sequencer_cut_invoke(bContext *C, wmOperator *op, wmEvent *event) void SEQUENCER_OT_cut(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cut Strips"); + ot->name= "Cut Strips"; ot->idname= "SEQUENCER_OT_cut"; - ot->description=_("Cut the selected strips"); + ot->description="Cut the selected strips"; /* api callbacks */ ot->invoke= sequencer_cut_invoke; @@ -1525,9 +1523,9 @@ void SEQUENCER_OT_cut(struct wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "frame", 0, INT_MIN, INT_MAX, _("Frame"), _("Frame where selected strips will be cut"), INT_MIN, INT_MAX); - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_cut_types), SEQ_CUT_SOFT, _("Type"), _("The type of cut operation to perform on strips")); - RNA_def_enum(ot->srna, "side", RNA_enum_items_gettexted(prop_side_types), SEQ_SIDE_BOTH, _("Side"), _("The side that remains selected after cutting")); + RNA_def_int(ot->srna, "frame", 0, INT_MIN, INT_MAX, "Frame", "Frame where selected strips will be cut", INT_MIN, INT_MAX); + RNA_def_enum(ot->srna, "type", prop_cut_types, SEQ_CUT_SOFT, "Type", "The type of cut operation to perform on strips"); + RNA_def_enum(ot->srna, "side", prop_side_types, SEQ_SIDE_BOTH, "Side", "The side that remains selected after cutting"); } /* duplicate operator */ @@ -1583,9 +1581,9 @@ static int sequencer_add_duplicate_invoke(bContext *C, wmOperator *op, wmEvent * void SEQUENCER_OT_duplicate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Duplicate Strips"); + ot->name= "Duplicate Strips"; ot->idname= "SEQUENCER_OT_duplicate"; - ot->description=_("Duplicate the selected strips"); + ot->description="Duplicate the selected strips"; /* api callbacks */ ot->invoke= sequencer_add_duplicate_invoke; @@ -1596,7 +1594,7 @@ void SEQUENCER_OT_duplicate(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* to give to transform */ - RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); } /* delete operator */ @@ -1656,9 +1654,9 @@ void SEQUENCER_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Erase Strips"); + ot->name= "Erase Strips"; ot->idname= "SEQUENCER_OT_delete"; - ot->description=_("Erase selected strips from the sequencer"); + ot->description="Erase selected strips from the sequencer"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -1801,9 +1799,9 @@ static int sequencer_separate_images_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_images_separate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Separate Images"); + ot->name= "Separate Images"; ot->idname= "SEQUENCER_OT_images_separate"; - ot->description=_("On image sequences strips, it return a strip for each image"); + ot->description="On image sequences strips, it return a strip for each image"; /* api callbacks */ ot->exec= sequencer_separate_images_exec; @@ -1812,7 +1810,7 @@ void SEQUENCER_OT_images_separate(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "length", 1, 1, 1000, _("Length"), _("Length of each frame"), 1, INT_MAX); + RNA_def_int(ot->srna, "length", 1, 1, 1000, "Length", "Length of each frame", 1, INT_MAX); } @@ -1873,9 +1871,9 @@ static int sequencer_meta_toggle_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_meta_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Meta Strip"); + ot->name= "Toggle Meta Strip"; ot->idname= "SEQUENCER_OT_meta_toggle"; - ot->description=_("Toggle a metastrip (to edit enclosed strips)"); + ot->description="Toggle a metastrip (to edit enclosed strips)"; /* api callbacks */ ot->exec= sequencer_meta_toggle_exec; @@ -1940,9 +1938,9 @@ static int sequencer_meta_make_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_meta_make(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Meta Strip"); + ot->name= "Make Meta Strip"; ot->idname= "SEQUENCER_OT_meta_make"; - ot->description=_("Group selected strips into a metastrip"); + ot->description="Group selected strips into a metastrip"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -2011,9 +2009,9 @@ static int sequencer_meta_separate_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_meta_separate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("UnMeta Strip"); + ot->name= "UnMeta Strip"; ot->idname= "SEQUENCER_OT_meta_separate"; - ot->description=_("Put the contents of a metastrip back in the sequencer"); + ot->description="Put the contents of a metastrip back in the sequencer"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -2044,9 +2042,9 @@ static int sequencer_view_all_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_view_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "SEQUENCER_OT_view_all"; - ot->description=_("View all the strips in the sequencer"); + ot->description="View all the strips in the sequencer"; /* api callbacks */ ot->exec= sequencer_view_all_exec; @@ -2110,9 +2108,9 @@ static int sequencer_view_all_preview_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_view_all_preview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "SEQUENCER_OT_view_all_preview"; - ot->description=_("Zoom preview to fit in the area"); + ot->description="Zoom preview to fit in the area"; /* api callbacks */ ot->exec= sequencer_view_all_preview_exec; @@ -2146,9 +2144,9 @@ static int sequencer_view_zoom_ratio_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_view_zoom_ratio(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sequencer View Zoom Ratio"); + ot->name= "Sequencer View Zoom Ratio"; ot->idname= "SEQUENCER_OT_view_zoom_ratio"; - ot->description = _("Change zoom ratio of sequencer preview"); + ot->description = "Change zoom ratio of sequencer preview"; /* api callbacks */ ot->exec= sequencer_view_zoom_ratio_exec; @@ -2156,15 +2154,15 @@ void SEQUENCER_OT_view_zoom_ratio(wmOperatorType *ot) /* properties */ RNA_def_float(ot->srna, "ratio", 1.0f, 0.0f, FLT_MAX, - _("Ratio"), _("Zoom ratio, 1.0 is 1:1, higher is zoomed in, lower is zoomed out."), -FLT_MAX, FLT_MAX); + "Ratio", "Zoom ratio, 1.0 is 1:1, higher is zoomed in, lower is zoomed out.", -FLT_MAX, FLT_MAX); } #if 0 static EnumPropertyItem view_type_items[] = { - {SEQ_VIEW_SEQUENCE, "SEQUENCER", ICON_SEQ_SEQUENCER, N_("Sequencer"), ""}, - {SEQ_VIEW_PREVIEW, "PREVIEW", ICON_SEQ_PREVIEW, N_("Image Preview"), ""}, - {SEQ_VIEW_SEQUENCE_PREVIEW, "SEQUENCER_PREVIEW", ICON_SEQ_SEQUENCER, N_("Sequencer and Image Preview"), ""}, + {SEQ_VIEW_SEQUENCE, "SEQUENCER", ICON_SEQ_SEQUENCER, "Sequencer", ""}, + {SEQ_VIEW_PREVIEW, "PREVIEW", ICON_SEQ_PREVIEW, "Image Preview", ""}, + {SEQ_VIEW_SEQUENCE_PREVIEW, "SEQUENCER_PREVIEW", ICON_SEQ_SEQUENCER, "Sequencer and Image Preview", ""}, {0, NULL, 0, NULL, NULL}}; #endif @@ -2184,9 +2182,9 @@ static int sequencer_view_toggle_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_view_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Toggle"); + ot->name= "View Toggle"; ot->idname= "SEQUENCER_OT_view_toggle"; - ot->description=_("Toggle between sequencer views (sequence, preview, both)"); + ot->description="Toggle between sequencer views (sequence, preview, both)"; /* api callbacks */ ot->exec= sequencer_view_toggle_exec; @@ -2264,9 +2262,9 @@ static int sequencer_view_selected_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_view_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Selected"); + ot->name= "View Selected"; ot->idname= "SEQUENCER_OT_view_selected"; - ot->description=_("Zoom the sequencer on the selected strips"); + ot->description="Zoom the sequencer on the selected strips"; /* api callbacks */ ot->exec= sequencer_view_selected_exec; @@ -2349,9 +2347,9 @@ static int sequencer_next_edit_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_next_edit(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Next Edit"); + ot->name= "Next Edit"; ot->idname= "SEQUENCER_OT_next_edit"; - ot->description=_("Move frame to next edit point"); + ot->description="Move frame to next edit point"; /* api callbacks */ ot->exec= sequencer_next_edit_exec; @@ -2379,9 +2377,9 @@ static int sequencer_previous_edit_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_previous_edit(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Previous Edit"); + ot->name= "Previous Edit"; ot->idname= "SEQUENCER_OT_previous_edit"; - ot->description=_("Move frame to previous edit point"); + ot->description="Move frame to previous edit point"; /* api callbacks */ ot->exec= sequencer_previous_edit_exec; @@ -2483,9 +2481,9 @@ static int sequencer_swap_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_swap(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Swap Strip"); + ot->name= "Swap Strip"; ot->idname= "SEQUENCER_OT_swap"; - ot->description=_("Swap active strip with strip to the left"); + ot->description="Swap active strip with strip to the left"; /* api callbacks */ ot->exec= sequencer_swap_exec; @@ -2495,7 +2493,7 @@ void SEQUENCER_OT_swap(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "side", RNA_enum_items_gettexted(prop_side_lr_types), SEQ_SIDE_RIGHT, _("Side"), _("Side of the strip to swap")); + RNA_def_enum(ot->srna, "side", prop_side_lr_types, SEQ_SIDE_RIGHT, "Side", "Side of the strip to swap"); } static int sequencer_rendersize_exec(bContext *C, wmOperator *UNUSED(op)) @@ -2542,9 +2540,9 @@ static int sequencer_rendersize_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_rendersize(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Render Size"); + ot->name= "Set Render Size"; ot->idname= "SEQUENCER_OT_rendersize"; - ot->description=_("Set render size and aspect from active sequence"); + ot->description="Set render size and aspect from active sequence"; /* api callbacks */ ot->exec= sequencer_rendersize_exec; @@ -2621,7 +2619,7 @@ static int sequencer_copy_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy"); + ot->name= "Copy"; ot->idname= "SEQUENCER_OT_copy"; ot->description=""; @@ -2672,7 +2670,7 @@ static int sequencer_paste_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste"); + ot->name= "Paste"; ot->idname= "SEQUENCER_OT_paste"; ot->description=""; @@ -2723,9 +2721,9 @@ static int sequencer_swap_data_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_swap_data(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sequencer Swap Data"); + ot->name= "Sequencer Swap Data"; ot->idname= "SEQUENCER_OT_swap_data"; - ot->description=_("Swap 2 sequencer strips"); + ot->description="Swap 2 sequencer strips"; /* api callbacks */ ot->exec= sequencer_swap_data_exec; @@ -2780,9 +2778,9 @@ static int view_ghost_border_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_view_ghost_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Offset View"); + ot->name= "Border Offset View"; ot->idname= "SEQUENCER_OT_view_ghost_border"; - ot->description=_("Enable border select mode"); + ot->description="Enable border select mode"; /* api callbacks */ ot->invoke= WM_border_select_invoke; diff --git a/source/blender/editors/space_sequencer/sequencer_select.c b/source/blender/editors/space_sequencer/sequencer_select.c index 88e64b184e1..86b28f5e89e 100644 --- a/source/blender/editors/space_sequencer/sequencer_select.c +++ b/source/blender/editors/space_sequencer/sequencer_select.c @@ -44,8 +44,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "DNA_scene_types.h" #include "BKE_context.h" @@ -248,9 +246,9 @@ static int sequencer_deselect_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_select_all_toggle(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); + ot->name= "Select or Deselect All"; ot->idname= "SEQUENCER_OT_select_all_toggle"; - ot->description=_("Select or deselect all strips"); + ot->description="Select or deselect all strips"; /* api callbacks */ ot->exec= sequencer_deselect_exec; @@ -286,9 +284,9 @@ static int sequencer_select_inverse_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_select_inverse(struct wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Inverse"); + ot->name= "Select Inverse"; ot->idname= "SEQUENCER_OT_select_inverse"; - ot->description=_("Select unselected strips"); + ot->description="Select unselected strips"; /* api callbacks */ ot->exec= sequencer_select_inverse_exec; @@ -509,9 +507,9 @@ static int sequencer_select_invoke(bContext *C, wmOperator *op, wmEvent *event) void SEQUENCER_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Activate/Select"); + ot->name= "Activate/Select"; ot->idname= "SEQUENCER_OT_select"; - ot->description=_("Select a strip (last selected becomes the \"active strip\")"); + ot->description="Select a strip (last selected becomes the \"active strip\")"; /* api callbacks */ ot->invoke= sequencer_select_invoke; @@ -521,11 +519,11 @@ void SEQUENCER_OT_select(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend the selection.")); - RNA_def_boolean(ot->srna, "linked_handle", 0, _("Linked Handle"), _("Select handles next to the active strip.")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend the selection."); + RNA_def_boolean(ot->srna, "linked_handle", 0, "Linked Handle", "Select handles next to the active strip."); /* for animation this is an enum but atm having an enum isnt useful for us */ - RNA_def_boolean(ot->srna, "left_right", 0, _("Left/Right"), _("select based on the frame side the cursor is on.")); - RNA_def_boolean(ot->srna, "linked_time", 0, _("Linked Time"), _("Select other strips at the same time.")); + RNA_def_boolean(ot->srna, "left_right", 0, "Left/Right", "select based on the frame side the cursor is on."); + RNA_def_boolean(ot->srna, "linked_time", 0, "Linked Time", "Select other strips at the same time."); } @@ -598,9 +596,9 @@ static int sequencer_select_more_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_select_more(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select More"); + ot->name= "Select More"; ot->idname= "SEQUENCER_OT_select_more"; - ot->description=_("Select more strips adjacent to the current selection"); + ot->description="Select more strips adjacent to the current selection"; /* api callbacks */ ot->exec= sequencer_select_more_exec; @@ -629,9 +627,9 @@ static int sequencer_select_less_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_select_less(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select less"); + ot->name= "Select less"; ot->idname= "SEQUENCER_OT_select_less"; - ot->description=_("Shrink the current selection of adjacent selected strips"); + ot->description="Shrink the current selection of adjacent selected strips"; /* api callbacks */ ot->exec= sequencer_select_less_exec; @@ -679,9 +677,9 @@ static int sequencer_select_linked_pick_invoke(bContext *C, wmOperator *op, wmEv void SEQUENCER_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select pick linked"); + ot->name= "Select pick linked"; ot->idname= "SEQUENCER_OT_select_linked_pick"; - ot->description=_("Select a chain of linked strips nearest to the mouse pointer"); + ot->description="Select a chain of linked strips nearest to the mouse pointer"; /* api callbacks */ ot->invoke= sequencer_select_linked_pick_invoke; @@ -691,7 +689,7 @@ void SEQUENCER_OT_select_linked_pick(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("extend the selection")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "extend the selection"); } @@ -714,9 +712,9 @@ static int sequencer_select_linked_exec(bContext *C, wmOperator *UNUSED(op)) void SEQUENCER_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select linked"); + ot->name= "Select linked"; ot->idname= "SEQUENCER_OT_select_linked"; - ot->description=_("Select all strips adjacent to the current selection"); + ot->description="Select all strips adjacent to the current selection"; /* api callbacks */ ot->exec= sequencer_select_linked_exec; @@ -764,9 +762,9 @@ static int sequencer_select_handles_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_select_handles(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Handles"); + ot->name= "Select Handles"; ot->idname= "SEQUENCER_OT_select_handles"; - ot->description=_("Select manipulator handles on the sides of the selected strip"); + ot->description="Select manipulator handles on the sides of the selected strip"; /* api callbacks */ ot->exec= sequencer_select_handles_exec; @@ -776,7 +774,7 @@ void SEQUENCER_OT_select_handles(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "side", prop_side_types, SEQ_SIDE_BOTH, _("Side"), _("The side of the handle that is selected")); + RNA_def_enum(ot->srna, "side", prop_side_types, SEQ_SIDE_BOTH, "Side", "The side of the handle that is selected"); } /* select side operator */ @@ -801,9 +799,9 @@ static int sequencer_select_active_side_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_select_active_side(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Active Side"); + ot->name= "Select Active Side"; ot->idname= "SEQUENCER_OT_select_active_side"; - ot->description=_("Select strips on the nominated side of the active strip"); + ot->description="Select strips on the nominated side of the active strip"; /* api callbacks */ ot->exec= sequencer_select_active_side_exec; @@ -813,7 +811,7 @@ void SEQUENCER_OT_select_active_side(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_enum(ot->srna, "side", prop_side_types, SEQ_SIDE_BOTH, _("Side"), _("The side of the handle that is selected")); + RNA_def_enum(ot->srna, "side", prop_side_types, SEQ_SIDE_BOTH, "Side", "The side of the handle that is selected"); } @@ -865,9 +863,9 @@ static int sequencer_borderselect_exec(bContext *C, wmOperator *op) void SEQUENCER_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); + ot->name= "Border Select"; ot->idname= "SEQUENCER_OT_select_border"; - ot->description=_("Enable border select mode"); + ot->description="Enable border select mode"; /* api callbacks */ ot->invoke= WM_border_select_invoke; diff --git a/source/blender/editors/space_text/text_header.c b/source/blender/editors/space_text/text_header.c index e82448e1277..165cec238c0 100644 --- a/source/blender/editors/space_text/text_header.c +++ b/source/blender/editors/space_text/text_header.c @@ -54,8 +54,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_screen.h" @@ -121,8 +119,8 @@ static int properties_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_properties(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Properties"); - ot->description= _("Toggle text properties panel"); + ot->name= "Properties"; + ot->description= "Toggle text properties panel"; ot->idname= "TEXT_OT_properties"; /* api callbacks */ diff --git a/source/blender/editors/space_text/text_ops.c b/source/blender/editors/space_text/text_ops.c index fcf7345e3c5..617bbf62e92 100644 --- a/source/blender/editors/space_text/text_ops.c +++ b/source/blender/editors/space_text/text_ops.c @@ -46,8 +46,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "PIL_time.h" #include "BKE_context.h" @@ -194,9 +192,9 @@ static int new_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_new(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Create Text Block"); + ot->name= "Create Text Block"; ot->idname= "TEXT_OT_new"; - ot->description= _("Create a new text data block"); + ot->description= "Create a new text data block"; /* api callbacks */ ot->invoke= WM_operator_confirm; @@ -294,9 +292,9 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void TEXT_OT_open(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Open Text Block"); + ot->name= "Open Text Block"; ot->idname= "TEXT_OT_open"; - ot->description= _("Open a new text data block"); + ot->description= "Open a new text data block"; /* api callbacks */ ot->exec= open_exec; @@ -309,7 +307,7 @@ void TEXT_OT_open(wmOperatorType *ot) /* properties */ WM_operator_properties_filesel(ot, FOLDERFILE|TEXTFILE|PYSCRIPTFILE, FILE_SPECIAL, FILE_OPENFILE, WM_FILESEL_FILEPATH); //XXX TODO, relative_path - RNA_def_boolean(ot->srna, "internal", 0, _("Make internal"), _("Make text file internal after loading")); + RNA_def_boolean(ot->srna, "internal", 0, "Make internal", "Make text file internal after loading"); } /******************* reload operator *********************/ @@ -339,9 +337,9 @@ static int reload_exec(bContext *C, wmOperator *op) void TEXT_OT_reload(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reload"); + ot->name= "Reload"; ot->idname= "TEXT_OT_reload"; - ot->description= _("Reload active text data block from its file"); + ot->description= "Reload active text data block from its file"; /* api callbacks */ ot->exec= reload_exec; @@ -389,9 +387,9 @@ static int unlink_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_unlink(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Unlink"); + ot->name= "Unlink"; ot->idname= "TEXT_OT_unlink"; - ot->description= _("Unlink active text data block"); + ot->description= "Unlink active text data block"; /* api callbacks */ ot->exec= unlink_exec; @@ -424,9 +422,9 @@ static int make_internal_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_make_internal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Make Internal"); + ot->name= "Make Internal"; ot->idname= "TEXT_OT_make_internal"; - ot->description= _("Make active text file internal"); + ot->description= "Make active text file internal"; /* api callbacks */ ot->exec= make_internal_exec; @@ -501,9 +499,9 @@ static int save_exec(bContext *C, wmOperator *op) void TEXT_OT_save(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Save"); + ot->name= "Save"; ot->idname= "TEXT_OT_save"; - ot->description= _("Save active text data block"); + ot->description= "Save active text data block"; /* api callbacks */ ot->exec= save_exec; @@ -558,9 +556,9 @@ static int save_as_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void TEXT_OT_save_as(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Save As"); + ot->name= "Save As"; ot->idname= "TEXT_OT_save_as"; - ot->description= _("Save active text file with options"); + ot->description= "Save active text file with options"; /* api callbacks */ ot->exec= save_as_exec; @@ -628,9 +626,9 @@ static int run_script_exec(bContext *C, wmOperator *op) void TEXT_OT_run_script(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Run Script"); + ot->name= "Run Script"; ot->idname= "TEXT_OT_run_script"; - ot->description= _("Run active script"); + ot->description= "Run active script"; /* api callbacks */ ot->poll= run_script_poll; @@ -688,9 +686,9 @@ static int refresh_pyconstraints_exec(bContext *UNUSED(C), wmOperator *UNUSED(op void TEXT_OT_refresh_pyconstraints(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Refresh PyConstraints"); + ot->name= "Refresh PyConstraints"; ot->idname= "TEXT_OT_refresh_pyconstraints"; - ot->description= _("Refresh all pyconstraints"); + ot->description= "Refresh all pyconstraints"; /* api callbacks */ ot->exec= refresh_pyconstraints_exec; @@ -812,16 +810,16 @@ static int paste_exec(bContext *C, wmOperator *op) void TEXT_OT_paste(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Paste"); + ot->name= "Paste"; ot->idname= "TEXT_OT_paste"; - ot->description= _("Paste text from clipboard"); + ot->description= "Paste text from clipboard"; /* api callbacks */ ot->exec= paste_exec; ot->poll= text_edit_poll; /* properties */ - RNA_def_boolean(ot->srna, "selection", 0, _("Selection"), _("Paste text selected elsewhere rather than copied, X11 only.")); + RNA_def_boolean(ot->srna, "selection", 0, "Selection", "Paste text selected elsewhere rather than copied, X11 only."); } /******************* copy operator *********************/ @@ -850,9 +848,9 @@ static int copy_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_copy(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Copy"); + ot->name= "Copy"; ot->idname= "TEXT_OT_copy"; - ot->description= _("Copy selected text to clipboard"); + ot->description= "Copy selected text to clipboard"; /* api callbacks */ ot->exec= copy_exec; @@ -883,9 +881,9 @@ static int cut_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_cut(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cut"); + ot->name= "Cut"; ot->idname= "TEXT_OT_cut"; - ot->description= _("Cut selected text to clipboard"); + ot->description= "Cut selected text to clipboard"; /* api callbacks */ ot->exec= cut_exec; @@ -918,9 +916,9 @@ static int indent_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_indent(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Indent"); + ot->name= "Indent"; ot->idname= "TEXT_OT_indent"; - ot->description= _("Indent selected text"); + ot->description= "Indent selected text"; /* api callbacks */ ot->exec= indent_exec; @@ -953,9 +951,9 @@ static int unindent_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_unindent(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Unindent"); + ot->name= "Unindent"; ot->idname= "TEXT_OT_unindent"; - ot->description= _("Unindent selected text"); + ot->description= "Unindent selected text"; /* api callbacks */ ot->exec= unindent_exec; @@ -1000,9 +998,9 @@ static int line_break_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_line_break(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Line Break"); + ot->name= "Line Break"; ot->idname= "TEXT_OT_line_break"; - ot->description= _("Insert line break at cursor position"); + ot->description= "Insert line break at cursor position"; /* api callbacks */ ot->exec= line_break_exec; @@ -1033,9 +1031,9 @@ static int comment_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_comment(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Comment"); + ot->name= "Comment"; ot->idname= "TEXT_OT_comment"; - ot->description= _("Convert selected text to comment"); + ot->description= "Convert selected text to comment"; /* api callbacks */ ot->exec= comment_exec; @@ -1067,9 +1065,9 @@ static int uncomment_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_uncomment(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Uncomment"); + ot->name= "Uncomment"; ot->idname= "TEXT_OT_uncomment"; - ot->description= _("Convert selected comment to text"); + ot->description= "Convert selected comment to text"; /* api callbacks */ ot->exec= uncomment_exec; @@ -1207,16 +1205,16 @@ static int convert_whitespace_exec(bContext *C, wmOperator *op) void TEXT_OT_convert_whitespace(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Convert Whitespace"); + ot->name= "Convert Whitespace"; ot->idname= "TEXT_OT_convert_whitespace"; - ot->description= _("Convert whitespaces by type"); + ot->description= "Convert whitespaces by type"; /* api callbacks */ ot->exec= convert_whitespace_exec; ot->poll= text_edit_poll; /* properties */ - RNA_def_enum(ot->srna, "type", whitespace_type_items, TO_SPACES, _("type"), _("Type of whitespace to convert to.")); + RNA_def_enum(ot->srna, "type", whitespace_type_items, TO_SPACES, "type", "Type of whitespace to convert to."); } /******************* select all operator *********************/ @@ -1236,9 +1234,9 @@ static int select_all_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select All"); + ot->name= "Select All"; ot->idname= "TEXT_OT_select_all"; - ot->description= _("Select all text"); + ot->description= "Select all text"; /* api callbacks */ ot->exec= select_all_exec; @@ -1262,9 +1260,9 @@ static int select_line_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_select_line(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Line"); + ot->name= "Select Line"; ot->idname= "TEXT_OT_select_line"; - ot->description= _("Select text by line"); + ot->description= "Select text by line"; /* api callbacks */ ot->exec= select_line_exec; @@ -1289,9 +1287,9 @@ static int select_word_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_select_word(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Word"); + ot->name= "Select Word"; ot->idname= "TEXT_OT_select_word"; - ot->description= _("Select word under cursor"); + ot->description= "Select word under cursor"; /* api callbacks */ ot->exec= select_word_exec; @@ -1325,9 +1323,9 @@ static int previous_marker_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_previous_marker(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Previous Marker"); + ot->name= "Previous Marker"; ot->idname= "TEXT_OT_previous_marker"; - ot->description= _("Move to previous marker"); + ot->description= "Move to previous marker"; /* api callbacks */ ot->exec= previous_marker_exec; @@ -1361,9 +1359,9 @@ static int next_marker_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_next_marker(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Next Marker"); + ot->name= "Next Marker"; ot->idname= "TEXT_OT_next_marker"; - ot->description= _("Move to next marker"); + ot->description= "Move to next marker"; /* api callbacks */ ot->exec= next_marker_exec; @@ -1387,9 +1385,9 @@ static int clear_all_markers_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_markers_clear(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clear All Markers"); + ot->name= "Clear All Markers"; ot->idname= "TEXT_OT_markers_clear"; - ot->description= _("Clear all markers"); + ot->description= "Clear all markers"; /* api callbacks */ ot->exec= clear_all_markers_exec; @@ -1900,16 +1898,16 @@ static int move_exec(bContext *C, wmOperator *op) void TEXT_OT_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Cursor"); + ot->name= "Move Cursor"; ot->idname= "TEXT_OT_move"; - ot->description= _("Move cursor to position type"); + ot->description= "Move cursor to position type"; /* api callbacks */ ot->exec= move_exec; ot->poll= text_edit_poll; /* properties */ - RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, _("Type"), _("Where to move cursor to.")); + RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, "Type", "Where to move cursor to."); } /******************* move select operator ********************/ @@ -1924,16 +1922,16 @@ static int move_select_exec(bContext *C, wmOperator *op) void TEXT_OT_move_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move Select"); + ot->name= "Move Select"; ot->idname= "TEXT_OT_move_select"; - ot->description= _("Make selection from current cursor position to new cursor position type"); + ot->description= "Make selection from current cursor position to new cursor position type"; /* api callbacks */ ot->exec= move_select_exec; ot->poll= text_space_edit_poll; /* properties */ - RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, _("Type"), _("Where to move cursor to, to make a selection.")); + RNA_def_enum(ot->srna, "type", move_type_items, LINE_BEGIN, "Type", "Where to move cursor to, to make a selection."); } /******************* jump operator *********************/ @@ -1966,9 +1964,9 @@ static int jump_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event)) void TEXT_OT_jump(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Jump"); + ot->name= "Jump"; ot->idname= "TEXT_OT_jump"; - ot->description= _("Jump cursor to line"); + ot->description= "Jump cursor to line"; /* api callbacks */ ot->invoke= jump_invoke; @@ -1976,7 +1974,7 @@ void TEXT_OT_jump(wmOperatorType *ot) ot->poll= text_edit_poll; /* properties */ - RNA_def_int(ot->srna, "line", 1, 1, INT_MAX, _("Line"), _("Line number to jump to."), 1, 10000); + RNA_def_int(ot->srna, "line", 1, 1, INT_MAX, "Line", "Line number to jump to.", 1, 10000); } /******************* delete operator **********************/ @@ -2019,16 +2017,16 @@ static int delete_exec(bContext *C, wmOperator *op) void TEXT_OT_delete(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Delete"); + ot->name= "Delete"; ot->idname= "TEXT_OT_delete"; - ot->description= _("Delete text by cursor position"); + ot->description= "Delete text by cursor position"; /* api callbacks */ ot->exec= delete_exec; ot->poll= text_edit_poll; /* properties */ - RNA_def_enum(ot->srna, "type", delete_type_items, DEL_NEXT_CHAR, _("Type"), _("Which part of the text to delete.")); + RNA_def_enum(ot->srna, "type", delete_type_items, DEL_NEXT_CHAR, "Type", "Which part of the text to delete."); } /******************* toggle overwrite operator **********************/ @@ -2047,9 +2045,9 @@ static int toggle_overwrite_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_overwrite_toggle(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Toggle Overwrite"); + ot->name= "Toggle Overwrite"; ot->idname= "TEXT_OT_overwrite_toggle"; - ot->description= _("Toggle overwrite while typing"); + ot->description= "Toggle overwrite while typing"; /* api callbacks */ ot->exec= toggle_overwrite_exec; @@ -2247,12 +2245,12 @@ static int scroll_invoke(bContext *C, wmOperator *op, wmEvent *event) void TEXT_OT_scroll(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scroll"); + ot->name= "Scroll"; /*don't really see the difference between this and scroll_bar. Both do basically the same thing (aside from keymaps).*/ ot->idname= "TEXT_OT_scroll"; - ot->description= _("Scroll text screen"); + ot->description= "Scroll text screen"; /* api callbacks */ ot->exec= scroll_exec; @@ -2265,7 +2263,7 @@ void TEXT_OT_scroll(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER; /* properties */ - RNA_def_int(ot->srna, "lines", 1, INT_MIN, INT_MAX, _("Lines"), _("Number of lines to scroll."), -100, 100); + RNA_def_int(ot->srna, "lines", 1, INT_MIN, INT_MAX, "Lines", "Number of lines to scroll.", -100, 100); } /******************** scroll bar operator *******************/ @@ -2330,12 +2328,12 @@ static int scroll_bar_invoke(bContext *C, wmOperator *op, wmEvent *event) void TEXT_OT_scroll_bar(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Scrollbar"); + ot->name= "Scrollbar"; /*don't really see the difference between this and scroll. Both do basically the same thing (aside from keymaps).*/ ot->idname= "TEXT_OT_scroll_bar"; - ot->description= _("Scroll text screen"); + ot->description= "Scroll text screen"; /* api callbacks */ ot->invoke= scroll_bar_invoke; @@ -2347,7 +2345,7 @@ void TEXT_OT_scroll_bar(wmOperatorType *ot) ot->flag= OPTYPE_BLOCKING; /* properties */ - RNA_def_int(ot->srna, "lines", 1, INT_MIN, INT_MAX, _("Lines"), _("Number of lines to scroll."), -100, 100); + RNA_def_int(ot->srna, "lines", 1, INT_MIN, INT_MAX, "Lines", "Number of lines to scroll.", -100, 100); } /******************* set selection operator **********************/ @@ -2627,9 +2625,9 @@ static int set_selection_cancel(bContext *C, wmOperator *op) void TEXT_OT_selection_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Selection"); + ot->name= "Set Selection"; ot->idname= "TEXT_OT_selection_set"; - ot->description= _("Set cursor selection"); + ot->description= "Set cursor selection"; /* api callbacks */ ot->invoke= set_selection_invoke; @@ -2638,7 +2636,7 @@ void TEXT_OT_selection_set(wmOperatorType *ot) ot->poll= text_region_edit_poll; /* properties */ - RNA_def_boolean(ot->srna, "select", 0, _("Select"), _("Set selection end rather than cursor.")); + RNA_def_boolean(ot->srna, "select", 0, "Select", "Set selection end rather than cursor."); } /******************* set cursor operator **********************/ @@ -2681,9 +2679,9 @@ static int set_cursor_invoke(bContext *C, wmOperator *op, wmEvent *event) void TEXT_OT_cursor_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Cursor"); + ot->name= "Set Cursor"; ot->idname= "TEXT_OT_cursor_set"; - ot->description= _("Set cursor position"); + ot->description= "Set cursor position"; /* api callbacks */ ot->invoke= set_cursor_invoke; @@ -2737,9 +2735,9 @@ static int line_number_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent *even void TEXT_OT_line_number(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Line Number"); + ot->name= "Line Number"; ot->idname= "TEXT_OT_line_number"; - ot->description= _("The current line number"); + ot->description= "The current line number"; /* api callbacks */ ot->invoke= line_number_invoke; @@ -2812,9 +2810,9 @@ static int insert_invoke(bContext *C, wmOperator *op, wmEvent *event) void TEXT_OT_insert(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Insert"); + ot->name= "Insert"; ot->idname= "TEXT_OT_insert"; - ot->description= _("Insert text at cursor position"); + ot->description= "Insert text at cursor position"; /* api callbacks */ ot->exec= insert_exec; @@ -2822,7 +2820,7 @@ void TEXT_OT_insert(wmOperatorType *ot) ot->poll= text_edit_poll; /* properties */ - RNA_def_string(ot->srna, "text", "", 0, _("Text"), _("Text to insert at the cursor position.")); + RNA_def_string(ot->srna, "text", "", 0, "Text", "Text to insert at the cursor position."); } /******************* find operator *********************/ @@ -2931,9 +2929,9 @@ static int find_exec(bContext *C, wmOperator *op) void TEXT_OT_find(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Find"); + ot->name= "Find"; ot->idname= "TEXT_OT_find"; - ot->description= _("Find specified text"); + ot->description= "Find specified text"; /* api callbacks */ ot->exec= find_exec; @@ -2950,9 +2948,9 @@ static int replace_exec(bContext *C, wmOperator *op) void TEXT_OT_replace(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Replace"); + ot->name= "Replace"; ot->idname= "TEXT_OT_replace"; - ot->description= _("Replace text with the specified text"); + ot->description= "Replace text with the specified text"; /* api callbacks */ ot->exec= replace_exec; @@ -2969,9 +2967,9 @@ static int mark_all_exec(bContext *C, wmOperator *op) void TEXT_OT_mark_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Mark All"); + ot->name= "Mark All"; ot->idname= "TEXT_OT_mark_all"; - ot->description= _("Mark all specified text"); + ot->description= "Mark all specified text"; /* api callbacks */ ot->exec= mark_all_exec; @@ -2999,9 +2997,9 @@ static int find_set_selected_exec(bContext *C, wmOperator *op) void TEXT_OT_find_set_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Find Set Selected"); + ot->name= "Find Set Selected"; ot->idname= "TEXT_OT_find_set_selected"; - ot->description= _("Find specified text and set as selected"); + ot->description= "Find specified text and set as selected"; /* api callbacks */ ot->exec= find_set_selected_exec; @@ -3026,9 +3024,9 @@ static int replace_set_selected_exec(bContext *C, wmOperator *UNUSED(op)) void TEXT_OT_replace_set_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Replace Set Selected"); + ot->name= "Replace Set Selected"; ot->idname= "TEXT_OT_replace_set_selected"; - ot->description= _("Replace text with specified text and set as selected"); + ot->description= "Replace text with specified text and set as selected"; /* api callbacks */ ot->exec= replace_set_selected_exec; @@ -3161,9 +3159,9 @@ static int resolve_conflict_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED( void TEXT_OT_resolve_conflict(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Resolve Conflict"); + ot->name= "Resolve Conflict"; ot->idname= "TEXT_OT_resolve_conflict"; - ot->description= _("When external text is out of sync, resolve the conflict"); + ot->description= "When external text is out of sync, resolve the conflict"; /* api callbacks */ ot->exec= resolve_conflict_exec; @@ -3171,7 +3169,7 @@ void TEXT_OT_resolve_conflict(wmOperatorType *ot) ot->poll= save_poll; /* properties */ - RNA_def_enum(ot->srna, "resolution", resolution_items, RESOLVE_IGNORE, _("Resolution"), _("How to solve conflict due to different in internal and external text.")); + RNA_def_enum(ot->srna, "resolution", resolution_items, RESOLVE_IGNORE, "Resolution", "How to solve conflict due to different in internal and external text."); } /********************** to 3d object operator *****************/ @@ -3189,9 +3187,9 @@ static int to_3d_object_exec(bContext *C, wmOperator *op) void TEXT_OT_to_3d_object(wmOperatorType *ot) { /* identifiers */ - ot->name= _("To 3D Object"); + ot->name= "To 3D Object"; ot->idname= "TEXT_OT_to_3d_object"; - ot->description= _("Create 3d text object from active text data block"); + ot->description= "Create 3d text object from active text data block"; /* api callbacks */ ot->exec= to_3d_object_exec; @@ -3201,7 +3199,7 @@ void TEXT_OT_to_3d_object(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "split_lines", 0, _("Split Lines"), _("Create one object per line in the text.")); + RNA_def_boolean(ot->srna, "split_lines", 0, "Split Lines", "Create one object per line in the text."); } diff --git a/source/blender/editors/space_time/CMakeLists.txt b/source/blender/editors/space_time/CMakeLists.txt index d6bf4a551ce..758d1e629f9 100644 --- a/source/blender/editors/space_time/CMakeLists.txt +++ b/source/blender/editors/space_time/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/space_time/SConscript b/source/blender/editors/space_time/SConscript index ec59d774f65..c08339ba692 100644 --- a/source/blender/editors/space_time/SConscript +++ b/source/blender/editors/space_time/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../makesrna ../../blenloader' diff --git a/source/blender/editors/space_time/time_ops.c b/source/blender/editors/space_time/time_ops.c index 538443fb9c7..78d903a2997 100644 --- a/source/blender/editors/space_time/time_ops.c +++ b/source/blender/editors/space_time/time_ops.c @@ -37,8 +37,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "ED_screen.h" @@ -77,9 +75,9 @@ static int time_set_sfra_exec (bContext *C, wmOperator *UNUSED(op)) static void TIME_OT_start_frame_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Start Frame"); + ot->name= "Set Start Frame"; ot->idname= "TIME_OT_start_frame_set"; - ot->description=_("Set the start frame"); + ot->description="Set the start frame"; /* api callbacks */ ot->exec= time_set_sfra_exec; @@ -119,9 +117,9 @@ static int time_set_efra_exec (bContext *C, wmOperator *UNUSED(op)) static void TIME_OT_end_frame_set (wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set End Frame"); + ot->name= "Set End Frame"; ot->idname= "TIME_OT_end_frame_set"; - ot->description=_("Set the end frame"); + ot->description="Set the end frame"; /* api callbacks */ ot->exec= time_set_efra_exec; @@ -161,9 +159,9 @@ static int time_view_all_exec (bContext *C, wmOperator *UNUSED(op)) static void TIME_OT_view_all (wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); + ot->name= "View All"; ot->idname= "TIME_OT_view_all"; - ot->description= _("Show the entire playable frame range"); + ot->description= "Show the entire playable frame range"; /* api callbacks */ ot->exec= time_view_all_exec; diff --git a/source/blender/editors/space_view3d/view3d_buttons.c b/source/blender/editors/space_view3d/view3d_buttons.c index 67e523ec355..50c587194b7 100644 --- a/source/blender/editors/space_view3d/view3d_buttons.c +++ b/source/blender/editors/space_view3d/view3d_buttons.c @@ -52,8 +52,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_action.h" #include "BKE_context.h" #include "BKE_curve.h" @@ -1471,8 +1469,8 @@ static int view3d_properties(bContext *C, wmOperator *UNUSED(op)) void VIEW3D_OT_properties(wmOperatorType *ot) { - ot->name= _("Properties"); - ot->description= _("Toggles the properties panel display"); + ot->name= "Properties"; + ot->description= "Toggles the properties panel display"; ot->idname= "VIEW3D_OT_properties"; ot->exec= view3d_properties; diff --git a/source/blender/editors/space_view3d/view3d_edit.c b/source/blender/editors/space_view3d/view3d_edit.c index af08690b869..761de836cfb 100644 --- a/source/blender/editors/space_view3d/view3d_edit.c +++ b/source/blender/editors/space_view3d/view3d_edit.c @@ -49,8 +49,6 @@ #include "BLI_rand.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_image.h" #include "BKE_library.h" @@ -579,13 +577,13 @@ enum { void viewrotate_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {VIEW_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, + {VIEW_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, - {VIEWROT_MODAL_AXIS_SNAP_ENABLE, "AXIS_SNAP_ENABLE", 0, N_("Enable Axis Snap"), ""}, - {VIEWROT_MODAL_AXIS_SNAP_DISABLE, "AXIS_SNAP_DISABLE", 0, N_("Disable Axis Snap"), ""}, + {VIEWROT_MODAL_AXIS_SNAP_ENABLE, "AXIS_SNAP_ENABLE", 0, "Enable Axis Snap", ""}, + {VIEWROT_MODAL_AXIS_SNAP_DISABLE, "AXIS_SNAP_DISABLE", 0, "Disable Axis Snap", ""}, - {VIEWROT_MODAL_SWITCH_ZOOM, "SWITCH_TO_ZOOM", 0, N_("Switch to Zoom")}, - {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, N_("Switch to Move")}, + {VIEWROT_MODAL_SWITCH_ZOOM, "SWITCH_TO_ZOOM", 0, "Switch to Zoom"}, + {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, "Switch to Move"}, {0, NULL, 0, NULL, NULL}}; @@ -594,7 +592,7 @@ void viewrotate_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if(keymap) return; - keymap= WM_modalkeymap_add(keyconf, _("View3D Rotate Modal"), RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "View3D Rotate Modal", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, MIDDLEMOUSE, KM_RELEASE, KM_ANY, 0, VIEW_MODAL_CONFIRM); @@ -922,8 +920,8 @@ void VIEW3D_OT_rotate(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Rotate view"); - ot->description = _("Rotate the view"); + ot->name= "Rotate view"; + ot->description = "Rotate the view"; ot->idname= "VIEW3D_OT_rotate"; /* api callbacks */ @@ -1218,10 +1216,10 @@ void VIEW3D_OT_ndof_pan(struct wmOperatorType *ot) void viewmove_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {VIEW_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, + {VIEW_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, - {VIEWROT_MODAL_SWITCH_ZOOM, "SWITCH_TO_ZOOM", 0, N_("Switch to Zoom")}, - {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, N_("Switch to Rotate")}, + {VIEWROT_MODAL_SWITCH_ZOOM, "SWITCH_TO_ZOOM", 0, "Switch to Zoom"}, + {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, "Switch to Rotate"}, {0, NULL, 0, NULL, NULL}}; @@ -1230,7 +1228,7 @@ void viewmove_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if(keymap) return; - keymap= WM_modalkeymap_add(keyconf, _("View3D Move Modal"), RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "View3D Move Modal", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, MIDDLEMOUSE, KM_RELEASE, KM_ANY, 0, VIEW_MODAL_CONFIRM); @@ -1357,8 +1355,8 @@ void VIEW3D_OT_move(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Move view"); - ot->description = _("Move the view"); + ot->name= "Move view"; + ot->description = "Move the view"; ot->idname= "VIEW3D_OT_move"; /* api callbacks */ @@ -1378,10 +1376,10 @@ void VIEW3D_OT_move(wmOperatorType *ot) void viewzoom_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {VIEW_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, + {VIEW_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, - {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, N_("Switch to Rotate")}, - {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, N_("Switch to Move")}, + {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, "Switch to Rotate"}, + {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, "Switch to Move"}, {0, NULL, 0, NULL, NULL}}; @@ -1390,7 +1388,7 @@ void viewzoom_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if(keymap) return; - keymap= WM_modalkeymap_add(keyconf, _("View3D Zoom Modal"), RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "View3D Zoom Modal", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, MIDDLEMOUSE, KM_RELEASE, KM_ANY, 0, VIEW_MODAL_CONFIRM); @@ -1629,10 +1627,10 @@ static int viewzoom_exec(bContext *C, wmOperator *op) void viewdolly_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {VIEW_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, + {VIEW_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, - {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, N_("Switch to Rotate")}, - {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, N_("Switch to Move")}, + {VIEWROT_MODAL_SWITCH_ROTATE, "SWITCH_TO_ROTATE", 0, "Switch to Rotate"}, + {VIEWROT_MODAL_SWITCH_MOVE, "SWITCH_TO_MOVE", 0, "Switch to Move"}, {0, NULL, 0, NULL, NULL}}; @@ -1641,7 +1639,7 @@ void viewdolly_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if(keymap) return; - keymap= WM_modalkeymap_add(keyconf, _("View3D Dolly Modal"), RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "View3D Dolly Modal", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, MIDDLEMOUSE, KM_RELEASE, KM_ANY, 0, VIEW_MODAL_CONFIRM); @@ -1719,8 +1717,8 @@ static int viewzoom_cancel(bContext *C, wmOperator *op) void VIEW3D_OT_zoom(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom View"); - ot->description = _("Zoom in/out in the view"); + ot->name= "Zoom View"; + ot->description = "Zoom in/out in the view"; ot->idname= "VIEW3D_OT_zoom"; /* api callbacks */ @@ -1733,9 +1731,9 @@ void VIEW3D_OT_zoom(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER; - RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, _("Delta"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "mx", 0, 0, INT_MAX, _("Zoom Position X"), "", 0, INT_MAX); - RNA_def_int(ot->srna, "my", 0, 0, INT_MAX, _("Zoom Position Y"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, "Delta", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mx", 0, 0, INT_MAX, "Zoom Position X", "", 0, INT_MAX); + RNA_def_int(ot->srna, "my", 0, 0, INT_MAX, "Zoom Position Y", "", 0, INT_MAX); } @@ -1952,8 +1950,8 @@ static int viewdolly_cancel(bContext *C, wmOperator *op) void VIEW3D_OT_dolly(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Dolly view"); - ot->description = _("Dolly in/out in the view"); + ot->name= "Dolly view"; + ot->description = "Dolly in/out in the view"; ot->idname= "VIEW3D_OT_dolly"; /* api callbacks */ @@ -1966,9 +1964,9 @@ void VIEW3D_OT_dolly(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_BLOCKING|OPTYPE_GRAB_POINTER; - RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, _("Delta"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "mx", 0, 0, INT_MAX, _("Zoom Position X"), "", 0, INT_MAX); - RNA_def_int(ot->srna, "my", 0, 0, INT_MAX, _("Zoom Position Y"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "delta", 0, INT_MIN, INT_MAX, "Delta", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "mx", 0, 0, INT_MAX, "Zoom Position X", "", 0, INT_MAX); + RNA_def_int(ot->srna, "my", 0, 0, INT_MAX, "Zoom Position Y", "", 0, INT_MAX); } @@ -2061,8 +2059,8 @@ static int view3d_all_exec(bContext *C, wmOperator *op) /* was view3d_home() in void VIEW3D_OT_view_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View All"); - ot->description = _("View all objects in scene"); + ot->name= "View All"; + ot->description = "View all objects in scene"; ot->idname= "VIEW3D_OT_view_all"; /* api callbacks */ @@ -2072,7 +2070,7 @@ void VIEW3D_OT_view_all(wmOperatorType *ot) /* flags */ ot->flag= 0; - RNA_def_boolean(ot->srna, "center", 0, _("Center"), ""); + RNA_def_boolean(ot->srna, "center", 0, "Center", ""); } @@ -2208,8 +2206,8 @@ void VIEW3D_OT_view_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Selected"); - ot->description = _("Move the view to the selection center"); + ot->name= "View Selected"; + ot->description = "Move the view to the selection center"; ot->idname= "VIEW3D_OT_view_selected"; /* api callbacks */ @@ -2243,8 +2241,8 @@ static int viewcenter_cursor_exec(bContext *C, wmOperator *UNUSED(op)) void VIEW3D_OT_view_center_cursor(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Center View to Cursor"); - ot->description= _("Centers the view so that the cursor is in the middle of the view"); + ot->name= "Center View to Cursor"; + ot->description= "Centers the view so that the cursor is in the middle of the view"; ot->idname= "VIEW3D_OT_view_center_cursor"; /* api callbacks */ @@ -2282,8 +2280,8 @@ static int view3d_center_camera_exec(bContext *C, wmOperator *UNUSED(op)) /* was void VIEW3D_OT_view_center_camera(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Camera Center"); - ot->description = _("Center the camera view"); + ot->name= "View Camera Center"; + ot->description = "Center the camera view"; ot->idname= "VIEW3D_OT_view_center_camera"; /* api callbacks */ @@ -2347,8 +2345,8 @@ static int render_border_exec(bContext *C, wmOperator *op) void VIEW3D_OT_render_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Render Border"); - ot->description = _("Set the boundaries of the border render and enables border render "); + ot->name= "Set Render Border"; + ot->description = "Set the boundaries of the border render and enables border render "; ot->idname= "VIEW3D_OT_render_border"; /* api callbacks */ @@ -2363,10 +2361,10 @@ void VIEW3D_OT_render_border(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* rna */ - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, "X Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, "X Max", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, "Y Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, "Y Max", "", INT_MIN, INT_MAX); } /* ********************* Border Zoom operator ****************** */ @@ -2503,8 +2501,8 @@ static int view3d_zoom_border_invoke(bContext *C, wmOperator *op, wmEvent *event void VIEW3D_OT_zoom_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Zoom"); - ot->description = _("Zoom in the view to the nearest object contained in the border"); + ot->name= "Border Zoom"; + ot->description = "Zoom in the view to the nearest object contained in the border"; ot->idname= "VIEW3D_OT_zoom_border"; /* api callbacks */ @@ -2519,10 +2517,10 @@ void VIEW3D_OT_zoom_border(wmOperatorType *ot) ot->flag= 0; /* rna */ - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, "X Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, "X Max", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, "Y Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, "Y Max", "", INT_MIN, INT_MAX); } @@ -2554,8 +2552,8 @@ static int view3d_zoom_1_to_1_camera_exec(bContext *C, wmOperator *UNUSED(op)) void VIEW3D_OT_zoom_camera_1_to_1(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Zoom Camera 1:1"); - ot->description = _("Match the camera to 1:1 to the render output"); + ot->name= "Zoom Camera 1:1"; + ot->description = "Match the camera to 1:1 to the render output"; ot->idname= "VIEW3D_OT_zoom_camera_1_to_1"; /* api callbacks */ @@ -2569,13 +2567,13 @@ void VIEW3D_OT_zoom_camera_1_to_1(wmOperatorType *ot) /* ********************* Changing view operator ****************** */ static EnumPropertyItem prop_view_items[] = { - {RV3D_VIEW_FRONT, "FRONT", 0, N_("Front"), N_("View From the Front")}, - {RV3D_VIEW_BACK, "BACK", 0, N_("Back"), N_("View From the Back")}, - {RV3D_VIEW_LEFT, "LEFT", 0, N_("Left"), N_("View From the Left")}, - {RV3D_VIEW_RIGHT, "RIGHT", 0, N_("Right"), N_("View From the Right")}, - {RV3D_VIEW_TOP, "TOP", 0, N_("Top"), N_("View From the Top")}, - {RV3D_VIEW_BOTTOM, "BOTTOM", 0, N_("Bottom"), N_("View From the Bottom")}, - {RV3D_VIEW_CAMERA, "CAMERA", 0, N_("Camera"), N_("View From the active amera")}, + {RV3D_VIEW_FRONT, "FRONT", 0, "Front", "View From the Front"}, + {RV3D_VIEW_BACK, "BACK", 0, "Back", "View From the Back"}, + {RV3D_VIEW_LEFT, "LEFT", 0, "Left", "View From the Left"}, + {RV3D_VIEW_RIGHT, "RIGHT", 0, "Right", "View From the Right"}, + {RV3D_VIEW_TOP, "TOP", 0, "Top", "View From the Top"}, + {RV3D_VIEW_BOTTOM, "BOTTOM", 0, "Bottom", "View From the Bottom"}, + {RV3D_VIEW_CAMERA, "CAMERA", 0, "Camera", "View From the active amera"}, {0, NULL, 0, NULL, NULL}}; @@ -2776,8 +2774,8 @@ static int viewnumpad_exec(bContext *C, wmOperator *op) void VIEW3D_OT_viewnumpad(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View numpad"); - ot->description = _("Set the view"); + ot->name= "View numpad"; + ot->description = "Set the view"; ot->idname= "VIEW3D_OT_viewnumpad"; /* api callbacks */ @@ -2787,15 +2785,15 @@ void VIEW3D_OT_viewnumpad(wmOperatorType *ot) /* flags */ ot->flag= 0; - RNA_def_enum(ot->srna, "type", prop_view_items, 0, _("View"), _("The Type of view")); - RNA_def_boolean(ot->srna, "align_active", 0, _("Align Active"), _("Align to the active objects axis")); + RNA_def_enum(ot->srna, "type", prop_view_items, 0, "View", "The Type of view"); + RNA_def_boolean(ot->srna, "align_active", 0, "Align Active", "Align to the active objects axis"); } static EnumPropertyItem prop_view_orbit_items[] = { - {V3D_VIEW_STEPLEFT, "ORBITLEFT", 0, N_("Orbit Left"), N_("Orbit the view around to the Left")}, - {V3D_VIEW_STEPRIGHT, "ORBITRIGHT", 0, N_("Orbit Right"), N_("Orbit the view around to the Right")}, - {V3D_VIEW_STEPUP, "ORBITUP", 0, N_("Orbit Up"), N_("Orbit the view Up")}, - {V3D_VIEW_STEPDOWN, "ORBITDOWN", 0, N_("Orbit Down"), N_("Orbit the view Down")}, + {V3D_VIEW_STEPLEFT, "ORBITLEFT", 0, "Orbit Left", "Orbit the view around to the Left"}, + {V3D_VIEW_STEPRIGHT, "ORBITRIGHT", 0, "Orbit Right", "Orbit the view around to the Right"}, + {V3D_VIEW_STEPUP, "ORBITUP", 0, "Orbit Up", "Orbit the view Up"}, + {V3D_VIEW_STEPDOWN, "ORBITDOWN", 0, "Orbit Down", "Orbit the view Down"}, {0, NULL, 0, NULL, NULL}}; static int vieworbit_exec(bContext *C, wmOperator *op) @@ -2845,8 +2843,8 @@ static int vieworbit_exec(bContext *C, wmOperator *op) void VIEW3D_OT_view_orbit(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Orbit"); - ot->description = _("Orbit the view"); + ot->name= "View Orbit"; + ot->description = "Orbit the view"; ot->idname= "VIEW3D_OT_view_orbit"; /* api callbacks */ @@ -2855,14 +2853,14 @@ void VIEW3D_OT_view_orbit(wmOperatorType *ot) /* flags */ ot->flag= 0; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_view_orbit_items), 0, _("Orbit"), _("Direction of View Orbit")); + RNA_def_enum(ot->srna, "type", prop_view_orbit_items, 0, "Orbit", "Direction of View Orbit"); } static EnumPropertyItem prop_view_pan_items[] = { - {V3D_VIEW_PANLEFT, "PANLEFT", 0, N_("Pan Left"), N_("Pan the view to the Left")}, - {V3D_VIEW_PANRIGHT, "PANRIGHT", 0, N_("Pan Right"), N_("Pan the view to the Right")}, - {V3D_VIEW_PANUP, "PANUP", 0, N_("Pan Up"), N_("Pan the view Up")}, - {V3D_VIEW_PANDOWN, "PANDOWN", 0, N_("Pan Down"), N_("Pan the view Down")}, + {V3D_VIEW_PANLEFT, "PANLEFT", 0, "Pan Left", "Pan the view to the Left"}, + {V3D_VIEW_PANRIGHT, "PANRIGHT", 0, "Pan Right", "Pan the view to the Right"}, + {V3D_VIEW_PANUP, "PANUP", 0, "Pan Up", "Pan the view Up"}, + {V3D_VIEW_PANDOWN, "PANDOWN", 0, "Pan Down", "Pan the view Down"}, {0, NULL, 0, NULL, NULL}}; static int viewpan_exec(bContext *C, wmOperator *op) @@ -2893,8 +2891,8 @@ static int viewpan_exec(bContext *C, wmOperator *op) void VIEW3D_OT_view_pan(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Pan"); - ot->description = _("Pan the view"); + ot->name= "View Pan"; + ot->description = "Pan the view"; ot->idname= "VIEW3D_OT_view_pan"; /* api callbacks */ @@ -2903,7 +2901,7 @@ void VIEW3D_OT_view_pan(wmOperatorType *ot) /* flags */ ot->flag= 0; - RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(prop_view_pan_items), 0, _("Pan"), _("Direction of View Pan")); + RNA_def_enum(ot->srna, "type", prop_view_pan_items, 0, "Pan", "Direction of View Pan"); } static int viewpersportho_exec(bContext *C, wmOperator *UNUSED(op)) @@ -2925,8 +2923,8 @@ static int viewpersportho_exec(bContext *C, wmOperator *UNUSED(op)) void VIEW3D_OT_view_persportho(wmOperatorType *ot) { /* identifiers */ - ot->name= _("View Persp/Ortho"); - ot->description = _("Switch the current view from perspective/orthographic"); + ot->name= "View Persp/Ortho"; + ot->description = "Switch the current view from perspective/orthographic"; ot->idname= "VIEW3D_OT_view_persportho"; /* api callbacks */ @@ -3002,8 +3000,8 @@ static int background_image_add_invoke(bContext *C, wmOperator *op, wmEvent *UNU void VIEW3D_OT_background_image_add(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Add Background Image"); - ot->description= _("Add a new background image"); + ot->name = "Add Background Image"; + ot->description= "Add a new background image"; ot->idname = "VIEW3D_OT_background_image_add"; /* api callbacks */ @@ -3015,8 +3013,8 @@ void VIEW3D_OT_background_image_add(wmOperatorType *ot) ot->flag = 0; /* properties */ - RNA_def_string(ot->srna, "name", "Image", 24, _("Name"), _("Image name to assign.")); - RNA_def_string(ot->srna, "filepath", "Path", FILE_MAX, _("Filepath"), _("Path to image file")); + RNA_def_string(ot->srna, "name", "Image", 24, "Name", "Image name to assign."); + RNA_def_string(ot->srna, "filepath", "Path", FILE_MAX, "Filepath", "Path to image file"); } @@ -3043,8 +3041,8 @@ static int background_image_remove_exec(bContext *C, wmOperator *op) void VIEW3D_OT_background_image_remove(wmOperatorType *ot) { /* identifiers */ - ot->name = _("Remove Background Image"); - ot->description= _("Remove a background image from the 3D view"); + ot->name = "Remove Background Image"; + ot->description= "Remove a background image from the 3D view"; ot->idname = "VIEW3D_OT_background_image_remove"; /* api callbacks */ @@ -3054,7 +3052,7 @@ void VIEW3D_OT_background_image_remove(wmOperatorType *ot) /* flags */ ot->flag = 0; - RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, _("Index"), _("Background image index to remove "), 0, INT_MAX); + RNA_def_int(ot->srna, "index", 0, 0, INT_MAX, "Index", "Background image index to remove ", 0, INT_MAX); } /* ********************* set clipping operator ****************** */ @@ -3142,8 +3140,8 @@ void VIEW3D_OT_clip_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Clipping Border"); - ot->description = _("Set the view clipping border"); + ot->name= "Clipping Border"; + ot->description = "Set the view clipping border"; ot->idname= "VIEW3D_OT_clip_border"; /* api callbacks */ @@ -3158,10 +3156,10 @@ void VIEW3D_OT_clip_border(wmOperatorType *ot) ot->flag= 0; /* rna */ - RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, _("X Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, _("X Max"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, _("Y Min"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, _("Y Max"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmin", 0, INT_MIN, INT_MAX, "X Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "xmax", 0, INT_MIN, INT_MAX, "X Max", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymin", 0, INT_MIN, INT_MAX, "Y Min", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "ymax", 0, INT_MIN, INT_MAX, "Y Max", "", INT_MIN, INT_MAX); } /* ***************** 3d cursor cursor op ******************* */ @@ -3235,8 +3233,8 @@ void VIEW3D_OT_cursor3d(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set 3D Cursor"); - ot->description = _("Set the location of the 3D cursor"); + ot->name= "Set 3D Cursor"; + ot->description = "Set the location of the 3D cursor"; ot->idname= "VIEW3D_OT_cursor3d"; /* api callbacks */ @@ -3277,8 +3275,8 @@ void VIEW3D_OT_manipulator(wmOperatorType *ot) { /* identifiers */ - ot->name= _("3D Manipulator"); - ot->description = _("Manipulate selected item by axis"); + ot->name= "3D Manipulator"; + ot->description = "Manipulate selected item by axis"; ot->idname= "VIEW3D_OT_manipulator"; /* api callbacks */ @@ -3311,8 +3309,8 @@ static int enable_manipulator_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE void VIEW3D_OT_enable_manipulator(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Enable 3D Manipulator"); - ot->description = _("Enable the transform manipulator for use"); + ot->name= "Enable 3D Manipulator"; + ot->description = "Enable the transform manipulator for use"; ot->idname= "VIEW3D_OT_enable_manipulator"; /* api callbacks */ @@ -3320,9 +3318,9 @@ void VIEW3D_OT_enable_manipulator(wmOperatorType *ot) ot->poll= ED_operator_view3d_active; /* rna later */ - RNA_def_boolean(ot->srna, "translate", 0, _("Translate"), _("Enable the translate manipulator")); - RNA_def_boolean(ot->srna, "rotate", 0, _("Rotate"), _("Enable the rotate manipulator")); - RNA_def_boolean(ot->srna, "scale", 0, _("Scale"), _("Enable the scale manipulator")); + RNA_def_boolean(ot->srna, "translate", 0, "Translate", "Enable the translate manipulator"); + RNA_def_boolean(ot->srna, "rotate", 0, "Rotate", "Enable the rotate manipulator"); + RNA_def_boolean(ot->srna, "scale", 0, "Scale", "Enable the scale manipulator"); } /* ************************* below the line! *********************** */ diff --git a/source/blender/editors/space_view3d/view3d_fly.c b/source/blender/editors/space_view3d/view3d_fly.c index 6835054a92c..30d1a508888 100644 --- a/source/blender/editors/space_view3d/view3d_fly.c +++ b/source/blender/editors/space_view3d/view3d_fly.c @@ -42,10 +42,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" -#include "BLF_api.h" -#include "RNA_define.h" -#include "RNA_access.h" - #include "BKE_context.h" #include "BKE_object.h" #include "BKE_report.h" @@ -87,26 +83,26 @@ void fly_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {FLY_MODAL_CANCEL, "CANCEL", 0, N_("Cancel"), ""}, - {FLY_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, - {FLY_MODAL_ACCELERATE, "ACCELERATE", 0, N_("Accelerate"), ""}, - {FLY_MODAL_DECELERATE, "DECELERATE", 0, N_("Decelerate"), ""}, + {FLY_MODAL_CANCEL, "CANCEL", 0, "Cancel", ""}, + {FLY_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, + {FLY_MODAL_ACCELERATE, "ACCELERATE", 0, "Accelerate", ""}, + {FLY_MODAL_DECELERATE, "DECELERATE", 0, "Decelerate", ""}, - {FLY_MODAL_PAN_ENABLE, "PAN_ENABLE", 0, N_("Pan Enable"), ""}, - {FLY_MODAL_PAN_DISABLE, "PAN_DISABLE", 0, N_("Pan Disable"), ""}, + {FLY_MODAL_PAN_ENABLE, "PAN_ENABLE", 0, "Pan Enable", ""}, + {FLY_MODAL_PAN_DISABLE, "PAN_DISABLE", 0, "Pan Disable", ""}, - {FLY_MODAL_DIR_FORWARD, "FORWARD", 0, N_("Fly Forward"), ""}, - {FLY_MODAL_DIR_BACKWARD,"BACKWARD", 0, N_("Fly Backward"), ""}, - {FLY_MODAL_DIR_LEFT, "LEFT", 0, N_("Fly Left"), ""}, - {FLY_MODAL_DIR_RIGHT, "RIGHT", 0, N_("Fly Right"), ""}, - {FLY_MODAL_DIR_UP, "UP", 0, N_("Fly Up"), ""}, - {FLY_MODAL_DIR_DOWN, "DOWN", 0, N_("Fly Down"), ""}, + {FLY_MODAL_DIR_FORWARD, "FORWARD", 0, "Fly Forward", ""}, + {FLY_MODAL_DIR_BACKWARD,"BACKWARD", 0, "Fly Backward", ""}, + {FLY_MODAL_DIR_LEFT, "LEFT", 0, "Fly Left", ""}, + {FLY_MODAL_DIR_RIGHT, "RIGHT", 0, "Fly Right", ""}, + {FLY_MODAL_DIR_UP, "UP", 0, "Fly Up", ""}, + {FLY_MODAL_DIR_DOWN, "DOWN", 0, "Fly Down", ""}, - {FLY_MODAL_AXIS_LOCK_X, "AXIS_LOCK_X", 0, N_("X Axis Correction"), N_("X axis correction (toggle)")}, - {FLY_MODAL_AXIS_LOCK_Z, "AXIS_LOCK_Z", 0, N_("X Axis Correction"), N_("Z axis correction (toggle)")}, + {FLY_MODAL_AXIS_LOCK_X, "AXIS_LOCK_X", 0, "X Axis Correction", "X axis correction (toggle)"}, + {FLY_MODAL_AXIS_LOCK_Z, "AXIS_LOCK_Z", 0, "X Axis Correction", "Z axis correction (toggle)"}, - {FLY_MODAL_PRECISION_ENABLE, "PRECISION_ENABLE", 0, N_("Precision Enable"), ""}, - {FLY_MODAL_PRECISION_DISABLE, "PRECISION_DISABLE", 0, N_("Precision Disable"), ""}, + {FLY_MODAL_PRECISION_ENABLE, "PRECISION_ENABLE", 0, "Precision Enable", ""}, + {FLY_MODAL_PRECISION_DISABLE, "PRECISION_DISABLE", 0, "Precision Disable", ""}, {0, NULL, 0, NULL, NULL}}; @@ -115,7 +111,7 @@ void fly_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if (keymap) return; - keymap= WM_modalkeymap_add(keyconf, "View3D Fly Modal", RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "View3D Fly Modal", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, ESCKEY, KM_PRESS, KM_ANY, 0, FLY_MODAL_CANCEL); @@ -1152,8 +1148,8 @@ static int fly_modal(bContext *C, wmOperator *op, wmEvent *event) void VIEW3D_OT_fly(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Fly Navigation"); - ot->description= _("Interactively fly around the scene"); + ot->name= "Fly Navigation"; + ot->description= "Interactively fly around the scene"; ot->idname= "VIEW3D_OT_fly"; /* api callbacks */ diff --git a/source/blender/editors/space_view3d/view3d_header.c b/source/blender/editors/space_view3d/view3d_header.c index ec323a24a0c..86f2af5f942 100644 --- a/source/blender/editors/space_view3d/view3d_header.c +++ b/source/blender/editors/space_view3d/view3d_header.c @@ -254,8 +254,8 @@ static int view3d_layers_poll(bContext *C) void VIEW3D_OT_layers(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Layers"); - ot->description= _("Toggle layer(s) visibility"); + ot->name= "Layers"; + ot->description= "Toggle layer(s) visibility"; ot->idname= "VIEW3D_OT_layers"; /* api callbacks */ @@ -266,9 +266,9 @@ void VIEW3D_OT_layers(wmOperatorType *ot) /* flags */ ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_int(ot->srna, "nr", 1, 0, 20, _("Number"), _("The layer number to set, zero for all layers"), 0, 20); - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Add this layer to the current view layers")); - RNA_def_boolean(ot->srna, "toggle", 1, _("Toggle"), _("Toggle the layer")); + RNA_def_int(ot->srna, "nr", 1, 0, 20, "Number", "The layer number to set, zero for all layers", 0, 20); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Add this layer to the current view layers"); + RNA_def_boolean(ot->srna, "toggle", 1, "Toggle", "Toggle the layer"); } static char *view3d_modeselect_pup(Scene *scene) diff --git a/source/blender/editors/space_view3d/view3d_select.c b/source/blender/editors/space_view3d/view3d_select.c index a8f91f86a4f..65914ead899 100644 --- a/source/blender/editors/space_view3d/view3d_select.c +++ b/source/blender/editors/space_view3d/view3d_select.c @@ -54,8 +54,6 @@ #include "BLI_linklist.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_paint.h" #include "BKE_armature.h" @@ -864,8 +862,8 @@ static int view3d_lasso_select_exec(bContext *C, wmOperator *op) void VIEW3D_OT_select_lasso(wmOperatorType *ot) { - ot->name= _("Lasso Select"); - ot->description= _("Select items using lasso selection"); + ot->name= "Lasso Select"; + ot->description= "Select items using lasso selection"; ot->idname= "VIEW3D_OT_select_lasso"; ot->invoke= WM_gesture_lasso_invoke; @@ -878,8 +876,8 @@ void VIEW3D_OT_select_lasso(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; RNA_def_collection_runtime(ot->srna, "path", &RNA_OperatorMousePath, "Path", ""); - RNA_def_boolean(ot->srna, "deselect", 0, _("Deselect"), _("Deselect rather than select items.")); - RNA_def_boolean(ot->srna, "extend", 1, _("Extend"), _("Extend selection instead of deselecting everything first.")); + RNA_def_boolean(ot->srna, "deselect", 0, "Deselect", "Deselect rather than select items."); + RNA_def_boolean(ot->srna, "extend", 1, "Extend", "Extend selection instead of deselecting everything first."); } @@ -1818,8 +1816,8 @@ static int view3d_borderselect_exec(bContext *C, wmOperator *op) void VIEW3D_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); - ot->description= _("Select items using border selection"); + ot->name= "Border Select"; + ot->description= "Select items using border selection"; ot->idname= "VIEW3D_OT_select_border"; /* api callbacks */ @@ -1895,8 +1893,8 @@ static int view3d_select_invoke(bContext *C, wmOperator *op, wmEvent *event) void VIEW3D_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Activate/Select"); - ot->description= _("Activate/select item(s)"); + ot->name= "Activate/Select"; + ot->description= "Activate/select item(s)"; ot->idname= "VIEW3D_OT_select"; /* api callbacks */ @@ -1907,10 +1905,10 @@ void VIEW3D_OT_select(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "extend", 0, _("Extend"), _("Extend selection instead of deselecting everything first.")); - RNA_def_boolean(ot->srna, "center", 0, _("Center"), _("Use the object center when selecting, in editmode used to extend object selection.")); - RNA_def_boolean(ot->srna, "enumerate", 0, _("Enumerate"), _("List objects under the mouse (object mode only).")); - RNA_def_boolean(ot->srna, "object", 0, _("Object"), _("Use object selection (editmode only).")); + RNA_def_boolean(ot->srna, "extend", 0, "Extend", "Extend selection instead of deselecting everything first."); + RNA_def_boolean(ot->srna, "center", 0, "Center", "Use the object center when selecting, in editmode used to extend object selection."); + RNA_def_boolean(ot->srna, "enumerate", 0, "Enumerate", "List objects under the mouse (object mode only)."); + RNA_def_boolean(ot->srna, "object", 0, "Object", "Use object selection (editmode only)."); } @@ -2311,8 +2309,8 @@ static int view3d_circle_select_exec(bContext *C, wmOperator *op) void VIEW3D_OT_select_circle(wmOperatorType *ot) { - ot->name= _("Circle Select"); - ot->description= _("Select items using circle selection"); + ot->name= "Circle Select"; + ot->description= "Select items using circle selection"; ot->idname= "VIEW3D_OT_select_circle"; ot->invoke= WM_gesture_circle_invoke; @@ -2326,6 +2324,6 @@ void VIEW3D_OT_select_circle(wmOperatorType *ot) RNA_def_int(ot->srna, "x", 0, INT_MIN, INT_MAX, "X", "", INT_MIN, INT_MAX); RNA_def_int(ot->srna, "y", 0, INT_MIN, INT_MAX, "Y", "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "radius", 0, INT_MIN, INT_MAX, _("Radius"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, _("Event Type"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "radius", 0, INT_MIN, INT_MAX, "Radius", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, "Event Type", "", INT_MIN, INT_MAX); } diff --git a/source/blender/editors/space_view3d/view3d_toolbar.c b/source/blender/editors/space_view3d/view3d_toolbar.c index 05cdc20efcb..ad338cef207 100644 --- a/source/blender/editors/space_view3d/view3d_toolbar.c +++ b/source/blender/editors/space_view3d/view3d_toolbar.c @@ -82,7 +82,7 @@ static void view3d_panel_operator_redo_header(const bContext *C, Panel *pa) wmOperator *op= WM_operator_last_redo(C); if(op) BLI_strncpy(pa->drawname, op->type->name, sizeof(pa->drawname)); - else BLI_strncpy(pa->drawname, _("Operator"), sizeof(pa->drawname)); + else BLI_strncpy(pa->drawname, N_("Operator"), sizeof(pa->drawname)); } static void view3d_panel_operator_redo_operator(const bContext *C, Panel *pa, wmOperator *op) @@ -259,8 +259,8 @@ static int view3d_toolshelf(bContext *C, wmOperator *UNUSED(op)) void VIEW3D_OT_toolshelf(wmOperatorType *ot) { - ot->name= _("Tool Shelf"); - ot->description= _("Toggles tool shelf display"); + ot->name= "Tool Shelf"; + ot->description= "Toggles tool shelf display"; ot->idname= "VIEW3D_OT_toolshelf"; ot->exec= view3d_toolshelf; diff --git a/source/blender/editors/space_view3d/view3d_view.c b/source/blender/editors/space_view3d/view3d_view.c index b1641da7608..44ae6837aa2 100644 --- a/source/blender/editors/space_view3d/view3d_view.c +++ b/source/blender/editors/space_view3d/view3d_view.c @@ -43,8 +43,6 @@ #include "BLI_listbase.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_anim.h" #include "BKE_action.h" #include "BKE_context.h" @@ -358,9 +356,9 @@ void VIEW3D_OT_smoothview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Smooth View"); + ot->name= "Smooth View"; ot->idname= "VIEW3D_OT_smoothview"; - ot->description=_("The time to animate the change of view (in milliseconds)"); + ot->description="The time to animate the change of view (in milliseconds)"; /* api callbacks */ ot->invoke= view3d_smoothview_invoke; @@ -408,8 +406,8 @@ void VIEW3D_OT_setcameratoview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Align Camera To View"); - ot->description= _("Set camera view to active view"); + ot->name= "Align Camera To View"; + ot->description= "Set camera view to active view"; ot->idname= "VIEW3D_OT_camera_to_view"; /* api callbacks */ @@ -454,8 +452,8 @@ void VIEW3D_OT_object_as_camera(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Active Object as Camera"); - ot->description= _("Set the active object as the active camera for this view or scene"); + ot->name= "Set Active Object as Camera"; + ot->description= "Set the active object as the active camera for this view or scene"; ot->idname= "VIEW3D_OT_object_as_camera"; /* api callbacks */ @@ -1620,8 +1618,8 @@ void VIEW3D_OT_localview(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Local View"); - ot->description= _("Toggle display of selected object(s) separately and centered in view"); + ot->name= "Local View"; + ot->description= "Toggle display of selected object(s) separately and centered in view"; ot->idname= "VIEW3D_OT_localview"; /* api callbacks */ @@ -1846,8 +1844,8 @@ void VIEW3D_OT_game_start(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Start Game Engine"); - ot->description= _("Start game engine"); + ot->name= "Start Game Engine"; + ot->description= "Start game engine"; ot->idname= "VIEW3D_OT_game_start"; /* api callbacks */ diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c index ae9acf7efc4..82598e0b5c6 100644 --- a/source/blender/editors/transform/transform.c +++ b/source/blender/editors/transform/transform.c @@ -53,7 +53,6 @@ #include "DNA_scene_types.h" /* PET modes */ #include "RNA_access.h" -#include "RNA_define.h" #include "BIF_gl.h" #include "BIF_glutil.h" @@ -86,8 +85,6 @@ #include "BLI_ghash.h" #include "BLI_linklist.h" -#include "BLF_api.h" - #include "UI_resources.h" //#include "blendef.h" @@ -492,29 +489,29 @@ static void view_editmove(unsigned short UNUSED(event)) wmKeyMap* transform_modal_keymap(wmKeyConfig *keyconf) { static EnumPropertyItem modal_items[] = { - {TFM_MODAL_CANCEL, "CANCEL", 0, N_("Cancel"), ""}, - {TFM_MODAL_CONFIRM, "CONFIRM", 0, N_("Confirm"), ""}, - {TFM_MODAL_TRANSLATE, "TRANSLATE", 0, N_("Translate"), ""}, - {TFM_MODAL_ROTATE, "ROTATE", 0, N_("Rotate"), ""}, - {TFM_MODAL_RESIZE, "RESIZE", 0, N_("Resize"), ""}, - {TFM_MODAL_SNAP_INV_ON, "SNAP_INV_ON", 0, N_("Invert Snap On"), ""}, - {TFM_MODAL_SNAP_INV_OFF, "SNAP_INV_OFF", 0, N_("Invert Snap Off"), ""}, - {TFM_MODAL_SNAP_TOGGLE, "SNAP_TOGGLE", 0, N_("Snap Toggle"), ""}, - {TFM_MODAL_AXIS_X, "AXIS_X", 0, N_("Orientation X axis"), ""}, - {TFM_MODAL_AXIS_Y, "AXIS_Y", 0, N_("Orientation Y axis"), ""}, - {TFM_MODAL_AXIS_Z, "AXIS_Z", 0, N_("Orientation Z axis"), ""}, - {TFM_MODAL_PLANE_X, "PLANE_X", 0, N_("Orientation X plane"), ""}, - {TFM_MODAL_PLANE_Y, "PLANE_Y", 0, N_("Orientation Y plane"), ""}, - {TFM_MODAL_PLANE_Z, "PLANE_Z", 0, N_("Orientation Z plane"), ""}, - {TFM_MODAL_CONS_OFF, "CONS_OFF", 0, N_("Remove Constraints"), ""}, - {TFM_MODAL_ADD_SNAP, "ADD_SNAP", 0, N_("Add Snap Point"), ""}, - {TFM_MODAL_REMOVE_SNAP, "REMOVE_SNAP", 0, N_("Remove Last Snap Point"), ""}, - {NUM_MODAL_INCREMENT_UP, "INCREMENT_UP", 0, N_("Numinput Increment Up"), ""}, - {NUM_MODAL_INCREMENT_DOWN, "INCREMENT_DOWN", 0, N_("Numinput Increment Down"), ""}, - {TFM_MODAL_PROPSIZE_UP, "PROPORTIONAL_SIZE_UP", 0, N_("Increase Proportional Influence"), ""}, - {TFM_MODAL_PROPSIZE_DOWN, "PROPORTIONAL_SIZE_DOWN", 0, N_("Decrease Poportional Influence"), ""}, - {TFM_MODAL_AUTOIK_LEN_INC, "AUTOIK_CHAIN_LEN_UP", 0, N_("Increase Max AutoIK Chain Length"), ""}, - {TFM_MODAL_AUTOIK_LEN_DEC, "AUTOIK_CHAIN_LEN_DOWN", 0, N_("Decrease Max AutoIK Chain Length"), ""}, + {TFM_MODAL_CANCEL, "CANCEL", 0, "Cancel", ""}, + {TFM_MODAL_CONFIRM, "CONFIRM", 0, "Confirm", ""}, + {TFM_MODAL_TRANSLATE, "TRANSLATE", 0, "Translate", ""}, + {TFM_MODAL_ROTATE, "ROTATE", 0, "Rotate", ""}, + {TFM_MODAL_RESIZE, "RESIZE", 0, "Resize", ""}, + {TFM_MODAL_SNAP_INV_ON, "SNAP_INV_ON", 0, "Invert Snap On", ""}, + {TFM_MODAL_SNAP_INV_OFF, "SNAP_INV_OFF", 0, "Invert Snap Off", ""}, + {TFM_MODAL_SNAP_TOGGLE, "SNAP_TOGGLE", 0, "Snap Toggle", ""}, + {TFM_MODAL_AXIS_X, "AXIS_X", 0, "Orientation X axis", ""}, + {TFM_MODAL_AXIS_Y, "AXIS_Y", 0, "Orientation Y axis", ""}, + {TFM_MODAL_AXIS_Z, "AXIS_Z", 0, "Orientation Z axis", ""}, + {TFM_MODAL_PLANE_X, "PLANE_X", 0, "Orientation X plane", ""}, + {TFM_MODAL_PLANE_Y, "PLANE_Y", 0, "Orientation Y plane", ""}, + {TFM_MODAL_PLANE_Z, "PLANE_Z", 0, "Orientation Z plane", ""}, + {TFM_MODAL_CONS_OFF, "CONS_OFF", 0, "Remove Constraints", ""}, + {TFM_MODAL_ADD_SNAP, "ADD_SNAP", 0, "Add Snap Point", ""}, + {TFM_MODAL_REMOVE_SNAP, "REMOVE_SNAP", 0, "Remove Last Snap Point", ""}, + {NUM_MODAL_INCREMENT_UP, "INCREMENT_UP", 0, "Numinput Increment Up", ""}, + {NUM_MODAL_INCREMENT_DOWN, "INCREMENT_DOWN", 0, "Numinput Increment Down", ""}, + {TFM_MODAL_PROPSIZE_UP, "PROPORTIONAL_SIZE_UP", 0, "Increase Proportional Influence", ""}, + {TFM_MODAL_PROPSIZE_DOWN, "PROPORTIONAL_SIZE_DOWN", 0, "Decrease Poportional Influence", ""}, + {TFM_MODAL_AUTOIK_LEN_INC, "AUTOIK_CHAIN_LEN_UP", 0, "Increase Max AutoIK Chain Length", ""}, + {TFM_MODAL_AUTOIK_LEN_DEC, "AUTOIK_CHAIN_LEN_DOWN", 0, "Decrease Max AutoIK Chain Length", ""}, {0, NULL, 0, NULL, NULL}}; wmKeyMap *keymap= WM_modalkeymap_get(keyconf, "Transform Modal Map"); @@ -522,7 +519,7 @@ wmKeyMap* transform_modal_keymap(wmKeyConfig *keyconf) /* this function is called for each spacetype, only needs to add map once */ if(keymap) return NULL; - keymap= WM_modalkeymap_add(keyconf, "Transform Modal Map", RNA_enum_items_gettexted(modal_items)); + keymap= WM_modalkeymap_add(keyconf, "Transform Modal Map", modal_items); /* items for modal map */ WM_modalkeymap_add_item(keymap, ESCKEY, KM_PRESS, KM_ANY, 0, TFM_MODAL_CANCEL); diff --git a/source/blender/editors/transform/transform_ops.c b/source/blender/editors/transform/transform_ops.c index b9ccb02ff5b..e35b8adc570 100644 --- a/source/blender/editors/transform/transform_ops.c +++ b/source/blender/editors/transform/transform_ops.c @@ -38,8 +38,6 @@ #include "BLI_math.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_global.h" #include "BKE_armature.h" @@ -114,34 +112,34 @@ static TransformModeItem transform_modes[] = EnumPropertyItem transform_mode_types[] = { - {TFM_INIT, "INIT", 0, N_("Init"), ""}, - {TFM_DUMMY, "DUMMY", 0, N_("Dummy"), ""}, - {TFM_TRANSLATION, "TRANSLATION", 0, N_("Translation"), ""}, - {TFM_ROTATION, "ROTATION", 0, N_("Rotation"), ""}, - {TFM_RESIZE, "RESIZE", 0, N_("Resize"), ""}, - {TFM_TOSPHERE, "TOSPHERE", 0, N_("Tosphere"), ""}, - {TFM_SHEAR, "SHEAR", 0, N_("Shear"), ""}, - {TFM_WARP, "WARP", 0, N_("Warp"), ""}, - {TFM_SHRINKFATTEN, "SHRINKFATTEN", 0, N_("Shrinkfatten"), ""}, - {TFM_TILT, "TILT", 0, N_("Tilt"), ""}, - {TFM_TRACKBALL, "TRACKBALL", 0, N_("Trackball"), ""}, - {TFM_PUSHPULL, "PUSHPULL", 0, N_("Pushpull"), ""}, - {TFM_CREASE, "CREASE", 0, N_("Crease"), ""}, - {TFM_MIRROR, "MIRROR", 0, N_("Mirror"), ""}, - {TFM_BONESIZE, "BONE_SIZE", 0, N_("Bonesize"), ""}, - {TFM_BONE_ENVELOPE, "BONE_ENVELOPE", 0, N_("Bone_Envelope"), ""}, - {TFM_CURVE_SHRINKFATTEN, "CURVE_SHRINKFATTEN", 0, N_("Curve_Shrinkfatten"), ""}, - {TFM_BONE_ROLL, "BONE_ROLL", 0, N_("Bone_Roll"), ""}, - {TFM_TIME_TRANSLATE, "TIME_TRANSLATE", 0, N_("Time_Translate"), ""}, - {TFM_TIME_SLIDE, "TIME_SLIDE", 0, N_("Time_Slide"), ""}, - {TFM_TIME_SCALE, "TIME_SCALE", 0, N_("Time_Scale"), ""}, - {TFM_TIME_EXTEND, "TIME_EXTEND", 0, N_("Time_Extend"), ""}, - {TFM_BAKE_TIME, "BAKE_TIME", 0, N_("Bake_Time"), ""}, - {TFM_BEVEL, "BEVEL", 0, N_("Bevel"), ""}, - {TFM_BWEIGHT, "BWEIGHT", 0, N_("Bweight"), ""}, - {TFM_ALIGN, "ALIGN", 0, N_("Align"), ""}, - {TFM_EDGE_SLIDE, "EDGESLIDE", 0, N_("Edge Slide"), ""}, - {TFM_SEQ_SLIDE, "SEQSLIDE", 0, N_("Sequence Slide"), ""}, + {TFM_INIT, "INIT", 0, "Init", ""}, + {TFM_DUMMY, "DUMMY", 0, "Dummy", ""}, + {TFM_TRANSLATION, "TRANSLATION", 0, "Translation", ""}, + {TFM_ROTATION, "ROTATION", 0, "Rotation", ""}, + {TFM_RESIZE, "RESIZE", 0, "Resize", ""}, + {TFM_TOSPHERE, "TOSPHERE", 0, "Tosphere", ""}, + {TFM_SHEAR, "SHEAR", 0, "Shear", ""}, + {TFM_WARP, "WARP", 0, "Warp", ""}, + {TFM_SHRINKFATTEN, "SHRINKFATTEN", 0, "Shrinkfatten", ""}, + {TFM_TILT, "TILT", 0, "Tilt", ""}, + {TFM_TRACKBALL, "TRACKBALL", 0, "Trackball", ""}, + {TFM_PUSHPULL, "PUSHPULL", 0, "Pushpull", ""}, + {TFM_CREASE, "CREASE", 0, "Crease", ""}, + {TFM_MIRROR, "MIRROR", 0, "Mirror", ""}, + {TFM_BONESIZE, "BONE_SIZE", 0, "Bonesize", ""}, + {TFM_BONE_ENVELOPE, "BONE_ENVELOPE", 0, "Bone_Envelope", ""}, + {TFM_CURVE_SHRINKFATTEN, "CURVE_SHRINKFATTEN", 0, "Curve_Shrinkfatten", ""}, + {TFM_BONE_ROLL, "BONE_ROLL", 0, "Bone_Roll", ""}, + {TFM_TIME_TRANSLATE, "TIME_TRANSLATE", 0, "Time_Translate", ""}, + {TFM_TIME_SLIDE, "TIME_SLIDE", 0, "Time_Slide", ""}, + {TFM_TIME_SCALE, "TIME_SCALE", 0, "Time_Scale", ""}, + {TFM_TIME_EXTEND, "TIME_EXTEND", 0, "Time_Extend", ""}, + {TFM_BAKE_TIME, "BAKE_TIME", 0, "Bake_Time", ""}, + {TFM_BEVEL, "BEVEL", 0, "Bevel", ""}, + {TFM_BWEIGHT, "BWEIGHT", 0, "Bweight", ""}, + {TFM_ALIGN, "ALIGN", 0, "Align", ""}, + {TFM_EDGE_SLIDE, "EDGESLIDE", 0, "Edge Slide", ""}, + {TFM_SEQ_SLIDE, "SEQSLIDE", 0, "Sequence Slide", ""}, {0, NULL, 0, NULL, NULL} }; @@ -159,8 +157,8 @@ static int snap_type_exec(bContext *C, wmOperator *op) static void TRANSFORM_OT_snap_type(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Snap Type"); - ot->description= _("Set the snap element type"); + ot->name= "Snap Type"; + ot->description= "Set the snap element type"; ot->idname= "TRANSFORM_OT_snap_type"; /* api callbacks */ @@ -173,7 +171,7 @@ static void TRANSFORM_OT_snap_type(wmOperatorType *ot) ot->flag= OPTYPE_UNDO; /* props */ - ot->prop= RNA_def_enum(ot->srna, "type", RNA_enum_items_gettexted(snap_element_items), 0, _("Type"), _("Set the snap element type")); + ot->prop= RNA_def_enum(ot->srna, "type", snap_element_items, 0, "Type", "Set the snap element type"); } @@ -206,8 +204,8 @@ static void TRANSFORM_OT_select_orientation(struct wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name = _("Select Orientation"); - ot->description= _("Select transformation orientation"); + ot->name = "Select Orientation"; + ot->description= "Select transformation orientation"; ot->idname = "TRANSFORM_OT_select_orientation"; ot->flag = OPTYPE_UNDO; @@ -217,7 +215,7 @@ static void TRANSFORM_OT_select_orientation(struct wmOperatorType *ot) ot->poll = ED_operator_view3d_active; prop= RNA_def_property(ot->srna, "orientation", PROP_ENUM, PROP_NONE); - RNA_def_property_ui_text(prop, _("Orientation"), _("Transformation orientation")); + RNA_def_property_ui_text(prop, "Orientation", "Transformation orientation"); RNA_def_enum_funcs(prop, rna_TransformOrientation_itemf); } @@ -259,8 +257,8 @@ static int delete_orientation_poll(bContext *C) static void TRANSFORM_OT_delete_orientation(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Delete Orientation"); - ot->description= _("Delete transformation orientation"); + ot->name = "Delete Orientation"; + ot->description= "Delete transformation orientation"; ot->idname = "TRANSFORM_OT_delete_orientation"; ot->flag = OPTYPE_UNDO; @@ -294,8 +292,8 @@ static int create_orientation_invoke(bContext *C, wmOperator *op, wmEvent *UNUSE static void TRANSFORM_OT_create_orientation(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Create Orientation"); - ot->description= _("Create transformation orientation from selection"); + ot->name = "Create Orientation"; + ot->description= "Create transformation orientation from selection"; ot->idname = "TRANSFORM_OT_create_orientation"; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; @@ -305,9 +303,9 @@ static void TRANSFORM_OT_create_orientation(struct wmOperatorType *ot) ot->poll = ED_operator_areaactive; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO; - RNA_def_string(ot->srna, "name", "", 35, _("Name"), _("Text to insert at the cursor position.")); - RNA_def_boolean(ot->srna, "use", 0, _("Use after creation"), _("Select orientation after its creation")); - RNA_def_boolean(ot->srna, "overwrite", 0, _("Overwrite previous"), _("Overwrite previously created orientation with same name")); + RNA_def_string(ot->srna, "name", "", 35, "Name", "Text to insert at the cursor position."); + RNA_def_boolean(ot->srna, "use", 0, "Use after creation", "Select orientation after its creation"); + RNA_def_boolean(ot->srna, "overwrite", 0, "Overwrite previous", "Overwrite previously created orientation with same name"); } static void transformops_exit(bContext *C, wmOperator *op) @@ -455,15 +453,15 @@ void Transform_Properties(struct wmOperatorType *ot, int flags) RNA_def_property_array(prop, 3); /* Make this not hidden when there's a nice axis selection widget */ RNA_def_property_flag(prop, PROP_HIDDEN); - RNA_def_property_ui_text(prop, _("Axis"), _("The axis around which the transformation occurs")); + RNA_def_property_ui_text(prop, "Axis", "The axis around which the transformation occurs"); } if (flags & P_CONSTRAINT) { - RNA_def_boolean_vector(ot->srna, "constraint_axis", 3, NULL, _("Constraint Axis"), ""); + RNA_def_boolean_vector(ot->srna, "constraint_axis", 3, NULL, "Constraint Axis", ""); prop= RNA_def_property(ot->srna, "constraint_orientation", PROP_ENUM, PROP_NONE); - RNA_def_property_ui_text(prop, _("Orientation"), _("Transformation orientation")); + RNA_def_property_ui_text(prop, "Orientation", "Transformation orientation"); RNA_def_enum_funcs(prop, rna_TransformOrientation_itemf); @@ -471,32 +469,32 @@ void Transform_Properties(struct wmOperatorType *ot, int flags) if (flags & P_MIRROR) { - RNA_def_boolean(ot->srna, "mirror", 0, _("Mirror Editing"), ""); + RNA_def_boolean(ot->srna, "mirror", 0, "Mirror Editing", ""); } if (flags & P_PROPORTIONAL) { - RNA_def_enum(ot->srna, "proportional", proportional_editing_items, 0, _("Proportional Editing"), ""); - RNA_def_enum(ot->srna, "proportional_edit_falloff", proportional_falloff_items, 0, _("Proportional Editing Falloff"), _("Falloff type for proportional editing mode.")); - RNA_def_float(ot->srna, "proportional_size", 1, 0.00001f, FLT_MAX, _("Proportional Size"), "", 0.001, 100); + RNA_def_enum(ot->srna, "proportional", proportional_editing_items, 0, "Proportional Editing", ""); + RNA_def_enum(ot->srna, "proportional_edit_falloff", proportional_falloff_items, 0, "Proportional Editing Falloff", "Falloff type for proportional editing mode."); + RNA_def_float(ot->srna, "proportional_size", 1, 0.00001f, FLT_MAX, "Proportional Size", "", 0.001, 100); } if (flags & P_SNAP) { - prop= RNA_def_boolean(ot->srna, "snap", 0, _("Use Snapping Options"), ""); + prop= RNA_def_boolean(ot->srna, "snap", 0, "Use Snapping Options", ""); RNA_def_property_flag(prop, PROP_HIDDEN); if (flags & P_GEO_SNAP) { - prop= RNA_def_enum(ot->srna, "snap_target", snap_target_items, 0, _("Target"), ""); + prop= RNA_def_enum(ot->srna, "snap_target", snap_target_items, 0, "Target", ""); RNA_def_property_flag(prop, PROP_HIDDEN); - prop= RNA_def_float_vector(ot->srna, "snap_point", 3, NULL, -FLT_MAX, FLT_MAX, _("Point"), "", -FLT_MAX, FLT_MAX); + prop= RNA_def_float_vector(ot->srna, "snap_point", 3, NULL, -FLT_MAX, FLT_MAX, "Point", "", -FLT_MAX, FLT_MAX); RNA_def_property_flag(prop, PROP_HIDDEN); if (flags & P_ALIGN_SNAP) { - prop= RNA_def_boolean(ot->srna, "snap_align", 0, _("Align with Point Normal"), ""); + prop= RNA_def_boolean(ot->srna, "snap_align", 0, "Align with Point Normal", ""); RNA_def_property_flag(prop, PROP_HIDDEN); - prop= RNA_def_float_vector(ot->srna, "snap_normal", 3, NULL, -FLT_MAX, FLT_MAX, _("Normal"), "", -FLT_MAX, FLT_MAX); + prop= RNA_def_float_vector(ot->srna, "snap_normal", 3, NULL, -FLT_MAX, FLT_MAX, "Normal", "", -FLT_MAX, FLT_MAX); RNA_def_property_flag(prop, PROP_HIDDEN); } } @@ -504,7 +502,7 @@ void Transform_Properties(struct wmOperatorType *ot, int flags) if (flags & P_OPTIONS) { - RNA_def_boolean(ot->srna, "texture_space", 0, _("Edit Object data texture space"), ""); + RNA_def_boolean(ot->srna, "texture_space", 0, "Edit Object data texture space", ""); } if (flags & P_CORRECT_UV) @@ -513,15 +511,15 @@ void Transform_Properties(struct wmOperatorType *ot, int flags) } // Add confirm method all the time. At the end because it's not really that important and should be hidden only in log, not in keymap edit - /*prop =*/ RNA_def_boolean(ot->srna, "release_confirm", 0, _("Confirm on Release"), _("Always confirm operation when releasing button")); + /*prop =*/ RNA_def_boolean(ot->srna, "release_confirm", 0, "Confirm on Release", "Always confirm operation when releasing button"); //RNA_def_property_flag(prop, PROP_HIDDEN); } void TRANSFORM_OT_translate(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Translate"); - ot->description= _("Translate selected items"); + ot->name = "Translate"; + ot->description= "Translate selected items"; ot->idname = OP_TRANSLATION; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -532,7 +530,7 @@ void TRANSFORM_OT_translate(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_vector_xyz(ot->srna, "value", 3, NULL, -FLT_MAX, FLT_MAX, _("Vector"), "", -FLT_MAX, FLT_MAX); + RNA_def_float_vector_xyz(ot->srna, "value", 3, NULL, -FLT_MAX, FLT_MAX, "Vector", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_CONSTRAINT|P_PROPORTIONAL|P_MIRROR|P_ALIGN_SNAP|P_OPTIONS); } @@ -540,8 +538,8 @@ void TRANSFORM_OT_translate(struct wmOperatorType *ot) void TRANSFORM_OT_resize(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Resize"); - ot->description= _("Resize selected items"); + ot->name = "Resize"; + ot->description= "Resize selected items"; ot->idname = OP_RESIZE; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -552,7 +550,7 @@ void TRANSFORM_OT_resize(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_vector(ot->srna, "value", 3, VecOne, -FLT_MAX, FLT_MAX, _("Vector"), "", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "value", 3, VecOne, -FLT_MAX, FLT_MAX, "Vector", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_CONSTRAINT|P_PROPORTIONAL|P_MIRROR|P_GEO_SNAP|P_OPTIONS); } @@ -561,8 +559,8 @@ void TRANSFORM_OT_resize(struct wmOperatorType *ot) void TRANSFORM_OT_trackball(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Trackball"); - ot->description= _("Trackball style rotation of selected items"); + ot->name = "Trackball"; + ot->description= "Trackball style rotation of selected items"; ot->idname = OP_TRACKBALL; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -573,7 +571,7 @@ void TRANSFORM_OT_trackball(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_vector(ot->srna, "value", 2, VecOne, -FLT_MAX, FLT_MAX, _("angle"), "", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "value", 2, VecOne, -FLT_MAX, FLT_MAX, "angle", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); } @@ -581,8 +579,8 @@ void TRANSFORM_OT_trackball(struct wmOperatorType *ot) void TRANSFORM_OT_rotate(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Rotate"); - ot->description= _("Rotate selected items"); + ot->name = "Rotate"; + ot->description= "Rotate selected items"; ot->idname = OP_ROTATION; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -593,7 +591,7 @@ void TRANSFORM_OT_rotate(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, _("Angle"), "", -M_PI*2, M_PI*2); + RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, "Angle", "", -M_PI*2, M_PI*2); Transform_Properties(ot, P_AXIS|P_CONSTRAINT|P_PROPORTIONAL|P_MIRROR|P_GEO_SNAP); } @@ -601,11 +599,11 @@ void TRANSFORM_OT_rotate(struct wmOperatorType *ot) void TRANSFORM_OT_tilt(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Tilt"); + ot->name = "Tilt"; /*optionals - "Tilt selected vertices." "Specify an extra axis rotation for selected vertices of 3d curve." */ - ot->description= _("Tilt selected control vertices of 3d curve"); + ot->description= "Tilt selected control vertices of 3d curve"; ot->idname = OP_TILT; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -616,7 +614,7 @@ void TRANSFORM_OT_tilt(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_editcurve; - RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, _("Angle"), "", -M_PI*2, M_PI*2); + RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, "Angle", "", -M_PI*2, M_PI*2); Transform_Properties(ot, P_CONSTRAINT|P_PROPORTIONAL|P_MIRROR|P_SNAP); } @@ -624,8 +622,8 @@ void TRANSFORM_OT_tilt(struct wmOperatorType *ot) void TRANSFORM_OT_warp(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Warp"); - ot->description= _("Warp selected items around the cursor"); + ot->name = "Warp"; + ot->description= "Warp selected items around the cursor"; ot->idname = OP_WARP; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -636,7 +634,7 @@ void TRANSFORM_OT_warp(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, _("Angle"), "", 0, 1); + RNA_def_float_rotation(ot->srna, "value", 1, NULL, -FLT_MAX, FLT_MAX, "Angle", "", 0, 1); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); // XXX Warp axis? @@ -645,8 +643,8 @@ void TRANSFORM_OT_warp(struct wmOperatorType *ot) void TRANSFORM_OT_shear(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Shear"); - ot->description= _("Shear selected items along the horizontal screen axis"); + ot->name = "Shear"; + ot->description= "Shear selected items along the horizontal screen axis"; ot->idname = OP_SHEAR; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -657,7 +655,7 @@ void TRANSFORM_OT_shear(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, _("Offset"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, "Offset", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); // XXX Shear axis? @@ -666,8 +664,8 @@ void TRANSFORM_OT_shear(struct wmOperatorType *ot) void TRANSFORM_OT_push_pull(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Push/Pull"); - ot->description= _("Push/Pull selected items"); + ot->name = "Push/Pull"; + ot->description= "Push/Pull selected items"; ot->idname = OP_PUSH_PULL; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -678,7 +676,7 @@ void TRANSFORM_OT_push_pull(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, _("Distance"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, "Distance", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); } @@ -686,8 +684,8 @@ void TRANSFORM_OT_push_pull(struct wmOperatorType *ot) void TRANSFORM_OT_shrink_fatten(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Shrink/Fatten"); - ot->description= _("Shrink/fatten selected vertices along normals"); + ot->name = "Shrink/Fatten"; + ot->description= "Shrink/fatten selected vertices along normals"; ot->idname = OP_SHRINK_FATTEN; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -698,7 +696,7 @@ void TRANSFORM_OT_shrink_fatten(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_editmesh; - RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, _("Offset"), "", -FLT_MAX, FLT_MAX); + RNA_def_float(ot->srna, "value", 0, -FLT_MAX, FLT_MAX, "Offset", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); } @@ -706,9 +704,9 @@ void TRANSFORM_OT_shrink_fatten(struct wmOperatorType *ot) void TRANSFORM_OT_tosphere(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("To Sphere"); + ot->name = "To Sphere"; //added "around mesh center" to differentiate between "MESH_OT_vertices_to_sphere()" - ot->description= _("Move selected vertices outward in a spherical shape around mesh center"); + ot->description= "Move selected vertices outward in a spherical shape around mesh center"; ot->idname = OP_TOSPHERE; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -719,7 +717,7 @@ void TRANSFORM_OT_tosphere(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - RNA_def_float_factor(ot->srna, "value", 0, 0, 1, _("Factor"), "", 0, 1); + RNA_def_float_factor(ot->srna, "value", 0, 0, 1, "Factor", "", 0, 1); Transform_Properties(ot, P_PROPORTIONAL|P_MIRROR|P_SNAP); } @@ -727,8 +725,8 @@ void TRANSFORM_OT_tosphere(struct wmOperatorType *ot) void TRANSFORM_OT_mirror(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Mirror"); - ot->description= _("Mirror selected vertices around one or more axes"); + ot->name = "Mirror"; + ot->description= "Mirror selected vertices around one or more axes"; ot->idname = OP_MIRROR; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -745,8 +743,8 @@ void TRANSFORM_OT_mirror(struct wmOperatorType *ot) void TRANSFORM_OT_edge_slide(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Edge Slide"); - ot->description= _("Slide an edge loop along a mesh"); + ot->name = "Edge Slide"; + ot->description= "Slide an edge loop along a mesh"; ot->idname = OP_EDGE_SLIDE; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -757,7 +755,7 @@ void TRANSFORM_OT_edge_slide(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_editmesh; - RNA_def_float_factor(ot->srna, "value", 0, -1.0f, 1.0f, _("Factor"), "", -1.0f, 1.0f); + RNA_def_float_factor(ot->srna, "value", 0, -1.0f, 1.0f, "Factor", "", -1.0f, 1.0f); Transform_Properties(ot, P_MIRROR|P_SNAP|P_CORRECT_UV); } @@ -765,8 +763,8 @@ void TRANSFORM_OT_edge_slide(struct wmOperatorType *ot) void TRANSFORM_OT_edge_crease(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Edge Crease"); - ot->description= _("Change the crease of edges"); + ot->name = "Edge Crease"; + ot->description= "Change the crease of edges"; ot->idname = OP_EDGE_CREASE; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -777,7 +775,7 @@ void TRANSFORM_OT_edge_crease(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_editmesh; - RNA_def_float_factor(ot->srna, "value", 0, -1.0f, 1.0f, _("Factor"), "", -1.0f, 1.0f); + RNA_def_float_factor(ot->srna, "value", 0, -1.0f, 1.0f, "Factor", "", -1.0f, 1.0f); Transform_Properties(ot, P_SNAP); } @@ -785,8 +783,8 @@ void TRANSFORM_OT_edge_crease(struct wmOperatorType *ot) void TRANSFORM_OT_seq_slide(struct wmOperatorType *ot) { /* identifiers */ - ot->name = _("Sequence Slide"); - ot->description= _("Slide a sequence strip in time"); + ot->name = "Sequence Slide"; + ot->description= "Slide a sequence strip in time"; ot->idname = OP_SEQ_SLIDE; ot->flag = OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -797,7 +795,7 @@ void TRANSFORM_OT_seq_slide(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_sequencer_active; - RNA_def_float_vector(ot->srna, "value", 2, VecOne, -FLT_MAX, FLT_MAX, _("angle"), "", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "value", 2, VecOne, -FLT_MAX, FLT_MAX, "angle", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_SNAP); } @@ -807,8 +805,8 @@ void TRANSFORM_OT_transform(struct wmOperatorType *ot) PropertyRNA *prop; /* identifiers */ - ot->name = _("Transform"); - ot->description= _("Transform selected items by mode type"); + ot->name = "Transform"; + ot->description= "Transform selected items by mode type"; ot->idname = "TRANSFORM_OT_transform"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO|OPTYPE_BLOCKING; @@ -819,10 +817,10 @@ void TRANSFORM_OT_transform(struct wmOperatorType *ot) ot->cancel = transform_cancel; ot->poll = ED_operator_screenactive; - prop= RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, _("Mode"), ""); + prop= RNA_def_enum(ot->srna, "mode", transform_mode_types, TFM_TRANSLATION, "Mode", ""); RNA_def_property_flag(prop, PROP_HIDDEN); - RNA_def_float_vector(ot->srna, "value", 4, NULL, -FLT_MAX, FLT_MAX, _("Values"), "", -FLT_MAX, FLT_MAX); + RNA_def_float_vector(ot->srna, "value", 4, NULL, -FLT_MAX, FLT_MAX, "Values", "", -FLT_MAX, FLT_MAX); Transform_Properties(ot, P_AXIS|P_CONSTRAINT|P_PROPORTIONAL|P_MIRROR|P_ALIGN_SNAP); } diff --git a/source/blender/editors/util/CMakeLists.txt b/source/blender/editors/util/CMakeLists.txt index e284540c5a6..72f13c14f5d 100644 --- a/source/blender/editors/util/CMakeLists.txt +++ b/source/blender/editors/util/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/util/SConscript b/source/blender/editors/util/SConscript index fffd2670814..cfbc735eb5c 100644 --- a/source/blender/editors/util/SConscript +++ b/source/blender/editors/util/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../makesrna' incs += ' ../../blenloader' diff --git a/source/blender/editors/util/undo.c b/source/blender/editors/util/undo.c index 21420d88899..c1aca61f795 100644 --- a/source/blender/editors/util/undo.c +++ b/source/blender/editors/util/undo.c @@ -46,8 +46,6 @@ #include "BLI_dynstr.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_blender.h" #include "BKE_context.h" #include "BKE_global.h" @@ -296,8 +294,8 @@ static int ed_redo_exec(bContext *C, wmOperator *UNUSED(op)) void ED_OT_undo(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Undo"); - ot->description= _("Undo previous action"); + ot->name= "Undo"; + ot->description= "Undo previous action"; ot->idname= "ED_OT_undo"; /* api callbacks */ @@ -323,8 +321,8 @@ void ED_OT_undo_push(wmOperatorType *ot) void ED_OT_redo(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Redo"); - ot->description= _("Redo previous action"); + ot->name= "Redo"; + ot->description= "Redo previous action"; ot->idname= "ED_OT_redo"; /* api callbacks */ @@ -521,8 +519,8 @@ static int undo_history_exec(bContext *C, wmOperator *op) void ED_OT_undo_history(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Undo History"); - ot->description= _("Redo specific action in history"); + ot->name= "Undo History"; + ot->description= "Redo specific action in history"; ot->idname= "ED_OT_undo_history"; /* api callbacks */ @@ -530,7 +528,7 @@ void ED_OT_undo_history(wmOperatorType *ot) ot->exec= undo_history_exec; ot->poll= ED_operator_screenactive; - RNA_def_int(ot->srna, "item", 0, 0, INT_MAX, _("Item"), "", 0, INT_MAX); + RNA_def_int(ot->srna, "item", 0, 0, INT_MAX, "Item", "", 0, INT_MAX); } diff --git a/source/blender/editors/uvedit/CMakeLists.txt b/source/blender/editors/uvedit/CMakeLists.txt index 4055585af74..552e1b60154 100644 --- a/source/blender/editors/uvedit/CMakeLists.txt +++ b/source/blender/editors/uvedit/CMakeLists.txt @@ -21,7 +21,6 @@ set(INC ../include - ../../blenfont ../../blenkernel ../../blenlib ../../blenloader diff --git a/source/blender/editors/uvedit/SConscript b/source/blender/editors/uvedit/SConscript index 695aa217b5e..2523de005d0 100644 --- a/source/blender/editors/uvedit/SConscript +++ b/source/blender/editors/uvedit/SConscript @@ -3,7 +3,7 @@ Import ('env') sources = env.Glob('*.c') -incs = '../include ../../blenfont ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../makesrna #/intern/opennl/extern ../../gpu ../../blenloader' diff --git a/source/blender/editors/uvedit/uvedit_ops.c b/source/blender/editors/uvedit/uvedit_ops.c index 1e3cfbede9c..05159414975 100644 --- a/source/blender/editors/uvedit/uvedit_ops.c +++ b/source/blender/editors/uvedit/uvedit_ops.c @@ -47,8 +47,6 @@ #include "BLI_editVert.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_customdata.h" #include "BKE_depsgraph.h" @@ -1204,17 +1202,17 @@ static int align_exec(bContext *C, wmOperator *op) static void UV_OT_align(wmOperatorType *ot) { static EnumPropertyItem axis_items[] = { - {'s', "ALIGN_S", 0, N_("Straighten"), N_("Align UVs along the line defined by the endpoints")}, - {'t', "ALIGN_T", 0, N_("Straighten X"), N_("Align UVs along the line defined by the endpoints along the X axis")}, - {'u', "ALIGN_U", 0, N_("Straighten Y"), N_("Align UVs along the line defined by the endpoints along the Y axis")}, - {'a', "ALIGN_AUTO", 0, N_("Align Auto"), N_("Automatically choose the axis on which there is most alignment already")}, - {'x', "ALIGN_X", 0, N_("Align X"), N_("Align UVs on X axis")}, - {'y', "ALIGN_Y", 0, N_("Align Y"), N_("Align UVs on Y axis")}, + {'s', "ALIGN_S", 0, "Straighten", "Align UVs along the line defined by the endpoints"}, + {'t', "ALIGN_T", 0, "Straighten X", "Align UVs along the line defined by the endpoints along the X axis"}, + {'u', "ALIGN_U", 0, "Straighten Y", "Align UVs along the line defined by the endpoints along the Y axis"}, + {'a', "ALIGN_AUTO", 0, "Align Auto", "Automatically choose the axis on which there is most alignment already"}, + {'x', "ALIGN_X", 0, "Align X", "Align UVs on X axis"}, + {'y', "ALIGN_Y", 0, "Align Y", "Align UVs on Y axis"}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Align"); - ot->description= _("Align selected UV vertices to an axis"); + ot->name= "Align"; + ot->description= "Align selected UV vertices to an axis"; ot->idname= "UV_OT_align"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1223,7 +1221,7 @@ static void UV_OT_align(wmOperatorType *ot) ot->poll= ED_operator_image_active; /* requires space image */; /* properties */ - RNA_def_enum(ot->srna, "axis", RNA_enum_items_gettexted(axis_items), 'a', _("Axis"), _("Axis to align UV locations on.")); + RNA_def_enum(ot->srna, "axis", axis_items, 'a', "Axis", "Axis to align UV locations on."); } /* ******************** weld operator **************** */ @@ -1238,8 +1236,8 @@ static int weld_exec(bContext *C, wmOperator *UNUSED(op)) static void UV_OT_weld(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Weld"); - ot->description= _("Weld selected UV vertices together"); + ot->name= "Weld"; + ot->description= "Weld selected UV vertices together"; ot->idname= "UV_OT_weld"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1425,8 +1423,8 @@ static int stitch_exec(bContext *C, wmOperator *op) static void UV_OT_stitch(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Stitch"); - ot->description= _("Stitch selected UV vertices by proximity"); + ot->name= "Stitch"; + ot->description= "Stitch selected UV vertices by proximity"; ot->idname= "UV_OT_stitch"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1435,8 +1433,8 @@ static void UV_OT_stitch(wmOperatorType *ot) ot->poll= ED_operator_uvedit; /* properties */ - RNA_def_boolean(ot->srna, "use_limit", 1, _("Use Limit"), _("Stitch UVs within a specified limit distance.")); - RNA_def_float(ot->srna, "limit", 0.01f, 0.0f, FLT_MAX, _("Limit"), _("Limit distance in normalized coordinates."), -FLT_MAX, FLT_MAX); + RNA_def_boolean(ot->srna, "use_limit", 1, "Use Limit", "Stitch UVs within a specified limit distance."); + RNA_def_float(ot->srna, "limit", 0.01f, 0.0f, FLT_MAX, "Limit", "Limit distance in normalized coordinates.", -FLT_MAX, FLT_MAX); } /* ******************** (de)select all operator **************** */ @@ -1521,8 +1519,8 @@ static int select_all_exec(bContext *C, wmOperator *op) static void UV_OT_select_all(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select or Deselect All"); - ot->description= _("Change selection of all UV vertices"); + ot->name= "Select or Deselect All"; + ot->description= "Change selection of all UV vertices"; ot->idname= "UV_OT_select_all"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1858,8 +1856,8 @@ static int select_invoke(bContext *C, wmOperator *op, wmEvent *event) static void UV_OT_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select"); - ot->description= _("Select UV vertices"); + ot->name= "Select"; + ot->description= "Select UV vertices"; ot->idname= "UV_OT_select"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1870,9 +1868,9 @@ static void UV_OT_select(wmOperatorType *ot) /* properties */ RNA_def_boolean(ot->srna, "extend", 0, - _("Extend"), _("Extend selection rather than clearing the existing selection.")); + "Extend", "Extend selection rather than clearing the existing selection."); RNA_def_float_vector(ot->srna, "location", 2, NULL, -FLT_MAX, FLT_MAX, - _("Location"), _("Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds."), -100.0f, 100.0f); + "Location", "Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds.", -100.0f, 100.0f); } /* ******************** loop select operator **************** */ @@ -1903,8 +1901,8 @@ static int select_loop_invoke(bContext *C, wmOperator *op, wmEvent *event) static void UV_OT_select_loop(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Loop Select"); - ot->description= _("Select a loop of connected UV vertices"); + ot->name= "Loop Select"; + ot->description= "Select a loop of connected UV vertices"; ot->idname= "UV_OT_select_loop"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1915,9 +1913,9 @@ static void UV_OT_select_loop(wmOperatorType *ot) /* properties */ RNA_def_boolean(ot->srna, "extend", 0, - _("Extend"), _("Extend selection rather than clearing the existing selection.")); + "Extend", "Extend selection rather than clearing the existing selection."); RNA_def_float_vector(ot->srna, "location", 2, NULL, -FLT_MAX, FLT_MAX, - _("Location"), _("Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds."), -100.0f, 100.0f); + "Location", "Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds.", -100.0f, 100.0f); } /* ******************** linked select operator **************** */ @@ -1980,8 +1978,8 @@ static int select_linked_exec(bContext *C, wmOperator *op) static void UV_OT_select_linked(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked"); - ot->description= _("Select all UV vertices linked to the active UV map"); + ot->name= "Select Linked"; + ot->description= "Select all UV vertices linked to the active UV map"; ot->idname= "UV_OT_select_linked"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1991,7 +1989,7 @@ static void UV_OT_select_linked(wmOperatorType *ot) /* properties */ RNA_def_boolean(ot->srna, "extend", 0, - _("Extend"), _("Extend selection rather than clearing the existing selection.")); + "Extend", "Extend selection rather than clearing the existing selection."); } static int select_linked_pick_invoke(bContext *C, wmOperator *op, wmEvent *event) @@ -2007,8 +2005,8 @@ static int select_linked_pick_exec(bContext *C, wmOperator *op) static void UV_OT_select_linked_pick(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Select Linked Pick"); - ot->description= _("Select all UV vertices linked under the mouse"); + ot->name= "Select Linked Pick"; + ot->description= "Select all UV vertices linked under the mouse"; ot->idname= "UV_OT_select_linked_pick"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2019,10 +2017,10 @@ static void UV_OT_select_linked_pick(wmOperatorType *ot) /* properties */ RNA_def_boolean(ot->srna, "extend", 0, - _("Extend"), _("Extend selection rather than clearing the existing selection.")); + "Extend", "Extend selection rather than clearing the existing selection."); RNA_def_float_vector(ot->srna, "location", 2, NULL, -FLT_MAX, FLT_MAX, - _("Location"), _("Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds."), -100.0f, 100.0f); + "Location", "Mouse location in normalized coordinates, 0.0 to 1.0 is within the image bounds.", -100.0f, 100.0f); } /* ******************** unlink selection operator **************** */ @@ -2064,8 +2062,8 @@ static int unlink_selection_exec(bContext *C, wmOperator *op) static void UV_OT_unlink_selected(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Unlink Selection"); - ot->description= _("Unlink selected UV vertices from active UV map"); + ot->name= "Unlink Selection"; + ot->description= "Unlink selected UV vertices from active UV map"; ot->idname= "UV_OT_unlink_selected"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2345,8 +2343,8 @@ static int border_select_exec(bContext *C, wmOperator *op) static void UV_OT_select_border(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Border Select"); - ot->description= _("Select UV vertices using border selection"); + ot->name= "Border Select"; + ot->description= "Select UV vertices using border selection"; ot->idname= "UV_OT_select_border"; /* api callbacks */ @@ -2360,7 +2358,7 @@ static void UV_OT_select_border(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_boolean(ot->srna, "pinned", 0, _("Pinned"), _("Border select pinned UVs only.")); + RNA_def_boolean(ot->srna, "pinned", 0, "Pinned", "Border select pinned UVs only."); WM_operator_properties_gesture_border(ot, FALSE); } @@ -2435,8 +2433,8 @@ static int circle_select_exec(bContext *C, wmOperator *op) static void UV_OT_circle_select(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Circle Select"); - ot->description= _("Select UV vertices using circle selection"); + ot->name= "Circle Select"; + ot->description= "Select UV vertices using circle selection"; ot->idname= "UV_OT_circle_select"; /* api callbacks */ @@ -2452,8 +2450,8 @@ static void UV_OT_circle_select(wmOperatorType *ot) /* properties */ RNA_def_int(ot->srna, "x", 0, INT_MIN, INT_MAX, "X", "", INT_MIN, INT_MAX); RNA_def_int(ot->srna, "y", 0, INT_MIN, INT_MAX, "Y", "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "radius", 0, INT_MIN, INT_MAX, _("Radius"), "", INT_MIN, INT_MAX); - RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, _("Gesture Mode"), "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "radius", 0, INT_MIN, INT_MAX, "Radius", "", INT_MIN, INT_MAX); + RNA_def_int(ot->srna, "gesture_mode", 0, INT_MIN, INT_MAX, "Gesture Mode", "", INT_MIN, INT_MAX); } /* ******************** snap cursor operator **************** */ @@ -2506,13 +2504,13 @@ static int snap_cursor_exec(bContext *C, wmOperator *op) static void UV_OT_snap_cursor(wmOperatorType *ot) { static EnumPropertyItem target_items[] = { - {0, "PIXELS", 0, N_("Pixels"), ""}, - {1, "SELECTED", 0, N_("Selected"), ""}, + {0, "PIXELS", 0, "Pixels", ""}, + {1, "SELECTED", 0, "Selected", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Snap Cursor"); - ot->description= _("Snap cursor to target type"); + ot->name= "Snap Cursor"; + ot->description= "Snap cursor to target type"; ot->idname= "UV_OT_snap_cursor"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2521,7 +2519,7 @@ static void UV_OT_snap_cursor(wmOperatorType *ot) ot->poll= ED_operator_image_active; /* requires space image */; /* properties */ - RNA_def_enum(ot->srna, "target", target_items, 0, _("Target"), _("Target to snap the selected UV's to.")); + RNA_def_enum(ot->srna, "target", target_items, 0, "Target", "Target to snap the selected UV's to."); } /* ******************** snap selection operator **************** */ @@ -2747,14 +2745,14 @@ static int snap_selection_exec(bContext *C, wmOperator *op) static void UV_OT_snap_selected(wmOperatorType *ot) { static EnumPropertyItem target_items[] = { - {0, "PIXELS", 0, N_("Pixels"), ""}, - {1, "CURSOR", 0, N_("Cursor"), ""}, - {2, "ADJACENT_UNSELECTED", 0, N_("Adjacent Unselected"), ""}, + {0, "PIXELS", 0, "Pixels", ""}, + {1, "CURSOR", 0, "Cursor", ""}, + {2, "ADJACENT_UNSELECTED", 0, "Adjacent Unselected", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Snap Selection"); - ot->description= _("Snap selected UV vertices to target type"); + ot->name= "Snap Selection"; + ot->description= "Snap selected UV vertices to target type"; ot->idname= "UV_OT_snap_selected"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2763,7 +2761,7 @@ static void UV_OT_snap_selected(wmOperatorType *ot) ot->poll= ED_operator_image_active; /* requires space image */; /* properties */ - RNA_def_enum(ot->srna, "target", RNA_enum_items_gettexted(target_items), 0, _("Target"), _("Target to snap the selected UV's to.")); + RNA_def_enum(ot->srna, "target", target_items, 0, "Target", "Target to snap the selected UV's to."); } /* ******************** pin operator **************** */ @@ -2808,8 +2806,8 @@ static int pin_exec(bContext *C, wmOperator *op) static void UV_OT_pin(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Pin"); - ot->description= _("Set/clear selected UV vertices as anchored between multiple unwrap operations"); + ot->name= "Pin"; + ot->description= "Set/clear selected UV vertices as anchored between multiple unwrap operations"; ot->idname= "UV_OT_pin"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2818,7 +2816,7 @@ static void UV_OT_pin(wmOperatorType *ot) ot->poll= ED_operator_uvedit; /* properties */ - RNA_def_boolean(ot->srna, "clear", 0, _("Clear"), _("Clear pinning for the selection instead of setting it.")); + RNA_def_boolean(ot->srna, "clear", 0, "Clear", "Clear pinning for the selection instead of setting it."); } /******************* select pinned operator ***************/ @@ -2854,8 +2852,8 @@ static int select_pinned_exec(bContext *C, wmOperator *UNUSED(op)) static void UV_OT_select_pinned(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Selected Pinned"); - ot->description= _("Select all pinned UV vertices"); + ot->name= "Selected Pinned"; + ot->description= "Select all pinned UV vertices"; ot->idname= "UV_OT_select_pinned"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -2993,8 +2991,8 @@ static int hide_exec(bContext *C, wmOperator *op) static void UV_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Hide Selected"); - ot->description= _("Hide (un)selected UV vertices"); + ot->name= "Hide Selected"; + ot->description= "Hide (un)selected UV vertices"; ot->idname= "UV_OT_hide"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -3003,7 +3001,7 @@ static void UV_OT_hide(wmOperatorType *ot) ot->poll= ED_operator_uvedit; /* props */ - RNA_def_boolean(ot->srna, "unselected", 0, _("Unselected"), _("Hide unselected rather than selected.")); + RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide unselected rather than selected."); } /****************** reveal operator ******************/ @@ -3127,8 +3125,8 @@ static int reveal_exec(bContext *C, wmOperator *UNUSED(op)) static void UV_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reveal Hidden"); - ot->description= _("Reveal all hidden UV vertices"); + ot->name= "Reveal Hidden"; + ot->description= "Reveal all hidden UV vertices"; ot->idname= "UV_OT_reveal"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -3170,8 +3168,8 @@ static int set_2d_cursor_invoke(bContext *C, wmOperator *op, wmEvent *event) static void UV_OT_cursor_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set 2D Cursor"); - ot->description= _("Set 2D cursor location"); + ot->name= "Set 2D Cursor"; + ot->description= "Set 2D cursor location"; ot->idname= "UV_OT_cursor_set"; /* api callbacks */ @@ -3183,7 +3181,7 @@ static void UV_OT_cursor_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float_vector(ot->srna, "location", 2, NULL, -FLT_MAX, FLT_MAX, _("Location"), _("Cursor location in 0.0-1.0 coordinates."), -10.0f, 10.0f); + RNA_def_float_vector(ot->srna, "location", 2, NULL, -FLT_MAX, FLT_MAX, "Location", "Cursor location in 0.0-1.0 coordinates.", -10.0f, 10.0f); } /********************** set tile operator **********************/ @@ -3236,8 +3234,8 @@ static int set_tile_invoke(bContext *C, wmOperator *op, wmEvent *event) static void UV_OT_tile_set(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Set Tile"); - ot->description= _("Set UV image tile coordinates"); + ot->name= "Set Tile"; + ot->description= "Set UV image tile coordinates"; ot->idname= "UV_OT_tile_set"; /* api callbacks */ @@ -3249,7 +3247,7 @@ static void UV_OT_tile_set(wmOperatorType *ot) ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_int_vector(ot->srna, "tile", 2, NULL, 0, INT_MAX, _("Tile"), _("Tile coordinate."), 0, 10); + RNA_def_int_vector(ot->srna, "tile", 2, NULL, 0, INT_MAX, "Tile", "Tile coordinate.", 0, 10); } /* ************************** registration **********************************/ diff --git a/source/blender/editors/uvedit/uvedit_unwrap_ops.c b/source/blender/editors/uvedit/uvedit_unwrap_ops.c index a2418dc1314..e8a7896abd5 100644 --- a/source/blender/editors/uvedit/uvedit_unwrap_ops.c +++ b/source/blender/editors/uvedit/uvedit_unwrap_ops.c @@ -49,8 +49,6 @@ #include "BLI_uvproject.h" #include "BLI_utildefines.h" -#include "BLF_api.h" - #include "BKE_context.h" #include "BKE_customdata.h" #include "BKE_depsgraph.h" @@ -463,10 +461,10 @@ static int minimize_stretch_cancel(bContext *C, wmOperator *op) void UV_OT_minimize_stretch(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Minimize Stretch"); + ot->name= "Minimize Stretch"; ot->idname= "UV_OT_minimize_stretch"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; - ot->description=_("Reduce UV stretching by relaxing angles"); + ot->description="Reduce UV stretching by relaxing angles"; /* api callbacks */ ot->exec= minimize_stretch_exec; @@ -476,9 +474,9 @@ void UV_OT_minimize_stretch(wmOperatorType *ot) ot->poll= ED_operator_uvedit; /* properties */ - RNA_def_boolean(ot->srna, "fill_holes", 1, _("Fill Holes"), _("Virtual fill holes in mesh before unwrapping, to better avoid overlaps and preserve symmetry.")); - RNA_def_float_factor(ot->srna, "blend", 0.0f, 0.0f, 1.0f, _("Blend"), _("Blend factor between stretch minimized and original."), 0.0f, 1.0f); - RNA_def_int(ot->srna, "iterations", 0, 0, INT_MAX, _("Iterations"), _("Number of iterations to run, 0 is unlimited when run interactively."), 0, 100); + RNA_def_boolean(ot->srna, "fill_holes", 1, "Fill Holes", "Virtual fill holes in mesh before unwrapping, to better avoid overlaps and preserve symmetry."); + RNA_def_float_factor(ot->srna, "blend", 0.0f, 0.0f, 1.0f, "Blend", "Blend factor between stretch minimized and original.", 0.0f, 1.0f); + RNA_def_int(ot->srna, "iterations", 0, 0, INT_MAX, "Iterations", "Number of iterations to run, 0 is unlimited when run interactively.", 0, 100); } /* ******************** Pack Islands operator **************** */ @@ -518,7 +516,7 @@ static int pack_islands_exec(bContext *C, wmOperator *op) void UV_OT_pack_islands(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Pack Islands"); + ot->name= "Pack Islands"; ot->idname= "UV_OT_pack_islands"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -527,7 +525,7 @@ void UV_OT_pack_islands(wmOperatorType *ot) ot->poll= ED_operator_uvedit; /* properties */ - RNA_def_float_factor(ot->srna, "margin", 0.0f, 0.0f, 1.0f, _("Margin"), _("Space between islands"), 0.0f, 1.0f); + RNA_def_float_factor(ot->srna, "margin", 0.0f, 0.0f, 1.0f, "Margin", "Space between islands", 0.0f, 1.0f); } /* ******************** Average Islands Scale operator **************** */ @@ -560,7 +558,7 @@ static int average_islands_scale_exec(bContext *C, wmOperator *UNUSED(op)) void UV_OT_average_islands_scale(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Average Islands Scale"); + ot->name= "Average Islands Scale"; ot->idname= "UV_OT_average_islands_scale"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -743,21 +741,21 @@ static void uv_map_transform(bContext *C, wmOperator *op, float center[3], float static void uv_transform_properties(wmOperatorType *ot, int radius) { static EnumPropertyItem direction_items[]= { - {VIEW_ON_EQUATOR, "VIEW_ON_EQUATOR", 0, N_("View on Equator"), N_("3D view is on the equator")}, - {VIEW_ON_POLES, "VIEW_ON_POLES", 0, N_("View on Poles"), N_("3D view is on the poles")}, - {ALIGN_TO_OBJECT, "ALIGN_TO_OBJECT", 0, N_("Align to Object"), N_("Align according to object transform")}, + {VIEW_ON_EQUATOR, "VIEW_ON_EQUATOR", 0, "View on Equator", "3D view is on the equator"}, + {VIEW_ON_POLES, "VIEW_ON_POLES", 0, "View on Poles", "3D view is on the poles"}, + {ALIGN_TO_OBJECT, "ALIGN_TO_OBJECT", 0, "Align to Object", "Align according to object transform"}, {0, NULL, 0, NULL, NULL} }; static EnumPropertyItem align_items[]= { - {POLAR_ZX, "POLAR_ZX", 0, N_("Polar ZX"), N_("Polar 0 is X")}, - {POLAR_ZY, "POLAR_ZY", 0, N_("Polar ZY"), N_("Polar 0 is Y")}, + {POLAR_ZX, "POLAR_ZX", 0, "Polar ZX", "Polar 0 is X"}, + {POLAR_ZY, "POLAR_ZY", 0, "Polar ZY", "Polar 0 is Y"}, {0, NULL, 0, NULL, NULL} }; - RNA_def_enum(ot->srna, "direction", RNA_enum_items_gettexted(direction_items), VIEW_ON_EQUATOR, _("Direction"), _("Direction of the sphere or cylinder.")); - RNA_def_enum(ot->srna, "align", RNA_enum_items_gettexted(align_items), VIEW_ON_EQUATOR, _("Align"), _("How to determine rotation around the pole.")); + RNA_def_enum(ot->srna, "direction", direction_items, VIEW_ON_EQUATOR, "Direction", "Direction of the sphere or cylinder."); + RNA_def_enum(ot->srna, "align", align_items, VIEW_ON_EQUATOR, "Align", "How to determine rotation around the pole."); if(radius) - RNA_def_float(ot->srna, "radius", 1.0f, 0.0f, FLT_MAX, _("Radius"), _("Radius of the sphere or cylinder."), 0.0001f, 100.0f); + RNA_def_float(ot->srna, "radius", 1.0f, 0.0f, FLT_MAX, "Radius", "Radius of the sphere or cylinder.", 0.0001f, 100.0f); } static void correct_uv_aspect(EditMesh *em) @@ -810,9 +808,9 @@ static void correct_uv_aspect(EditMesh *em) static void uv_map_clip_correct_properties(wmOperatorType *ot) { - RNA_def_boolean(ot->srna, "correct_aspect", 1, _("Correct Aspect"), _("Map UV's taking image aspect ratio into account.")); - RNA_def_boolean(ot->srna, "clip_to_bounds", 0, _("Clip to Bounds"), _("Clip UV coordinates to bounds after unwrapping.")); - RNA_def_boolean(ot->srna, "scale_to_bounds", 0, _("Scale to Bounds"), _("Scale UV coordinates to bounds after unwrapping.")); + RNA_def_boolean(ot->srna, "correct_aspect", 1, "Correct Aspect", "Map UV's taking image aspect ratio into account."); + RNA_def_boolean(ot->srna, "clip_to_bounds", 0, "Clip to Bounds", "Clip UV coordinates to bounds after unwrapping."); + RNA_def_boolean(ot->srna, "scale_to_bounds", 0, "Scale to Bounds", "Scale UV coordinates to bounds after unwrapping."); } static void uv_map_clip_correct(EditMesh *em, wmOperator *op) @@ -954,13 +952,13 @@ static int unwrap_exec(bContext *C, wmOperator *op) void UV_OT_unwrap(wmOperatorType *ot) { static EnumPropertyItem method_items[] = { - {0, "ANGLE_BASED", 0, N_("Angle Based"), ""}, - {1, "CONFORMAL", 0, N_("Conformal"), ""}, + {0, "ANGLE_BASED", 0, "Angle Based", ""}, + {1, "CONFORMAL", 0, "Conformal", ""}, {0, NULL, 0, NULL, NULL}}; /* identifiers */ - ot->name= _("Unwrap"); - ot->description= _("Unwrap the mesh of the object being edited"); + ot->name= "Unwrap"; + ot->description= "Unwrap the mesh of the object being edited"; ot->idname= "UV_OT_unwrap"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -969,9 +967,9 @@ void UV_OT_unwrap(wmOperatorType *ot) ot->poll= ED_operator_uvmap; /* properties */ - RNA_def_enum(ot->srna, "method", RNA_enum_items_gettexted(method_items), 0, _("Method"), _("Unwrapping method. Angle Based usually gives better results than Conformal, while being somewhat slower.")); - RNA_def_boolean(ot->srna, "fill_holes", 1, _("Fill Holes"), _("Virtual fill holes in mesh before unwrapping, to better avoid overlaps and preserve symmetry.")); - RNA_def_boolean(ot->srna, "correct_aspect", 1, _("Correct Aspect"), _("Map UV's taking image aspect ratio into account.")); + RNA_def_enum(ot->srna, "method", method_items, 0, "Method", "Unwrapping method. Angle Based usually gives better results than Conformal, while being somewhat slower."); + RNA_def_boolean(ot->srna, "fill_holes", 1, "Fill Holes", "Virtual fill holes in mesh before unwrapping, to better avoid overlaps and preserve symmetry."); + RNA_def_boolean(ot->srna, "correct_aspect", 1, "Correct Aspect", "Map UV's taking image aspect ratio into account."); } /**************** Project From View operator **************/ @@ -1071,7 +1069,7 @@ static int uv_from_view_poll(bContext *C) void UV_OT_from_view(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Project From View"); + ot->name= "Project From View"; ot->idname= "UV_OT_project_from_view"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1080,7 +1078,7 @@ void UV_OT_from_view(wmOperatorType *ot) ot->poll= uv_from_view_poll; /* properties */ - RNA_def_boolean(ot->srna, "orthographic", 0, _("Orthographic"), _("Use orthographic projection.")); + RNA_def_boolean(ot->srna, "orthographic", 0, "Orthographic", "Use orthographic projection."); uv_map_clip_correct_properties(ot); } @@ -1128,7 +1126,7 @@ static int reset_exec(bContext *C, wmOperator *UNUSED(op)) void UV_OT_reset(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Reset"); + ot->name= "Reset"; ot->idname= "UV_OT_reset"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1216,7 +1214,7 @@ static int sphere_project_exec(bContext *C, wmOperator *op) void UV_OT_sphere_project(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Sphere Projection"); + ot->name= "Sphere Projection"; ot->idname= "UV_OT_sphere_project"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1288,7 +1286,7 @@ static int cylinder_project_exec(bContext *C, wmOperator *op) void UV_OT_cylinder_project(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cylinder Projection"); + ot->name= "Cylinder Projection"; ot->idname= "UV_OT_cylinder_project"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1375,7 +1373,7 @@ static int cube_project_exec(bContext *C, wmOperator *op) void UV_OT_cube_project(wmOperatorType *ot) { /* identifiers */ - ot->name= _("Cube Projection"); + ot->name= "Cube Projection"; ot->idname= "UV_OT_cube_project"; ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO; @@ -1384,6 +1382,6 @@ void UV_OT_cube_project(wmOperatorType *ot) ot->poll= ED_operator_uvmap; /* properties */ - RNA_def_float(ot->srna, "cube_size", 1.0f, 0.0f, FLT_MAX, _("Cube Size"), _("Size of the cube to project on."), 0.001f, 100.0f); + RNA_def_float(ot->srna, "cube_size", 1.0f, 0.0f, FLT_MAX, "Cube Size", "Size of the cube to project on.", 0.001f, 100.0f); uv_map_clip_correct_properties(ot); } |