Commit Graph

184 Commits

Author SHA1 Message Date
vocx-fc
107a945ccc Draft: standardized module to build messages 2020-02-10 11:12:45 +01:00
vocx-fc
ccebb92258 Draft: added init_tools to create the toolbars 2020-02-10 11:02:28 +01:00
vocx-fc
d8fd4b2f9c Draft: move translate function to translate module
The translate mechanism in Draft depends on the `QtCore`
`translate` function. This is defined in its own module
so that `DraftGui.py` is not as big and hard to manage.

Other modules in Draft can import the translate function
without needing to import the entire interface, which
often causes errors and circular dependencies.

We can import `QtCore.QT_TRANSLATE_NOOP` at the top level
in `Draft.py` because it does not depend on the graphical
interface.
2020-01-15 10:05:52 +01:00
vocx-fc
abd31f0b2b Draft: move todo static class to the todo module
The todo class in `DraftGui.py` can be placed in its
own module so that `DraftGui.py` isn't as big
and hard to maintain.
2020-01-14 12:49:29 +01:00
vocx-fc
4d956930f5 Draft: new module for GUI utility functions
Many auxiliary tools used by `Draft.py` can be defined
in another module. Many functions are moved to this module
so that `Draft.py` isn't as big and hard to maintain.

The following is a list o functions that were moved:
`get3DView`, `autogroup`, `dimSymbol`, `dimDash`,
`removeHidden`, `formatObject`, `getSelection`,
`getSelectionEx`, `select`, `loadTexture`.

Moreover, many of these functions were renamed
to comply better with PEP8 guidelines,
particularly the use of `snake_case`. For example,
`get3DView` is now `get_3d_view`.

Aliases are provided for the old names so that
other functions and classes that depend on these
won't break. The new names should be the official
programming interface, while the old names
should be deprecated at some point in the future.
2020-01-10 10:04:07 +01:00
vocx-fc
7721ca0157 Draft: new module for utility functions
Many auxiliary tools used by `Draft.py` can be defined
in another module. Many functions are moved to this module
so that `Draft.py` isn't as big and hard to maintain.

The following is a list of functions and attributes that were moved:
`stringencodecoin`, `arrowtypes`, `typecheck`,
`getParamType`, `getParam`, `setParam`, `precision`,
`tolerance`, `epsilon`, `getRealName`, `getType`,
`getObjectsOfType`, `isClone`, `getGroupNames`,
`ungroup`, `shapify`, `getGroupContents`,
`printShape`, `compareObjects`, `loadSvgPatterns`,
`svgpatterns`, `getMovableChildren`, `getWindows`,
`utf8_decode`.

Moreover, many of these functions were renamed
to comply better with PEP8 guidelines, particularly
the use of `snake_case`. For example, `getGroupNames`
is now `get_group_names`; `getMovableChildren`
is now `get_movable_children`.

Aliases are provided for the old names so that
other functions and classes that depend on these
won't break. The new names should be the official
programming interface, while the old names
should be deprecated at some point in the future.
2020-01-08 15:16:55 +01:00
vocx-fc
ab6976c5db Draft: add new command for Draft CircularArray
Added object, viewprovider, icon; gui command definition, task panel,
add command to InitGui; add callbacks, and delay system.
2020-01-08 15:16:07 +01:00
vocx-fc
1336381eec Draft: new command for Draft PolarArray
Added object, viewprovider, icon; gui command definition, task panel,
add command to InitGui; add callbacks, and delay system.
2020-01-07 07:18:39 -03:00
vocx-fc
1b45c3da7e Draft: fix CMakeLists to install files in directories 2019-12-28 15:56:02 -03:00
vocx-fc
11f4fabf2f Draft: add GuiCommandBase class to serve as the parent class of all DraftTools
Prepare auxiliary directories to restructure all graphical tools
for objects, viewproviders, gui commands, and taskpanels.
2019-12-27 11:01:34 -03:00
vocx-fc
2a4fb552ec Draft: move the TestDraft unit tests to separate modules
This results in better organization of the tests,
avoiding extremely big files.
2019-12-17 15:06:36 -03:00
Yorik van Havre
b7b8dbabf5 Split Draft_SelectPlane and DraftSetWorkingPlaneProxy to a separate file 2019-09-02 17:23:57 -03:00
vocx-fc
4c5e719e45 Draft: added DraftFillet.py to the sources, also InitGui.py, Draft.py, DraftTools.py, and CMakeLists.txt 2019-08-22 10:54:41 -03:00
Yorik van Havre
ee446ee441 Moving OfflineRenderingUtils.py from Draft to Arch 2019-06-29 21:03:03 -03:00
Yorik van Havre
5f229e8c29 Draft: Added Offline rendering utils module 2019-06-29 20:59:46 -03:00
Yorik van Havre
43c3977c46 Draft: Added missing cmake entry from last commit 2019-06-17 16:43:01 -03:00
Yorik van Havre
2c918366e4 Draft: Introduced Layers system (former VisGroup) 2019-06-05 18:47:01 -03:00
George Shuklin
dce109309d Include getSVG.py into Draft_SRCS 2018-12-17 09:37:51 -03:00
wmayer
8088aa159f CMake 2.8.12 and lower allowed the SOURCE signature in add_custom_command
In CMake 3.0 the policy CMP0050 was introduced where it could be set to OLD to keep this behaviour while for NEW an error was raised.
Since CMake 3.5.2 a warning comes up when using the OLD behaviour and that it will be removed in a future version.

In FreeCAD we switched to the new behaviour now and removed the SOURCE signature from add_custom_command which affects the macros
fc_copy_sources, fc_target_copy_resource and fc_target_copy_resource_flat and their usage.
It's not possible any more to add files to a target by using the macros. Now a file must be added to the target before using the macros.

This commit fixes it for Arch, Draft, OpenSCAD, Material, Plot and Ship
2018-08-20 11:47:39 +02:00
triplus
93c7a6bcac Add SVG workbench icons 2016-02-26 23:17:43 +01:00
Ian Rees
0a70ce4eef Add cmake checks for BUILD_GUI to some modules 2016-02-13 13:45:27 +13:00
Yorik van Havre
279d156d30 Draft: Starting a C++ DXF importer - issue #2205 2015-08-10 19:55:59 -03:00
wmayer
4459b37e45 + fix copying Python resource files to destination on Windows 2014-11-08 11:08:58 +01:00
Yorik van Havre
8676ed01c3 Arch and Draft rc files are now compiled at build time - issue #1796 2014-11-05 20:07:53 -02:00
Yorik van Havre
80fe67584a Draft: removed macros menu - fixes #490
The macros menu code is on http://www.freecadweb.org/wiki/index.php?title=Macro_MacroMenu
2014-08-07 11:07:22 -03:00
Yorik van Havre
2aacbf46e1 Draft: Added test suite 2013-08-15 19:24:54 -03:00
Yorik van Havre
6b434a4d0d Draft: fixed cmake and installer stuff with removed draftlibs 2013-06-23 15:33:26 -03:00
Yorik van Havre
05bbf9c67c Draft: fixed Draft's cmake file 2013-04-21 19:22:30 -03:00
Yorik van Havre
28f386f3ab Renamed Draft fcvec and fcgeo modules
Draft/draftlibs/fcvec becomes Draft/DraftVecUtils
Draft/draftlibs/fcgeo becomes Draft/DraftGeomUtils
2012-05-22 11:45:40 -03:00
wmayer
837ddf5f38 Support of INSTALL target on Windows (VC++ and MinGW) 2012-02-17 21:41:00 +01:00
yorikvanhavre
f5d2ae2295 + separated Draft Snap and Trackers into their own files
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5277 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-12-12 16:20:41 +00:00
yorikvanhavre
6c601565e2 Changing some filenames in Draft to more unified naming scheme
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5276 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-12-12 16:03:18 +00:00
wmayer
bde949f7e4 0000519: Patch to set proper RPATH's for system wide installation on Linux
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5270 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-12-11 12:36:36 +00:00
wmayer
120ca87015 + unify DLL export defines to namespace names
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5000 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-10-10 13:44:52 +00:00