donovaly
d1b354fc6b
add units Gauss, Weber and Oersted
2020-01-07 07:36:22 -03:00
donovaly
317c153494
Quantity.cpp: fix spacing
2020-01-05 15:00:46 +01:00
donovaly
68ea38cc8d
add the units Ohm and Siemens
2020-01-05 15:00:46 +01:00
wmayer
a92cf1a785
Base: [skip ci] do not normalize axis when changing angle of a Rotation object
2019-12-28 14:04:02 +01:00
luz.paz
011e5aedfa
src/Base: [skip ci] fix header uniformity
...
This PR fixes header uniformity across all `src/Base` files
2019-12-25 11:38:58 +01:00
donovaly
bab14b5895
more fixes for the UnitsCalculator
...
- we must read out the unit system description UTF8 to get the characters ² and ³
- update unit system description according to today's unit "cft" addition
- don't hardcode the unit system descriptions in the .ui file
- add acceleration to imperial schema
2019-12-24 13:31:13 +01:00
donovaly
3da00267cf
cosmetics to keep the overview
2019-12-24 13:31:00 +01:00
donovaly
b255475d7c
missing parts from from commit 33b8054228
...
- also add keV and MeV since these are the units used in practice
2019-12-24 13:31:00 +01:00
wmayer
2484cd56ef
Units: extend parser to accept mph, sqft and cft. Fix a bug in imperial civil schema
2019-12-23 19:55:21 +01:00
donovaly
a6a043a6f2
also add unit THz as requested
2019-12-23 16:49:45 +01:00
donovaly
edd97de6a2
add units Mpsi, cal and kcal
...
- also ass missing parts from commit 0021efbf
2019-12-23 16:49:45 +01:00
wmayer
e1b7ef10c7
add posibility to use a unit schema other then the system schema to represent a quantity
2019-12-21 13:35:14 +01:00
wmayer
980c6ab227
Base: [skip ci] replace raw pointers of UnitsSchema with unique_ptr
2019-12-21 10:45:22 +01:00
wmayer
c16c7eda27
Base: [skip ci] make UnitSystem an enum class
2019-12-21 10:10:19 +01:00
wmayer
a81e7ff747
Base: [skip ci] handle acceleration and force m/s^2
2019-12-20 16:53:26 +01:00
wmayer
065356281d
Python: change generation of callback functions for class or static methods
2019-12-19 17:55:12 +01:00
wmayer
546dc43929
Base: [skip ci] fix block comment in lexer file
2019-12-19 17:08:11 +01:00
donovaly
26196ae612
add mJ and kW
...
- also some fixes
- add conversions for forces
2019-12-19 13:31:12 +01:00
donovaly
23ec305c4b
correct Unit::Work conversions
...
- also add conversions for Unit::Mass and Unit::Power
2019-12-19 13:31:12 +01:00
donovaly
53b34a3dc0
take care of the UnitsCalculator
...
- also fix uF and uH
- add conversion routine for C and T
2019-12-19 13:31:12 +01:00
donovaly
4b99ee28ce
generate QuantityLexer.c
...
- also set proper unit conversions
- fix MilliWatt and MilliMole
2019-12-19 13:31:12 +01:00
donovaly
94bae36cee
add the following units:
...
- mmol
- ml
- bar
- mbar
- kJ
- kWh
- eV
- C
- T
- F (p, n, u, m)
- H (n, u, m)
2019-12-19 13:31:12 +01:00
luz.paz
cc97145e9d
Fix various typos [skip ci]
...
Fixed via
```
codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,currenty,dof,doubleclick,dum,eiter,elemente,feld,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml
```
2019-12-17 15:13:48 -03:00
wmayer
33f1511039
fix -Wformat-pedantic
2019-12-05 12:23:51 +01:00
asapelkin
875a463923
Used single quotes for single character in string::find algorithm, more efficient
2019-11-21 18:59:43 +01:00
asapelkin
ced8100ab9
use emplace_back instead of push_back where justified
2019-11-21 14:48:09 +01:00
wmayer
aa472d8460
[skip ci] suppress -Wgnu-zero-variadic-macro-arguments for some headers
2019-11-13 22:38:09 +01:00
wmayer
f5a63e0953
Enhabce TypePy:
...
add convenience method getAllDerived()
support TypePy asrgument in getAllDerivedFrom() and isDerivedFrom()
return TypePy instead of str in getAllDerivedFrom()
2019-11-13 10:41:04 +01:00
wmayer
d953a44eaf
declare getAllDerivedFrom as static method
2019-11-13 00:57:21 +01:00
wmayer
79ef4be9de
export typeid system to Python
2019-11-13 00:43:23 +01:00
wmayer
4539bd90b7
handle possible exceptions for FreeCAD.Units.Unit(input string)
2019-11-03 19:01:27 +01:00
wmayer
0a5b1f3aab
support quantities in a string of the form: value / unit
2019-11-03 18:47:33 +01:00
luz.paz
30a717beac
Fix typos and misc. formatting [skip ci]
...
Found via `codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,currenty,dof,doubleclick,dum,eiter,elemente,feld,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml`
2019-10-21 16:02:23 -03:00
wmayer
210601c2be
[skip ci] remove unused variable
2019-10-21 12:04:23 +02:00
wmayer
617a8d7598
Support for Frequency in quantity parser
2019-10-21 11:49:55 +02:00
wmayer
4d831ea442
Basic support for Frequency as unit
2019-10-20 18:14:56 +02:00
howetuft
3e5d3460c7
Fix -Wdeprecated-copy warnings (rule of 5/3/0)
...
Fix -Wdeprecated-copy warnings in various places. Consists in enforcing
rule of five/three/zero (https://en.cppreference.com/w/cpp/language/rule_of_three )
mainly by deleting redundant copy constructors or copy assignment operators
that replicate default constructors/operators, or more rarely by adding
missing copy/move constructors/operators.
See also https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#c20-if-you-can-avoid-defining-default-operations-do
2019-10-20 17:02:17 +02:00
wmayer
77bc9cd8d5
restore old behaviour of Python wrapper of Console class to increase flexibility when using in worker threads
2019-10-20 13:51:53 +02:00
wmayer
4a6b80dbb6
in RedirectStdOutput/RedirectStdError/RedirectStdLog only flush when last character is newline to avoid garbled output in log file
2019-10-20 13:42:51 +02:00
wmayer
c71c893a50
fix -Winconsistent-missing-override
2019-10-20 13:23:41 +02:00
wmayer
5ba9bc6a16
minor optimization in ConsoleObserverFile, if prefix is unknown then still write passed message
2019-10-20 12:52:08 +02:00
ezzieyguywuf
9fcc18b08e
Refactor and rename ConsoleObserver...
...
...Renamed to "ILogger", to designate that this is an Interface for a
Logger. This "Interface" is pure virtual, so that it cannot be
instantiated directly. This makes it clear that it is intended to be
derived.
Finally, got rid of all the individual log-style methods and replaced
with SendLog. The idea here is that day-to-day users will only interact
with ILogger through ConsoleSingleton (or, likely, LoggerSingleton in
the future). This singleton will manage an arbirtary collection of
ILogger, and call SendLog with the appropriate parameters based on what
the user requests.
Therefore, the singleton itself will have the individual Log, Message,
Error, etc... methods, while stil allowing us to simplify the code base
of ILogger and its derived classes.
2019-10-20 11:46:15 +02:00
luz.paz
b877cc49a7
Doxygen: Base/Parameter.h description
...
Adding a cursory description for `Parameter.h` + typo fix for it's companion .cpp file.
.
2019-10-19 16:14:53 -03:00
wmayer
fd2940ead7
replace some old C style casts with static_cast or reinterpret_cast
2019-10-18 15:50:15 +02:00
wmayer
4642913b61
fix several memory leaks in ParameterGrp when removing nodes from DOM document
2019-10-18 15:43:22 +02:00
wmayer
7a45d74bc7
+ implement a correct cleaning of a parameter group without creating ghost instances of ParameterGrp
2019-10-18 15:38:58 +02:00
wmayer
4dedd32031
+ before creating element in DOM document check if the group node still has the correct name
2019-10-18 15:34:20 +02:00
Richard
f53baef54a
Update swigpyrun.in for Python 3.8
...
In Python 3.8 some functions related to thread state were intentionally made private.
This fix (specific to FreeCAD) was suggested here:
https://bugs.python.org/issue35886
2019-10-18 10:12:59 +02:00
wmayer
bd76bbd625
Add an XSD validation scheme and implement ParameterManager::CheckDocument(), function is used in the parameter editor
2019-10-14 22:56:03 +02:00
wmayer
b656301c9b
expose Placement.slerp to Python
2019-10-12 23:58:54 +02:00