Patches to Bf Blender for CAD development. https://tornavis.org/
Go to file
Bastien Montagne 87cc890aef Support units in modal numinput
Summary:
This completly changes the way modal numinput is handled. Now, edited expression is a string, which then gets unit- and py-evaluated to get a float value.

We gain many power and flexibility, but lose a few "shortcuts" like '-' to negate, or '/' to inverse (if they are really needed, we still can add them with modifiers, like e.g. ctrl-/ or so).

Features:
- units (cm, ", deg, etc.).
- basic operations from python/BKE_unit (+, *, **, etc.), and math constants and functions (pi, sin, etc.).
- you can navigate in edited value (left/right key, ctrl to move by block) and insert/delete chars, e.g. to fix a typo without having to rewrite everything.
- you can go to next/previous value with (ctrl-)TAB key.
- As before, hitting backspace after having deleted all leading chars will first reset the edited value to init state, and on second press, the whole "modal numinput" editing will be cancelled, going back to usual transform with mouse.

Notes:
- Did not touch to how values are shown in header when modal numinput is not enabled (would do that in another commit), so this is still quite inconsistent.
- Added back radian support in BKE_unit.
- Added arcminute/arcsecond to BKE_unit.
(those unit changes affect all angle UI controls, btw, so you can now enter radians or longitude/latitude values when in degrees units).

Related to T37600.

Reviewers: brecht, campbellbarton, carter2422

Reviewed By: brecht, campbellbarton, carter2422
Thanks everybody!

Differential Revision: http://developer.blender.org/D61
2013-12-21 17:44:48 +01:00
build_files Raise Python version to 3.3.3. 2013-12-19 22:44:51 +01:00
doc Game Engine: Option to record static objects animation 2013-12-09 22:28:38 +11:00
extern CMake: report messages as status (else ccmake treats like an error) 2013-12-10 13:18:46 +11:00
intern Cleanup: Code and style cleanup for Cycles curve export code. 2013-12-21 00:20:16 +01:00
release Vertex/weight paint: remove "Use All Faces" option. 2013-12-18 17:50:51 +01:00
scons@2d6ebcb239 Squashed commit of the following: 2013-11-21 16:51:29 +01:00
source Support units in modal numinput 2013-12-21 17:44:48 +01:00
.arcconfig Added the wrong file. Now addin .arcconfig for real. 2013-11-15 20:40:43 +06:00
.gitignore Ignore *.patch and *.diff files which are in the working tree root 2013-11-22 23:28:35 +06:00
.gitmodules
CMakeLists.txt MSVC 2013 cmake changes 2013-12-20 14:32:51 +01:00
COPYING
GNUmakefile Convenience Makefile: spaces in the build path would fail still. 2013-11-17 21:16:39 +11:00
SConstruct Fix T37780: no languages in user preferences with SCons on Windows / Linux. 2013-12-12 06:09:58 +01:00