Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-08-18Refactor translation code out of blenfontCampbell Barton
- Add blentranslation `BLT_*` module. - moved & split `BLF_translation.h` into (`BLT_translation.h`, `BLT_lang.h`). - moved `BLF_*_unifont` functions from `blf_translation.c` to new source file `blf_font_i18n.c`.
2015-01-26Cleanup: strcmp/strncmp -> STREQ/STREQLEN (in boolean usage).Bastien Montagne
Makes usage of those funcs much more clear, we even had mixed '!strcmp(foo, bar)' and 'strcmp(foo, bar) == 0' in several places...
2014-12-25Refactor 'immediate search' featureBastien Montagne
Currently, code just checks whether a text-edited button uses a given icon (VIEWZOOM) to decide to apply changes on each typed char. This patch adds a propper button flag (UI_BUT_TEXTEDIT_UPDATE) and a dedicated RNA flag (PROP_TEXTEDIT_UPDATE) for that. It's also now usable not only for text buttons, but also for example for num buttons when in 'text edit' mode, etc. It also fixes an actual bug, which is for text properties, in 'immediate' mode, hitting escape would not restore org value, because `ui_apply_but_TEX()` would set its orgstr to NULL on first call (giving it to `but->rename_orig` instead of copying it). Note no change in behavior is expected from user POV. Update for addons using that 'VIEWZOOM' icon 'feature' will follow (if any). Reviewers: campbellbarton Reviewed By: campbellbarton Projects: #user_interface, #bf_blender:_next Differential Revision: https://developer.blender.org/D938
2014-08-27UI: Warn when using fallback categoryCampbell Barton
Scripts should be updated.
2014-08-26Fix T38999: Tool tabs and Old Addons living in perfect harmony.Bastien Montagne
Just have a default 'Misc' category (harmless for panels in non-cat context). In case we would still want a panel to show in all tabs (rather unlikely), just explicitely give an empty string to its bl_category property. Note I choose 'Misc' because it's much shorter than 'Uncategorized' (space is an issue here), it's a one-liner to change it anyway if UI Mafia does not like it!
2014-04-01Code cleanup: remove TRUE/FALSE & WITH_BOOL_COMPAT defineCampbell Barton
2014-02-08RNA API: remove unused PROP_NEVER_CLAMP flagCampbell Barton
2014-02-07Quiet warningCampbell Barton
2014-02-06Fix T38515: python menu tooltip description affecting unrelated menus.Brecht Van Lommel
2014-01-25Fix T38356: Crash when UIList.filter_items returns too few items.Bastien Montagne
2014-01-16Code Cleanup: no need to pass empty strings as default valuesCampbell Barton
2013-12-16UI: Tabs categories for panels (D75)Campbell Barton
- works by defining panel categories, currently restricted to the toolbar. - no panels define bl_categories yet, so no user visible changes since tabs only show when there are multiple. - panel pinning is available in rmb menu or alt+lmb.
2013-09-20code cleanup: quiet rna warnings, remove remove_strict_flags() for cmake/rna.Campbell Barton
also set_source_files_properties() wasn't working for rna_*_gen.c files, set dna.c and generated data files with generated property too.
2013-09-10Usual UI messages fixes...Bastien Montagne
2013-08-30minor ui editsCampbell Barton
- move addon refresh button into header - uilist, use icon for sorting by name (gives more room for name, icon is used in fileselector for same purpose). - rename orderby to sort in rna and flag names. - simplify BKE_nurb_handle_calc_simple
2013-08-29Last uiList patch (for now!): filtering and reordering of shown elements.Bastien Montagne
Thanks to Brecht for the reviews. :) This commit adds a show/hide extension below each uiList, containing by default an option to filter and/or reorder items by name (and to reverse those filtering and reordering). Each derived uiList class in Python can define more specific filtering by implementing callbacks: the draw_filter() function to draw options in UI, and the filter_items() function to effectively filter/reorder items. Note: the advanced options for vgroups shown as "proof od concept" in patches do not go in trunk for now, we have to find a better way to get those vgroups info for UI code, we can't afford to loop over each vertex here! And doc (release notes and uiList example) is still to be updated, will do this in next days.
2013-03-19Various cleanup around default i18n context.Bastien Montagne
Issue is that the real default context is NULL, however, in python and RNA, this value can't be used easily. So we use a specific string instead ("*"), defined as BLF_I18NCONTEXT_DEFAULT_BPYRNA. From now on, all bpy/rna code should only use the BLF_I18NCONTEXT_DEFAULT_BPYRNA value, while all "usual" C code should use the BLF_I18NCONTEXT_DEFAULT value (BLF_pgettext is still able to "understand" both, anyway). Also added BLF_is_default_context helper func, so that we can keep that check in a single place! Finally, we should no need anymore to understand the void string "" as default context too - two values for a same thing are more than enough!
2013-03-15Add the possibility to define the translation context for py rna classes ↵Bastien Montagne
(operators, panels and menus). Thanks to Campell and Brecht for the reviews!
2013-01-28Fix [#34023] r54146 breaks name-display of default "UI_UL_list"Bastien Montagne
draw_item *is* optional (it then uses default C function), even though there is not much sense to register a class without it, except for our default UI_UL_list!
2013-01-28Fix for errors caused by fixing RNA function register flags. Default UIList ↵Lukas Toenne
class now has a dummy draw_item callback. Panel draw_header is now optional (most panel classes don't define it).
2013-01-20Python i18n API. Many thanks to Campbell and Brecht for the reviews and ↵Bastien Montagne
suggestions! This commit adds: * A new bpy.app.translations module giving some info about locales/translation stuff (current active locale, all locales currently known by blender, all translation contexts currently defined, etc.). * The ability for addons to feature translations, using the (un)register functions of above module. * Also cleans up "translate py string when storing into RNA prop" by removing "PROP_TRANSLATE" string's subtype, and adding a PROP_STRING_PY_TRANSLATE flag instead (this way it is no more exposed to python...). Addon translations work with py dictionaries: each addon features a dict {lang: {(context, message): translation, ...}, ...}, which is registered when the addon is enabled (and unregistered when disabled). Then, when a key (context, message) is not found in regular mo catalog, a cache dict for current locale is built from all registered addon translations, and key is searched in it. Note: currently addons writers have to do all the work by hand, will add something (probably extend "edit translation" addon) to automate messages extraction from addons soon(ish)! To get a look to expected behavior from addons, have a look at render_copy_settings/__init__.py and render_copy_settings/translations.py (rather stupid example currently, but...). Once we have a complete process, I'll also update relevant wiki pages.
2013-01-09remove uiPanelClearType(), instead redraw all windows when ↵Campbell Barton
registering/unregistering.
2013-01-09avoid having dangling panel pointers in the interface, unregistering addons ↵Campbell Barton
could leave the interface pointing to freed memory.
2013-01-09add RNA_def_struct_ptr(...) to use for runtime struct registration, saves ↵Campbell Barton
over 2000 string lookups on startup and gives overall ~10% speedup for starting blender on my system.
2013-01-05Remove some uneeded/irrelevant "PROP_TRANSLATE".Bastien Montagne
This sub-type is actually *only* needed for the "text" property of UI rna api (maybe we should rename it to "PROP_PY_TRANSLATE", as it is anyway only 'active' during conversion from py string to RNA string property...). In fact, I think it should only be used in RNA func properties anyway, as it stores the translated string into the property, it should only be used with "one time" RNA stuff...
2012-12-28style cleanup: var naming for ui listCampbell Barton
2012-12-28This commit frees list ui items from their dependencies to Panel, and hence ↵Bastien Montagne
from all the limitations this implied (mostly, the "only one list per panel" one). It introduces a new (py-extendable and registrable) RNA type, UIList (roughly similar to Panel one), which currently contains only "standard" list's scroll pos and size (but may be expended to include e.g. some filtering data, etc.). This now makes lists completely independent from Panels! This UIList has a draw_item callback which allows to customize items' drawing from python, that all addons can now use. Incidentally, this also greatly simplifies the C code of this widget, as we do not code any "special case" here anymore! To make all this work, other changes were also necessary: * Now all buttons (uiBut struct) have a 'custom_data' void pointer, used currently to store the uiList struct associated with a given uiLayoutListBox. * DynamicPaintSurface now exposes a new bool, use_color_preview (readonly), saying whether that surface has some 3D view preview data or not. * UILayout class has now four new (static) functions, to get the actual icon of any RNA object (important e.g. with materials or textures), and to get an enum item's UI name, description and icon. * UILayout's label() func now takes an optional 'icon_value' integer parameter, which if not zero will override the 'icon' one (mandatory to use "custom" icons as generated for material/texture/... previews). Note: not sure whether we should add that one to all UILayout's prop funcs? Note: will update addons using template list asap.
2012-12-12Fix for misleading doc string of panel header options.Lukas Toenne
2012-10-21A final bunch of UI messages fixes and tweaks, and some ↵Bastien Montagne
BKE_report()<->BKE_reportf() fixes.
2012-10-13And more UI messages spell check.Bastien Montagne
2012-07-03More spell and typo fixes (mostly visualise->visualize, grey->gray, ↵Bastien Montagne
normalise->normalize).
2012-05-12style cleanup: mostly whitespace in rnaCampbell Barton
2012-04-28Plugin system:Thomas Dinges
* Remove RNA, Operator and UI for Texture and Sequence plugins. Since 2.5x no effort has been done to bring that back, so there is simply no reason in keeping that code and the UI for that ;-) * Low Level code still exists and is unchanged.
2012-04-09fix [#30865] Crash when browsing last operators in outliner (or by Python API)Campbell Barton
Operator descriptions can be NULL pointers, fix this by making use of PROP_NEVER_NULL flag, when its not set, generated string funcs will test for NULL.
2012-03-18Code style edits (mostly spliting long lines, and removing trailing spaces).Bastien Montagne
Note about long lines: I did not touch to two pieces of code (because I don’t see any way to keep a nicely formated, compact code, with shorter lines): * The node types definitions into rna_nodetree_types.h * The vgroup name functions into rna_particle.c
2012-03-09style cleanup: spelling.Campbell Barton
also remove large, duplicate comments from sunsky.h
2012-03-06Code cleanup in rna files (huge, higly automated with py script).Bastien Montagne
Addresses: * C++ comments. * Spaces after if/for/while/switch statements. * Spaces around assignment operators.
2012-02-16Reverting changes in commit r43458.Sergey Sharybin
That was intended change to clear PROP_TRANSLATE flag from bl_label property of operators, panels and menus (see rev40570) If this flag leads to another issues it should be fixed in another way. This fixes #30210: International Font Problem
2012-01-17Poor menu labels were not translated!Bastien Montagne
2011-11-15replace rna description string limits with rna define RNA_DYN_DESCR_MAXCampbell Barton
2011-11-15add support for python __doc__ comments in menu classes showing in the ↵Campbell Barton
tooltip, since menus are used as buttons too.
2011-10-23remove $Id: tags after discussion on the mailign list: ↵Campbell Barton
http://markmail.org/message/fp7ozcywxum3ar7n
2011-10-20replace RNA function string lookups with direct assignments, currently the ↵Campbell Barton
lookup returns the same pointer every time. some of these functions - panel/operator poll for eg, are called many times per redraw so while not a bottleneck its unnecessary.
2011-10-02Minor: Other UI strings typos and tweaks. Also updated french po & mo.Bastien Montagne
2011-09-29Minor: Other UI strings typos and tweaks. Also updated french po & mo.Bastien Montagne
(grrr... That update created tons of new things... back to ~40% done...)
2011-09-26Remove PROP_TRANSLATE flag from labels for operators, menus and panels.Sergey Sharybin
This flag lead to storing translated label for templates and instant language switching became impossible. This labels are display-time translated.
2011-09-21add missing define for last commit and tag bl_label & bl_descriptions for ↵Campbell Barton
translating too
2011-09-19/blender/makesrna: Removed final points in UI strings and messages.Bastien Montagne
Plus a few splits of very long lines…
2011-05-31tag unused rna args.Campbell Barton
2011-05-18RNA: make mechanism used by operators to keep python instance alive more ↵Brecht Van Lommel
generic, to be used by render engine later.