Age | Commit message (Collapse) | Author |
|
Previous state:
Right now, there are "memories" of the "old" (less than a month!) translation way:
* A few remaining calls to BLF_gettext() (only UI_translate_do_iface and UI_translate_do_tooltip should be used).
* The _() macro still also calls BLF_gettext()!
New state:
Here are the changes made by the patch:
* Removing the no more needed _() macro.
* Removing most N_() and _() calls, only keeping the few needed ones (i.e. strings that are in no other way findable by xgettext and/or update_msg script).
* Defining in UI_interface.h IFACE_() and TIP_() macros (resp. for UI_translate_do_iface and UI_translate_do_tooltip).
* Replacing all calls to BLF_gettext by relevant IFACE_ or TIP_ one.
* Replacing all calls to UI_translate_do_iface by IFACE_.
* Replacing all calls to UI_translate_do_tooltip by TIP_.
All this somewhat clarifies and simplifies the code.
On the bf-translations scripts side, this only implies adding IFACE_ and TIP_ as detection markers for xgettext.
It also allows to reduce POTFILES.in quite notably (only 20 files remaining in it).
Please also have a look at those pages:
* Coder POV: http://wiki.blender.org/index.php/Dev:2.5/Source/Interface/Internationalization
* Translator POV: http://wiki.blender.org/index.php/Dev:2.5/Doc/How_to/Translate_Blender
|
|
|
|
Language Enum
|
|
- fix for cmake's SSE detection which would fail because of strict warnings and also had redundant cache setting.
- was incorrectly initializing variables (own bad)
- python was searching for libs on every run, now only do this if there not cached.
|
|
since it doesnt ensure \0 termination.
also dont call CTX_data_scene() twice when checking for function arguments.
|
|
also rename backface_culling --> use_backface_culling (which is used elsewhere in rna)
|
|
|
|
|
|
add image strip crashes Blender
Crash was caused by sprintf which tried to parse bytes sequence belongs to chinese letter.
Using codepage 1252 for LC_ALL seems to fix this issue, but needs further testing.
|
|
|
|
|
|
- Move all translation-related declarations to BLF_translation.h
- Reverted some changes to match trunk svn rev40365
|
|
|
|
when toggling use antialising user preference. Also fix some other use of
uninitialized memory found by valgrind.
|
|
|
|
|
|
|
|
- remove saniy checks from blf_font.c, the callers now check instead.
- move duplicate code into defines (may move into static functions).
- move kerning checks into const values set at the start of the function, rather then checking on every character.
|
|
- Static variables can be initialized with constants only.
- Removed bunifont.ttf.c from datafiles -- it's not actually a
data file. Unicode font loading stuff is not in blenkernel/font.c
- Allocate as much memory for unzipped data as it's needed.
Default read chunk is 512Kb.
- Fixed regression (or just a typo) in setting utf locale.
- Default locale set to en_US:en works fine now.
- Commented put Nepali language in user preferences -- it's
not supported by current droid font and imo it's better to
have nice font for languages we actually have translation for
rather than allowing to choose more languages in user preferences.
|
|
glGetIntegerv(GL_TEXTURE_2D_BINDING_EXT, &cur_tex);
... with shadow enabled glGetFloatv(GL_CURRENT_COLOR, color) was called twice per character as well.
Now only call glGetFloatv(GL_CURRENT_COLOR, ...) once per string and only when drawing with shadow or blur, texture bind is stored in the font.
Gives 8% overall FPS speedup when displaying heavy UI in my test.
|
|
|
|
|
|
- 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.
|
|
|
|
|
|
|
|
for ascii characters in a utf8 string use glyph_ascii_table lookup rather than call blf_glyph_search(), otherwise fallback to blf_utf8_next() and blf_glyph_search().
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
failure bugs
|
|
|
|
remove missing includes and use more strict formatting.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Copy unifont..ttf.gz from source tree to target datafile path( now ONLY works with cmake );
Set the locale the same with system's setting;
If need unicode font, unzip and load unifont when init ui styles;
Apply gettext() to labels in space_info.py, who are the main menu items.
Each of these should have been commit one by one. As they work well according to my tests, so I just lazily send a long list.
|
|
blender_add_lib now takes a separate include argument to suppress warnings in system includes (mostly ffmpeg & python).
also only build wm_apple.c on apple+carbon configuration.
|