summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Drobchenko <xepecine@gmail.com>2011-07-05 15:12:43 +0000
committerNick <xepecine@gmail.com>2011-07-05 15:12:43 +0000
commit4d613dc583b96ea9205cd06f229956d6ec56c9e6 (patch)
tree4ef65b8843a4ee4f05c4895643f8abb0a63602a5
parentExtensions. Perspective. use transform elements if present (Bug 168942) (diff)
downloadinkscape-4d613dc583b96ea9205cd06f229956d6ec56c9e6.tar.gz
inkscape-4d613dc583b96ea9205cd06f229956d6ec56c9e6.zip
Gcodetools have been upgraded to v. 1.7.
(bzr r10417)
-rw-r--r--CMakeScripts/ConfigChecks.cmake140
-rw-r--r--CMakeScripts/ConfigPaths.cmake62
-rw-r--r--CMakeScripts/HelperMacros.cmake130
-rw-r--r--CMakeScripts/IncludeJava.cmake28
-rw-r--r--Doxyfile2924
-rw-r--r--packaging/win32/AdvUninstLog.nsh874
-rw-r--r--packaging/win32/AdvUninstLog.txt240
-rw-r--r--packaging/win32/MessageBox.txt370
-rw-r--r--packaging/win32/RequireLatestNSIS.nsh18
-rw-r--r--packaging/win32/VersionCompleteXXXX.nsh94
-rw-r--r--packaging/win32/ifexist.nsh42
-rw-r--r--packaging/win32/languages/Japanese.nsh226
-rw-r--r--packaging/win32/languages/SimpChinese.nsh226
-rw-r--r--packaging/win32/languages/TradChinese.nsh226
-rw-r--r--packaging/win32/md5dll.txt136
-rw-r--r--packaging/win32/portable/App/AppInfo/appinfo.ini52
-rw-r--r--packaging/win32/portable/App/AppInfo/installer.ini30
-rw-r--r--packaging/win32/portable/App/readme.txt2
-rw-r--r--packaging/win32/portable/Other/Source/InkscapePortable.ini12
-rw-r--r--packaging/win32/portable/Other/Source/InkscapePortable.nsi260
-rw-r--r--packaging/win32/portable/Other/Source/License.txt686
-rw-r--r--packaging/win32/portable/Other/Source/PortableApps.comInstallerCustom.nsh24
-rw-r--r--packaging/win32/portable/Other/Source/PortableApps.comLauncherLANG_ENGLISH.nsh12
-rw-r--r--packaging/win32/portable/Other/Source/Readme.txt134
-rw-r--r--packaging/win32/portable/Other/Source/ReplaceInFileWithTextReplace.nsh126
-rw-r--r--packaging/win32/portable/help.html354
-rw-r--r--share/extensions/Poly3DObjects/cube.obj36
-rw-r--r--share/extensions/Poly3DObjects/cuboct.obj60
-rw-r--r--share/extensions/Poly3DObjects/dodec.obj72
-rw-r--r--share/extensions/Poly3DObjects/great_dodec.obj192
-rw-r--r--share/extensions/Poly3DObjects/great_rhombicosidodec.obj370
-rw-r--r--share/extensions/Poly3DObjects/great_rhombicuboct.obj154
-rw-r--r--share/extensions/Poly3DObjects/great_stel_dodec.obj192
-rw-r--r--share/extensions/Poly3DObjects/icos.obj72
-rw-r--r--share/extensions/Poly3DObjects/icosidodec.obj130
-rw-r--r--share/extensions/Poly3DObjects/jessens_orthog_icos.obj68
-rw-r--r--share/extensions/Poly3DObjects/methane.obj26
-rw-r--r--share/extensions/Poly3DObjects/oct.obj34
-rw-r--r--share/extensions/Poly3DObjects/rh_axes.obj24
-rw-r--r--share/extensions/Poly3DObjects/rhomb_dodec.obj56
-rw-r--r--share/extensions/Poly3DObjects/rhomb_triacont.obj130
-rw-r--r--share/extensions/Poly3DObjects/small_rhombicosidodec.obj254
-rw-r--r--share/extensions/Poly3DObjects/small_rhombicuboct.obj108
-rw-r--r--share/extensions/Poly3DObjects/small_triam_icos.obj190
-rw-r--r--share/extensions/Poly3DObjects/snub_cube.obj130
-rw-r--r--share/extensions/Poly3DObjects/snub_dodec.obj312
-rw-r--r--share/extensions/Poly3DObjects/szilassi.obj48
-rw-r--r--share/extensions/Poly3DObjects/tet.obj24
-rw-r--r--share/extensions/Poly3DObjects/trunc_cube.obj84
-rw-r--r--share/extensions/Poly3DObjects/trunc_dodec.obj192
-rw-r--r--share/extensions/Poly3DObjects/trunc_icos.obj192
-rw-r--r--share/extensions/Poly3DObjects/trunc_oct.obj82
-rw-r--r--share/extensions/Poly3DObjects/trunc_tet.obj46
-rw-r--r--share/extensions/gcodetools.py3189
-rw-r--r--share/extensions/gcodetools_about.inx53
-rw-r--r--share/extensions/gcodetools_all_in_one.inx194
-rw-r--r--share/extensions/gcodetools_area.inx55
-rw-r--r--share/extensions/gcodetools_check_for_updates.inx8
-rw-r--r--share/extensions/gcodetools_dxf_points.inx21
-rw-r--r--share/extensions/gcodetools_engraving.inx45
-rw-r--r--share/extensions/gcodetools_graffiti.inx119
-rw-r--r--share/extensions/gcodetools_lathe.inx52
-rw-r--r--share/extensions/gcodetools_orientation_points.inx15
-rw-r--r--share/extensions/gcodetools_path_to_gcode.inx36
-rw-r--r--share/extensions/gcodetools_prepare_path_for_plasma.inx61
-rw-r--r--share/extensions/gcodetools_tools_library.inx10
-rw-r--r--share/extensions/xaml2svg/animation.xsl282
-rw-r--r--share/extensions/xaml2svg/brushes.xsl488
-rw-r--r--share/extensions/xaml2svg/canvas.xsl160
-rw-r--r--share/extensions/xaml2svg/geometry.xsl544
-rw-r--r--share/extensions/xaml2svg/properties.xsl572
-rw-r--r--share/extensions/xaml2svg/shapes.xsl342
-rw-r--r--share/extensions/xaml2svg/transform.xsl240
-rw-r--r--share/keys/corel-draw-x4.xml2
-rw-r--r--share/keys/macromedia-freehand-mx.xml868
-rw-r--r--src/2geom/!PLEASE DON'T MAKE CHANGES IN THESE FILES.README14
-rw-r--r--src/CMakeLists.txt1196
-rw-r--r--src/dom/mingwenv.bat4
-rw-r--r--src/inkscape-manifest.xml18
-rw-r--r--src/inkview-manifest.xml18
-rw-r--r--src/inkview.rc58
-rw-r--r--src/libvpsc/CMakeLists.txt58
82 files changed, 10842 insertions, 8586 deletions
diff --git a/CMakeScripts/ConfigChecks.cmake b/CMakeScripts/ConfigChecks.cmake
index a04cf2698..5f76e01e9 100644
--- a/CMakeScripts/ConfigChecks.cmake
+++ b/CMakeScripts/ConfigChecks.cmake
@@ -1,70 +1,70 @@
-#---------------
-# From here on:
-# Set all HAVE_XXX variables, to correctly set all defines in config.h
-#SET(CMAKE_REQUIRED_INCLUDES ${INK_INCLUDES})
-include(CheckIncludeFiles)
-include(CheckFunctionExists)
-include(CheckStructHasMember)
-# usage: CHECK_INCLUDE_FILES (<header> <RESULT_VARIABLE> )
-# usage: CHECK_FUNCTION_EXISTS (<function name> <RESULT_VARIABLE> )
-# usage: CHECK_STRUCT_HAS_MEMBER (<struct> <member> <header> <RESULT_VARIABLE>)
-
-CHECK_INCLUDE_FILES(boost/concept_check.hpp HAVE_BOOST_CONCEPT_CHECK_HPP)
-CHECK_INCLUDE_FILES(cairo-pdf.h HAVE_CAIRO_PDF)
-CHECK_FUNCTION_EXISTS(floor HAVE_FLOOR)
-CHECK_FUNCTION_EXISTS(fpsetmask HAVE_FPSETMASK)
-CHECK_INCLUDE_FILES(gc/gc.h HAVE_GC_GC_H)
-CHECK_INCLUDE_FILES(gc.h HAVE_GC_H)
-CHECK_INCLUDE_FILES(getopt.h HAVE_GETOPT_H)
-CHECK_FUNCTION_EXISTS(gettext HAVE_GETTEXT)
-CHECK_FUNCTION_EXISTS(gettimeofday HAVE_GETTIMEOFDAY)
-CHECK_FUNCTION_EXISTS(gtk_window_fullscreen HAVE_GTK_WINDOW_FULLSCREEN)
-CHECK_FUNCTION_EXISTS(gtk_window_set_default_icon_from_file HAVE_GTK_WINDOW_SET_DEFAULT_ICON_FROM_FILE)
-CHECK_INCLUDE_FILES(ieeefp.h HAVE_IEEEFP_H)
-CHECK_INCLUDE_FILES(inttypes.h HAVE_INTTYPES_H)
-CHECK_INCLUDE_FILES(locale.h HAVE_LC_MESSAGES)
-CHECK_INCLUDE_FILES(locale.h HAVE_LOCALE_H)
-CHECK_INCLUDE_FILES(libintl.h HAVE_LIBINTL_H)
-CHECK_INCLUDE_FILES(fcntl.h HAVE_FCNTL_H)
-CHECK_FUNCTION_EXISTS(mallinfo HAVE_MALLINFO)
-CHECK_INCLUDE_FILES(malloc.h HAVE_MALLOC_H)
-CHECK_FUNCTION_EXISTS(memmove HAVE_MEMMOVE)
-CHECK_INCLUDE_FILES(memory.h HAVE_MEMORY_H)
-CHECK_FUNCTION_EXISTS(memset HAVE_MEMSET)
-CHECK_FUNCTION_EXISTS(mkdir HAVE_MKDIR)
-CHECK_FUNCTION_EXISTS(pow HAVE_POW)
-CHECK_FUNCTION_EXISTS(sqrt HAVE_SQRT)
-CHECK_INCLUDE_FILES(stddef.h HAVE_STDDEF_H)
-CHECK_INCLUDE_FILES(stdint.h HAVE_STDINT_H)
-CHECK_INCLUDE_FILES(stdlib.h HAVE_STDLIB_H)
-CHECK_INCLUDE_FILES(strings.h HAVE_STRINGS_H)
-CHECK_INCLUDE_FILES(string.h HAVE_STRING_H)
-CHECK_FUNCTION_EXISTS(strncasecmp HAVE_STRNCASECMP)
-CHECK_FUNCTION_EXISTS(strpbrk HAVE_STRPBRK)
-CHECK_FUNCTION_EXISTS(strrchr HAVE_STRRCHR)
-CHECK_FUNCTION_EXISTS(strspn HAVE_STRSPN)
-CHECK_FUNCTION_EXISTS(strstr HAVE_STRSTR)
-CHECK_FUNCTION_EXISTS(strtoul HAVE_STRTOUL)
-CHECK_STRUCT_HAS_MEMBER(fordblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_FORDBLKS)
-CHECK_STRUCT_HAS_MEMBER(fsmblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_FSMBLKS)
-CHECK_STRUCT_HAS_MEMBER(hblkhd mallinfo malloc.h HAVE_STRUCT_MALLINFO_HBLKHD)
-CHECK_STRUCT_HAS_MEMBER(uordblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_UORDBLKS)
-CHECK_STRUCT_HAS_MEMBER(usmblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_USMBLKS)
-CHECK_INCLUDE_FILES(sys/filio.h HAVE_SYS_FILIO_H)
-CHECK_INCLUDE_FILES(sys/stat.h HAVE_SYS_STAT_H)
-CHECK_INCLUDE_FILES(sys/time.h HAVE_SYS_TIME_H)
-CHECK_INCLUDE_FILES(sys/types.h HAVE_SYS_TYPES_H)
-CHECK_INCLUDE_FILES(unistd.h HAVE_UNISTD_H)
-CHECK_INCLUDE_FILES(zlib.h HAVE_ZLIB_H)
-
-#Enable pango defines, necessary for compilation on Win32, how about Linux?
-# yes but needs to be done a better way
-if(HAVE_CAIRO_PDF)
- set(PANGO_ENABLE_ENGINE TRUE)
- set(RENDER_WITH_PANGO_CAIRO TRUE)
-endif()
-
-# Create the two configuration files: config.h and inkscape_version.h
-# Create them in the binary root dir
-configure_file(${CMAKE_SOURCE_DIR}/config.h.cmake ${CMAKE_BINARY_DIR}/include/config.h)
-add_definitions(-DHAVE_CONFIG_H)
+#---------------
+# From here on:
+# Set all HAVE_XXX variables, to correctly set all defines in config.h
+#SET(CMAKE_REQUIRED_INCLUDES ${INK_INCLUDES})
+include(CheckIncludeFiles)
+include(CheckFunctionExists)
+include(CheckStructHasMember)
+# usage: CHECK_INCLUDE_FILES (<header> <RESULT_VARIABLE> )
+# usage: CHECK_FUNCTION_EXISTS (<function name> <RESULT_VARIABLE> )
+# usage: CHECK_STRUCT_HAS_MEMBER (<struct> <member> <header> <RESULT_VARIABLE>)
+
+CHECK_INCLUDE_FILES(boost/concept_check.hpp HAVE_BOOST_CONCEPT_CHECK_HPP)
+CHECK_INCLUDE_FILES(cairo-pdf.h HAVE_CAIRO_PDF)
+CHECK_FUNCTION_EXISTS(floor HAVE_FLOOR)
+CHECK_FUNCTION_EXISTS(fpsetmask HAVE_FPSETMASK)
+CHECK_INCLUDE_FILES(gc/gc.h HAVE_GC_GC_H)
+CHECK_INCLUDE_FILES(gc.h HAVE_GC_H)
+CHECK_INCLUDE_FILES(getopt.h HAVE_GETOPT_H)
+CHECK_FUNCTION_EXISTS(gettext HAVE_GETTEXT)
+CHECK_FUNCTION_EXISTS(gettimeofday HAVE_GETTIMEOFDAY)
+CHECK_FUNCTION_EXISTS(gtk_window_fullscreen HAVE_GTK_WINDOW_FULLSCREEN)
+CHECK_FUNCTION_EXISTS(gtk_window_set_default_icon_from_file HAVE_GTK_WINDOW_SET_DEFAULT_ICON_FROM_FILE)
+CHECK_INCLUDE_FILES(ieeefp.h HAVE_IEEEFP_H)
+CHECK_INCLUDE_FILES(inttypes.h HAVE_INTTYPES_H)
+CHECK_INCLUDE_FILES(locale.h HAVE_LC_MESSAGES)
+CHECK_INCLUDE_FILES(locale.h HAVE_LOCALE_H)
+CHECK_INCLUDE_FILES(libintl.h HAVE_LIBINTL_H)
+CHECK_INCLUDE_FILES(fcntl.h HAVE_FCNTL_H)
+CHECK_FUNCTION_EXISTS(mallinfo HAVE_MALLINFO)
+CHECK_INCLUDE_FILES(malloc.h HAVE_MALLOC_H)
+CHECK_FUNCTION_EXISTS(memmove HAVE_MEMMOVE)
+CHECK_INCLUDE_FILES(memory.h HAVE_MEMORY_H)
+CHECK_FUNCTION_EXISTS(memset HAVE_MEMSET)
+CHECK_FUNCTION_EXISTS(mkdir HAVE_MKDIR)
+CHECK_FUNCTION_EXISTS(pow HAVE_POW)
+CHECK_FUNCTION_EXISTS(sqrt HAVE_SQRT)
+CHECK_INCLUDE_FILES(stddef.h HAVE_STDDEF_H)
+CHECK_INCLUDE_FILES(stdint.h HAVE_STDINT_H)
+CHECK_INCLUDE_FILES(stdlib.h HAVE_STDLIB_H)
+CHECK_INCLUDE_FILES(strings.h HAVE_STRINGS_H)
+CHECK_INCLUDE_FILES(string.h HAVE_STRING_H)
+CHECK_FUNCTION_EXISTS(strncasecmp HAVE_STRNCASECMP)
+CHECK_FUNCTION_EXISTS(strpbrk HAVE_STRPBRK)
+CHECK_FUNCTION_EXISTS(strrchr HAVE_STRRCHR)
+CHECK_FUNCTION_EXISTS(strspn HAVE_STRSPN)
+CHECK_FUNCTION_EXISTS(strstr HAVE_STRSTR)
+CHECK_FUNCTION_EXISTS(strtoul HAVE_STRTOUL)
+CHECK_STRUCT_HAS_MEMBER(fordblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_FORDBLKS)
+CHECK_STRUCT_HAS_MEMBER(fsmblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_FSMBLKS)
+CHECK_STRUCT_HAS_MEMBER(hblkhd mallinfo malloc.h HAVE_STRUCT_MALLINFO_HBLKHD)
+CHECK_STRUCT_HAS_MEMBER(uordblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_UORDBLKS)
+CHECK_STRUCT_HAS_MEMBER(usmblks mallinfo malloc.h HAVE_STRUCT_MALLINFO_USMBLKS)
+CHECK_INCLUDE_FILES(sys/filio.h HAVE_SYS_FILIO_H)
+CHECK_INCLUDE_FILES(sys/stat.h HAVE_SYS_STAT_H)
+CHECK_INCLUDE_FILES(sys/time.h HAVE_SYS_TIME_H)
+CHECK_INCLUDE_FILES(sys/types.h HAVE_SYS_TYPES_H)
+CHECK_INCLUDE_FILES(unistd.h HAVE_UNISTD_H)
+CHECK_INCLUDE_FILES(zlib.h HAVE_ZLIB_H)
+
+#Enable pango defines, necessary for compilation on Win32, how about Linux?
+# yes but needs to be done a better way
+if(HAVE_CAIRO_PDF)
+ set(PANGO_ENABLE_ENGINE TRUE)
+ set(RENDER_WITH_PANGO_CAIRO TRUE)
+endif()
+
+# Create the two configuration files: config.h and inkscape_version.h
+# Create them in the binary root dir
+configure_file(${CMAKE_SOURCE_DIR}/config.h.cmake ${CMAKE_BINARY_DIR}/include/config.h)
+add_definitions(-DHAVE_CONFIG_H)
diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake
index de9a9b5d0..af0a7d50c 100644
--- a/CMakeScripts/ConfigPaths.cmake
+++ b/CMakeScripts/ConfigPaths.cmake
@@ -1,31 +1,31 @@
-MESSAGE(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}")
-
-IF(WIN32)
- SET(PACKAGE_LOCALE_DIR "locale")
-ELSEIF(WIN32)
- # TODO: check and change this to correct value:
- SET(PACKAGE_LOCALE_DIR "locale")
-ENDIF(WIN32)
-
-#SET(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib)
-#SET(CMAKE_SKIP_RPATH:BOOL OFF)
-
-# Include base dir, so other files can refer to the generated files.
-# CMAKE_INCLUDE_CURRENT_DIR is not enough as it only includes the current dir and not the basedir with config.h in it
-#INCLUDE_DIRECTORIES ("${CMAKE_BINARY_DIR}" "${PROJECT_SOURCE_DIR}" src/)
-#LINK_DIRECTORIES ("${LINK_DIRECTORIES}" "${CMAKE_BINARY_DIR}" "${PROJECT_SOURCE_DIR}" src/)
-
-#INSTALL(TARGETS INKSCAPE
-# RUNTIME DESTINATION bin
-# LIBRARY DESTINATION lib
-# ARCHIVE DESTINATION lib
-#)
-
-#FILE(GLOB files "${CMAKE_CURRENT_SOURCE_DIR}/*.h")
-#INSTALL(FILES ${files} DESTINATION include/INKSCAPE/INKSCAPE)
-
-#CONFIGURE_FILE( ${CMAKE_SOURCE_DIR}/INKSCAPE.pc.in
-# ${CMAKE_BINARY_DIR}/INKSCAPE.pc @ONLY IMMEDIATE )
-#INSTALL(FILES "${CMAKE_BINARY_DIR}/INKSCAPE.pc" DESTINATION lib/pkgconfig)
-
-#SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin CACHE INTERNAL "Where to put the executables")set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib CACHE INTERNAL "Where to put the libraries")
+MESSAGE(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}")
+
+IF(WIN32)
+ SET(PACKAGE_LOCALE_DIR "locale")
+ELSEIF(WIN32)
+ # TODO: check and change this to correct value:
+ SET(PACKAGE_LOCALE_DIR "locale")
+ENDIF(WIN32)
+
+#SET(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/lib)
+#SET(CMAKE_SKIP_RPATH:BOOL OFF)
+
+# Include base dir, so other files can refer to the generated files.
+# CMAKE_INCLUDE_CURRENT_DIR is not enough as it only includes the current dir and not the basedir with config.h in it
+#INCLUDE_DIRECTORIES ("${CMAKE_BINARY_DIR}" "${PROJECT_SOURCE_DIR}" src/)
+#LINK_DIRECTORIES ("${LINK_DIRECTORIES}" "${CMAKE_BINARY_DIR}" "${PROJECT_SOURCE_DIR}" src/)
+
+#INSTALL(TARGETS INKSCAPE
+# RUNTIME DESTINATION bin
+# LIBRARY DESTINATION lib
+# ARCHIVE DESTINATION lib
+#)
+
+#FILE(GLOB files "${CMAKE_CURRENT_SOURCE_DIR}/*.h")
+#INSTALL(FILES ${files} DESTINATION include/INKSCAPE/INKSCAPE)
+
+#CONFIGURE_FILE( ${CMAKE_SOURCE_DIR}/INKSCAPE.pc.in
+# ${CMAKE_BINARY_DIR}/INKSCAPE.pc @ONLY IMMEDIATE )
+#INSTALL(FILES "${CMAKE_BINARY_DIR}/INKSCAPE.pc" DESTINATION lib/pkgconfig)
+
+#SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin CACHE INTERNAL "Where to put the executables")set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib CACHE INTERNAL "Where to put the libraries")
diff --git a/CMakeScripts/HelperMacros.cmake b/CMakeScripts/HelperMacros.cmake
index cdb4d0386..7cd2333bc 100644
--- a/CMakeScripts/HelperMacros.cmake
+++ b/CMakeScripts/HelperMacros.cmake
@@ -1,65 +1,65 @@
-# A macro to replace slashes and spaces in a string with underscores
-macro(SANITIZE_PATH _string_var)
- string(REGEX REPLACE "[\\/ ]+" "_" ${_string_var} ${${_string_var}})
-endmacro()
-
-
-macro(inkscape_source_group
- sources)
-
- # Group by location on disk
- source_group("Source Files" FILES CMakeLists.txt)
-
- foreach(_SRC ${sources})
- get_filename_component(_SRC_EXT ${_SRC} EXT)
- if((${_SRC_EXT} MATCHES ".h") OR (${_SRC_EXT} MATCHES ".hpp"))
- source_group("Header Files" FILES ${_SRC})
- else()
- source_group("Source Files" FILES ${_SRC})
- endif()
- endforeach()
-
- unset(_SRC)
- unset(_SRC_EXT)
-endmacro()
-
-
-# only MSVC uses SOURCE_GROUP
-macro(add_inkscape_lib
- name
- sources)
-
- add_library(${name} ${sources})
-
- # works fine without having the includes
- # listed is helpful for IDE's (QtCreator/MSVC)
- inkscape_source_group("${sources}")
-
-endmacro()
-
-
-# A macro to append to the global source property
-set_property(GLOBAL PROPERTY inkscape_global_SRC "")
-
-macro (add_inkscape_source
- sources)
-
- foreach(_SRC ${ARGV})
- get_filename_component(_ABS_SRC ${_SRC} ABSOLUTE)
- set_property(GLOBAL APPEND PROPERTY inkscape_global_SRC ${_ABS_SRC})
- endforeach()
- unset(_SRC)
- unset(_ABS_SRC)
-endmacro()
-
-# A macro to append to the global source property
-macro (add_inkscape_library
- sources)
-
- foreach(_SRC ${ARGV})
- get_filename_component(_ABS_SRC ${_SRC} ABSOLUTE)
- set_property(GLOBAL APPEND PROPERTY inkscape_global_SRC ${_ABS_SRC})
- endforeach()
- unset(_SRC)
- unset(_ABS_SRC)
-endmacro()
+# A macro to replace slashes and spaces in a string with underscores
+macro(SANITIZE_PATH _string_var)
+ string(REGEX REPLACE "[\\/ ]+" "_" ${_string_var} ${${_string_var}})
+endmacro()
+
+
+macro(inkscape_source_group
+ sources)
+
+ # Group by location on disk
+ source_group("Source Files" FILES CMakeLists.txt)
+
+ foreach(_SRC ${sources})
+ get_filename_component(_SRC_EXT ${_SRC} EXT)
+ if((${_SRC_EXT} MATCHES ".h") OR (${_SRC_EXT} MATCHES ".hpp"))
+ source_group("Header Files" FILES ${_SRC})
+ else()
+ source_group("Source Files" FILES ${_SRC})
+ endif()
+ endforeach()
+
+ unset(_SRC)
+ unset(_SRC_EXT)
+endmacro()
+
+
+# only MSVC uses SOURCE_GROUP
+macro(add_inkscape_lib
+ name
+ sources)
+
+ add_library(${name} ${sources})
+
+ # works fine without having the includes
+ # listed is helpful for IDE's (QtCreator/MSVC)
+ inkscape_source_group("${sources}")
+
+endmacro()
+
+
+# A macro to append to the global source property
+set_property(GLOBAL PROPERTY inkscape_global_SRC "")
+
+macro (add_inkscape_source
+ sources)
+
+ foreach(_SRC ${ARGV})
+ get_filename_component(_ABS_SRC ${_SRC} ABSOLUTE)
+ set_property(GLOBAL APPEND PROPERTY inkscape_global_SRC ${_ABS_SRC})
+ endforeach()
+ unset(_SRC)
+ unset(_ABS_SRC)
+endmacro()
+
+# A macro to append to the global source property
+macro (add_inkscape_library
+ sources)
+
+ foreach(_SRC ${ARGV})
+ get_filename_component(_ABS_SRC ${_SRC} ABSOLUTE)
+ set_property(GLOBAL APPEND PROPERTY inkscape_global_SRC ${_ABS_SRC})
+ endforeach()
+ unset(_SRC)
+ unset(_ABS_SRC)
+endmacro()
diff --git a/CMakeScripts/IncludeJava.cmake b/CMakeScripts/IncludeJava.cmake
index bd8bdb58e..1e20a4ca5 100644
--- a/CMakeScripts/IncludeJava.cmake
+++ b/CMakeScripts/IncludeJava.cmake
@@ -1,14 +1,14 @@
-# - include the src/javainc dir in the include path and the correct config path too
-
-
-INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc )
-
-IF (WIN32)
- INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/win32 )
-ENDIF (WIN32)
-IF (UNIX)
- INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/linux )
-ENDIF (UNIX)
-IF (SOLARIS)
- INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/solaris )
-ENDIF (SOLARIS)
+# - include the src/javainc dir in the include path and the correct config path too
+
+
+INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc )
+
+IF (WIN32)
+ INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/win32 )
+ENDIF (WIN32)
+IF (UNIX)
+ INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/linux )
+ENDIF (UNIX)
+IF (SOLARIS)
+ INCLUDE_DIRECTORIES( ${CMAKE_SOURCE_DIR}/src/bind/javainc/solaris )
+ENDIF (SOLARIS)
diff --git a/Doxyfile b/Doxyfile
index 8d74cbb12..4225f0efe 100644
--- a/Doxyfile
+++ b/Doxyfile
@@ -1,1462 +1,1462 @@
-# Doxyfile 1.5.7
-
-# This file describes the settings to be used by the documentation system
-# doxygen (www.doxygen.org) for a project
-#
-# All text after a hash (#) is considered a comment and will be ignored
-# The format is:
-# TAG = value [value, ...]
-# For lists items can also be appended using:
-# TAG += value [value, ...]
-# Values that contain spaces should be placed between quotes (" ")
-
-#---------------------------------------------------------------------------
-# Project related configuration options
-#---------------------------------------------------------------------------
-
-# This tag specifies the encoding used for all characters in the config file
-# that follow. The default is UTF-8 which is also the encoding used for all
-# text before the first occurrence of this tag. Doxygen uses libiconv (or the
-# iconv built into libc) for the transcoding. See
-# http://www.gnu.org/software/libiconv for the list of possible encodings.
-
-DOXYFILE_ENCODING = UTF-8
-
-# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
-# by quotes) that should identify the project.
-
-PROJECT_NAME = inkscape
-
-# The PROJECT_NUMBER tag can be used to enter a project or revision number.
-# This could be handy for archiving the generated documentation or
-# if some version control system is used.
-
-PROJECT_NUMBER =
-
-# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
-# base path where the generated documentation will be put.
-# If a relative path is entered, it will be relative to the location
-# where doxygen was started. If left blank the current directory will be used.
-
-OUTPUT_DIRECTORY = doxygen
-
-# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create
-# 4096 sub-directories (in 2 levels) under the output directory of each output
-# format and will distribute the generated files over these directories.
-# Enabling this option can be useful when feeding doxygen a huge amount of
-# source files, where putting all generated files in the same directory would
-# otherwise cause performance problems for the file system.
-
-CREATE_SUBDIRS = NO
-
-# The OUTPUT_LANGUAGE tag is used to specify the language in which all
-# documentation generated by doxygen is written. Doxygen will use this
-# information to generate all constant output in the proper language.
-# The default language is English, other supported languages are:
-# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional,
-# Croatian, Czech, Danish, Dutch, Farsi, Finnish, French, German, Greek,
-# Hungarian, Italian, Japanese, Japanese-en (Japanese with English messages),
-# Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, Polish,
-# Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak, Slovene,
-# Spanish, Swedish, and Ukrainian.
-
-OUTPUT_LANGUAGE = English
-
-# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will
-# include brief member descriptions after the members that are listed in
-# the file and class documentation (similar to JavaDoc).
-# Set to NO to disable this.
-
-BRIEF_MEMBER_DESC = YES
-
-# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend
-# the brief description of a member or function before the detailed description.
-# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the
-# brief descriptions will be completely suppressed.
-
-REPEAT_BRIEF = YES
-
-# This tag implements a quasi-intelligent brief description abbreviator
-# that is used to form the text in various listings. Each string
-# in this list, if found as the leading text of the brief description, will be
-# stripped from the text and the result after processing the whole list, is
-# used as the annotated text. Otherwise, the brief description is used as-is.
-# If left blank, the following values are used ("$name" is automatically
-# replaced with the name of the entity): "The $name class" "The $name widget"
-# "The $name file" "is" "provides" "specifies" "contains"
-# "represents" "a" "an" "the"
-
-ABBREVIATE_BRIEF =
-
-# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then
-# Doxygen will generate a detailed section even if there is only a brief
-# description.
-
-ALWAYS_DETAILED_SEC = NO
-
-# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all
-# inherited members of a class in the documentation of that class as if those
-# members were ordinary class members. Constructors, destructors and assignment
-# operators of the base classes will not be shown.
-
-INLINE_INHERITED_MEMB = NO
-
-# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full
-# path before files name in the file list and in the header files. If set
-# to NO the shortest path that makes the file name unique will be used.
-
-FULL_PATH_NAMES = YES
-
-# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag
-# can be used to strip a user-defined part of the path. Stripping is
-# only done if one of the specified strings matches the left-hand part of
-# the path. The tag can be used to show relative paths in the file list.
-# If left blank the directory from which doxygen is run is used as the
-# path to strip.
-
-STRIP_FROM_PATH =
-
-# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of
-# the path mentioned in the documentation of a class, which tells
-# the reader which header file to include in order to use a class.
-# If left blank only the name of the header file containing the class
-# definition is used. Otherwise one should specify the include paths that
-# are normally passed to the compiler using the -I flag.
-
-STRIP_FROM_INC_PATH =
-
-# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter
-# (but less readable) file names. This can be useful is your file systems
-# doesn't support long names like on DOS, Mac, or CD-ROM.
-
-SHORT_NAMES = NO
-
-# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen
-# will interpret the first line (until the first dot) of a JavaDoc-style
-# comment as the brief description. If set to NO, the JavaDoc
-# comments will behave just like regular Qt-style comments
-# (thus requiring an explicit @brief command for a brief description.)
-
-JAVADOC_AUTOBRIEF = YES
-
-# If the QT_AUTOBRIEF tag is set to YES then Doxygen will
-# interpret the first line (until the first dot) of a Qt-style
-# comment as the brief description. If set to NO, the comments
-# will behave just like regular Qt-style comments (thus requiring
-# an explicit \brief command for a brief description.)
-
-QT_AUTOBRIEF = NO
-
-# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen
-# treat a multi-line C++ special comment block (i.e. a block of //! or ///
-# comments) as a brief description. This used to be the default behaviour.
-# The new default is to treat a multi-line C++ comment block as a detailed
-# description. Set this tag to YES if you prefer the old behaviour instead.
-
-MULTILINE_CPP_IS_BRIEF = NO
-
-# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented
-# member inherits the documentation from any documented member that it
-# re-implements.
-
-INHERIT_DOCS = YES
-
-# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce
-# a new page for each member. If set to NO, the documentation of a member will
-# be part of the file/class/namespace that contains it.
-
-SEPARATE_MEMBER_PAGES = NO
-
-# The TAB_SIZE tag can be used to set the number of spaces in a tab.
-# Doxygen uses this value to replace tabs by spaces in code fragments.
-
-TAB_SIZE = 4
-
-# This tag can be used to specify a number of aliases that acts
-# as commands in the documentation. An alias has the form "name=value".
-# For example adding "sideeffect=\par Side Effects:\n" will allow you to
-# put the command \sideeffect (or @sideeffect) in the documentation, which
-# will result in a user-defined paragraph with heading "Side Effects:".
-# You can put \n's in the value part of an alias to insert newlines.
-
-ALIASES =
-
-# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C
-# sources only. Doxygen will then generate output that is more tailored for C.
-# For instance, some of the names that are used will be different. The list
-# of all members will be omitted, etc.
-
-OPTIMIZE_OUTPUT_FOR_C = YES
-
-# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java
-# sources only. Doxygen will then generate output that is more tailored for
-# Java. For instance, namespaces will be presented as packages, qualified
-# scopes will look different, etc.
-
-OPTIMIZE_OUTPUT_JAVA = NO
-
-# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran
-# sources only. Doxygen will then generate output that is more tailored for
-# Fortran.
-
-OPTIMIZE_FOR_FORTRAN = NO
-
-# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL
-# sources. Doxygen will then generate output that is tailored for
-# VHDL.
-
-OPTIMIZE_OUTPUT_VHDL = NO
-
-# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want
-# to include (a tag file for) the STL sources as input, then you should
-# set this tag to YES in order to let doxygen match functions declarations and
-# definitions whose arguments contain STL classes (e.g. func(std::string); v.s.
-# func(std::string) {}). This also make the inheritance and collaboration
-# diagrams that involve STL classes more complete and accurate.
-
-BUILTIN_STL_SUPPORT = YES
-
-# If you use Microsoft's C++/CLI language, you should set this option to YES to
-# enable parsing support.
-
-CPP_CLI_SUPPORT = NO
-
-# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only.
-# Doxygen will parse them like normal C++ but will assume all classes use public
-# instead of private inheritance when no explicit protection keyword is present.
-
-SIP_SUPPORT = NO
-
-# For Microsoft's IDL there are propget and propput attributes to indicate getter
-# and setter methods for a property. Setting this option to YES (the default)
-# will make doxygen to replace the get and set methods by a property in the
-# documentation. This will only work if the methods are indeed getting or
-# setting a simple type. If this is not the case, or you want to show the
-# methods anyway, you should set this option to NO.
-
-IDL_PROPERTY_SUPPORT = YES
-
-# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC
-# tag is set to YES, then doxygen will reuse the documentation of the first
-# member in the group (if any) for the other members of the group. By default
-# all members of a group must be documented explicitly.
-
-DISTRIBUTE_GROUP_DOC = NO
-
-# Set the SUBGROUPING tag to YES (the default) to allow class member groups of
-# the same type (for instance a group of public functions) to be put as a
-# subgroup of that type (e.g. under the Public Functions section). Set it to
-# NO to prevent subgrouping. Alternatively, this can be done per class using
-# the \nosubgrouping command.
-
-SUBGROUPING = YES
-
-# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum
-# is documented as struct, union, or enum with the name of the typedef. So
-# typedef struct TypeS {} TypeT, will appear in the documentation as a struct
-# with name TypeT. When disabled the typedef will appear as a member of a file,
-# namespace, or class. And the struct will be named TypeS. This can typically
-# be useful for C code in case the coding convention dictates that all compound
-# types are typedef'ed and only the typedef is referenced, never the tag name.
-
-TYPEDEF_HIDES_STRUCT = NO
-
-# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to
-# determine which symbols to keep in memory and which to flush to disk.
-# When the cache is full, less often used symbols will be written to disk.
-# For small to medium size projects (<1000 input files) the default value is
-# probably good enough. For larger projects a too small cache size can cause
-# doxygen to be busy swapping symbols to and from disk most of the time
-# causing a significant performance penality.
-# If the system has enough physical memory increasing the cache will improve the
-# performance by keeping more symbols in memory. Note that the value works on
-# a logarithmic scale so increasing the size by one will rougly double the
-# memory usage. The cache size is given by this formula:
-# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0,
-# corresponding to a cache size of 2^16 = 65536 symbols
-
-SYMBOL_CACHE_SIZE = 0
-
-#---------------------------------------------------------------------------
-# Build related configuration options
-#---------------------------------------------------------------------------
-
-# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in
-# documentation are documented, even if no documentation was available.
-# Private class members and static file members will be hidden unless
-# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
-
-EXTRACT_ALL = YES
-
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class
-# will be included in the documentation.
-
-EXTRACT_PRIVATE = YES
-
-# If the EXTRACT_STATIC tag is set to YES all static members of a file
-# will be included in the documentation.
-
-EXTRACT_STATIC = YES
-
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs)
-# defined locally in source files will be included in the documentation.
-# If set to NO only classes defined in header files are included.
-
-EXTRACT_LOCAL_CLASSES = NO
-
-# This flag is only useful for Objective-C code. When set to YES local
-# methods, which are defined in the implementation section but not in
-# the interface are included in the documentation.
-# If set to NO (the default) only methods in the interface are included.
-
-EXTRACT_LOCAL_METHODS = NO
-
-# If this flag is set to YES, the members of anonymous namespaces will be
-# extracted and appear in the documentation as a namespace called
-# 'anonymous_namespace{file}', where file will be replaced with the base
-# name of the file that contains the anonymous namespace. By default
-# anonymous namespace are hidden.
-
-EXTRACT_ANON_NSPACES = NO
-
-# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all
-# undocumented members of documented classes, files or namespaces.
-# If set to NO (the default) these members will be included in the
-# various overviews, but no documentation section is generated.
-# This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_MEMBERS = NO
-
-# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all
-# undocumented classes that are normally visible in the class hierarchy.
-# If set to NO (the default) these classes will be included in the various
-# overviews. This option has no effect if EXTRACT_ALL is enabled.
-
-HIDE_UNDOC_CLASSES = NO
-
-# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all
-# friend (class|struct|union) declarations.
-# If set to NO (the default) these declarations will be included in the
-# documentation.
-
-HIDE_FRIEND_COMPOUNDS = NO
-
-# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any
-# documentation blocks found inside the body of a function.
-# If set to NO (the default) these blocks will be appended to the
-# function's detailed documentation block.
-
-HIDE_IN_BODY_DOCS = NO
-
-# The INTERNAL_DOCS tag determines if documentation
-# that is typed after a \internal command is included. If the tag is set
-# to NO (the default) then the documentation will be excluded.
-# Set it to YES to include the internal documentation.
-
-INTERNAL_DOCS = NO
-
-# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate
-# file names in lower-case letters. If set to YES upper-case letters are also
-# allowed. This is useful if you have classes or files whose names only differ
-# in case and if your file system supports case sensitive file names. Windows
-# and Mac users are advised to set this option to NO.
-
-CASE_SENSE_NAMES = YES
-
-# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen
-# will show members with their full class and namespace scopes in the
-# documentation. If set to YES the scope will be hidden.
-
-HIDE_SCOPE_NAMES = YES
-
-# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen
-# will put a list of the files that are included by a file in the documentation
-# of that file.
-
-SHOW_INCLUDE_FILES = YES
-
-# If the INLINE_INFO tag is set to YES (the default) then a tag [inline]
-# is inserted in the documentation for inline members.
-
-INLINE_INFO = YES
-
-# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen
-# will sort the (detailed) documentation of file and class members
-# alphabetically by member name. If set to NO the members will appear in
-# declaration order.
-
-SORT_MEMBER_DOCS = YES
-
-# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the
-# brief documentation of file, namespace and class members alphabetically
-# by member name. If set to NO (the default) the members will appear in
-# declaration order.
-
-SORT_BRIEF_DOCS = NO
-
-# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the
-# hierarchy of group names into alphabetical order. If set to NO (the default)
-# the group names will appear in their defined order.
-
-SORT_GROUP_NAMES = NO
-
-# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be
-# sorted by fully-qualified names, including namespaces. If set to
-# NO (the default), the class list will be sorted only by class name,
-# not including the namespace part.
-# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
-# Note: This option applies only to the class list, not to the
-# alphabetical list.
-
-SORT_BY_SCOPE_NAME = NO
-
-# The GENERATE_TODOLIST tag can be used to enable (YES) or
-# disable (NO) the todo list. This list is created by putting \todo
-# commands in the documentation.
-
-GENERATE_TODOLIST = YES
-
-# The GENERATE_TESTLIST tag can be used to enable (YES) or
-# disable (NO) the test list. This list is created by putting \test
-# commands in the documentation.
-
-GENERATE_TESTLIST = YES
-
-# The GENERATE_BUGLIST tag can be used to enable (YES) or
-# disable (NO) the bug list. This list is created by putting \bug
-# commands in the documentation.
-
-GENERATE_BUGLIST = YES
-
-# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or
-# disable (NO) the deprecated list. This list is created by putting
-# \deprecated commands in the documentation.
-
-GENERATE_DEPRECATEDLIST= YES
-
-# The ENABLED_SECTIONS tag can be used to enable conditional
-# documentation sections, marked by \if sectionname ... \endif.
-
-ENABLED_SECTIONS =
-
-# The MAX_INITIALIZER_LINES tag determines the maximum number of lines
-# the initial value of a variable or define consists of for it to appear in
-# the documentation. If the initializer consists of more lines than specified
-# here it will be hidden. Use a value of 0 to hide initializers completely.
-# The appearance of the initializer of individual variables and defines in the
-# documentation can be controlled using \showinitializer or \hideinitializer
-# command in the documentation regardless of this setting.
-
-MAX_INITIALIZER_LINES = 30
-
-# Set the SHOW_USED_FILES tag to NO to disable the list of files generated
-# at the bottom of the documentation of classes and structs. If set to YES the
-# list will mention the files that were used to generate the documentation.
-
-SHOW_USED_FILES = YES
-
-# If the sources in your project are distributed over multiple directories
-# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy
-# in the documentation. The default is NO.
-
-SHOW_DIRECTORIES = NO
-
-# Set the SHOW_FILES tag to NO to disable the generation of the Files page.
-# This will remove the Files entry from the Quick Index and from the
-# Folder Tree View (if specified). The default is YES.
-
-SHOW_FILES = YES
-
-# Set the SHOW_NAMESPACES tag to NO to disable the generation of the
-# Namespaces page. This will remove the Namespaces entry from the Quick Index
-# and from the Folder Tree View (if specified). The default is YES.
-
-SHOW_NAMESPACES = YES
-
-# The FILE_VERSION_FILTER tag can be used to specify a program or script that
-# doxygen should invoke to get the current version for each file (typically from
-# the version control system). Doxygen will invoke the program by executing (via
-# popen()) the command <command> <input-file>, where <command> is the value of
-# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file
-# provided by doxygen. Whatever the program writes to standard output
-# is used as the file version. See the manual for examples.
-
-FILE_VERSION_FILTER =
-
-# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed by
-# doxygen. The layout file controls the global structure of the generated output files
-# in an output format independent way. The create the layout file that represents
-# doxygen's defaults, run doxygen with the -l option. You can optionally specify a
-# file name after the option, if omitted DoxygenLayout.xml will be used as the name
-# of the layout file.
-
-LAYOUT_FILE =
-
-#---------------------------------------------------------------------------
-# configuration options related to warning and progress messages
-#---------------------------------------------------------------------------
-
-# The QUIET tag can be used to turn on/off the messages that are generated
-# by doxygen. Possible values are YES and NO. If left blank NO is used.
-
-QUIET = NO
-
-# The WARNINGS tag can be used to turn on/off the warning messages that are
-# generated by doxygen. Possible values are YES and NO. If left blank
-# NO is used.
-
-WARNINGS = YES
-
-# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings
-# for undocumented members. If EXTRACT_ALL is set to YES then this flag will
-# automatically be disabled.
-
-WARN_IF_UNDOCUMENTED = NO
-
-# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for
-# potential errors in the documentation, such as not documenting some
-# parameters in a documented function, or documenting parameters that
-# don't exist or using markup commands wrongly.
-
-WARN_IF_DOC_ERROR = YES
-
-# This WARN_NO_PARAMDOC option can be abled to get warnings for
-# functions that are documented, but have no documentation for their parameters
-# or return value. If set to NO (the default) doxygen will only warn about
-# wrong or incomplete parameter documentation, but not about the absence of
-# documentation.
-
-WARN_NO_PARAMDOC = NO
-
-# The WARN_FORMAT tag determines the format of the warning messages that
-# doxygen can produce. The string should contain the $file, $line, and $text
-# tags, which will be replaced by the file and line number from which the
-# warning originated and the warning text. Optionally the format may contain
-# $version, which will be replaced by the version of the file (if it could
-# be obtained via FILE_VERSION_FILTER)
-
-WARN_FORMAT = "$file:$line: $text"
-
-# The WARN_LOGFILE tag can be used to specify a file to which warning
-# and error messages should be written. If left blank the output is written
-# to stderr.
-
-WARN_LOGFILE = doxygen_warnings.log
-
-#---------------------------------------------------------------------------
-# configuration options related to the input files
-#---------------------------------------------------------------------------
-
-# The INPUT tag can be used to specify the files and/or directories that contain
-# documented source files. You may enter file names like "myfile.cpp" or
-# directories like "/usr/src/myproject". Separate the files or directories
-# with spaces.
-
-INPUT = src
-
-# This tag can be used to specify the character encoding of the source files
-# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
-# also the default input encoding. Doxygen uses libiconv (or the iconv built
-# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for
-# the list of possible encodings.
-
-INPUT_ENCODING = UTF-8
-
-# If the value of the INPUT tag contains directories, you can use the
-# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
-# and *.h) to filter out the source-files in the directories. If left
-# blank the following patterns are tested:
-# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx
-# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90
-
-FILE_PATTERNS = *.cpp *.h
-
-# The RECURSIVE tag can be used to turn specify whether or not subdirectories
-# should be searched for input files as well. Possible values are YES and NO.
-# If left blank NO is used.
-
-RECURSIVE = YES
-
-# The EXCLUDE tag can be used to specify files and/or directories that should
-# excluded from the INPUT source files. This way you can easily exclude a
-# subdirectory from a directory tree whose root is specified with the INPUT tag.
-
-EXCLUDE =
-
-# The EXCLUDE_SYMLINKS tag can be used select whether or not files or
-# directories that are symbolic links (a Unix filesystem feature) are excluded
-# from the input.
-
-EXCLUDE_SYMLINKS = YES
-
-# If the value of the INPUT tag contains directories, you can use the
-# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude
-# certain files from those directories. Note that the wildcards are matched
-# against the file with absolute path, so to exclude all test directories
-# for example use the pattern */test/*
-
-EXCLUDE_PATTERNS =
-
-# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
-# (namespaces, classes, functions, etc.) that should be excluded from the
-# output. The symbol name can be a fully qualified name, a word, or if the
-# wildcard * is used, a substring. Examples: ANamespace, AClass,
-# AClass::ANamespace, ANamespace::*Test
-
-EXCLUDE_SYMBOLS =
-
-# The EXAMPLE_PATH tag can be used to specify one or more files or
-# directories that contain example code fragments that are included (see
-# the \include command).
-
-EXAMPLE_PATH =
-
-# If the value of the EXAMPLE_PATH tag contains directories, you can use the
-# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
-# and *.h) to filter out the source-files in the directories. If left
-# blank all files are included.
-
-EXAMPLE_PATTERNS =
-
-# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be
-# searched for input files to be used with the \include or \dontinclude
-# commands irrespective of the value of the RECURSIVE tag.
-# Possible values are YES and NO. If left blank NO is used.
-
-EXAMPLE_RECURSIVE = NO
-
-# The IMAGE_PATH tag can be used to specify one or more files or
-# directories that contain image that are included in the documentation (see
-# the \image command).
-
-IMAGE_PATH =
-
-# The INPUT_FILTER tag can be used to specify a program that doxygen should
-# invoke to filter for each input file. Doxygen will invoke the filter program
-# by executing (via popen()) the command <filter> <input-file>, where <filter>
-# is the value of the INPUT_FILTER tag, and <input-file> is the name of an
-# input file. Doxygen will then use the output that the filter program writes
-# to standard output. If FILTER_PATTERNS is specified, this tag will be
-# ignored.
-
-INPUT_FILTER =
-
-# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern
-# basis. Doxygen will compare the file name with each pattern and apply the
-# filter if there is a match. The filters are a list of the form:
-# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further
-# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER
-# is applied to all files.
-
-FILTER_PATTERNS =
-
-# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using
-# INPUT_FILTER) will be used to filter the input files when producing source
-# files to browse (i.e. when SOURCE_BROWSER is set to YES).
-
-FILTER_SOURCE_FILES = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to source browsing
-#---------------------------------------------------------------------------
-
-# If the SOURCE_BROWSER tag is set to YES then a list of source files will
-# be generated. Documented entities will be cross-referenced with these sources.
-# Note: To get rid of all source code in the generated output, make sure also
-# VERBATIM_HEADERS is set to NO.
-
-SOURCE_BROWSER = NO
-
-# Setting the INLINE_SOURCES tag to YES will include the body
-# of functions and classes directly in the documentation.
-
-INLINE_SOURCES = NO
-
-# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct
-# doxygen to hide any special comment blocks from generated source code
-# fragments. Normal C and C++ comments will always remain visible.
-
-STRIP_CODE_COMMENTS = YES
-
-# If the REFERENCED_BY_RELATION tag is set to YES
-# then for each documented function all documented
-# functions referencing it will be listed.
-
-REFERENCED_BY_RELATION = YES
-
-# If the REFERENCES_RELATION tag is set to YES
-# then for each documented function all documented entities
-# called/used by that function will be listed.
-
-REFERENCES_RELATION = YES
-
-# If the REFERENCES_LINK_SOURCE tag is set to YES (the default)
-# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from
-# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will
-# link to the source code. Otherwise they will link to the documentstion.
-
-REFERENCES_LINK_SOURCE = YES
-
-# If the USE_HTAGS tag is set to YES then the references to source code
-# will point to the HTML generated by the htags(1) tool instead of doxygen
-# built-in source browser. The htags tool is part of GNU's global source
-# tagging system (see http://www.gnu.org/software/global/global.html). You
-# will need version 4.8.6 or higher.
-
-USE_HTAGS = NO
-
-# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen
-# will generate a verbatim copy of the header file for each class for
-# which an include is specified. Set to NO to disable this.
-
-VERBATIM_HEADERS = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the alphabetical class index
-#---------------------------------------------------------------------------
-
-# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then
-# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns
-# in which this list will be split (can be a number in the range [1..20])
-
-COLS_IN_ALPHA_INDEX = 5
-
-# In case all classes in a project start with a common prefix, all
-# classes will be put under the same header in the alphabetical index.
-# The IGNORE_PREFIX tag can be used to specify one or more prefixes that
-# should be ignored while generating the index headers.
-
-IGNORE_PREFIX =
-
-#---------------------------------------------------------------------------
-# configuration options related to the HTML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_HTML tag is set to YES (the default) Doxygen will
-# generate HTML output.
-
-GENERATE_HTML = YES
-
-# The HTML_OUTPUT tag is used to specify where the HTML docs will be put.
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be
-# put in front of it. If left blank `html' will be used as the default path.
-
-HTML_OUTPUT = html
-
-# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
-# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
-# doxygen will generate files with .html extension.
-
-HTML_FILE_EXTENSION = .html
-
-# The HTML_HEADER tag can be used to specify a personal HTML header for
-# each generated HTML page. If it is left blank doxygen will generate a
-# standard header.
-
-HTML_HEADER =
-
-# The HTML_FOOTER tag can be used to specify a personal HTML footer for
-# each generated HTML page. If it is left blank doxygen will generate a
-# standard footer.
-
-HTML_FOOTER =
-
-# The HTML_STYLESHEET tag can be used to specify a user-defined cascading
-# style sheet that is used by each HTML page. It can be used to
-# fine-tune the look of the HTML output. If the tag is left blank doxygen
-# will generate a default style sheet. Note that doxygen will try to copy
-# the style sheet file to the HTML output directory, so don't put your own
-# stylesheet in the HTML output directory as well, or it will be erased!
-
-HTML_STYLESHEET =
-
-# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes,
-# files or namespaces will be aligned in HTML using tables. If set to
-# NO a bullet list will be used.
-
-HTML_ALIGN_MEMBERS = YES
-
-# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML
-# documentation will contain sections that can be hidden and shown after the
-# page has loaded. For this to work a browser that supports
-# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox
-# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari).
-
-HTML_DYNAMIC_SECTIONS = NO
-
-# If the GENERATE_DOCSET tag is set to YES, additional index files
-# will be generated that can be used as input for Apple's Xcode 3
-# integrated development environment, introduced with OSX 10.5 (Leopard).
-# To create a documentation set, doxygen will generate a Makefile in the
-# HTML output directory. Running make will produce the docset in that
-# directory and running "make install" will install the docset in
-# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find
-# it at startup.
-# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for more information.
-
-GENERATE_DOCSET = NO
-
-# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the
-# feed. A documentation feed provides an umbrella under which multiple
-# documentation sets from a single provider (such as a company or product suite)
-# can be grouped.
-
-DOCSET_FEEDNAME = "Doxygen generated docs"
-
-# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that
-# should uniquely identify the documentation set bundle. This should be a
-# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen
-# will append .docset to the name.
-
-DOCSET_BUNDLE_ID = org.doxygen.Project
-
-# If the GENERATE_HTMLHELP tag is set to YES, additional index files
-# will be generated that can be used as input for tools like the
-# Microsoft HTML help workshop to generate a compiled HTML help file (.chm)
-# of the generated HTML documentation.
-
-GENERATE_HTMLHELP = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can
-# be used to specify the file name of the resulting .chm file. You
-# can add a path in front of the file if the result should not be
-# written to the html output directory.
-
-CHM_FILE =
-
-# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can
-# be used to specify the location (absolute path including file name) of
-# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run
-# the HTML help compiler on the generated index.hhp.
-
-HHC_LOCATION =
-
-# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag
-# controls if a separate .chi index file is generated (YES) or that
-# it should be included in the master .chm file (NO).
-
-GENERATE_CHI = NO
-
-# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING
-# is used to encode HtmlHelp index (hhk), content (hhc) and project file
-# content.
-
-CHM_INDEX_ENCODING =
-
-# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag
-# controls whether a binary table of contents is generated (YES) or a
-# normal table of contents (NO) in the .chm file.
-
-BINARY_TOC = NO
-
-# The TOC_EXPAND flag can be set to YES to add extra items for group members
-# to the contents of the HTML help documentation and to the tree view.
-
-TOC_EXPAND = NO
-
-# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and QHP_VIRTUAL_FOLDER
-# are set, an additional index file will be generated that can be used as input for
-# Qt's qhelpgenerator to generate a Qt Compressed Help (.qch) of the generated
-# HTML documentation.
-
-GENERATE_QHP = NO
-
-# If the QHG_LOCATION tag is specified, the QCH_FILE tag can
-# be used to specify the file name of the resulting .qch file.
-# The path specified is relative to the HTML output folder.
-
-QCH_FILE =
-
-# The QHP_NAMESPACE tag specifies the namespace to use when generating
-# Qt Help Project output. For more information please see
-# <a href="http://doc.trolltech.com/qthelpproject.html#namespace">Qt Help Project / Namespace</a>.
-
-QHP_NAMESPACE = org.doxygen.Project
-
-# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating
-# Qt Help Project output. For more information please see
-# <a href="http://doc.trolltech.com/qthelpproject.html#virtual-folders">Qt Help Project / Virtual Folders</a>.
-
-QHP_VIRTUAL_FOLDER = doc
-
-# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can
-# be used to specify the location of Qt's qhelpgenerator.
-# If non-empty doxygen will try to run qhelpgenerator on the generated
-# .qhp file .
-
-QHG_LOCATION =
-
-# The DISABLE_INDEX tag can be used to turn on/off the condensed index at
-# top of each HTML page. The value NO (the default) enables the index and
-# the value YES disables it.
-
-DISABLE_INDEX = NO
-
-# This tag can be used to set the number of enum values (range [1..20])
-# that doxygen will group on one line in the generated HTML documentation.
-
-ENUM_VALUES_PER_LINE = 4
-
-# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index
-# structure should be generated to display hierarchical information.
-# If the tag value is set to FRAME, a side panel will be generated
-# containing a tree-like index structure (just like the one that
-# is generated for HTML Help). For this to work a browser that supports
-# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+,
-# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are
-# probably better off using the HTML help feature. Other possible values
-# for this tag are: HIERARCHIES, which will generate the Groups, Directories,
-# and Class Hierarchy pages using a tree view instead of an ordered list;
-# ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which
-# disables this behavior completely. For backwards compatibility with previous
-# releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE
-# respectively.
-
-GENERATE_TREEVIEW = NO
-
-# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be
-# used to set the initial width (in pixels) of the frame in which the tree
-# is shown.
-
-TREEVIEW_WIDTH = 250
-
-# Use this tag to change the font size of Latex formulas included
-# as images in the HTML documentation. The default is 10. Note that
-# when you change the font size after a successful doxygen run you need
-# to manually remove any form_*.png images from the HTML output directory
-# to force them to be regenerated.
-
-FORMULA_FONTSIZE = 10
-
-#---------------------------------------------------------------------------
-# configuration options related to the LaTeX output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
-# generate Latex output.
-
-GENERATE_LATEX = NO
-
-# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be
-# put in front of it. If left blank `latex' will be used as the default path.
-
-LATEX_OUTPUT = latex
-
-# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be
-# invoked. If left blank `latex' will be used as the default command name.
-
-LATEX_CMD_NAME = latex
-
-# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to
-# generate index for LaTeX. If left blank `makeindex' will be used as the
-# default command name.
-
-MAKEINDEX_CMD_NAME = makeindex
-
-# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact
-# LaTeX documents. This may be useful for small projects and may help to
-# save some trees in general.
-
-COMPACT_LATEX = NO
-
-# The PAPER_TYPE tag can be used to set the paper type that is used
-# by the printer. Possible values are: a4, a4wide, letter, legal and
-# executive. If left blank a4wide will be used.
-
-PAPER_TYPE = a4wide
-
-# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX
-# packages that should be included in the LaTeX output.
-
-EXTRA_PACKAGES =
-
-# The LATEX_HEADER tag can be used to specify a personal LaTeX header for
-# the generated latex document. The header should contain everything until
-# the first chapter. If it is left blank doxygen will generate a
-# standard header. Notice: only use this tag if you know what you are doing!
-
-LATEX_HEADER =
-
-# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated
-# is prepared for conversion to pdf (using ps2pdf). The pdf file will
-# contain links (just like the HTML output) instead of page references
-# This makes the output suitable for online browsing using a pdf viewer.
-
-PDF_HYPERLINKS = NO
-
-# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of
-# plain latex in the generated Makefile. Set this option to YES to get a
-# higher quality PDF documentation.
-
-USE_PDFLATEX = NO
-
-# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode.
-# command to the generated LaTeX files. This will instruct LaTeX to keep
-# running if errors occur, instead of asking the user for help.
-# This option is also used when generating formulas in HTML.
-
-LATEX_BATCHMODE = NO
-
-# If LATEX_HIDE_INDICES is set to YES then doxygen will not
-# include the index chapters (such as File Index, Compound Index, etc.)
-# in the output.
-
-LATEX_HIDE_INDICES = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the RTF output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output
-# The RTF output is optimized for Word 97 and may not look very pretty with
-# other RTF readers or editors.
-
-GENERATE_RTF = NO
-
-# The RTF_OUTPUT tag is used to specify where the RTF docs will be put.
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be
-# put in front of it. If left blank `rtf' will be used as the default path.
-
-RTF_OUTPUT = rtf
-
-# If the COMPACT_RTF tag is set to YES Doxygen generates more compact
-# RTF documents. This may be useful for small projects and may help to
-# save some trees in general.
-
-COMPACT_RTF = NO
-
-# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated
-# will contain hyperlink fields. The RTF file will
-# contain links (just like the HTML output) instead of page references.
-# This makes the output suitable for online browsing using WORD or other
-# programs which support those fields.
-# Note: wordpad (write) and others do not support links.
-
-RTF_HYPERLINKS = NO
-
-# Load stylesheet definitions from file. Syntax is similar to doxygen's
-# config file, i.e. a series of assignments. You only have to provide
-# replacements, missing definitions are set to their default value.
-
-RTF_STYLESHEET_FILE =
-
-# Set optional variables used in the generation of an rtf document.
-# Syntax is similar to doxygen's config file.
-
-RTF_EXTENSIONS_FILE =
-
-#---------------------------------------------------------------------------
-# configuration options related to the man page output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_MAN tag is set to YES (the default) Doxygen will
-# generate man pages
-
-GENERATE_MAN = NO
-
-# The MAN_OUTPUT tag is used to specify where the man pages will be put.
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be
-# put in front of it. If left blank `man' will be used as the default path.
-
-MAN_OUTPUT = man
-
-# The MAN_EXTENSION tag determines the extension that is added to
-# the generated man pages (default is the subroutine's section .3)
-
-MAN_EXTENSION = .3
-
-# If the MAN_LINKS tag is set to YES and Doxygen generates man output,
-# then it will generate one additional man file for each entity
-# documented in the real man page(s). These additional files
-# only source the real man page, but without them the man command
-# would be unable to find the correct page. The default is NO.
-
-MAN_LINKS = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the XML output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_XML tag is set to YES Doxygen will
-# generate an XML file that captures the structure of
-# the code including all documentation.
-
-GENERATE_XML = NO
-
-# The XML_OUTPUT tag is used to specify where the XML pages will be put.
-# If a relative path is entered the value of OUTPUT_DIRECTORY will be
-# put in front of it. If left blank `xml' will be used as the default path.
-
-XML_OUTPUT = xml
-
-# The XML_SCHEMA tag can be used to specify an XML schema,
-# which can be used by a validating XML parser to check the
-# syntax of the XML files.
-
-XML_SCHEMA =
-
-# The XML_DTD tag can be used to specify an XML DTD,
-# which can be used by a validating XML parser to check the
-# syntax of the XML files.
-
-XML_DTD =
-
-# If the XML_PROGRAMLISTING tag is set to YES Doxygen will
-# dump the program listings (including syntax highlighting
-# and cross-referencing information) to the XML output. Note that
-# enabling this will significantly increase the size of the XML output.
-
-XML_PROGRAMLISTING = YES
-
-#---------------------------------------------------------------------------
-# configuration options for the AutoGen Definitions output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will
-# generate an AutoGen Definitions (see autogen.sf.net) file
-# that captures the structure of the code including all
-# documentation. Note that this feature is still experimental
-# and incomplete at the moment.
-
-GENERATE_AUTOGEN_DEF = NO
-
-#---------------------------------------------------------------------------
-# configuration options related to the Perl module output
-#---------------------------------------------------------------------------
-
-# If the GENERATE_PERLMOD tag is set to YES Doxygen will
-# generate a Perl module file that captures the structure of
-# the code including all documentation. Note that this
-# feature is still experimental and incomplete at the
-# moment.
-
-GENERATE_PERLMOD = NO
-
-# If the PERLMOD_LATEX tag is set to YES Doxygen will generate
-# the necessary Makefile rules, Perl scripts and LaTeX code to be able
-# to generate PDF and DVI output from the Perl module output.
-
-PERLMOD_LATEX = NO
-
-# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be
-# nicely formatted so it can be parsed by a human reader. This is useful
-# if you want to understand what is going on. On the other hand, if this
-# tag is set to NO the size of the Perl module output will be much smaller
-# and Perl will parse it just the same.
-
-PERLMOD_PRETTY = YES
-
-# The names of the make variables in the generated doxyrules.make file
-# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX.
-# This is useful so different doxyrules.make files included by the same
-# Makefile don't overwrite each other's variables.
-
-PERLMOD_MAKEVAR_PREFIX =
-
-#---------------------------------------------------------------------------
-# Configuration options related to the preprocessor
-#---------------------------------------------------------------------------
-
-# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will
-# evaluate all C-preprocessor directives found in the sources and include
-# files.
-
-ENABLE_PREPROCESSING = YES
-
-# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro
-# names in the source code. If set to NO (the default) only conditional
-# compilation will be performed. Macro expansion can be done in a controlled
-# way by setting EXPAND_ONLY_PREDEF to YES.
-
-MACRO_EXPANSION = NO
-
-# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES
-# then the macro expansion is limited to the macros specified with the
-# PREDEFINED and EXPAND_AS_DEFINED tags.
-
-EXPAND_ONLY_PREDEF = NO
-
-# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files
-# in the INCLUDE_PATH (see below) will be search if a #include is found.
-
-SEARCH_INCLUDES = YES
-
-# The INCLUDE_PATH tag can be used to specify one or more directories that
-# contain include files that are not input files but should be processed by
-# the preprocessor.
-
-INCLUDE_PATH = src
-
-# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard
-# patterns (like *.h and *.hpp) to filter out the header-files in the
-# directories. If left blank, the patterns specified with FILE_PATTERNS will
-# be used.
-
-INCLUDE_FILE_PATTERNS =
-
-# The PREDEFINED tag can be used to specify one or more macro names that
-# are defined before the preprocessor is started (similar to the -D option of
-# gcc). The argument of the tag is a list of macros of the form: name
-# or name=definition (no spaces). If the definition and the = are
-# omitted =1 is assumed. To prevent a macro definition from being
-# undefined via #undef or recursively expanded use the := operator
-# instead of the = operator.
-
-PREDEFINED =
-
-# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then
-# this tag can be used to specify a list of macro names that should be expanded.
-# The macro definition that is found in the sources will be used.
-# Use the PREDEFINED tag if you want to use a different macro definition.
-
-EXPAND_AS_DEFINED =
-
-# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then
-# doxygen's preprocessor will remove all function-like macros that are alone
-# on a line, have an all uppercase name, and do not end with a semicolon. Such
-# function macros are typically used for boiler-plate code, and will confuse
-# the parser if not removed.
-
-SKIP_FUNCTION_MACROS = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to external references
-#---------------------------------------------------------------------------
-
-# The TAGFILES option can be used to specify one or more tagfiles.
-# Optionally an initial location of the external documentation
-# can be added for each tagfile. The format of a tag file without
-# this location is as follows:
-# TAGFILES = file1 file2 ...
-# Adding location for the tag files is done as follows:
-# TAGFILES = file1=loc1 "file2 = loc2" ...
-# where "loc1" and "loc2" can be relative or absolute paths or
-# URLs. If a location is present for each tag, the installdox tool
-# does not have to be run to correct the links.
-# Note that each tag file must have a unique name
-# (where the name does NOT include the path)
-# If a tag file is not located in the directory in which doxygen
-# is run, you must also specify the path to the tagfile here.
-
-TAGFILES =
-
-# When a file name is specified after GENERATE_TAGFILE, doxygen will create
-# a tag file that is based on the input files it reads.
-
-GENERATE_TAGFILE =
-
-# If the ALLEXTERNALS tag is set to YES all external classes will be listed
-# in the class index. If set to NO only the inherited external classes
-# will be listed.
-
-ALLEXTERNALS = NO
-
-# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed
-# in the modules index. If set to NO, only the current project's groups will
-# be listed.
-
-EXTERNAL_GROUPS = YES
-
-# The PERL_PATH should be the absolute path and name of the perl script
-# interpreter (i.e. the result of `which perl').
-
-PERL_PATH = /usr/bin/perl
-
-#---------------------------------------------------------------------------
-# Configuration options related to the dot tool
-#---------------------------------------------------------------------------
-
-# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will
-# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base
-# or super classes. Setting the tag to NO turns the diagrams off. Note that
-# this option is superseded by the HAVE_DOT option below. This is only a
-# fallback. It is recommended to install and use dot, since it yields more
-# powerful graphs.
-
-CLASS_DIAGRAMS = YES
-
-# You can define message sequence charts within doxygen comments using the \msc
-# command. Doxygen will then run the mscgen tool (see
-# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the
-# documentation. The MSCGEN_PATH tag allows you to specify the directory where
-# the mscgen tool resides. If left empty the tool is assumed to be found in the
-# default search path.
-
-MSCGEN_PATH =
-
-# If set to YES, the inheritance and collaboration graphs will hide
-# inheritance and usage relations if the target is undocumented
-# or is not a class.
-
-HIDE_UNDOC_RELATIONS = YES
-
-# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is
-# available from the path. This tool is part of Graphviz, a graph visualization
-# toolkit from AT&T and Lucent Bell Labs. The other options in this section
-# have no effect if this option is set to NO (the default)
-
-HAVE_DOT = YES
-
-# By default doxygen will write a font called FreeSans.ttf to the output
-# directory and reference it in all dot files that doxygen generates. This
-# font does not include all possible unicode characters however, so when you need
-# these (or just want a differently looking font) you can specify the font name
-# using DOT_FONTNAME. You need need to make sure dot is able to find the font,
-# which can be done by putting it in a standard location or by setting the
-# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory
-# containing the font.
-
-DOT_FONTNAME = FreeSans
-
-# By default doxygen will tell dot to use the output directory to look for the
-# FreeSans.ttf font (which doxygen will put there itself). If you specify a
-# different font using DOT_FONTNAME you can set the path where dot
-# can find it using this tag.
-
-DOT_FONTPATH =
-
-# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen
-# will generate a graph for each documented class showing the direct and
-# indirect inheritance relations. Setting this tag to YES will force the
-# the CLASS_DIAGRAMS tag to NO.
-
-CLASS_GRAPH = YES
-
-# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen
-# will generate a graph for each documented class showing the direct and
-# indirect implementation dependencies (inheritance, containment, and
-# class references variables) of the class with other documented classes.
-
-COLLABORATION_GRAPH = YES
-
-# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen
-# will generate a graph for groups, showing the direct groups dependencies
-
-GROUP_GRAPHS = YES
-
-# If the UML_LOOK tag is set to YES doxygen will generate inheritance and
-# collaboration diagrams in a style similar to the OMG's Unified Modeling
-# Language.
-
-UML_LOOK = NO
-
-# If set to YES, the inheritance and collaboration graphs will show the
-# relations between templates and their instances.
-
-TEMPLATE_RELATIONS = NO
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT
-# tags are set to YES then doxygen will generate a graph for each documented
-# file showing the direct and indirect include dependencies of the file with
-# other documented files.
-
-INCLUDE_GRAPH = YES
-
-# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and
-# HAVE_DOT tags are set to YES then doxygen will generate a graph for each
-# documented header file showing the documented files that directly or
-# indirectly include this file.
-
-INCLUDED_BY_GRAPH = YES
-
-# If the CALL_GRAPH and HAVE_DOT options are set to YES then
-# doxygen will generate a call dependency graph for every global function
-# or class method. Note that enabling this option will significantly increase
-# the time of a run. So in most cases it will be better to enable call graphs
-# for selected functions only using the \callgraph command.
-
-CALL_GRAPH = NO
-
-# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then
-# doxygen will generate a caller dependency graph for every global function
-# or class method. Note that enabling this option will significantly increase
-# the time of a run. So in most cases it will be better to enable caller
-# graphs for selected functions only using the \callergraph command.
-
-CALLER_GRAPH = NO
-
-# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen
-# will graphical hierarchy of all classes instead of a textual one.
-
-GRAPHICAL_HIERARCHY = YES
-
-# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES
-# then doxygen will show the dependencies a directory has on other directories
-# in a graphical way. The dependency relations are determined by the #include
-# relations between the files in the directories.
-
-DIRECTORY_GRAPH = YES
-
-# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images
-# generated by dot. Possible values are png, jpg, or gif
-# If left blank png will be used.
-
-DOT_IMAGE_FORMAT = png
-
-# The tag DOT_PATH can be used to specify the path where the dot tool can be
-# found. If left blank, it is assumed the dot tool can be found in the path.
-
-DOT_PATH =
-
-# The DOTFILE_DIRS tag can be used to specify one or more directories that
-# contain dot files that are included in the documentation (see the
-# \dotfile command).
-
-DOTFILE_DIRS =
-
-# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of
-# nodes that will be shown in the graph. If the number of nodes in a graph
-# becomes larger than this value, doxygen will truncate the graph, which is
-# visualized by representing a node as a red box. Note that doxygen if the
-# number of direct children of the root node in a graph is already larger than
-# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note
-# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH.
-
-DOT_GRAPH_MAX_NODES = 50
-
-# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the
-# graphs generated by dot. A depth value of 3 means that only nodes reachable
-# from the root by following a path via at most 3 edges will be shown. Nodes
-# that lay further from the root node will be omitted. Note that setting this
-# option to 1 or 2 may greatly reduce the computation time needed for large
-# code bases. Also note that the size of a graph can be further restricted by
-# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction.
-
-MAX_DOT_GRAPH_DEPTH = 0
-
-# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent
-# background. This is disabled by default, because dot on Windows does not
-# seem to support this out of the box. Warning: Depending on the platform used,
-# enabling this option may lead to badly anti-aliased labels on the edges of
-# a graph (i.e. they become hard to read).
-
-DOT_TRANSPARENT = NO
-
-# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output
-# files in one run (i.e. multiple -o and -T options on the command line). This
-# makes dot run faster, but since only newer versions of dot (>1.8.10)
-# support this, this feature is disabled by default.
-
-DOT_MULTI_TARGETS = NO
-
-# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will
-# generate a legend page explaining the meaning of the various boxes and
-# arrows in the dot generated graphs.
-
-GENERATE_LEGEND = YES
-
-# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will
-# remove the intermediate dot files that are used to generate
-# the various graphs.
-
-DOT_CLEANUP = YES
-
-#---------------------------------------------------------------------------
-# Configuration::additions related to the search engine
-#---------------------------------------------------------------------------
-
-# The SEARCHENGINE tag specifies whether or not a search engine should be
-# used. If set to NO the values of all tags below this one will be ignored.
-
-SEARCHENGINE = NO
+# Doxyfile 1.5.7
+
+# This file describes the settings to be used by the documentation system
+# doxygen (www.doxygen.org) for a project
+#
+# All text after a hash (#) is considered a comment and will be ignored
+# The format is:
+# TAG = value [value, ...]
+# For lists items can also be appended using:
+# TAG += value [value, ...]
+# Values that contain spaces should be placed between quotes (" ")
+
+#---------------------------------------------------------------------------
+# Project related configuration options
+#---------------------------------------------------------------------------
+
+# This tag specifies the encoding used for all characters in the config file
+# that follow. The default is UTF-8 which is also the encoding used for all
+# text before the first occurrence of this tag. Doxygen uses libiconv (or the
+# iconv built into libc) for the transcoding. See
+# http://www.gnu.org/software/libiconv for the list of possible encodings.
+
+DOXYFILE_ENCODING = UTF-8
+
+# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
+# by quotes) that should identify the project.
+
+PROJECT_NAME = inkscape
+
+# The PROJECT_NUMBER tag can be used to enter a project or revision number.
+# This could be handy for archiving the generated documentation or
+# if some version control system is used.
+
+PROJECT_NUMBER =
+
+# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
+# base path where the generated documentation will be put.
+# If a relative path is entered, it will be relative to the location
+# where doxygen was started. If left blank the current directory will be used.
+
+OUTPUT_DIRECTORY = doxygen
+
+# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create
+# 4096 sub-directories (in 2 levels) under the output directory of each output
+# format and will distribute the generated files over these directories.
+# Enabling this option can be useful when feeding doxygen a huge amount of
+# source files, where putting all generated files in the same directory would
+# otherwise cause performance problems for the file system.
+
+CREATE_SUBDIRS = NO
+
+# The OUTPUT_LANGUAGE tag is used to specify the language in which all
+# documentation generated by doxygen is written. Doxygen will use this
+# information to generate all constant output in the proper language.
+# The default language is English, other supported languages are:
+# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional,
+# Croatian, Czech, Danish, Dutch, Farsi, Finnish, French, German, Greek,
+# Hungarian, Italian, Japanese, Japanese-en (Japanese with English messages),
+# Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, Polish,
+# Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak, Slovene,
+# Spanish, Swedish, and Ukrainian.
+
+OUTPUT_LANGUAGE = English
+
+# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will
+# include brief member descriptions after the members that are listed in
+# the file and class documentation (similar to JavaDoc).
+# Set to NO to disable this.
+
+BRIEF_MEMBER_DESC = YES
+
+# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend
+# the brief description of a member or function before the detailed description.
+# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the
+# brief descriptions will be completely suppressed.
+
+REPEAT_BRIEF = YES
+
+# This tag implements a quasi-intelligent brief description abbreviator
+# that is used to form the text in various listings. Each string
+# in this list, if found as the leading text of the brief description, will be
+# stripped from the text and the result after processing the whole list, is
+# used as the annotated text. Otherwise, the brief description is used as-is.
+# If left blank, the following values are used ("$name" is automatically
+# replaced with the name of the entity): "The $name class" "The $name widget"
+# "The $name file" "is" "provides" "specifies" "contains"
+# "represents" "a" "an" "the"
+
+ABBREVIATE_BRIEF =
+
+# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then
+# Doxygen will generate a detailed section even if there is only a brief
+# description.
+
+ALWAYS_DETAILED_SEC = NO
+
+# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all
+# inherited members of a class in the documentation of that class as if those
+# members were ordinary class members. Constructors, destructors and assignment
+# operators of the base classes will not be shown.
+
+INLINE_INHERITED_MEMB = NO
+
+# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full
+# path before files name in the file list and in the header files. If set
+# to NO the shortest path that makes the file name unique will be used.
+
+FULL_PATH_NAMES = YES
+
+# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag
+# can be used to strip a user-defined part of the path. Stripping is
+# only done if one of the specified strings matches the left-hand part of
+# the path. The tag can be used to show relative paths in the file list.
+# If left blank the directory from which doxygen is run is used as the
+# path to strip.
+
+STRIP_FROM_PATH =
+
+# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of
+# the path mentioned in the documentation of a class, which tells
+# the reader which header file to include in order to use a class.
+# If left blank only the name of the header file containing the class
+# definition is used. Otherwise one should specify the include paths that
+# are normally passed to the compiler using the -I flag.
+
+STRIP_FROM_INC_PATH =
+
+# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter
+# (but less readable) file names. This can be useful is your file systems
+# doesn't support long names like on DOS, Mac, or CD-ROM.
+
+SHORT_NAMES = NO
+
+# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen
+# will interpret the first line (until the first dot) of a JavaDoc-style
+# comment as the brief description. If set to NO, the JavaDoc
+# comments will behave just like regular Qt-style comments
+# (thus requiring an explicit @brief command for a brief description.)
+
+JAVADOC_AUTOBRIEF = YES
+
+# If the QT_AUTOBRIEF tag is set to YES then Doxygen will
+# interpret the first line (until the first dot) of a Qt-style
+# comment as the brief description. If set to NO, the comments
+# will behave just like regular Qt-style comments (thus requiring
+# an explicit \brief command for a brief description.)
+
+QT_AUTOBRIEF = NO
+
+# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen
+# treat a multi-line C++ special comment block (i.e. a block of //! or ///
+# comments) as a brief description. This used to be the default behaviour.
+# The new default is to treat a multi-line C++ comment block as a detailed
+# description. Set this tag to YES if you prefer the old behaviour instead.
+
+MULTILINE_CPP_IS_BRIEF = NO
+
+# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented
+# member inherits the documentation from any documented member that it
+# re-implements.
+
+INHERIT_DOCS = YES
+
+# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce
+# a new page for each member. If set to NO, the documentation of a member will
+# be part of the file/class/namespace that contains it.
+
+SEPARATE_MEMBER_PAGES = NO
+
+# The TAB_SIZE tag can be used to set the number of spaces in a tab.
+# Doxygen uses this value to replace tabs by spaces in code fragments.
+
+TAB_SIZE = 4
+
+# This tag can be used to specify a number of aliases that acts
+# as commands in the documentation. An alias has the form "name=value".
+# For example adding "sideeffect=\par Side Effects:\n" will allow you to
+# put the command \sideeffect (or @sideeffect) in the documentation, which
+# will result in a user-defined paragraph with heading "Side Effects:".
+# You can put \n's in the value part of an alias to insert newlines.
+
+ALIASES =
+
+# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C
+# sources only. Doxygen will then generate output that is more tailored for C.
+# For instance, some of the names that are used will be different. The list
+# of all members will be omitted, etc.
+
+OPTIMIZE_OUTPUT_FOR_C = YES
+
+# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java
+# sources only. Doxygen will then generate output that is more tailored for
+# Java. For instance, namespaces will be presented as packages, qualified
+# scopes will look different, etc.
+
+OPTIMIZE_OUTPUT_JAVA = NO
+
+# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran
+# sources only. Doxygen will then generate output that is more tailored for
+# Fortran.
+
+OPTIMIZE_FOR_FORTRAN = NO
+
+# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL
+# sources. Doxygen will then generate output that is tailored for
+# VHDL.
+
+OPTIMIZE_OUTPUT_VHDL = NO
+
+# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want
+# to include (a tag file for) the STL sources as input, then you should
+# set this tag to YES in order to let doxygen match functions declarations and
+# definitions whose arguments contain STL classes (e.g. func(std::string); v.s.
+# func(std::string) {}). This also make the inheritance and collaboration
+# diagrams that involve STL classes more complete and accurate.
+
+BUILTIN_STL_SUPPORT = YES
+
+# If you use Microsoft's C++/CLI language, you should set this option to YES to
+# enable parsing support.
+
+CPP_CLI_SUPPORT = NO
+
+# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only.
+# Doxygen will parse them like normal C++ but will assume all classes use public
+# instead of private inheritance when no explicit protection keyword is present.
+
+SIP_SUPPORT = NO
+
+# For Microsoft's IDL there are propget and propput attributes to indicate getter
+# and setter methods for a property. Setting this option to YES (the default)
+# will make doxygen to replace the get and set methods by a property in the
+# documentation. This will only work if the methods are indeed getting or
+# setting a simple type. If this is not the case, or you want to show the
+# methods anyway, you should set this option to NO.
+
+IDL_PROPERTY_SUPPORT = YES
+
+# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC
+# tag is set to YES, then doxygen will reuse the documentation of the first
+# member in the group (if any) for the other members of the group. By default
+# all members of a group must be documented explicitly.
+
+DISTRIBUTE_GROUP_DOC = NO
+
+# Set the SUBGROUPING tag to YES (the default) to allow class member groups of
+# the same type (for instance a group of public functions) to be put as a
+# subgroup of that type (e.g. under the Public Functions section). Set it to
+# NO to prevent subgrouping. Alternatively, this can be done per class using
+# the \nosubgrouping command.
+
+SUBGROUPING = YES
+
+# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum
+# is documented as struct, union, or enum with the name of the typedef. So
+# typedef struct TypeS {} TypeT, will appear in the documentation as a struct
+# with name TypeT. When disabled the typedef will appear as a member of a file,
+# namespace, or class. And the struct will be named TypeS. This can typically
+# be useful for C code in case the coding convention dictates that all compound
+# types are typedef'ed and only the typedef is referenced, never the tag name.
+
+TYPEDEF_HIDES_STRUCT = NO
+
+# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to
+# determine which symbols to keep in memory and which to flush to disk.
+# When the cache is full, less often used symbols will be written to disk.
+# For small to medium size projects (<1000 input files) the default value is
+# probably good enough. For larger projects a too small cache size can cause
+# doxygen to be busy swapping symbols to and from disk most of the time
+# causing a significant performance penality.
+# If the system has enough physical memory increasing the cache will improve the
+# performance by keeping more symbols in memory. Note that the value works on
+# a logarithmic scale so increasing the size by one will rougly double the
+# memory usage. The cache size is given by this formula:
+# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0,
+# corresponding to a cache size of 2^16 = 65536 symbols
+
+SYMBOL_CACHE_SIZE = 0
+
+#---------------------------------------------------------------------------
+# Build related configuration options
+#---------------------------------------------------------------------------
+
+# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in
+# documentation are documented, even if no documentation was available.
+# Private class members and static file members will be hidden unless
+# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
+
+EXTRACT_ALL = YES
+
+# If the EXTRACT_PRIVATE tag is set to YES all private members of a class
+# will be included in the documentation.
+
+EXTRACT_PRIVATE = YES
+
+# If the EXTRACT_STATIC tag is set to YES all static members of a file
+# will be included in the documentation.
+
+EXTRACT_STATIC = YES
+
+# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs)
+# defined locally in source files will be included in the documentation.
+# If set to NO only classes defined in header files are included.
+
+EXTRACT_LOCAL_CLASSES = NO
+
+# This flag is only useful for Objective-C code. When set to YES local
+# methods, which are defined in the implementation section but not in
+# the interface are included in the documentation.
+# If set to NO (the default) only methods in the interface are included.
+
+EXTRACT_LOCAL_METHODS = NO
+
+# If this flag is set to YES, the members of anonymous namespaces will be
+# extracted and appear in the documentation as a namespace called
+# 'anonymous_namespace{file}', where file will be replaced with the base
+# name of the file that contains the anonymous namespace. By default
+# anonymous namespace are hidden.
+
+EXTRACT_ANON_NSPACES = NO
+
+# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all
+# undocumented members of documented classes, files or namespaces.
+# If set to NO (the default) these members will be included in the
+# various overviews, but no documentation section is generated.
+# This option has no effect if EXTRACT_ALL is enabled.
+
+HIDE_UNDOC_MEMBERS = NO
+
+# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all
+# undocumented classes that are normally visible in the class hierarchy.
+# If set to NO (the default) these classes will be included in the various
+# overviews. This option has no effect if EXTRACT_ALL is enabled.
+
+HIDE_UNDOC_CLASSES = NO
+
+# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all
+# friend (class|struct|union) declarations.
+# If set to NO (the default) these declarations will be included in the
+# documentation.
+
+HIDE_FRIEND_COMPOUNDS = NO
+
+# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any
+# documentation blocks found inside the body of a function.
+# If set to NO (the default) these blocks will be appended to the
+# function's detailed documentation block.
+
+HIDE_IN_BODY_DOCS = NO
+
+# The INTERNAL_DOCS tag determines if documentation
+# that is typed after a \internal command is included. If the tag is set
+# to NO (the default) then the documentation will be excluded.
+# Set it to YES to include the internal documentation.
+
+INTERNAL_DOCS = NO
+
+# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate
+# file names in lower-case letters. If set to YES upper-case letters are also
+# allowed. This is useful if you have classes or files whose names only differ
+# in case and if your file system supports case sensitive file names. Windows
+# and Mac users are advised to set this option to NO.
+
+CASE_SENSE_NAMES = YES
+
+# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen
+# will show members with their full class and namespace scopes in the
+# documentation. If set to YES the scope will be hidden.
+
+HIDE_SCOPE_NAMES = YES
+
+# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen
+# will put a list of the files that are included by a file in the documentation
+# of that file.
+
+SHOW_INCLUDE_FILES = YES
+
+# If the INLINE_INFO tag is set to YES (the default) then a tag [inline]
+# is inserted in the documentation for inline members.
+
+INLINE_INFO = YES
+
+# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen
+# will sort the (detailed) documentation of file and class members
+# alphabetically by member name. If set to NO the members will appear in
+# declaration order.
+
+SORT_MEMBER_DOCS = YES
+
+# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the
+# brief documentation of file, namespace and class members alphabetically
+# by member name. If set to NO (the default) the members will appear in
+# declaration order.
+
+SORT_BRIEF_DOCS = NO
+
+# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the
+# hierarchy of group names into alphabetical order. If set to NO (the default)
+# the group names will appear in their defined order.
+
+SORT_GROUP_NAMES = NO
+
+# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be
+# sorted by fully-qualified names, including namespaces. If set to
+# NO (the default), the class list will be sorted only by class name,
+# not including the namespace part.
+# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.
+# Note: This option applies only to the class list, not to the
+# alphabetical list.
+
+SORT_BY_SCOPE_NAME = NO
+
+# The GENERATE_TODOLIST tag can be used to enable (YES) or
+# disable (NO) the todo list. This list is created by putting \todo
+# commands in the documentation.
+
+GENERATE_TODOLIST = YES
+
+# The GENERATE_TESTLIST tag can be used to enable (YES) or
+# disable (NO) the test list. This list is created by putting \test
+# commands in the documentation.
+
+GENERATE_TESTLIST = YES
+
+# The GENERATE_BUGLIST tag can be used to enable (YES) or
+# disable (NO) the bug list. This list is created by putting \bug
+# commands in the documentation.
+
+GENERATE_BUGLIST = YES
+
+# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or
+# disable (NO) the deprecated list. This list is created by putting
+# \deprecated commands in the documentation.
+
+GENERATE_DEPRECATEDLIST= YES
+
+# The ENABLED_SECTIONS tag can be used to enable conditional
+# documentation sections, marked by \if sectionname ... \endif.
+
+ENABLED_SECTIONS =
+
+# The MAX_INITIALIZER_LINES tag determines the maximum number of lines
+# the initial value of a variable or define consists of for it to appear in
+# the documentation. If the initializer consists of more lines than specified
+# here it will be hidden. Use a value of 0 to hide initializers completely.
+# The appearance of the initializer of individual variables and defines in the
+# documentation can be controlled using \showinitializer or \hideinitializer
+# command in the documentation regardless of this setting.
+
+MAX_INITIALIZER_LINES = 30
+
+# Set the SHOW_USED_FILES tag to NO to disable the list of files generated
+# at the bottom of the documentation of classes and structs. If set to YES the
+# list will mention the files that were used to generate the documentation.
+
+SHOW_USED_FILES = YES
+
+# If the sources in your project are distributed over multiple directories
+# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy
+# in the documentation. The default is NO.
+
+SHOW_DIRECTORIES = NO
+
+# Set the SHOW_FILES tag to NO to disable the generation of the Files page.
+# This will remove the Files entry from the Quick Index and from the
+# Folder Tree View (if specified). The default is YES.
+
+SHOW_FILES = YES
+
+# Set the SHOW_NAMESPACES tag to NO to disable the generation of the
+# Namespaces page. This will remove the Namespaces entry from the Quick Index
+# and from the Folder Tree View (if specified). The default is YES.
+
+SHOW_NAMESPACES = YES
+
+# The FILE_VERSION_FILTER tag can be used to specify a program or script that
+# doxygen should invoke to get the current version for each file (typically from
+# the version control system). Doxygen will invoke the program by executing (via
+# popen()) the command <command> <input-file>, where <command> is the value of
+# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file
+# provided by doxygen. Whatever the program writes to standard output
+# is used as the file version. See the manual for examples.
+
+FILE_VERSION_FILTER =
+
+# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed by
+# doxygen. The layout file controls the global structure of the generated output files
+# in an output format independent way. The create the layout file that represents
+# doxygen's defaults, run doxygen with the -l option. You can optionally specify a
+# file name after the option, if omitted DoxygenLayout.xml will be used as the name
+# of the layout file.
+
+LAYOUT_FILE =
+
+#---------------------------------------------------------------------------
+# configuration options related to warning and progress messages
+#---------------------------------------------------------------------------
+
+# The QUIET tag can be used to turn on/off the messages that are generated
+# by doxygen. Possible values are YES and NO. If left blank NO is used.
+
+QUIET = NO
+
+# The WARNINGS tag can be used to turn on/off the warning messages that are
+# generated by doxygen. Possible values are YES and NO. If left blank
+# NO is used.
+
+WARNINGS = YES
+
+# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings
+# for undocumented members. If EXTRACT_ALL is set to YES then this flag will
+# automatically be disabled.
+
+WARN_IF_UNDOCUMENTED = NO
+
+# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for
+# potential errors in the documentation, such as not documenting some
+# parameters in a documented function, or documenting parameters that
+# don't exist or using markup commands wrongly.
+
+WARN_IF_DOC_ERROR = YES
+
+# This WARN_NO_PARAMDOC option can be abled to get warnings for
+# functions that are documented, but have no documentation for their parameters
+# or return value. If set to NO (the default) doxygen will only warn about
+# wrong or incomplete parameter documentation, but not about the absence of
+# documentation.
+
+WARN_NO_PARAMDOC = NO
+
+# The WARN_FORMAT tag determines the format of the warning messages that
+# doxygen can produce. The string should contain the $file, $line, and $text
+# tags, which will be replaced by the file and line number from which the
+# warning originated and the warning text. Optionally the format may contain
+# $version, which will be replaced by the version of the file (if it could
+# be obtained via FILE_VERSION_FILTER)
+
+WARN_FORMAT = "$file:$line: $text"
+
+# The WARN_LOGFILE tag can be used to specify a file to which warning
+# and error messages should be written. If left blank the output is written
+# to stderr.
+
+WARN_LOGFILE = doxygen_warnings.log
+
+#---------------------------------------------------------------------------
+# configuration options related to the input files
+#---------------------------------------------------------------------------
+
+# The INPUT tag can be used to specify the files and/or directories that contain
+# documented source files. You may enter file names like "myfile.cpp" or
+# directories like "/usr/src/myproject". Separate the files or directories
+# with spaces.
+
+INPUT = src
+
+# This tag can be used to specify the character encoding of the source files
+# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
+# also the default input encoding. Doxygen uses libiconv (or the iconv built
+# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for
+# the list of possible encodings.
+
+INPUT_ENCODING = UTF-8
+
+# If the value of the INPUT tag contains directories, you can use the
+# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
+# and *.h) to filter out the source-files in the directories. If left
+# blank the following patterns are tested:
+# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx
+# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90
+
+FILE_PATTERNS = *.cpp *.h
+
+# The RECURSIVE tag can be used to turn specify whether or not subdirectories
+# should be searched for input files as well. Possible values are YES and NO.
+# If left blank NO is used.
+
+RECURSIVE = YES
+
+# The EXCLUDE tag can be used to specify files and/or directories that should
+# excluded from the INPUT source files. This way you can easily exclude a
+# subdirectory from a directory tree whose root is specified with the INPUT tag.
+
+EXCLUDE =
+
+# The EXCLUDE_SYMLINKS tag can be used select whether or not files or
+# directories that are symbolic links (a Unix filesystem feature) are excluded
+# from the input.
+
+EXCLUDE_SYMLINKS = YES
+
+# If the value of the INPUT tag contains directories, you can use the
+# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude
+# certain files from those directories. Note that the wildcards are matched
+# against the file with absolute path, so to exclude all test directories
+# for example use the pattern */test/*
+
+EXCLUDE_PATTERNS =
+
+# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names
+# (namespaces, classes, functions, etc.) that should be excluded from the
+# output. The symbol name can be a fully qualified name, a word, or if the
+# wildcard * is used, a substring. Examples: ANamespace, AClass,
+# AClass::ANamespace, ANamespace::*Test
+
+EXCLUDE_SYMBOLS =
+
+# The EXAMPLE_PATH tag can be used to specify one or more files or
+# directories that contain example code fragments that are included (see
+# the \include command).
+
+EXAMPLE_PATH =
+
+# If the value of the EXAMPLE_PATH tag contains directories, you can use the
+# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
+# and *.h) to filter out the source-files in the directories. If left
+# blank all files are included.
+
+EXAMPLE_PATTERNS =
+
+# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be
+# searched for input files to be used with the \include or \dontinclude
+# commands irrespective of the value of the RECURSIVE tag.
+# Possible values are YES and NO. If left blank NO is used.
+
+EXAMPLE_RECURSIVE = NO
+
+# The IMAGE_PATH tag can be used to specify one or more files or
+# directories that contain image that are included in the documentation (see
+# the \image command).
+
+IMAGE_PATH =
+
+# The INPUT_FILTER tag can be used to specify a program that doxygen should
+# invoke to filter for each input file. Doxygen will invoke the filter program
+# by executing (via popen()) the command <filter> <input-file>, where <filter>
+# is the value of the INPUT_FILTER tag, and <input-file> is the name of an
+# input file. Doxygen will then use the output that the filter program writes
+# to standard output. If FILTER_PATTERNS is specified, this tag will be
+# ignored.
+
+INPUT_FILTER =
+
+# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern
+# basis. Doxygen will compare the file name with each pattern and apply the
+# filter if there is a match. The filters are a list of the form:
+# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further
+# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER
+# is applied to all files.
+
+FILTER_PATTERNS =
+
+# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using
+# INPUT_FILTER) will be used to filter the input files when producing source
+# files to browse (i.e. when SOURCE_BROWSER is set to YES).
+
+FILTER_SOURCE_FILES = NO
+
+#---------------------------------------------------------------------------
+# configuration options related to source browsing
+#---------------------------------------------------------------------------
+
+# If the SOURCE_BROWSER tag is set to YES then a list of source files will
+# be generated. Documented entities will be cross-referenced with these sources.
+# Note: To get rid of all source code in the generated output, make sure also
+# VERBATIM_HEADERS is set to NO.
+
+SOURCE_BROWSER = NO
+
+# Setting the INLINE_SOURCES tag to YES will include the body
+# of functions and classes directly in the documentation.
+
+INLINE_SOURCES = NO
+
+# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct
+# doxygen to hide any special comment blocks from generated source code
+# fragments. Normal C and C++ comments will always remain visible.
+
+STRIP_CODE_COMMENTS = YES
+
+# If the REFERENCED_BY_RELATION tag is set to YES
+# then for each documented function all documented
+# functions referencing it will be listed.
+
+REFERENCED_BY_RELATION = YES
+
+# If the REFERENCES_RELATION tag is set to YES
+# then for each documented function all documented entities
+# called/used by that function will be listed.
+
+REFERENCES_RELATION = YES
+
+# If the REFERENCES_LINK_SOURCE tag is set to YES (the default)
+# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from
+# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will
+# link to the source code. Otherwise they will link to the documentstion.
+
+REFERENCES_LINK_SOURCE = YES
+
+# If the USE_HTAGS tag is set to YES then the references to source code
+# will point to the HTML generated by the htags(1) tool instead of doxygen
+# built-in source browser. The htags tool is part of GNU's global source
+# tagging system (see http://www.gnu.org/software/global/global.html). You
+# will need version 4.8.6 or higher.
+
+USE_HTAGS = NO
+
+# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen
+# will generate a verbatim copy of the header file for each class for
+# which an include is specified. Set to NO to disable this.
+
+VERBATIM_HEADERS = NO
+
+#---------------------------------------------------------------------------
+# configuration options related to the alphabetical class index
+#---------------------------------------------------------------------------
+
+# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then
+# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns
+# in which this list will be split (can be a number in the range [1..20])
+
+COLS_IN_ALPHA_INDEX = 5
+
+# In case all classes in a project start with a common prefix, all
+# classes will be put under the same header in the alphabetical index.
+# The IGNORE_PREFIX tag can be used to specify one or more prefixes that
+# should be ignored while generating the index headers.
+
+IGNORE_PREFIX =
+
+#---------------------------------------------------------------------------
+# configuration options related to the HTML output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_HTML tag is set to YES (the default) Doxygen will
+# generate HTML output.
+
+GENERATE_HTML = YES
+
+# The HTML_OUTPUT tag is used to specify where the HTML docs will be put.
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be
+# put in front of it. If left blank `html' will be used as the default path.
+
+HTML_OUTPUT = html
+
+# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
+# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
+# doxygen will generate files with .html extension.
+
+HTML_FILE_EXTENSION = .html
+
+# The HTML_HEADER tag can be used to specify a personal HTML header for
+# each generated HTML page. If it is left blank doxygen will generate a
+# standard header.
+
+HTML_HEADER =
+
+# The HTML_FOOTER tag can be used to specify a personal HTML footer for
+# each generated HTML page. If it is left blank doxygen will generate a
+# standard footer.
+
+HTML_FOOTER =
+
+# The HTML_STYLESHEET tag can be used to specify a user-defined cascading
+# style sheet that is used by each HTML page. It can be used to
+# fine-tune the look of the HTML output. If the tag is left blank doxygen
+# will generate a default style sheet. Note that doxygen will try to copy
+# the style sheet file to the HTML output directory, so don't put your own
+# stylesheet in the HTML output directory as well, or it will be erased!
+
+HTML_STYLESHEET =
+
+# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes,
+# files or namespaces will be aligned in HTML using tables. If set to
+# NO a bullet list will be used.
+
+HTML_ALIGN_MEMBERS = YES
+
+# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML
+# documentation will contain sections that can be hidden and shown after the
+# page has loaded. For this to work a browser that supports
+# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox
+# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari).
+
+HTML_DYNAMIC_SECTIONS = NO
+
+# If the GENERATE_DOCSET tag is set to YES, additional index files
+# will be generated that can be used as input for Apple's Xcode 3
+# integrated development environment, introduced with OSX 10.5 (Leopard).
+# To create a documentation set, doxygen will generate a Makefile in the
+# HTML output directory. Running make will produce the docset in that
+# directory and running "make install" will install the docset in
+# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find
+# it at startup.
+# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for more information.
+
+GENERATE_DOCSET = NO
+
+# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the
+# feed. A documentation feed provides an umbrella under which multiple
+# documentation sets from a single provider (such as a company or product suite)
+# can be grouped.
+
+DOCSET_FEEDNAME = "Doxygen generated docs"
+
+# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that
+# should uniquely identify the documentation set bundle. This should be a
+# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen
+# will append .docset to the name.
+
+DOCSET_BUNDLE_ID = org.doxygen.Project
+
+# If the GENERATE_HTMLHELP tag is set to YES, additional index files
+# will be generated that can be used as input for tools like the
+# Microsoft HTML help workshop to generate a compiled HTML help file (.chm)
+# of the generated HTML documentation.
+
+GENERATE_HTMLHELP = NO
+
+# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can
+# be used to specify the file name of the resulting .chm file. You
+# can add a path in front of the file if the result should not be
+# written to the html output directory.
+
+CHM_FILE =
+
+# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can
+# be used to specify the location (absolute path including file name) of
+# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run
+# the HTML help compiler on the generated index.hhp.
+
+HHC_LOCATION =
+
+# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag
+# controls if a separate .chi index file is generated (YES) or that
+# it should be included in the master .chm file (NO).
+
+GENERATE_CHI = NO
+
+# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING
+# is used to encode HtmlHelp index (hhk), content (hhc) and project file
+# content.
+
+CHM_INDEX_ENCODING =
+
+# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag
+# controls whether a binary table of contents is generated (YES) or a
+# normal table of contents (NO) in the .chm file.
+
+BINARY_TOC = NO
+
+# The TOC_EXPAND flag can be set to YES to add extra items for group members
+# to the contents of the HTML help documentation and to the tree view.
+
+TOC_EXPAND = NO
+
+# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and QHP_VIRTUAL_FOLDER
+# are set, an additional index file will be generated that can be used as input for
+# Qt's qhelpgenerator to generate a Qt Compressed Help (.qch) of the generated
+# HTML documentation.
+
+GENERATE_QHP = NO
+
+# If the QHG_LOCATION tag is specified, the QCH_FILE tag can
+# be used to specify the file name of the resulting .qch file.
+# The path specified is relative to the HTML output folder.
+
+QCH_FILE =
+
+# The QHP_NAMESPACE tag specifies the namespace to use when generating
+# Qt Help Project output. For more information please see
+# <a href="http://doc.trolltech.com/qthelpproject.html#namespace">Qt Help Project / Namespace</a>.
+
+QHP_NAMESPACE = org.doxygen.Project
+
+# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating
+# Qt Help Project output. For more information please see
+# <a href="http://doc.trolltech.com/qthelpproject.html#virtual-folders">Qt Help Project / Virtual Folders</a>.
+
+QHP_VIRTUAL_FOLDER = doc
+
+# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can
+# be used to specify the location of Qt's qhelpgenerator.
+# If non-empty doxygen will try to run qhelpgenerator on the generated
+# .qhp file .
+
+QHG_LOCATION =
+
+# The DISABLE_INDEX tag can be used to turn on/off the condensed index at
+# top of each HTML page. The value NO (the default) enables the index and
+# the value YES disables it.
+
+DISABLE_INDEX = NO
+
+# This tag can be used to set the number of enum values (range [1..20])
+# that doxygen will group on one line in the generated HTML documentation.
+
+ENUM_VALUES_PER_LINE = 4
+
+# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index
+# structure should be generated to display hierarchical information.
+# If the tag value is set to FRAME, a side panel will be generated
+# containing a tree-like index structure (just like the one that
+# is generated for HTML Help). For this to work a browser that supports
+# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+,
+# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are
+# probably better off using the HTML help feature. Other possible values
+# for this tag are: HIERARCHIES, which will generate the Groups, Directories,
+# and Class Hierarchy pages using a tree view instead of an ordered list;
+# ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which
+# disables this behavior completely. For backwards compatibility with previous
+# releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE
+# respectively.
+
+GENERATE_TREEVIEW = NO
+
+# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be
+# used to set the initial width (in pixels) of the frame in which the tree
+# is shown.
+
+TREEVIEW_WIDTH = 250
+
+# Use this tag to change the font size of Latex formulas included
+# as images in the HTML documentation. The default is 10. Note that
+# when you change the font size after a successful doxygen run you need
+# to manually remove any form_*.png images from the HTML output directory
+# to force them to be regenerated.
+
+FORMULA_FONTSIZE = 10
+
+#---------------------------------------------------------------------------
+# configuration options related to the LaTeX output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
+# generate Latex output.
+
+GENERATE_LATEX = NO
+
+# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be
+# put in front of it. If left blank `latex' will be used as the default path.
+
+LATEX_OUTPUT = latex
+
+# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be
+# invoked. If left blank `latex' will be used as the default command name.
+
+LATEX_CMD_NAME = latex
+
+# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to
+# generate index for LaTeX. If left blank `makeindex' will be used as the
+# default command name.
+
+MAKEINDEX_CMD_NAME = makeindex
+
+# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact
+# LaTeX documents. This may be useful for small projects and may help to
+# save some trees in general.
+
+COMPACT_LATEX = NO
+
+# The PAPER_TYPE tag can be used to set the paper type that is used
+# by the printer. Possible values are: a4, a4wide, letter, legal and
+# executive. If left blank a4wide will be used.
+
+PAPER_TYPE = a4wide
+
+# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX
+# packages that should be included in the LaTeX output.
+
+EXTRA_PACKAGES =
+
+# The LATEX_HEADER tag can be used to specify a personal LaTeX header for
+# the generated latex document. The header should contain everything until
+# the first chapter. If it is left blank doxygen will generate a
+# standard header. Notice: only use this tag if you know what you are doing!
+
+LATEX_HEADER =
+
+# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated
+# is prepared for conversion to pdf (using ps2pdf). The pdf file will
+# contain links (just like the HTML output) instead of page references
+# This makes the output suitable for online browsing using a pdf viewer.
+
+PDF_HYPERLINKS = NO
+
+# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of
+# plain latex in the generated Makefile. Set this option to YES to get a
+# higher quality PDF documentation.
+
+USE_PDFLATEX = NO
+
+# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode.
+# command to the generated LaTeX files. This will instruct LaTeX to keep
+# running if errors occur, instead of asking the user for help.
+# This option is also used when generating formulas in HTML.
+
+LATEX_BATCHMODE = NO
+
+# If LATEX_HIDE_INDICES is set to YES then doxygen will not
+# include the index chapters (such as File Index, Compound Index, etc.)
+# in the output.
+
+LATEX_HIDE_INDICES = NO
+
+#---------------------------------------------------------------------------
+# configuration options related to the RTF output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output
+# The RTF output is optimized for Word 97 and may not look very pretty with
+# other RTF readers or editors.
+
+GENERATE_RTF = NO
+
+# The RTF_OUTPUT tag is used to specify where the RTF docs will be put.
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be
+# put in front of it. If left blank `rtf' will be used as the default path.
+
+RTF_OUTPUT = rtf
+
+# If the COMPACT_RTF tag is set to YES Doxygen generates more compact
+# RTF documents. This may be useful for small projects and may help to
+# save some trees in general.
+
+COMPACT_RTF = NO
+
+# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated
+# will contain hyperlink fields. The RTF file will
+# contain links (just like the HTML output) instead of page references.
+# This makes the output suitable for online browsing using WORD or other
+# programs which support those fields.
+# Note: wordpad (write) and others do not support links.
+
+RTF_HYPERLINKS = NO
+
+# Load stylesheet definitions from file. Syntax is similar to doxygen's
+# config file, i.e. a series of assignments. You only have to provide
+# replacements, missing definitions are set to their default value.
+
+RTF_STYLESHEET_FILE =
+
+# Set optional variables used in the generation of an rtf document.
+# Syntax is similar to doxygen's config file.
+
+RTF_EXTENSIONS_FILE =
+
+#---------------------------------------------------------------------------
+# configuration options related to the man page output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_MAN tag is set to YES (the default) Doxygen will
+# generate man pages
+
+GENERATE_MAN = NO
+
+# The MAN_OUTPUT tag is used to specify where the man pages will be put.
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be
+# put in front of it. If left blank `man' will be used as the default path.
+
+MAN_OUTPUT = man
+
+# The MAN_EXTENSION tag determines the extension that is added to
+# the generated man pages (default is the subroutine's section .3)
+
+MAN_EXTENSION = .3
+
+# If the MAN_LINKS tag is set to YES and Doxygen generates man output,
+# then it will generate one additional man file for each entity
+# documented in the real man page(s). These additional files
+# only source the real man page, but without them the man command
+# would be unable to find the correct page. The default is NO.
+
+MAN_LINKS = NO
+
+#---------------------------------------------------------------------------
+# configuration options related to the XML output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_XML tag is set to YES Doxygen will
+# generate an XML file that captures the structure of
+# the code including all documentation.
+
+GENERATE_XML = NO
+
+# The XML_OUTPUT tag is used to specify where the XML pages will be put.
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be
+# put in front of it. If left blank `xml' will be used as the default path.
+
+XML_OUTPUT = xml
+
+# The XML_SCHEMA tag can be used to specify an XML schema,
+# which can be used by a validating XML parser to check the
+# syntax of the XML files.
+
+XML_SCHEMA =
+
+# The XML_DTD tag can be used to specify an XML DTD,
+# which can be used by a validating XML parser to check the
+# syntax of the XML files.
+
+XML_DTD =
+
+# If the XML_PROGRAMLISTING tag is set to YES Doxygen will
+# dump the program listings (including syntax highlighting
+# and cross-referencing information) to the XML output. Note that
+# enabling this will significantly increase the size of the XML output.
+
+XML_PROGRAMLISTING = YES
+
+#---------------------------------------------------------------------------
+# configuration options for the AutoGen Definitions output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will
+# generate an AutoGen Definitions (see autogen.sf.net) file
+# that captures the structure of the code including all
+# documentation. Note that this feature is still experimental
+# and incomplete at the moment.
+
+GENERATE_AUTOGEN_DEF = NO
+
+#---------------------------------------------------------------------------
+# configuration options related to the Perl module output
+#---------------------------------------------------------------------------
+
+# If the GENERATE_PERLMOD tag is set to YES Doxygen will
+# generate a Perl module file that captures the structure of
+# the code including all documentation. Note that this
+# feature is still experimental and incomplete at the
+# moment.
+
+GENERATE_PERLMOD = NO
+
+# If the PERLMOD_LATEX tag is set to YES Doxygen will generate
+# the necessary Makefile rules, Perl scripts and LaTeX code to be able
+# to generate PDF and DVI output from the Perl module output.
+
+PERLMOD_LATEX = NO
+
+# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be
+# nicely formatted so it can be parsed by a human reader. This is useful
+# if you want to understand what is going on. On the other hand, if this
+# tag is set to NO the size of the Perl module output will be much smaller
+# and Perl will parse it just the same.
+
+PERLMOD_PRETTY = YES
+
+# The names of the make variables in the generated doxyrules.make file
+# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX.
+# This is useful so different doxyrules.make files included by the same
+# Makefile don't overwrite each other's variables.
+
+PERLMOD_MAKEVAR_PREFIX =
+
+#---------------------------------------------------------------------------
+# Configuration options related to the preprocessor
+#---------------------------------------------------------------------------
+
+# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will
+# evaluate all C-preprocessor directives found in the sources and include
+# files.
+
+ENABLE_PREPROCESSING = YES
+
+# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro
+# names in the source code. If set to NO (the default) only conditional
+# compilation will be performed. Macro expansion can be done in a controlled
+# way by setting EXPAND_ONLY_PREDEF to YES.
+
+MACRO_EXPANSION = NO
+
+# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES
+# then the macro expansion is limited to the macros specified with the
+# PREDEFINED and EXPAND_AS_DEFINED tags.
+
+EXPAND_ONLY_PREDEF = NO
+
+# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files
+# in the INCLUDE_PATH (see below) will be search if a #include is found.
+
+SEARCH_INCLUDES = YES
+
+# The INCLUDE_PATH tag can be used to specify one or more directories that
+# contain include files that are not input files but should be processed by
+# the preprocessor.
+
+INCLUDE_PATH = src
+
+# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard
+# patterns (like *.h and *.hpp) to filter out the header-files in the
+# directories. If left blank, the patterns specified with FILE_PATTERNS will
+# be used.
+
+INCLUDE_FILE_PATTERNS =
+
+# The PREDEFINED tag can be used to specify one or more macro names that
+# are defined before the preprocessor is started (similar to the -D option of
+# gcc). The argument of the tag is a list of macros of the form: name
+# or name=definition (no spaces). If the definition and the = are
+# omitted =1 is assumed. To prevent a macro definition from being
+# undefined via #undef or recursively expanded use the := operator
+# instead of the = operator.
+
+PREDEFINED =
+
+# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then
+# this tag can be used to specify a list of macro names that should be expanded.
+# The macro definition that is found in the sources will be used.
+# Use the PREDEFINED tag if you want to use a different macro definition.
+
+EXPAND_AS_DEFINED =
+
+# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then
+# doxygen's preprocessor will remove all function-like macros that are alone
+# on a line, have an all uppercase name, and do not end with a semicolon. Such
+# function macros are typically used for boiler-plate code, and will confuse
+# the parser if not removed.
+
+SKIP_FUNCTION_MACROS = YES
+
+#---------------------------------------------------------------------------
+# Configuration::additions related to external references
+#---------------------------------------------------------------------------
+
+# The TAGFILES option can be used to specify one or more tagfiles.
+# Optionally an initial location of the external documentation
+# can be added for each tagfile. The format of a tag file without
+# this location is as follows:
+# TAGFILES = file1 file2 ...
+# Adding location for the tag files is done as follows:
+# TAGFILES = file1=loc1 "file2 = loc2" ...
+# where "loc1" and "loc2" can be relative or absolute paths or
+# URLs. If a location is present for each tag, the installdox tool
+# does not have to be run to correct the links.
+# Note that each tag file must have a unique name
+# (where the name does NOT include the path)
+# If a tag file is not located in the directory in which doxygen
+# is run, you must also specify the path to the tagfile here.
+
+TAGFILES =
+
+# When a file name is specified after GENERATE_TAGFILE, doxygen will create
+# a tag file that is based on the input files it reads.
+
+GENERATE_TAGFILE =
+
+# If the ALLEXTERNALS tag is set to YES all external classes will be listed
+# in the class index. If set to NO only the inherited external classes
+# will be listed.
+
+ALLEXTERNALS = NO
+
+# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed
+# in the modules index. If set to NO, only the current project's groups will
+# be listed.
+
+EXTERNAL_GROUPS = YES
+
+# The PERL_PATH should be the absolute path and name of the perl script
+# interpreter (i.e. the result of `which perl').
+
+PERL_PATH = /usr/bin/perl
+
+#---------------------------------------------------------------------------
+# Configuration options related to the dot tool
+#---------------------------------------------------------------------------
+
+# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will
+# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base
+# or super classes. Setting the tag to NO turns the diagrams off. Note that
+# this option is superseded by the HAVE_DOT option below. This is only a
+# fallback. It is recommended to install and use dot, since it yields more
+# powerful graphs.
+
+CLASS_DIAGRAMS = YES
+
+# You can define message sequence charts within doxygen comments using the \msc
+# command. Doxygen will then run the mscgen tool (see
+# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the
+# documentation. The MSCGEN_PATH tag allows you to specify the directory where
+# the mscgen tool resides. If left empty the tool is assumed to be found in the
+# default search path.
+
+MSCGEN_PATH =
+
+# If set to YES, the inheritance and collaboration graphs will hide
+# inheritance and usage relations if the target is undocumented
+# or is not a class.
+
+HIDE_UNDOC_RELATIONS = YES
+
+# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is
+# available from the path. This tool is part of Graphviz, a graph visualization
+# toolkit from AT&T and Lucent Bell Labs. The other options in this section
+# have no effect if this option is set to NO (the default)
+
+HAVE_DOT = YES
+
+# By default doxygen will write a font called FreeSans.ttf to the output
+# directory and reference it in all dot files that doxygen generates. This
+# font does not include all possible unicode characters however, so when you need
+# these (or just want a differently looking font) you can specify the font name
+# using DOT_FONTNAME. You need need to make sure dot is able to find the font,
+# which can be done by putting it in a standard location or by setting the
+# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory
+# containing the font.
+
+DOT_FONTNAME = FreeSans
+
+# By default doxygen will tell dot to use the output directory to look for the
+# FreeSans.ttf font (which doxygen will put there itself). If you specify a
+# different font using DOT_FONTNAME you can set the path where dot
+# can find it using this tag.
+
+DOT_FONTPATH =
+
+# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen
+# will generate a graph for each documented class showing the direct and
+# indirect inheritance relations. Setting this tag to YES will force the
+# the CLASS_DIAGRAMS tag to NO.
+
+CLASS_GRAPH = YES
+
+# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen
+# will generate a graph for each documented class showing the direct and
+# indirect implementation dependencies (inheritance, containment, and
+# class references variables) of the class with other documented classes.
+
+COLLABORATION_GRAPH = YES
+
+# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen
+# will generate a graph for groups, showing the direct groups dependencies
+
+GROUP_GRAPHS = YES
+
+# If the UML_LOOK tag is set to YES doxygen will generate inheritance and
+# collaboration diagrams in a style similar to the OMG's Unified Modeling
+# Language.
+
+UML_LOOK = NO
+
+# If set to YES, the inheritance and collaboration graphs will show the
+# relations between templates and their instances.
+
+TEMPLATE_RELATIONS = NO
+
+# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT
+# tags are set to YES then doxygen will generate a graph for each documented
+# file showing the direct and indirect include dependencies of the file with
+# other documented files.
+
+INCLUDE_GRAPH = YES
+
+# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and
+# HAVE_DOT tags are set to YES then doxygen will generate a graph for each
+# documented header file showing the documented files that directly or
+# indirectly include this file.
+
+INCLUDED_BY_GRAPH = YES
+
+# If the CALL_GRAPH and HAVE_DOT options are set to YES then
+# doxygen will generate a call dependency graph for every global function
+# or class method. Note that enabling this option will significantly increase
+# the time of a run. So in most cases it will be better to enable call graphs
+# for selected functions only using the \callgraph command.
+
+CALL_GRAPH = NO
+
+# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then
+# doxygen will generate a caller dependency graph for every global function
+# or class method. Note that enabling this option will significantly increase
+# the time of a run. So in most cases it will be better to enable caller
+# graphs for selected functions only using the \callergraph command.
+
+CALLER_GRAPH = NO
+
+# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen
+# will graphical hierarchy of all classes instead of a textual one.
+
+GRAPHICAL_HIERARCHY = YES
+
+# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES
+# then doxygen will show the dependencies a directory has on other directories
+# in a graphical way. The dependency relations are determined by the #include
+# relations between the files in the directories.
+
+DIRECTORY_GRAPH = YES
+
+# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images
+# generated by dot. Possible values are png, jpg, or gif
+# If left blank png will be used.
+
+DOT_IMAGE_FORMAT = png
+
+# The tag DOT_PATH can be used to specify the path where the dot tool can be
+# found. If left blank, it is assumed the dot tool can be found in the path.
+
+DOT_PATH =
+
+# The DOTFILE_DIRS tag can be used to specify one or more directories that
+# contain dot files that are included in the documentation (see the
+# \dotfile command).
+
+DOTFILE_DIRS =
+
+# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of
+# nodes that will be shown in the graph. If the number of nodes in a graph
+# becomes larger than this value, doxygen will truncate the graph, which is
+# visualized by representing a node as a red box. Note that doxygen if the
+# number of direct children of the root node in a graph is already larger than
+# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note
+# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH.
+
+DOT_GRAPH_MAX_NODES = 50
+
+# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the
+# graphs generated by dot. A depth value of 3 means that only nodes reachable
+# from the root by following a path via at most 3 edges will be shown. Nodes
+# that lay further from the root node will be omitted. Note that setting this
+# option to 1 or 2 may greatly reduce the computation time needed for large
+# code bases. Also note that the size of a graph can be further restricted by
+# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction.
+
+MAX_DOT_GRAPH_DEPTH = 0
+
+# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent
+# background. This is disabled by default, because dot on Windows does not
+# seem to support this out of the box. Warning: Depending on the platform used,
+# enabling this option may lead to badly anti-aliased labels on the edges of
+# a graph (i.e. they become hard to read).
+
+DOT_TRANSPARENT = NO
+
+# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output
+# files in one run (i.e. multiple -o and -T options on the command line). This
+# makes dot run faster, but since only newer versions of dot (>1.8.10)
+# support this, this feature is disabled by default.
+
+DOT_MULTI_TARGETS = NO
+
+# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will
+# generate a legend page explaining the meaning of the various boxes and
+# arrows in the dot generated graphs.
+
+GENERATE_LEGEND = YES
+
+# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will
+# remove the intermediate dot files that are used to generate
+# the various graphs.
+
+DOT_CLEANUP = YES
+
+#---------------------------------------------------------------------------
+# Configuration::additions related to the search engine
+#---------------------------------------------------------------------------
+
+# The SEARCHENGINE tag specifies whether or not a search engine should be
+# used. If set to NO the values of all tags below this one will be ignored.
+
+SEARCHENGINE = NO
diff --git a/packaging/win32/AdvUninstLog.nsh b/packaging/win32/AdvUninstLog.nsh
index 2b5b5c77b..f48049164 100644
--- a/packaging/win32/AdvUninstLog.nsh
+++ b/packaging/win32/AdvUninstLog.nsh
@@ -1,437 +1,437 @@
- ;_____________________________ HEADER FILE BEGIN ____________________________
-
- # Advanced Uninstall Log NSIS header
- # Version 1.0 2007-01-31
- # By Red Wine (http://nsis.sf.net/User:Red_Wine)
-
- # Usage: See included examples Uninstall_Log_Default_UI.nsi - Uninstall_Log_Modern_UI.nsi
-
-!verbose push
- !verbose 3
-
-!ifndef ADVANCED_UNINSTALL.LOG_NSH
- !define ADVANCED_UNINSTALL.LOG_NSH
-
-!ifndef INSTDIR_REG_ROOT | INSTDIR_REG_KEY
- !error "You must properly define both INSTDIR_REG_ROOT and INSTDIR_REG_KEY"
-!endif
-
-!ifndef UNINSTALL_LOG
- !define UNINSTALL_LOG "Uninstall"
-!endif
-
-!ifndef UNINST_LOG_VERBOSE
- !define UNINST_LOG_VERBOSE "3"
-!endif
-
-!verbose pop
-
-!echo "Advanced Uninstall Log NSIS header v1.0 2007-01-31 by Red Wine (http://nsis.sf.net/User:Red_Wine)"
-
-!verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
-!define UNINST_EXE "$INSTDIR\${UNINSTALL_LOG}.exe"
-!define UNINST_DAT "$INSTDIR\${UNINSTALL_LOG}.dat"
-!define UNLOG_PART "$PLUGINSDIR\part."
-!define UNLOG_TEMP "$PLUGINSDIR\unlog.tmp"
-!define EXCLU_LIST "$PLUGINSDIR\exclude.tmp"
-!define UNLOG_HEAD "=========== Uninstaller Log please do not edit this file ==========="
-
- var unlog_tmp_0
- var unlog_tmp_1
- var unlog_tmp_2
- var unlog_tmp_3
- var unlog_error
-
-!include FileFunc.nsh
-!include TextFunc.nsh
-
-!insertmacro Locate
-!insertmacro un.Locate
-!insertmacro DirState
-!insertmacro un.DirState
-!insertmacro FileJoin
-!insertmacro TrimNewLines
-!insertmacro un.TrimNewLines
-
-;.............................. Uninstaller Macros ..............................
-
-!macro UNINSTALL.LOG_BEGIN_UNINSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- IfFileExists "${UNINST_DAT}" +3
- MessageBox MB_ICONSTOP|MB_OK "${UNINST_DAT} not found, unable to perform uninstall." /SD IDOK
- Quit
-
- StrCmp "$PLUGINSDIR" "" 0 +2
- InitPluginsDir
-
- CopyFiles "${UNINST_DAT}" "${UNLOG_TEMP}"
- FileOpen $unlog_tmp_2 "${UNLOG_TEMP}" r
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_END_UNINSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- FileClose $unlog_tmp_2
- DeleteRegValue ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}.dat"
- DeleteRegValue ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory"
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_UNINSTALL TargetDir
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- !ifndef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
- !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
- !endif
-
- !ifdef INTERACTIVE_UNINSTALL
- GetTempFileName $unlog_tmp_5 "$PLUGINSDIR"
- FileOpen $unlog_tmp_4 "$unlog_tmp_5" a
- !endif
-
- ${PerfomUninstall} "${TargetDir}" "${UnLog_Uninstall_CallBackFunc}"
-
- !ifdef INTERACTIVE_UNINSTALL
- FileClose $unlog_tmp_4
- !endif
-
- !verbose pop
-!macroend
-
-
-!define PerfomUninstall "!insertmacro PERFORMUNINSTALL"
-
-!macro PERFORMUNINSTALL TargetDir UninstCallBackFunc
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- !define ID ${__LINE__}
-
- ${un.Locate} "${TargetDir}" "/L=F" "${UninstCallBackFunc}"
-
- loop_${ID}:
-
- StrCpy $unlog_tmp_1 0
-
- ${un.Locate} "${TargetDir}" "/L=DE" "${UninstCallBackFunc}"
- StrCmp $unlog_tmp_1 "0" 0 loop_${ID}
-
- ${un.DirState} "${TargetDir}" $unlog_tmp_0
- StrCmp "$unlog_tmp_0" "0" 0 +2
- RmDir "${TargetDir}"
-
- IfErrors 0 +2
- MessageBox MB_ICONEXCLAMATION|MB_OK "${UNINSTALL_LOG} Log error" /SD IDOK
-
- !undef ID
-
- !verbose pop
-!macroend
-
-
-!macro INTERACTIVE_UNINSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- !ifdef INTERACTIVE_UNINSTALL
- !error "INTERACTIVE_UNINSTALL is already defined"
- !endif
-
- var unlog_tmp_4
- var unlog_tmp_5
-
- !define INTERACTIVE_UNINSTALL
-
- !ifdef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
- !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
- !endif
-
- !ifdef UnLog_Uninstall_CallBackFunc
- !undef UnLog_Uninstall_CallBackFunc
- !endif
-
- !ifndef UnLog_Uninstall_CallBackFunc
- !insertmacro UNINSTALL.LOG_UNINSTALL_INTERACTIVE
- !define UnLog_Uninstall_CallBackFunc "un._LocateCallBack_Function_Interactive"
- !endif
-
- !verbose pop
-!macroend
-
-
-!macro UNATTENDED_UNINSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- !ifdef UNATTENDED_UNINSTALL
- !error "UNATTENDED_UNINSTALL is already defined"
- !endif
-
- !define UNATTENDED_UNINSTALL
-
- !ifdef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
- !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
- !endif
-
- !ifdef UnLog_Uninstall_CallBackFunc
- !undef UnLog_Uninstall_CallBackFunc
- !endif
-
- !ifndef UnLog_Uninstall_CallBackFunc
- !insertmacro UNINSTALL.LOG_UNINSTALL_UNATTENDED
- !define UnLog_Uninstall_CallBackFunc "un._LocateCallBack_Function_Unattended"
- !endif
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_UNINSTALL_UNATTENDED
-
- Function un._LocateCallBack_Function_Unattended
- start:
- FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
- ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
- StrCmp "$unlog_tmp_3" "$R9" islog
- IfErrors nolog
- goto start
-
- islog:
- IfFileExists "$R9\*.*" isdir
-
- isfile:
- Delete "$R9"
- goto end
-
- isdir:
- RmDir "$R9"
- IntOp $unlog_tmp_1 $unlog_tmp_1 + 1
- goto end
-
- nolog:
- ClearErrors
- StrCmp "$R9" "${UNINST_EXE}" isfile
- StrCmp "$R9" "${UNINST_DAT}" isfile
-
- end:
- FileSeek $unlog_tmp_2 0 SET
- Push $unlog_tmp_0
- FunctionEnd
-
-!macroend
-
-
-!macro UNINSTALL.LOG_UNINSTALL_INTERACTIVE
-
- Function un._LocateCallBack_Function_Interactive
- start:
- FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
- ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
- StrCmp "$unlog_tmp_3" "$R9" islog
- IfErrors nolog
- goto start
-
- islog:
- IfFileExists "$R9\*.*" isdir
-
- isfile:
- Delete "$R9"
- goto end
-
- isdir:
- RmDir "$R9"
- IntOp $unlog_tmp_1 $unlog_tmp_1 + 1
- goto end
-
- nolog:
- ClearErrors
- FileSeek $unlog_tmp_4 0 SET
- read:
- FileRead $unlog_tmp_4 "$unlog_tmp_3"
- ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
- StrCmp "$unlog_tmp_3" "$R9" end
- IfErrors +2
- goto read
- ClearErrors
- StrCmp "$R9" "${UNINST_EXE}" isfile
- StrCmp "$R9" "${UNINST_DAT}" isfile
- IfFileExists "$R9\*.*" msgdir
-
- MessageBox MB_ICONQUESTION|MB_YESNO \
- 'Delete File "$R9"?' /SD IDNO IDYES isfile IDNO nodel
-
- msgdir:
- MessageBox MB_ICONQUESTION|MB_YESNO \
- 'Delete Directory "$R9"?' /SD IDNO IDYES isdir IDNO nodel
-
- nodel:
- FileSeek $unlog_tmp_4 0 END
- FileWrite $unlog_tmp_4 "$R9$\r$\n"
-
- end:
- FileSeek $unlog_tmp_2 0 SET
- Push $unlog_tmp_0
- FunctionEnd
-
-!macroend
-
-;................................. Installer Macros .................................
-
-!macro UNINSTALL.LOG_INSTALL_UNATTENDED
-
- Function _LocateCallBack_Function_Install
- loop:
- FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
- ${TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
- IfErrors 0 +4
- ClearErrors
- FileSeek $unlog_tmp_2 0 SET
- goto next
- StrCmp "$R9" "$unlog_tmp_3" end
- goto loop
- next:
- FileWrite $unlog_tmp_1 "$R9$\r$\n"
- end:
- Push $unlog_tmp_0
- FunctionEnd
-
-!macroend
-
-
-!ifdef UnLog_Install_Func_CallBack
- !undef UnLog_Install_Func_CallBack
-!endif
-
-!ifndef UnLog_Install_Func_CallBack
- !insertmacro UNINSTALL.LOG_INSTALL_UNATTENDED
- !define UnLog_Install_Func_CallBack "_LocateCallBack_Function_Install"
-!endif
-
-
-!macro UNINSTALL.LOG_PREPARE_INSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- Push $0
- Push $1
- ClearErrors
- ReadRegStr "$0" ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory"
- IfErrors next
- ${DirState} "$0" $1
- StrCmp "$1" "-1" next
- StrCmp "$1" "0" next
- IfFileExists "$0\${UNINSTALL_LOG}.dat" next
- MessageBox MB_ICONEXCLAMATION|MB_OK \
- "Previous installation detected at $0.$\n\
- Required file ${UNINSTALL_LOG}.dat is missing.$\n$\nIt is highly recommended \
- to select an empty directory and perform a fresh installation." /SD IDOK
- StrCpy $unlog_error "error"
-
- next:
- ClearErrors
- StrCmp "$PLUGINSDIR" "" 0 +2
- InitPluginsDir
-
- GetTempFileName "$1"
- FileOpen $0 "$1" w
- FileWrite $0 "${UNLOG_HEAD}$\r$\n"
- FileClose $0
- Rename "$1" "${UNLOG_TEMP}"
- Pop $1
- Pop $0
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_UPDATE_INSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- Delete "${UNINST_DAT}"
- Rename "${UNLOG_TEMP}" "${UNINST_DAT}"
- WriteUninstaller "${UNINST_EXE}"
- WriteRegStr ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}.dat" "${UNINST_DAT}"
- WriteRegStr ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory" "$INSTDIR"
-
- !verbose pop
-!macroend
-
-
-!define uninstall.log_install "!insertmacro UNINSTALL.LOG_INSTALL"
-
-!macro UNINSTALL.LOG_INSTALL FileOpenWrite FileOpenRead TargetDir
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- FileOpen $unlog_tmp_1 "${FileOpenWrite}" w
- FileOpen $unlog_tmp_2 "${FileOpenRead}" r
-
- ${Locate} "${TargetDir}" "/L=FD" "${UnLog_Install_Func_CallBack}"
-
- StrCmp $unlog_error "error" 0 +2
- ClearErrors
-
- IfErrors 0 +2
- MessageBox MB_ICONEXCLAMATION|MB_OK "Error creating ${UNINSTALL_LOG} Log." /SD IDOK
-
- FileClose $unlog_tmp_1
- FileClose $unlog_tmp_2
-
- !verbose pop
-!macroend
-
-
-!define uninstall.log_mergeID "!insertmacro UNINSTALL.LOG_MERGE"
-
-!macro UNINSTALL.LOG_MERGE UnlogPart
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- ${FileJoin} "${UNLOG_TEMP}" "${UnlogPart}" "${UNLOG_TEMP}"
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_OPEN_INSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- StrCmp $unlog_error "error" +2
- ${uninstall.log_install} "${EXCLU_LIST}" "${UNINST_DAT}" "$OUTDIR"
-
- !verbose pop
-!macroend
-
-
-!macro UNINSTALL.LOG_CLOSE_INSTALL
- !verbose push
- !verbose ${UNINST_LOG_VERBOSE}
-
- !define ID ${__LINE__}
-
- ${uninstall.log_install} "${UNLOG_PART}${ID}" "${EXCLU_LIST}" "$OUTDIR"
- ${uninstall.log_mergeID} "${UNLOG_PART}${ID}"
-
- !undef ID ${__LINE__}
-
- !verbose pop
-!macroend
-
-!endif
-
-!verbose pop
- ;_____________________________ HEADER FILE END ____________________________
-
+ ;_____________________________ HEADER FILE BEGIN ____________________________
+
+ # Advanced Uninstall Log NSIS header
+ # Version 1.0 2007-01-31
+ # By Red Wine (http://nsis.sf.net/User:Red_Wine)
+
+ # Usage: See included examples Uninstall_Log_Default_UI.nsi - Uninstall_Log_Modern_UI.nsi
+
+!verbose push
+ !verbose 3
+
+!ifndef ADVANCED_UNINSTALL.LOG_NSH
+ !define ADVANCED_UNINSTALL.LOG_NSH
+
+!ifndef INSTDIR_REG_ROOT | INSTDIR_REG_KEY
+ !error "You must properly define both INSTDIR_REG_ROOT and INSTDIR_REG_KEY"
+!endif
+
+!ifndef UNINSTALL_LOG
+ !define UNINSTALL_LOG "Uninstall"
+!endif
+
+!ifndef UNINST_LOG_VERBOSE
+ !define UNINST_LOG_VERBOSE "3"
+!endif
+
+!verbose pop
+
+!echo "Advanced Uninstall Log NSIS header v1.0 2007-01-31 by Red Wine (http://nsis.sf.net/User:Red_Wine)"
+
+!verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+!define UNINST_EXE "$INSTDIR\${UNINSTALL_LOG}.exe"
+!define UNINST_DAT "$INSTDIR\${UNINSTALL_LOG}.dat"
+!define UNLOG_PART "$PLUGINSDIR\part."
+!define UNLOG_TEMP "$PLUGINSDIR\unlog.tmp"
+!define EXCLU_LIST "$PLUGINSDIR\exclude.tmp"
+!define UNLOG_HEAD "=========== Uninstaller Log please do not edit this file ==========="
+
+ var unlog_tmp_0
+ var unlog_tmp_1
+ var unlog_tmp_2
+ var unlog_tmp_3
+ var unlog_error
+
+!include FileFunc.nsh
+!include TextFunc.nsh
+
+!insertmacro Locate
+!insertmacro un.Locate
+!insertmacro DirState
+!insertmacro un.DirState
+!insertmacro FileJoin
+!insertmacro TrimNewLines
+!insertmacro un.TrimNewLines
+
+;.............................. Uninstaller Macros ..............................
+
+!macro UNINSTALL.LOG_BEGIN_UNINSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ IfFileExists "${UNINST_DAT}" +3
+ MessageBox MB_ICONSTOP|MB_OK "${UNINST_DAT} not found, unable to perform uninstall." /SD IDOK
+ Quit
+
+ StrCmp "$PLUGINSDIR" "" 0 +2
+ InitPluginsDir
+
+ CopyFiles "${UNINST_DAT}" "${UNLOG_TEMP}"
+ FileOpen $unlog_tmp_2 "${UNLOG_TEMP}" r
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_END_UNINSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ FileClose $unlog_tmp_2
+ DeleteRegValue ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}.dat"
+ DeleteRegValue ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory"
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_UNINSTALL TargetDir
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ !ifndef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
+ !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
+ !endif
+
+ !ifdef INTERACTIVE_UNINSTALL
+ GetTempFileName $unlog_tmp_5 "$PLUGINSDIR"
+ FileOpen $unlog_tmp_4 "$unlog_tmp_5" a
+ !endif
+
+ ${PerfomUninstall} "${TargetDir}" "${UnLog_Uninstall_CallBackFunc}"
+
+ !ifdef INTERACTIVE_UNINSTALL
+ FileClose $unlog_tmp_4
+ !endif
+
+ !verbose pop
+!macroend
+
+
+!define PerfomUninstall "!insertmacro PERFORMUNINSTALL"
+
+!macro PERFORMUNINSTALL TargetDir UninstCallBackFunc
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ !define ID ${__LINE__}
+
+ ${un.Locate} "${TargetDir}" "/L=F" "${UninstCallBackFunc}"
+
+ loop_${ID}:
+
+ StrCpy $unlog_tmp_1 0
+
+ ${un.Locate} "${TargetDir}" "/L=DE" "${UninstCallBackFunc}"
+ StrCmp $unlog_tmp_1 "0" 0 loop_${ID}
+
+ ${un.DirState} "${TargetDir}" $unlog_tmp_0
+ StrCmp "$unlog_tmp_0" "0" 0 +2
+ RmDir "${TargetDir}"
+
+ IfErrors 0 +2
+ MessageBox MB_ICONEXCLAMATION|MB_OK "${UNINSTALL_LOG} Log error" /SD IDOK
+
+ !undef ID
+
+ !verbose pop
+!macroend
+
+
+!macro INTERACTIVE_UNINSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ !ifdef INTERACTIVE_UNINSTALL
+ !error "INTERACTIVE_UNINSTALL is already defined"
+ !endif
+
+ var unlog_tmp_4
+ var unlog_tmp_5
+
+ !define INTERACTIVE_UNINSTALL
+
+ !ifdef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
+ !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
+ !endif
+
+ !ifdef UnLog_Uninstall_CallBackFunc
+ !undef UnLog_Uninstall_CallBackFunc
+ !endif
+
+ !ifndef UnLog_Uninstall_CallBackFunc
+ !insertmacro UNINSTALL.LOG_UNINSTALL_INTERACTIVE
+ !define UnLog_Uninstall_CallBackFunc "un._LocateCallBack_Function_Interactive"
+ !endif
+
+ !verbose pop
+!macroend
+
+
+!macro UNATTENDED_UNINSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ !ifdef UNATTENDED_UNINSTALL
+ !error "UNATTENDED_UNINSTALL is already defined"
+ !endif
+
+ !define UNATTENDED_UNINSTALL
+
+ !ifdef INTERACTIVE_UNINSTALL & UNATTENDED_UNINSTALL
+ !error "You must insert either Interactive or Unattended Uninstall neither both, neither none."
+ !endif
+
+ !ifdef UnLog_Uninstall_CallBackFunc
+ !undef UnLog_Uninstall_CallBackFunc
+ !endif
+
+ !ifndef UnLog_Uninstall_CallBackFunc
+ !insertmacro UNINSTALL.LOG_UNINSTALL_UNATTENDED
+ !define UnLog_Uninstall_CallBackFunc "un._LocateCallBack_Function_Unattended"
+ !endif
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_UNINSTALL_UNATTENDED
+
+ Function un._LocateCallBack_Function_Unattended
+ start:
+ FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
+ ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
+ StrCmp "$unlog_tmp_3" "$R9" islog
+ IfErrors nolog
+ goto start
+
+ islog:
+ IfFileExists "$R9\*.*" isdir
+
+ isfile:
+ Delete "$R9"
+ goto end
+
+ isdir:
+ RmDir "$R9"
+ IntOp $unlog_tmp_1 $unlog_tmp_1 + 1
+ goto end
+
+ nolog:
+ ClearErrors
+ StrCmp "$R9" "${UNINST_EXE}" isfile
+ StrCmp "$R9" "${UNINST_DAT}" isfile
+
+ end:
+ FileSeek $unlog_tmp_2 0 SET
+ Push $unlog_tmp_0
+ FunctionEnd
+
+!macroend
+
+
+!macro UNINSTALL.LOG_UNINSTALL_INTERACTIVE
+
+ Function un._LocateCallBack_Function_Interactive
+ start:
+ FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
+ ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
+ StrCmp "$unlog_tmp_3" "$R9" islog
+ IfErrors nolog
+ goto start
+
+ islog:
+ IfFileExists "$R9\*.*" isdir
+
+ isfile:
+ Delete "$R9"
+ goto end
+
+ isdir:
+ RmDir "$R9"
+ IntOp $unlog_tmp_1 $unlog_tmp_1 + 1
+ goto end
+
+ nolog:
+ ClearErrors
+ FileSeek $unlog_tmp_4 0 SET
+ read:
+ FileRead $unlog_tmp_4 "$unlog_tmp_3"
+ ${un.TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
+ StrCmp "$unlog_tmp_3" "$R9" end
+ IfErrors +2
+ goto read
+ ClearErrors
+ StrCmp "$R9" "${UNINST_EXE}" isfile
+ StrCmp "$R9" "${UNINST_DAT}" isfile
+ IfFileExists "$R9\*.*" msgdir
+
+ MessageBox MB_ICONQUESTION|MB_YESNO \
+ 'Delete File "$R9"?' /SD IDNO IDYES isfile IDNO nodel
+
+ msgdir:
+ MessageBox MB_ICONQUESTION|MB_YESNO \
+ 'Delete Directory "$R9"?' /SD IDNO IDYES isdir IDNO nodel
+
+ nodel:
+ FileSeek $unlog_tmp_4 0 END
+ FileWrite $unlog_tmp_4 "$R9$\r$\n"
+
+ end:
+ FileSeek $unlog_tmp_2 0 SET
+ Push $unlog_tmp_0
+ FunctionEnd
+
+!macroend
+
+;................................. Installer Macros .................................
+
+!macro UNINSTALL.LOG_INSTALL_UNATTENDED
+
+ Function _LocateCallBack_Function_Install
+ loop:
+ FileRead $unlog_tmp_2 "$unlog_tmp_3" ${NSIS_MAX_STRLEN}
+ ${TrimNewLines} "$unlog_tmp_3" "$unlog_tmp_3"
+ IfErrors 0 +4
+ ClearErrors
+ FileSeek $unlog_tmp_2 0 SET
+ goto next
+ StrCmp "$R9" "$unlog_tmp_3" end
+ goto loop
+ next:
+ FileWrite $unlog_tmp_1 "$R9$\r$\n"
+ end:
+ Push $unlog_tmp_0
+ FunctionEnd
+
+!macroend
+
+
+!ifdef UnLog_Install_Func_CallBack
+ !undef UnLog_Install_Func_CallBack
+!endif
+
+!ifndef UnLog_Install_Func_CallBack
+ !insertmacro UNINSTALL.LOG_INSTALL_UNATTENDED
+ !define UnLog_Install_Func_CallBack "_LocateCallBack_Function_Install"
+!endif
+
+
+!macro UNINSTALL.LOG_PREPARE_INSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ Push $0
+ Push $1
+ ClearErrors
+ ReadRegStr "$0" ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory"
+ IfErrors next
+ ${DirState} "$0" $1
+ StrCmp "$1" "-1" next
+ StrCmp "$1" "0" next
+ IfFileExists "$0\${UNINSTALL_LOG}.dat" next
+ MessageBox MB_ICONEXCLAMATION|MB_OK \
+ "Previous installation detected at $0.$\n\
+ Required file ${UNINSTALL_LOG}.dat is missing.$\n$\nIt is highly recommended \
+ to select an empty directory and perform a fresh installation." /SD IDOK
+ StrCpy $unlog_error "error"
+
+ next:
+ ClearErrors
+ StrCmp "$PLUGINSDIR" "" 0 +2
+ InitPluginsDir
+
+ GetTempFileName "$1"
+ FileOpen $0 "$1" w
+ FileWrite $0 "${UNLOG_HEAD}$\r$\n"
+ FileClose $0
+ Rename "$1" "${UNLOG_TEMP}"
+ Pop $1
+ Pop $0
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_UPDATE_INSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ Delete "${UNINST_DAT}"
+ Rename "${UNLOG_TEMP}" "${UNINST_DAT}"
+ WriteUninstaller "${UNINST_EXE}"
+ WriteRegStr ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}.dat" "${UNINST_DAT}"
+ WriteRegStr ${INSTDIR_REG_ROOT} "${INSTDIR_REG_KEY}" "${UNINSTALL_LOG}Directory" "$INSTDIR"
+
+ !verbose pop
+!macroend
+
+
+!define uninstall.log_install "!insertmacro UNINSTALL.LOG_INSTALL"
+
+!macro UNINSTALL.LOG_INSTALL FileOpenWrite FileOpenRead TargetDir
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ FileOpen $unlog_tmp_1 "${FileOpenWrite}" w
+ FileOpen $unlog_tmp_2 "${FileOpenRead}" r
+
+ ${Locate} "${TargetDir}" "/L=FD" "${UnLog_Install_Func_CallBack}"
+
+ StrCmp $unlog_error "error" 0 +2
+ ClearErrors
+
+ IfErrors 0 +2
+ MessageBox MB_ICONEXCLAMATION|MB_OK "Error creating ${UNINSTALL_LOG} Log." /SD IDOK
+
+ FileClose $unlog_tmp_1
+ FileClose $unlog_tmp_2
+
+ !verbose pop
+!macroend
+
+
+!define uninstall.log_mergeID "!insertmacro UNINSTALL.LOG_MERGE"
+
+!macro UNINSTALL.LOG_MERGE UnlogPart
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ ${FileJoin} "${UNLOG_TEMP}" "${UnlogPart}" "${UNLOG_TEMP}"
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_OPEN_INSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ StrCmp $unlog_error "error" +2
+ ${uninstall.log_install} "${EXCLU_LIST}" "${UNINST_DAT}" "$OUTDIR"
+
+ !verbose pop
+!macroend
+
+
+!macro UNINSTALL.LOG_CLOSE_INSTALL
+ !verbose push
+ !verbose ${UNINST_LOG_VERBOSE}
+
+ !define ID ${__LINE__}
+
+ ${uninstall.log_install} "${UNLOG_PART}${ID}" "${EXCLU_LIST}" "$OUTDIR"
+ ${uninstall.log_mergeID} "${UNLOG_PART}${ID}"
+
+ !undef ID ${__LINE__}
+
+ !verbose pop
+!macroend
+
+!endif
+
+!verbose pop
+ ;_____________________________ HEADER FILE END ____________________________
+
diff --git a/packaging/win32/AdvUninstLog.txt b/packaging/win32/AdvUninstLog.txt
index b92c5cec7..c294c3df2 100644
--- a/packaging/win32/AdvUninstLog.txt
+++ b/packaging/win32/AdvUninstLog.txt
@@ -1,121 +1,121 @@
-Overview
-
-Advanced Uninstall Log for NSIS was born in the need to cover a specific gap.
-It's been discussed fairly enough that the File /r command is very useful
-in cases when developers want to add a huge amount of sub directories and
-files, nevertheless it has the disadvantage that such an installation should
-be uninstalled with RmDir /r which is risky and removes also data that has
-been added/created later within the installation folder.
-
-
-
-
-About Advanced Uninstall Log.
-
-Advanced Uninstall Log is a macro system provided in a NSIS header that
-is able to monitor an installation and build an uninstall log file which
-is used by the uninstaller to uninstall files/directories that have been
-added within specific installation blocks.
-
-This means that files which have been installed outside these blocks,
-or added later either by the user or application's activities, ignored
-by the uninstaller.
-
-Moreover files that might exist into the target directory prior the current
-installation, ignored as well.
-
-Advanced Uninstall Log creates an uninstall log that removes only files that
-have been installed and optionally interacts with users for every other file
-and/or directory has found in installation folder and requires permission to
-remove these files/directories.
-
-It is enhanced as well to support updates, e.g. if the installer later would
-update the installation by adding new data, the uninstaller would remove the
-new data that has been added by the installer, without bothering users about.
-
-
-
-
-Features
-
-If target installation folder exists and contains files and/or directories
-they all preserved from being uninstalled.
-
-Uninstaller removes data that has been added within specific installation
-blocks, preserving all other data that has been created/added outside of
-these installation blocks. See included examples for details.
-
-Supports unlimited updates/reinstallations.
-
-Supports two uninstaller modes. Interactive mode requires confirmation
-to remove every other file exept those files that have been installed.
-Unattended mode leaves intact every other file without bothering users.
-
-In case when uninstall log (uninstall.dat) has been removed manually instead
-of execute uninstaller, if users attempt to run the installer later, a warning
-issued that they should select a new output folder.
-
-Implements only the included with NSIS release headers FileFunc and TextFunc.
-There is no need for external plugins and headers, adds a very small overhead.
-
-
-
-
-Restrictions
-
-If uninstall log (uninstall.dat) is missing uninstaller won't execute at all.
-
-Due to file create - write procedure that is required in order to add/update
-the uninstall log (uninstall.dat), restricted users on NT based systems won't
-be able to execute the installer.
-
-
-
-
-Disadvantage
-
-Since the header does not implement anything else than the common NSIS release,
-a delay occurs while builds and reads the uninstall log because it needs to
-throw the list several times. Talking for common cases, most likely the delay
-won't be noticeable, however, in cases where the target directory isn't empty
-and contains a large amount of data which will be excluded from uninstall log,
-or added large amount of data after the installation which will be excluded also,
-the delay should be noticeable.
-
-
-
-
-Credits
-
-A very big thanks goes to kichik.
-When my idea of the Advanced Uninstall Log became an NSIS header, it was
-indeed an amateur's attempt to write a flexible and errors free NSIS header.
-Kichik dropped me a dozen of suggestions helping me to achieve my plan.
-However, his main suggestion to eliminate the mentioned above disadvantage,
-still remains untouched by me.
-
-
-
-
-License
-
-This header file is provided 'as-is', without any express or implied warranty.
-In no event will the author be held liable for any damages arising from the use
-of this header file.
-
-Permission is granted to anyone to use this header file for any purpose,
-including commercial applications, and to alter it and redistribute it freely,
-subject to the following restrictions:
-
- 1. The origin of this header file must not be misrepresented;
- you must not claim that you wrote the original header file.
- If you use this header file in a product, an acknowledgment in
- the product documentation would be appreciated but is not required.
-
- 2. Altered versions must be plainly marked as such, and must not be
- misrepresented as being the original header file.
-
- 3. This notice may not be removed or altered from any distribution.
-
-
+Overview
+
+Advanced Uninstall Log for NSIS was born in the need to cover a specific gap.
+It's been discussed fairly enough that the File /r command is very useful
+in cases when developers want to add a huge amount of sub directories and
+files, nevertheless it has the disadvantage that such an installation should
+be uninstalled with RmDir /r which is risky and removes also data that has
+been added/created later within the installation folder.
+
+
+
+
+About Advanced Uninstall Log.
+
+Advanced Uninstall Log is a macro system provided in a NSIS header that
+is able to monitor an installation and build an uninstall log file which
+is used by the uninstaller to uninstall files/directories that have been
+added within specific installation blocks.
+
+This means that files which have been installed outside these blocks,
+or added later either by the user or application's activities, ignored
+by the uninstaller.
+
+Moreover files that might exist into the target directory prior the current
+installation, ignored as well.
+
+Advanced Uninstall Log creates an uninstall log that removes only files that
+have been installed and optionally interacts with users for every other file
+and/or directory has found in installation folder and requires permission to
+remove these files/directories.
+
+It is enhanced as well to support updates, e.g. if the installer later would
+update the installation by adding new data, the uninstaller would remove the
+new data that has been added by the installer, without bothering users about.
+
+
+
+
+Features
+
+If target installation folder exists and contains files and/or directories
+they all preserved from being uninstalled.
+
+Uninstaller removes data that has been added within specific installation
+blocks, preserving all other data that has been created/added outside of
+these installation blocks. See included examples for details.
+
+Supports unlimited updates/reinstallations.
+
+Supports two uninstaller modes. Interactive mode requires confirmation
+to remove every other file exept those files that have been installed.
+Unattended mode leaves intact every other file without bothering users.
+
+In case when uninstall log (uninstall.dat) has been removed manually instead
+of execute uninstaller, if users attempt to run the installer later, a warning
+issued that they should select a new output folder.
+
+Implements only the included with NSIS release headers FileFunc and TextFunc.
+There is no need for external plugins and headers, adds a very small overhead.
+
+
+
+
+Restrictions
+
+If uninstall log (uninstall.dat) is missing uninstaller won't execute at all.
+
+Due to file create - write procedure that is required in order to add/update
+the uninstall log (uninstall.dat), restricted users on NT based systems won't
+be able to execute the installer.
+
+
+
+
+Disadvantage
+
+Since the header does not implement anything else than the common NSIS release,
+a delay occurs while builds and reads the uninstall log because it needs to
+throw the list several times. Talking for common cases, most likely the delay
+won't be noticeable, however, in cases where the target directory isn't empty
+and contains a large amount of data which will be excluded from uninstall log,
+or added large amount of data after the installation which will be excluded also,
+the delay should be noticeable.
+
+
+
+
+Credits
+
+A very big thanks goes to kichik.
+When my idea of the Advanced Uninstall Log became an NSIS header, it was
+indeed an amateur's attempt to write a flexible and errors free NSIS header.
+Kichik dropped me a dozen of suggestions helping me to achieve my plan.
+However, his main suggestion to eliminate the mentioned above disadvantage,
+still remains untouched by me.
+
+
+
+
+License
+
+This header file is provided 'as-is', without any express or implied warranty.
+In no event will the author be held liable for any damages arising from the use
+of this header file.
+
+Permission is granted to anyone to use this header file for any purpose,
+including commercial applications, and to alter it and redistribute it freely,
+subject to the following restrictions:
+
+ 1. The origin of this header file must not be misrepresented;
+ you must not claim that you wrote the original header file.
+ If you use this header file in a product, an acknowledgment in
+ the product documentation would be appreciated but is not required.
+
+ 2. Altered versions must be plainly marked as such, and must not be
+ misrepresented as being the original header file.
+
+ 3. This notice may not be removed or altered from any distribution.
+
+
eof \ No newline at end of file
diff --git a/packaging/win32/MessageBox.txt b/packaging/win32/MessageBox.txt
index dddab5553..c2aa963d6 100644
--- a/packaging/win32/MessageBox.txt
+++ b/packaging/win32/MessageBox.txt
@@ -1,186 +1,186 @@
-Customisable MessageBox Plug-In (v0.98 beta 3)
-
-[ Archive Page: http://nsis.sourceforge.net/archive/??? ]
-
---------------
-
-The Customisable MessageBox plug-in allows you to use a MessageBox in your installer which can be altered to how you want it to be. You can control:
- * the number of buttons shown
- * the text each button shows
- * a standard or customisable icon ( flexible so you can use the installer or other files )
- * a fully working 'forth' button!
-
-The plug-in uses a few tricks to allow for the messagebox functionality to be altered so that the button text can finally be altered making [ Yes | Yes to All | No | No to All ] ( and anything else you care for ) possible.
-
-Also with the changes made it is now possible to have a functional 'forth' button - yes you read correctly! When using the function just pass in four button texts and you will see the forth button - simple really :o)
-
-There is only the one function to show the messagebox so enjoy.
-
-[ As of v0.98 beta the parameters of calling the function have changed, check out usage for the revised options - thanks to n0On3 for the suggestions. ]
-
-
-Usage
------
-
-messagebox::show styles caption ( module_name, icon_id ) text but1 [ but2 but3 but4 ]
-
-styles - messagebox styles ( supports most of the windows messagebox styles )
-
-caption - the text to be used for the dialog title ( or the installer title if not specified )
-
-module_name - sets the name of the file ( usually a dll or exe file ) that contains the custom icon to be used - if 0 is passed then the installer will be used
-
-icon_id - the id of the icon group to be used for the custom icon
-
-text - the text to be shown by the messagebox
-
-but1 - specified text or name id to use ie IDYES, IDNO, etc ( there must always be at least one button )
-
-but2, but3, but4 - optional buttons which follow the same way as for but1
-
-
-When passing in options, you should use a "" pair for options you pass in to ensure the strings are correctly read. It is not necessary to do so for the predefined button texts
-e.g. "IDCANCEL" is the same as IDCANCEL.
-
-See Example.nsi for an example ;o) ( bit hacked at the moment due to testing but shows most things )
-
-
-Return Values
------
-
-To get the return value use Pop $0 immediately after the function has been used incase other functions alter the value.
-
-If there were no problems then the function will return the number of the button pressed working from the left being 'button 1'.
-i.e.
- if you have [ yes | no | abort ] and 'no' is selected then the return value will be '2'
-
-If an error happens then the messagebox will return 0.
-
-If there are no buttons passed then the function will return '-1'.
-
-
-Some More Info
-----------------
-
-If you pass an empty string for the caption ( "" ) then the installer title text will be used instead (stripping back the current section name as NSIS messageboxes do).
-If the installer is run silently then the title will be blank if setting the caption option to "" ( as NSIS messageboxes do ). This is because when the installer is silent it does not have a visible window and so will not have a window title ( had not taken this into account initially, oops - fixed from v0.98 beta 3 ).
-
-When you want to use a custom icon, setting module to '0' will look for the icon in the installer otherwise it will search the file specified.
-e.g.
- "0,103" will load the installer icon ( well in testing it does :o) )
- "shell32.dll,24" will load the help file icon from the shell32.dll ( as long as the file exists! )
-
-If the module passed is not valid then the usericon style will not be used ( you may receive a windows message informing of this ).
-
-If the icon is not valid then the messagebox will just show a blank area where the icon would be displayed assuming that the value of module is valid.
-
-If a usericon is specified then if there are any of the messagebox icon styles passed in, these will be ignored. This allows an icon to appear otherwise internal style conflicts will prevent any icon being shown.
-
-If you want to display the standard button texts then pass the following strings in for the necessary button:
-
- IDOK - Ok
- IDCANCEL - Cancel
- IDABORT - Abort
- IDRETRY - Retry
- IDIGNORE - Ignore
- IDYES - Yes
- IDNO - No
- IDHELP - Help / 4th button
- IDTRYAGAIN - Try Again
- IDCONTINUE - Continue
-
-When the function is processing the passed button texts to use, if a duplicate of the predefined texts (above) happen then the only the first instance will be allowed
-e.g.
- IDYES "ah go on if you dare" IDYES -> [ YES | ah go on if you dare ]
-
-Each button will be resized if needed to allow the text to fit correctly in the button without being clipped. If the text is still too long for the messagebox width ( limited to 80% of the screen width ) then buttons will be resized and clipping of the button text may happen again ( this will be fixed in v1.0 ).
-
-
-Final Notes
--------
-
-I have no idea how the code will work with international text (since i just use plain text in the code) so if you try it in a multilanguage setup then let me know how it reacts or if there are any issues with the function's display.
-
-The predefined button texts are hard coded and cannot be altered. To alter the default texts involves passing in the language button text as a custom button text.
-
-The button resizing code is not complete at the moment ( as can be clearly seen from the first messagebox ) when it detects that the width of the messagebox is at the 80% screen width. Issues are that the buttons are not correctly resized to ensure that they appear correctly ( as is the case with the second messagebox ). This is more down to fiddling with the button widths after the initial processing but will be fixed soon :o)
-
-
-Credits
--------
-
-Coded by Darren Owen, aka DrO (Sept 2003)
-
-n0On3 - Idea request and helpful feedback ( the simplified function use over previous versions :o) )
-
-A plugin from me to you :o)
-
-
-Version History
--------
-
-v0.1
-* Initial release of the function
-* Basic support to show that the button text can be altered on the messagebox
-* Inital support for controlling the number of buttons shown
-
-v0.5
-* Setting of text of only the buttons wanted ( "/but? blah" )
-* Now if a string is not passed then the text will not be set (broken in the v0.1 release)
-* Altered a lot of internal workings to allow for more customising of the MessageBox
-* Better support for the number of buttons to show
-* The functional '4th' button - making use of the 'Help' button to act as a real button
-* Fixed a number of crash issues due to buffer sizes and a few other bugs, etc
-
-v0.8
-* A lot of changes made :o)
-* Improved internal handling so that now button text is set correctly either when the number of buttons is set or user styles are set so now "/but2 blah" will always set the second buttons text and not just a few cases as beforehand
-* Altered the order of the parameters from earlier versions to make some internals easier to do :o)
-* The 4th / Help button will now close the MessageBox in ALL cases - would not close correctly if there was not a 'cancel' button in earlier versions
-* Buffers are now allocated to the NSIS buffer sizes passed to the dll on use for better compatibility between dll and installer
-* When the button numbers are set, the function will map the returned value now to the button selected instead of the normal wndows defined return value
-* some other bits and bobs that i've forgotten on the way
-
-v0.9
-* Added in support for displaying custom icons on the messagebox ( along with standard icons which can be shown ) either in the installer or from other files
-* Altered the example script to show off some more bits of what it can do
-
-v0.95 beta
-* Added in support for resizing of buttons based on the text set into the button ( use the /trim before the text to be set )
-* Messagebox is now limited to approximately 80% of the screen size ( as the messagebox normally does )
-* The resizing of button texts will also update the width of the text width to ensure it keeps to the size of the messagebox
-* Support is not complete for /trim ( still need to update the graduating of the width increment )
-* When the 80% width is reached, currently buttons will disappear off the messagebox ( handling for a double height button will come to cope with this soon )
-* Altered the example script to show off some more bits of what it can do
-
-v0.98 beta
-* Removed the passing in of a hwnd parameter - is always owned by the installer
-* Altered the custom icon option to be a single parameter now in the form 'module,id' where module can be 0 to use the installer
-* All return values are now mapped to the button number pressed ie 1,2,etc
-* Now the number of buttons to show is based on the button string texts passed in to the function :o)
-* Altered the order of parameters to work in a top to bottom order with respect to the messagebox layout and to match closer to the NSIS setup
-[ a good suggestion from n0On3 - nice ]
-- now goes: style title usericon text but1 [ but2 but3 but4 ]
-* Altered the button texts to be set in the order passed and will also convert the default ids too! eg IDYES -> "Yes", IDIGNORE -> "Ignore"
-* Fixed the graduating of the button trim feature to appear 'natural'
-[ adds approxiamately 3 character widths either side when the text won't fit fully in the button ]
-* Fixed a few bugs in the code introduced in the changes made
-* Support for MB_DEFBUTTON? is broken when a button has to be resized ( will fix this soon - already worked out how to but not why this happens )
-
-v0.98 beta 2
-* Fixed the MB_DEFBUTTON? issue ( needed to prevent the wm_active message being handled )
-* Verified the installer will show icons correctly if the installer is run silently ( no code changes were made )
-* Added in checking of the defined buttons to ensure that duplicates are not allowed (only the first occurrance is allowed)
-* Checked that all strings are verified for having data before being used
-* A few code tidy-ups introduced to the code
-* Typo fix in the example
-* Added in stripping out of the icon definitions if a user icon is specified (otherwise no icon will appear!)
-* Updated the readme file to reflect the changes made to the plug-in's functionality since v0.98 beta and to clarify things in better detail now ( i hope )
-* Added in a reference to the archive page for the plugin ( will upload majority of this file to the archive )
-* All internal buffers are now set to the buffer size passed into the plugin when it is called and altered how they are referenced
-* Fixed how the module string is cleared, should fix a potential crash issue i hope
-* Partially fixed the resizing of the text area when using long button strings to correctly limit out when the 80% limit is reached ( fine when now icon is used at the moment )
-* Added a silent installer option to the example script, just !define SILENT to get the silent version (should show that the function works fine either in a normal or silent installer)
-
-v0.98 beta 3
+Customisable MessageBox Plug-In (v0.98 beta 3)
+
+[ Archive Page: http://nsis.sourceforge.net/archive/??? ]
+
+--------------
+
+The Customisable MessageBox plug-in allows you to use a MessageBox in your installer which can be altered to how you want it to be. You can control:
+ * the number of buttons shown
+ * the text each button shows
+ * a standard or customisable icon ( flexible so you can use the installer or other files )
+ * a fully working 'forth' button!
+
+The plug-in uses a few tricks to allow for the messagebox functionality to be altered so that the button text can finally be altered making [ Yes | Yes to All | No | No to All ] ( and anything else you care for ) possible.
+
+Also with the changes made it is now possible to have a functional 'forth' button - yes you read correctly! When using the function just pass in four button texts and you will see the forth button - simple really :o)
+
+There is only the one function to show the messagebox so enjoy.
+
+[ As of v0.98 beta the parameters of calling the function have changed, check out usage for the revised options - thanks to n0On3 for the suggestions. ]
+
+
+Usage
+-----
+
+messagebox::show styles caption ( module_name, icon_id ) text but1 [ but2 but3 but4 ]
+
+styles - messagebox styles ( supports most of the windows messagebox styles )
+
+caption - the text to be used for the dialog title ( or the installer title if not specified )
+
+module_name - sets the name of the file ( usually a dll or exe file ) that contains the custom icon to be used - if 0 is passed then the installer will be used
+
+icon_id - the id of the icon group to be used for the custom icon
+
+text - the text to be shown by the messagebox
+
+but1 - specified text or name id to use ie IDYES, IDNO, etc ( there must always be at least one button )
+
+but2, but3, but4 - optional buttons which follow the same way as for but1
+
+
+When passing in options, you should use a "" pair for options you pass in to ensure the strings are correctly read. It is not necessary to do so for the predefined button texts
+e.g. "IDCANCEL" is the same as IDCANCEL.
+
+See Example.nsi for an example ;o) ( bit hacked at the moment due to testing but shows most things )
+
+
+Return Values
+-----
+
+To get the return value use Pop $0 immediately after the function has been used incase other functions alter the value.
+
+If there were no problems then the function will return the number of the button pressed working from the left being 'button 1'.
+i.e.
+ if you have [ yes | no | abort ] and 'no' is selected then the return value will be '2'
+
+If an error happens then the messagebox will return 0.
+
+If there are no buttons passed then the function will return '-1'.
+
+
+Some More Info
+----------------
+
+If you pass an empty string for the caption ( "" ) then the installer title text will be used instead (stripping back the current section name as NSIS messageboxes do).
+If the installer is run silently then the title will be blank if setting the caption option to "" ( as NSIS messageboxes do ). This is because when the installer is silent it does not have a visible window and so will not have a window title ( had not taken this into account initially, oops - fixed from v0.98 beta 3 ).
+
+When you want to use a custom icon, setting module to '0' will look for the icon in the installer otherwise it will search the file specified.
+e.g.
+ "0,103" will load the installer icon ( well in testing it does :o) )
+ "shell32.dll,24" will load the help file icon from the shell32.dll ( as long as the file exists! )
+
+If the module passed is not valid then the usericon style will not be used ( you may receive a windows message informing of this ).
+
+If the icon is not valid then the messagebox will just show a blank area where the icon would be displayed assuming that the value of module is valid.
+
+If a usericon is specified then if there are any of the messagebox icon styles passed in, these will be ignored. This allows an icon to appear otherwise internal style conflicts will prevent any icon being shown.
+
+If you want to display the standard button texts then pass the following strings in for the necessary button:
+
+ IDOK - Ok
+ IDCANCEL - Cancel
+ IDABORT - Abort
+ IDRETRY - Retry
+ IDIGNORE - Ignore
+ IDYES - Yes
+ IDNO - No
+ IDHELP - Help / 4th button
+ IDTRYAGAIN - Try Again
+ IDCONTINUE - Continue
+
+When the function is processing the passed button texts to use, if a duplicate of the predefined texts (above) happen then the only the first instance will be allowed
+e.g.
+ IDYES "ah go on if you dare" IDYES -> [ YES | ah go on if you dare ]
+
+Each button will be resized if needed to allow the text to fit correctly in the button without being clipped. If the text is still too long for the messagebox width ( limited to 80% of the screen width ) then buttons will be resized and clipping of the button text may happen again ( this will be fixed in v1.0 ).
+
+
+Final Notes
+-------
+
+I have no idea how the code will work with international text (since i just use plain text in the code) so if you try it in a multilanguage setup then let me know how it reacts or if there are any issues with the function's display.
+
+The predefined button texts are hard coded and cannot be altered. To alter the default texts involves passing in the language button text as a custom button text.
+
+The button resizing code is not complete at the moment ( as can be clearly seen from the first messagebox ) when it detects that the width of the messagebox is at the 80% screen width. Issues are that the buttons are not correctly resized to ensure that they appear correctly ( as is the case with the second messagebox ). This is more down to fiddling with the button widths after the initial processing but will be fixed soon :o)
+
+
+Credits
+-------
+
+Coded by Darren Owen, aka DrO (Sept 2003)
+
+n0On3 - Idea request and helpful feedback ( the simplified function use over previous versions :o) )
+
+A plugin from me to you :o)
+
+
+Version History
+-------
+
+v0.1
+* Initial release of the function
+* Basic support to show that the button text can be altered on the messagebox
+* Inital support for controlling the number of buttons shown
+
+v0.5
+* Setting of text of only the buttons wanted ( "/but? blah" )
+* Now if a string is not passed then the text will not be set (broken in the v0.1 release)
+* Altered a lot of internal workings to allow for more customising of the MessageBox
+* Better support for the number of buttons to show
+* The functional '4th' button - making use of the 'Help' button to act as a real button
+* Fixed a number of crash issues due to buffer sizes and a few other bugs, etc
+
+v0.8
+* A lot of changes made :o)
+* Improved internal handling so that now button text is set correctly either when the number of buttons is set or user styles are set so now "/but2 blah" will always set the second buttons text and not just a few cases as beforehand
+* Altered the order of the parameters from earlier versions to make some internals easier to do :o)
+* The 4th / Help button will now close the MessageBox in ALL cases - would not close correctly if there was not a 'cancel' button in earlier versions
+* Buffers are now allocated to the NSIS buffer sizes passed to the dll on use for better compatibility between dll and installer
+* When the button numbers are set, the function will map the returned value now to the button selected instead of the normal wndows defined return value
+* some other bits and bobs that i've forgotten on the way
+
+v0.9
+* Added in support for displaying custom icons on the messagebox ( along with standard icons which can be shown ) either in the installer or from other files
+* Altered the example script to show off some more bits of what it can do
+
+v0.95 beta
+* Added in support for resizing of buttons based on the text set into the button ( use the /trim before the text to be set )
+* Messagebox is now limited to approximately 80% of the screen size ( as the messagebox normally does )
+* The resizing of button texts will also update the width of the text width to ensure it keeps to the size of the messagebox
+* Support is not complete for /trim ( still need to update the graduating of the width increment )
+* When the 80% width is reached, currently buttons will disappear off the messagebox ( handling for a double height button will come to cope with this soon )
+* Altered the example script to show off some more bits of what it can do
+
+v0.98 beta
+* Removed the passing in of a hwnd parameter - is always owned by the installer
+* Altered the custom icon option to be a single parameter now in the form 'module,id' where module can be 0 to use the installer
+* All return values are now mapped to the button number pressed ie 1,2,etc
+* Now the number of buttons to show is based on the button string texts passed in to the function :o)
+* Altered the order of parameters to work in a top to bottom order with respect to the messagebox layout and to match closer to the NSIS setup
+[ a good suggestion from n0On3 - nice ]
+- now goes: style title usericon text but1 [ but2 but3 but4 ]
+* Altered the button texts to be set in the order passed and will also convert the default ids too! eg IDYES -> "Yes", IDIGNORE -> "Ignore"
+* Fixed the graduating of the button trim feature to appear 'natural'
+[ adds approxiamately 3 character widths either side when the text won't fit fully in the button ]
+* Fixed a few bugs in the code introduced in the changes made
+* Support for MB_DEFBUTTON? is broken when a button has to be resized ( will fix this soon - already worked out how to but not why this happens )
+
+v0.98 beta 2
+* Fixed the MB_DEFBUTTON? issue ( needed to prevent the wm_active message being handled )
+* Verified the installer will show icons correctly if the installer is run silently ( no code changes were made )
+* Added in checking of the defined buttons to ensure that duplicates are not allowed (only the first occurrance is allowed)
+* Checked that all strings are verified for having data before being used
+* A few code tidy-ups introduced to the code
+* Typo fix in the example
+* Added in stripping out of the icon definitions if a user icon is specified (otherwise no icon will appear!)
+* Updated the readme file to reflect the changes made to the plug-in's functionality since v0.98 beta and to clarify things in better detail now ( i hope )
+* Added in a reference to the archive page for the plugin ( will upload majority of this file to the archive )
+* All internal buffers are now set to the buffer size passed into the plugin when it is called and altered how they are referenced
+* Fixed how the module string is cleared, should fix a potential crash issue i hope
+* Partially fixed the resizing of the text area when using long button strings to correctly limit out when the 80% limit is reached ( fine when now icon is used at the moment )
+* Added a silent installer option to the example script, just !define SILENT to get the silent version (should show that the function works fine either in a normal or silent installer)
+
+v0.98 beta 3
* Fixed a crash when a silent installer is run ( pointed out by n0On3 ) - not checking the string length when getting the installer title if ""is the pased caption value, doh! \ No newline at end of file
diff --git a/packaging/win32/RequireLatestNSIS.nsh b/packaging/win32/RequireLatestNSIS.nsh
index 29552ac02..f859ec7ad 100644
--- a/packaging/win32/RequireLatestNSIS.nsh
+++ b/packaging/win32/RequireLatestNSIS.nsh
@@ -1,9 +1,9 @@
-!if ${NSIS_VERSION} = v2.45
- !error "There is a bug in !searchparse which makes this script not compile in NSIS 2.45. Please upgrade to NSIS 2.46 or later and try again."
-!else
- !echo "(If you get a compile error with !searchparse, please upgrade to NSIS 2.46 or later and try again.)"
-!endif
-!searchparse ${NSIS_VERSION} "v" V
-!if ${V} < 2.46
- !error "You only have NSIS ${V}, but NSIS 2.46 or later is required for proper Windows 7 support. Please upgrade to NSIS 2.46 or later and try again."
-!endif
+!if ${NSIS_VERSION} = v2.45
+ !error "There is a bug in !searchparse which makes this script not compile in NSIS 2.45. Please upgrade to NSIS 2.46 or later and try again."
+!else
+ !echo "(If you get a compile error with !searchparse, please upgrade to NSIS 2.46 or later and try again.)"
+!endif
+!searchparse ${NSIS_VERSION} "v" V
+!if ${V} < 2.46
+ !error "You only have NSIS ${V}, but NSIS 2.46 or later is required for proper Windows 7 support. Please upgrade to NSIS 2.46 or later and try again."
+!endif
diff --git a/packaging/win32/VersionCompleteXXXX.nsh b/packaging/win32/VersionCompleteXXXX.nsh
index e2ff740e4..e4c6961cd 100644
--- a/packaging/win32/VersionCompleteXXXX.nsh
+++ b/packaging/win32/VersionCompleteXXXX.nsh
@@ -1,47 +1,47 @@
-; See http://nsis.sourceforge.net/VersionCompleteXXXX for documentation
-!macro VersionCompleteXXXN _INPUT_VALUE _OUTPUT_SYMBOL _REVISION
- !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
- !if `${_VERSION_1}` == ``
- !undef _VERSION_1
- !define _VERSION_1 0
- !endif
- !if `${_VERSION_2}` == ``
- !undef _VERSION_2
- !define _VERSION_2 0
- !endif
- !if `${_VERSION_3}` == ``
- !undef _VERSION_3
- !define _VERSION_3 0
- !endif
- !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_REVISION}
- !undef _VERSION_1
- !undef _VERSION_2
- !undef _VERSION_3
- !undef _VERSION_4
-!macroend
-!define VersionCompleteXXXN `!insertmacro VersionCompleteXXXN`
-!macro VersionCompleteXXXX _INPUT_VALUE _OUTPUT_SYMBOL
- !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
- !if `${_VERSION_1}` == ``
- !undef _VERSION_1
- !define _VERSION_1 0
- !endif
- !if `${_VERSION_2}` == ``
- !undef _VERSION_2
- !define _VERSION_2 0
- !endif
- !if `${_VERSION_3}` == ``
- !undef _VERSION_3
- !define _VERSION_3 0
- !endif
- !if `${_VERSION_4}` == ``
- !undef _VERSION_4
- !define _VERSION_4 0
- !endif
- !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_VERSION_4}
- !undef _VERSION_1
- !undef _VERSION_2
- !undef _VERSION_3
- !undef _VERSION_4
-!macroend
-!define VersionCompleteXXXX `!insertmacro VersionCompleteXXXX`
+; See http://nsis.sourceforge.net/VersionCompleteXXXX for documentation
+!macro VersionCompleteXXXN _INPUT_VALUE _OUTPUT_SYMBOL _REVISION
+ !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
+ !if `${_VERSION_1}` == ``
+ !undef _VERSION_1
+ !define _VERSION_1 0
+ !endif
+ !if `${_VERSION_2}` == ``
+ !undef _VERSION_2
+ !define _VERSION_2 0
+ !endif
+ !if `${_VERSION_3}` == ``
+ !undef _VERSION_3
+ !define _VERSION_3 0
+ !endif
+ !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_REVISION}
+ !undef _VERSION_1
+ !undef _VERSION_2
+ !undef _VERSION_3
+ !undef _VERSION_4
+!macroend
+!define VersionCompleteXXXN `!insertmacro VersionCompleteXXXN`
+!macro VersionCompleteXXXX _INPUT_VALUE _OUTPUT_SYMBOL
+ !searchparse /noerrors ${_INPUT_VALUE} "" _VERSION_1 "." _VERSION_2 "." _VERSION_3 "." _VERSION_4
+ !if `${_VERSION_1}` == ``
+ !undef _VERSION_1
+ !define _VERSION_1 0
+ !endif
+ !if `${_VERSION_2}` == ``
+ !undef _VERSION_2
+ !define _VERSION_2 0
+ !endif
+ !if `${_VERSION_3}` == ``
+ !undef _VERSION_3
+ !define _VERSION_3 0
+ !endif
+ !if `${_VERSION_4}` == ``
+ !undef _VERSION_4
+ !define _VERSION_4 0
+ !endif
+ !define ${_OUTPUT_SYMBOL} ${_VERSION_1}.${_VERSION_2}.${_VERSION_3}.${_VERSION_4}
+ !undef _VERSION_1
+ !undef _VERSION_2
+ !undef _VERSION_3
+ !undef _VERSION_4
+!macroend
+!define VersionCompleteXXXX `!insertmacro VersionCompleteXXXX`
diff --git a/packaging/win32/ifexist.nsh b/packaging/win32/ifexist.nsh
index 80fd40aaa..f14236c2e 100644
--- a/packaging/win32/ifexist.nsh
+++ b/packaging/win32/ifexist.nsh
@@ -1,21 +1,21 @@
-; See http://nsis.sourceforge.net/Check_if_a_file_exists_at_compile_time for documentation
-!macro !ifexist _FILE_NAME
- !tempfile _TEMPFILE
- !system `if exist "${_FILE_NAME}" echo !define _FILE_EXISTS > "${_TEMPFILE}"`
- !include `${_TEMPFILE}`
- !delfile `${_TEMPFILE}`
- !undef _TEMPFILE
- !ifdef _FILE_EXISTS
- !undef _FILE_EXISTS
-!macroend
-!define !ifexist "!insertmacro !ifexist"
-!macro !ifnexist _FILE_NAME
- !tempfile _TEMPFILE
- !system `if not exist "${_FILE_NAME}" echo !define _FILE_EXISTS > "${_TEMPFILE}"`
- !include `${_TEMPFILE}`
- !delfile `${_TEMPFILE}`
- !undef _TEMPFILE
- !ifdef _FILE_EXISTS
- !undef _FILE_EXISTS
-!macroend
-!define !ifnexist "!insertmacro !ifnexist"
+; See http://nsis.sourceforge.net/Check_if_a_file_exists_at_compile_time for documentation
+!macro !ifexist _FILE_NAME
+ !tempfile _TEMPFILE
+ !system `if exist "${_FILE_NAME}" echo !define _FILE_EXISTS > "${_TEMPFILE}"`
+ !include `${_TEMPFILE}`
+ !delfile `${_TEMPFILE}`
+ !undef _TEMPFILE
+ !ifdef _FILE_EXISTS
+ !undef _FILE_EXISTS
+!macroend
+!define !ifexist "!insertmacro !ifexist"
+!macro !ifnexist _FILE_NAME
+ !tempfile _TEMPFILE
+ !system `if not exist "${_FILE_NAME}" echo !define _FILE_EXISTS > "${_TEMPFILE}"`
+ !include `${_TEMPFILE}`
+ !delfile `${_TEMPFILE}`
+ !undef _TEMPFILE
+ !ifdef _FILE_EXISTS
+ !undef _FILE_EXISTS
+!macroend
+!define !ifnexist "!insertmacro !ifnexist"
diff --git a/packaging/win32/languages/Japanese.nsh b/packaging/win32/languages/Japanese.nsh
index b8c61f22a..c8e949aa0 100644
--- a/packaging/win32/languages/Japanese.nsh
+++ b/packaging/win32/languages/Japanese.nsh
@@ -1,113 +1,113 @@
-;Language: Japanese (1041, CP932)
-;By Kenji Inoue <kenz@oct.zaq.ne.jp>, Masato Hashimoto <cabezon.hashimoto@gmail.com>
-${LangFileString} CaptionDescription "Open Source Scalable Vector Graphics Editor"
-${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ‚Í GNU General Public License (GPL) ‚̉º‚ÅƒŠƒŠ[ƒX‚³‚ê‚Ü‚·BŽQl‚É“–ŠYƒ‰ƒCƒZƒ“ƒX‚ð‚±‚±‚É•\ަ‚µ‚Ü‚·B$_CLICK"
-${LangFileString} DIFFERENT_USER "Inkscape ‚̓†[ƒU $0 ‚É‚æ‚Á‚ăCƒ“ƒXƒg[ƒ‹‚³‚ê‚Ä‚¢‚Ü‚·B$\r$\n‚±‚̂܂ܑ±‚¯‚邯³í‚ÉŠ®—¹‚µ‚È‚¢‚©‚à‚µ‚ê‚Ü‚¹‚ñB$\r$\n$0 ‚ŃƒOƒCƒ“‚µ‚Ä‚©‚çÄ“xŽŽ‚݂Ă­‚¾‚³‚¢B"
-${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ‚ÍŠù‚ɃCƒ“ƒXƒg[ƒ‹‚³‚ê‚Ä‚¢‚Ü‚·B$\n$(^Name) ‚ðƒCƒ“ƒXƒg[ƒ‹‚·‚é‘O‚ɈȑO‚̃o[ƒWƒ‡ƒ“‚ð휂µ‚Ü‚·‚©?"
-${LangFileString} OK_CANCEL_DESC "$\n$\nOK ‚ð‰Ÿ‚µ‚ÄŒp‘±‚·‚é‚© CANCEL ‚ð‰Ÿ‚µ‚Ä’†Ž~‚µ‚Ä‚­‚¾‚³‚¢B"
-${LangFileString} NO_ADMIN "ŠÇ—ŽÒŒ ŒÀ‚ª‚ ‚è‚Ü‚¹‚ñB$\r$\n‚·‚ׂẴ†[ƒU‚ɑ΂·‚é Inkscape ‚̃Cƒ“ƒXƒg[ƒ‹‚ͳí‚ÉŠ®—¹‚µ‚È‚¢‚©‚à‚µ‚ê‚Ü‚¹‚ñB$\r$\n'‚·‚ׂẴ†[ƒU' ƒIƒvƒVƒ‡ƒ“‚̃`ƒFƒbƒNƒ}[ƒN‚ðŠO‚µ‚Ä‚­‚¾‚³‚¢B"
-${LangFileString} NOT_SUPPORTED "Inkscape ‚Í Windows 95/98/ME ã‚ł͓®ì‚µ‚Ü‚¹‚ñ!$\r$\nÚ‚µ‚­‚̓IƒtƒBƒVƒƒƒ‹ƒEƒFƒuƒTƒCƒg‚ð‚²——‚­‚¾‚³‚¢B"
-${LangFileString} Full "Š®‘S"
-${LangFileString} Optimal "œK"
-${LangFileString} Minimal "Ŭ"
-${LangFileString} Core "Inkscape SVG Editor (•K{)"
-${LangFileString} CoreDesc "Inkscape ‚̃RƒAƒtƒ@ƒCƒ‹‚ÆDLL"
-${LangFileString} GTKFiles "GTK+ ƒ‰ƒ“ƒ^ƒCƒ€ŠÂ‹« (•K{)"
-${LangFileString} GTKFilesDesc "ƒ}ƒ‹ƒ`ƒvƒ‰ƒbƒgƒtƒH[ƒ€‘Ήž GUI ƒc[ƒ‹ƒLƒbƒg (Inkscape ‚ªŽg—p)"
-${LangFileString} Shortcuts "ƒVƒ‡[ƒgƒJƒbƒg"
-${LangFileString} ShortcutsDesc "Inkscape ‚ðŠJŽn‚·‚邽‚߂̃Vƒ‡[ƒgƒJƒbƒg"
-${LangFileString} Alluser "‚·‚ׂẴ†[ƒU"
-${LangFileString} AlluserDesc "‚±‚̃Rƒ“ƒsƒ…[ƒ^‚ðŽg‚¤‚·‚ׂĂÌl‚É‚±‚̃AƒvƒŠƒP[ƒVƒ‡ƒ“‚ðƒCƒ“ƒXƒg[ƒ‹ (‚·‚ׂẴ†[ƒU)"
-${LangFileString} Desktop "ƒfƒXƒNƒgƒbƒv"
-${LangFileString} DesktopDesc "Inkscape ‚ւ̃Vƒ‡[ƒgƒJƒbƒg‚ðƒfƒXƒNƒgƒbƒv‚Éì¬"
-${LangFileString} Startmenu "ƒXƒ^[ƒgƒƒjƒ…["
-${LangFileString} StartmenuDesc "ƒXƒ^[ƒgƒƒjƒ…[‚É Inkscape ‚Ì€–Ú‚ðì¬"
-${LangFileString} Quicklaunch "ƒNƒCƒbƒN‹N“®"
-${LangFileString} QuicklaunchDesc "Inkscape ‚ւ̃Vƒ‡[ƒgƒJƒbƒg‚ðƒNƒCƒbƒN‹N“®ƒc[ƒ‹ƒo[‚Éì¬"
-${LangFileString} SVGWriter "SVG ƒtƒ@ƒCƒ‹‚ð Inkscape ‚ÅŠJ‚­"
-${LangFileString} SVGWriterDesc "SVG ƒtƒ@ƒCƒ‹‚Ì•W€ƒGƒfƒBƒ^‚É Inkscape ‚ðÝ’è"
-${LangFileString} ContextMenu "ƒRƒ“ƒeƒLƒXƒgƒƒjƒ…["
-${LangFileString} ContextMenuDesc "SVG ƒtƒ@ƒCƒ‹‚̃Rƒ“ƒeƒLƒXƒgƒƒjƒ…[‚É Inkscape ‚ð’ljÁ"
-${LangFileString} DeletePrefs "ŒÂlÝ’è‚ðíœ"
-${LangFileString} DeletePrefsDesc "ˆÈ‘O‚̃Cƒ“ƒXƒg[ƒ‹Žž‚©‚çˆø‚«Œp‚¢‚¾ŒÂlÝ’è‚ðíœ"
-${LangFileString} Addfiles "’ljÁƒtƒ@ƒCƒ‹"
-${LangFileString} AddfilesDesc "’ljÁƒtƒ@ƒCƒ‹"
-${LangFileString} Examples "ƒTƒ“ƒvƒ‹ƒtƒ@ƒCƒ‹"
-${LangFileString} ExamplesDesc "Inkscape ‚̃Tƒ“ƒvƒ‹ƒtƒ@ƒCƒ‹"
-${LangFileString} Tutorials "ƒ`ƒ…[ƒgƒŠƒAƒ‹"
-${LangFileString} TutorialsDesc "Inkscape ‚̃`ƒ…[ƒgƒŠƒAƒ‹"
-${LangFileString} Languages "Œ¾Œê"
-${LangFileString} LanguagesDesc "Inkscape ‚Ì‚³‚Ü‚´‚܂Ȍ¾Œêƒtƒ@ƒCƒ‹‚ðƒCƒ“ƒXƒg[ƒ‹"
-${LangFileString} lng_am "ƒAƒ€ƒnƒ‰Œê"
-${LangFileString} lng_ar "ƒAƒ‰ƒrƒAŒê"
-${LangFileString} lng_az "ƒAƒ[ƒ‹ƒoƒCƒWƒƒƒ“Œê"
-${LangFileString} lng_be "ƒxƒ‰ƒ‹[ƒVŒê"
-${LangFileString} lng_bg "ƒuƒ‹ƒKƒŠƒAŒê"
-${LangFileString} lng_bn "ƒxƒ“ƒKƒ‹Œê"
-${LangFileString} lng_br "ƒuƒ‹ƒgƒ“Œê"
-${LangFileString} lng_ca "ƒJƒ^ƒƒjƒAŒê"
-${LangFileString} lng_ca@valencia "ƒoƒŒƒ“ƒVƒAŒê"
-${LangFileString} lng_cs "ƒ`ƒFƒRŒê"
-${LangFileString} lng_da "ƒfƒ“ƒ}[ƒNŒê"
-${LangFileString} lng_de "ƒhƒCƒcŒê"
-${LangFileString} lng_dz "ƒ]ƒ“ƒJŒê"
-${LangFileString} lng_el "ƒMƒŠƒVƒƒŒê"
-${LangFileString} lng_en "‰pŒê"
-${LangFileString} lng_en_AU "‰pŒê (ƒI[ƒXƒgƒ‰ƒŠƒA)"
-${LangFileString} lng_en_CA "‰pŒê (ƒJƒiƒ_)"
-${LangFileString} lng_en_GB "‰pŒê (‰p‘)"
-${LangFileString} lng_en_US@piglatin "ƒsƒbƒOEƒ‰ƒeƒ“Œê"
-${LangFileString} lng_eo "ƒGƒXƒyƒ‰ƒ“ƒgŒê"
-${LangFileString} lng_es "ƒXƒyƒCƒ“Œê"
-${LangFileString} lng_es_MX "ƒXƒyƒCƒ“Œê (ƒƒLƒVƒR)"
-${LangFileString} lng_et "ƒGƒXƒgƒjƒAŒê"
-${LangFileString} lng_eu "ƒoƒXƒNŒê"
-${LangFileString} lng_fa "ƒtƒ@ƒ‹ƒVŒê"
-${LangFileString} lng_fi "ƒtƒBƒ“ƒ‰ƒ“ƒhŒê"
-${LangFileString} lng_fr "ƒtƒ‰ƒ“ƒXŒê"
-${LangFileString} lng_ga "ƒAƒCƒ‹ƒ‰ƒ“ƒhŒê"
-${LangFileString} lng_gl "ƒKƒŠƒVƒAŒê"
-${LangFileString} lng_he "ƒwƒuƒ‰ƒCŒê"
-${LangFileString} lng_hr "ƒNƒƒAƒ`ƒAŒê"
-${LangFileString} lng_hu "ƒnƒ“ƒKƒŠ[Œê"
-${LangFileString} lng_id "ƒCƒ“ƒhƒlƒVƒAŒê"
-${LangFileString} lng_it "ƒCƒ^ƒŠƒAŒê"
-${LangFileString} lng_ja "“ú–{Œê"
-${LangFileString} lng_km "ƒNƒ[ƒ‹Œê"
-${LangFileString} lng_ko "ŠØ‘Œê"
-${LangFileString} lng_lt "ƒŠƒgƒAƒjƒAŒê"
-${LangFileString} lng_mk "ƒ}ƒPƒhƒjƒAŒê"
-${LangFileString} lng_mn "ƒ‚ƒ“ƒSƒ‹Œê"
-${LangFileString} lng_ne "ƒlƒp[ƒ‹Œê"
-${LangFileString} lng_nb "ƒmƒ‹ƒEƒF[Œêƒu[ƒNƒ‚[ƒ‹"
-${LangFileString} lng_nl "ƒIƒ‰ƒ“ƒ_Œê"
-${LangFileString} lng_nn "ƒmƒ‹ƒEƒF[Œêƒj[ƒmƒVƒ…ƒN"
-${LangFileString} lng_pa "ƒpƒ“ƒWƒƒƒuŒê"
-${LangFileString} lng_pl "ƒ|[ƒ‰ƒ“ƒhŒê"
-${LangFileString} lng_pt "ƒ|ƒ‹ƒgƒKƒ‹Œê"
-${LangFileString} lng_pt_BR "ƒ|ƒ‹ƒgƒKƒ‹Œê (ƒuƒ‰ƒWƒ‹)"
-${LangFileString} lng_ro "ƒ‹[ƒ}ƒjƒAŒê"
-${LangFileString} lng_ru "ƒƒVƒAŒê"
-${LangFileString} lng_rw "ƒLƒjƒ„ƒ‹ƒƒ“ƒ_Œê"
-${LangFileString} lng_sk "ƒXƒƒoƒLƒAŒê"
-${LangFileString} lng_sl "ƒXƒƒxƒjƒAŒê"
-${LangFileString} lng_sq "ƒAƒ‹ƒoƒjƒAŒê"
-${LangFileString} lng_sr "ƒZƒ‹ƒrƒAŒê"
-${LangFileString} lng_sr@latin "ƒZƒ‹ƒrƒAŒêƒ‰ƒeƒ“•¶Žš"
-${LangFileString} lng_sv "ƒXƒEƒF[ƒfƒ“Œê"
-${LangFileString} lng_te_IN "ƒeƒ‹ƒOŒê"
-${LangFileString} lng_th "ƒ^ƒCŒê"
-${LangFileString} lng_tr "ƒgƒ‹ƒRŒê"
-${LangFileString} lng_uk "ƒEƒNƒ‰ƒCƒiŒê"
-${LangFileString} lng_vi "ƒxƒgƒiƒ€Œê"
-${LangFileString} lng_zh_CN "’†‘Œê (ŠÈ‘ÌŽš)"
-${LangFileString} lng_zh_TW "’†‘Œê (”ɑ̎š)"
-${LangFileString} UInstOpt "ƒAƒ“ƒCƒ“ƒXƒg[ƒ‹ƒIƒvƒVƒ‡ƒ“"
-${LangFileString} UInstOpt1 "•K—v‚Å‚ ‚ê‚Έȉº‚̃IƒvƒVƒ‡ƒ“‚ð‘I‘ð‚µ‚Ä‚­‚¾‚³‚¢"
-${LangFileString} PurgePrefs "ŒÂlÝ’è‚ðŽc‚·"
-${LangFileString} UninstallLogNotFound "$INSTDIR\uninstall.log ‚ªŒ©‚‚©‚è‚Ü‚¹‚ñ!$\r$\nƒfƒBƒŒƒNƒgƒŠ $INSTDIR ‚ðŽè“®‚Å휂µ‚ăAƒ“ƒCƒ“ƒXƒg[ƒ‹‚µ‚Ä‚­‚¾‚³‚¢!"
-${LangFileString} FileChanged "ƒtƒ@ƒCƒ‹ $filename ‚̓Cƒ“ƒXƒg[ƒ‹Œã‚É•ÏX‚³‚ê‚Ä‚¢‚Ü‚·B$\r$\n‚±‚̃tƒ@ƒCƒ‹‚ð휂µ‚Ü‚·‚©?"
-${LangFileString} Yes "‚Í‚¢"
-${LangFileString} AlwaysYes "‘S‚Ă͂¢"
-${LangFileString} No "‚¢‚¢‚¦"
-${LangFileString} AlwaysNo "‘S‚Ä‚¢‚¢‚¦"
+;Language: Japanese (1041, CP932)
+;By Kenji Inoue <kenz@oct.zaq.ne.jp>, Masato Hashimoto <cabezon.hashimoto@gmail.com>
+${LangFileString} CaptionDescription "Open Source Scalable Vector Graphics Editor"
+${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ‚Í GNU General Public License (GPL) ‚̉º‚ÅƒŠƒŠ[ƒX‚³‚ê‚Ü‚·BŽQl‚É“–ŠYƒ‰ƒCƒZƒ“ƒX‚ð‚±‚±‚É•\ަ‚µ‚Ü‚·B$_CLICK"
+${LangFileString} DIFFERENT_USER "Inkscape ‚̓†[ƒU $0 ‚É‚æ‚Á‚ăCƒ“ƒXƒg[ƒ‹‚³‚ê‚Ä‚¢‚Ü‚·B$\r$\n‚±‚̂܂ܑ±‚¯‚邯³í‚ÉŠ®—¹‚µ‚È‚¢‚©‚à‚µ‚ê‚Ü‚¹‚ñB$\r$\n$0 ‚ŃƒOƒCƒ“‚µ‚Ä‚©‚çÄ“xŽŽ‚݂Ă­‚¾‚³‚¢B"
+${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ‚ÍŠù‚ɃCƒ“ƒXƒg[ƒ‹‚³‚ê‚Ä‚¢‚Ü‚·B$\n$(^Name) ‚ðƒCƒ“ƒXƒg[ƒ‹‚·‚é‘O‚ɈȑO‚̃o[ƒWƒ‡ƒ“‚ð휂µ‚Ü‚·‚©?"
+${LangFileString} OK_CANCEL_DESC "$\n$\nOK ‚ð‰Ÿ‚µ‚ÄŒp‘±‚·‚é‚© CANCEL ‚ð‰Ÿ‚µ‚Ä’†Ž~‚µ‚Ä‚­‚¾‚³‚¢B"
+${LangFileString} NO_ADMIN "ŠÇ—ŽÒŒ ŒÀ‚ª‚ ‚è‚Ü‚¹‚ñB$\r$\n‚·‚ׂẴ†[ƒU‚ɑ΂·‚é Inkscape ‚̃Cƒ“ƒXƒg[ƒ‹‚ͳí‚ÉŠ®—¹‚µ‚È‚¢‚©‚à‚µ‚ê‚Ü‚¹‚ñB$\r$\n'‚·‚ׂẴ†[ƒU' ƒIƒvƒVƒ‡ƒ“‚̃`ƒFƒbƒNƒ}[ƒN‚ðŠO‚µ‚Ä‚­‚¾‚³‚¢B"
+${LangFileString} NOT_SUPPORTED "Inkscape ‚Í Windows 95/98/ME ã‚ł͓®ì‚µ‚Ü‚¹‚ñ!$\r$\nÚ‚µ‚­‚̓IƒtƒBƒVƒƒƒ‹ƒEƒFƒuƒTƒCƒg‚ð‚²——‚­‚¾‚³‚¢B"
+${LangFileString} Full "Š®‘S"
+${LangFileString} Optimal "œK"
+${LangFileString} Minimal "Ŭ"
+${LangFileString} Core "Inkscape SVG Editor (•K{)"
+${LangFileString} CoreDesc "Inkscape ‚̃RƒAƒtƒ@ƒCƒ‹‚ÆDLL"
+${LangFileString} GTKFiles "GTK+ ƒ‰ƒ“ƒ^ƒCƒ€ŠÂ‹« (•K{)"
+${LangFileString} GTKFilesDesc "ƒ}ƒ‹ƒ`ƒvƒ‰ƒbƒgƒtƒH[ƒ€‘Ήž GUI ƒc[ƒ‹ƒLƒbƒg (Inkscape ‚ªŽg—p)"
+${LangFileString} Shortcuts "ƒVƒ‡[ƒgƒJƒbƒg"
+${LangFileString} ShortcutsDesc "Inkscape ‚ðŠJŽn‚·‚邽‚߂̃Vƒ‡[ƒgƒJƒbƒg"
+${LangFileString} Alluser "‚·‚ׂẴ†[ƒU"
+${LangFileString} AlluserDesc "‚±‚̃Rƒ“ƒsƒ…[ƒ^‚ðŽg‚¤‚·‚ׂĂÌl‚É‚±‚̃AƒvƒŠƒP[ƒVƒ‡ƒ“‚ðƒCƒ“ƒXƒg[ƒ‹ (‚·‚ׂẴ†[ƒU)"
+${LangFileString} Desktop "ƒfƒXƒNƒgƒbƒv"
+${LangFileString} DesktopDesc "Inkscape ‚ւ̃Vƒ‡[ƒgƒJƒbƒg‚ðƒfƒXƒNƒgƒbƒv‚Éì¬"
+${LangFileString} Startmenu "ƒXƒ^[ƒgƒƒjƒ…["
+${LangFileString} StartmenuDesc "ƒXƒ^[ƒgƒƒjƒ…[‚É Inkscape ‚Ì€–Ú‚ðì¬"
+${LangFileString} Quicklaunch "ƒNƒCƒbƒN‹N“®"
+${LangFileString} QuicklaunchDesc "Inkscape ‚ւ̃Vƒ‡[ƒgƒJƒbƒg‚ðƒNƒCƒbƒN‹N“®ƒc[ƒ‹ƒo[‚Éì¬"
+${LangFileString} SVGWriter "SVG ƒtƒ@ƒCƒ‹‚ð Inkscape ‚ÅŠJ‚­"
+${LangFileString} SVGWriterDesc "SVG ƒtƒ@ƒCƒ‹‚Ì•W€ƒGƒfƒBƒ^‚É Inkscape ‚ðÝ’è"
+${LangFileString} ContextMenu "ƒRƒ“ƒeƒLƒXƒgƒƒjƒ…["
+${LangFileString} ContextMenuDesc "SVG ƒtƒ@ƒCƒ‹‚̃Rƒ“ƒeƒLƒXƒgƒƒjƒ…[‚É Inkscape ‚ð’ljÁ"
+${LangFileString} DeletePrefs "ŒÂlÝ’è‚ðíœ"
+${LangFileString} DeletePrefsDesc "ˆÈ‘O‚̃Cƒ“ƒXƒg[ƒ‹Žž‚©‚çˆø‚«Œp‚¢‚¾ŒÂlÝ’è‚ðíœ"
+${LangFileString} Addfiles "’ljÁƒtƒ@ƒCƒ‹"
+${LangFileString} AddfilesDesc "’ljÁƒtƒ@ƒCƒ‹"
+${LangFileString} Examples "ƒTƒ“ƒvƒ‹ƒtƒ@ƒCƒ‹"
+${LangFileString} ExamplesDesc "Inkscape ‚̃Tƒ“ƒvƒ‹ƒtƒ@ƒCƒ‹"
+${LangFileString} Tutorials "ƒ`ƒ…[ƒgƒŠƒAƒ‹"
+${LangFileString} TutorialsDesc "Inkscape ‚̃`ƒ…[ƒgƒŠƒAƒ‹"
+${LangFileString} Languages "Œ¾Œê"
+${LangFileString} LanguagesDesc "Inkscape ‚Ì‚³‚Ü‚´‚܂Ȍ¾Œêƒtƒ@ƒCƒ‹‚ðƒCƒ“ƒXƒg[ƒ‹"
+${LangFileString} lng_am "ƒAƒ€ƒnƒ‰Œê"
+${LangFileString} lng_ar "ƒAƒ‰ƒrƒAŒê"
+${LangFileString} lng_az "ƒAƒ[ƒ‹ƒoƒCƒWƒƒƒ“Œê"
+${LangFileString} lng_be "ƒxƒ‰ƒ‹[ƒVŒê"
+${LangFileString} lng_bg "ƒuƒ‹ƒKƒŠƒAŒê"
+${LangFileString} lng_bn "ƒxƒ“ƒKƒ‹Œê"
+${LangFileString} lng_br "ƒuƒ‹ƒgƒ“Œê"
+${LangFileString} lng_ca "ƒJƒ^ƒƒjƒAŒê"
+${LangFileString} lng_ca@valencia "ƒoƒŒƒ“ƒVƒAŒê"
+${LangFileString} lng_cs "ƒ`ƒFƒRŒê"
+${LangFileString} lng_da "ƒfƒ“ƒ}[ƒNŒê"
+${LangFileString} lng_de "ƒhƒCƒcŒê"
+${LangFileString} lng_dz "ƒ]ƒ“ƒJŒê"
+${LangFileString} lng_el "ƒMƒŠƒVƒƒŒê"
+${LangFileString} lng_en "‰pŒê"
+${LangFileString} lng_en_AU "‰pŒê (ƒI[ƒXƒgƒ‰ƒŠƒA)"
+${LangFileString} lng_en_CA "‰pŒê (ƒJƒiƒ_)"
+${LangFileString} lng_en_GB "‰pŒê (‰p‘)"
+${LangFileString} lng_en_US@piglatin "ƒsƒbƒOEƒ‰ƒeƒ“Œê"
+${LangFileString} lng_eo "ƒGƒXƒyƒ‰ƒ“ƒgŒê"
+${LangFileString} lng_es "ƒXƒyƒCƒ“Œê"
+${LangFileString} lng_es_MX "ƒXƒyƒCƒ“Œê (ƒƒLƒVƒR)"
+${LangFileString} lng_et "ƒGƒXƒgƒjƒAŒê"
+${LangFileString} lng_eu "ƒoƒXƒNŒê"
+${LangFileString} lng_fa "ƒtƒ@ƒ‹ƒVŒê"
+${LangFileString} lng_fi "ƒtƒBƒ“ƒ‰ƒ“ƒhŒê"
+${LangFileString} lng_fr "ƒtƒ‰ƒ“ƒXŒê"
+${LangFileString} lng_ga "ƒAƒCƒ‹ƒ‰ƒ“ƒhŒê"
+${LangFileString} lng_gl "ƒKƒŠƒVƒAŒê"
+${LangFileString} lng_he "ƒwƒuƒ‰ƒCŒê"
+${LangFileString} lng_hr "ƒNƒƒAƒ`ƒAŒê"
+${LangFileString} lng_hu "ƒnƒ“ƒKƒŠ[Œê"
+${LangFileString} lng_id "ƒCƒ“ƒhƒlƒVƒAŒê"
+${LangFileString} lng_it "ƒCƒ^ƒŠƒAŒê"
+${LangFileString} lng_ja "“ú–{Œê"
+${LangFileString} lng_km "ƒNƒ[ƒ‹Œê"
+${LangFileString} lng_ko "ŠØ‘Œê"
+${LangFileString} lng_lt "ƒŠƒgƒAƒjƒAŒê"
+${LangFileString} lng_mk "ƒ}ƒPƒhƒjƒAŒê"
+${LangFileString} lng_mn "ƒ‚ƒ“ƒSƒ‹Œê"
+${LangFileString} lng_ne "ƒlƒp[ƒ‹Œê"
+${LangFileString} lng_nb "ƒmƒ‹ƒEƒF[Œêƒu[ƒNƒ‚[ƒ‹"
+${LangFileString} lng_nl "ƒIƒ‰ƒ“ƒ_Œê"
+${LangFileString} lng_nn "ƒmƒ‹ƒEƒF[Œêƒj[ƒmƒVƒ…ƒN"
+${LangFileString} lng_pa "ƒpƒ“ƒWƒƒƒuŒê"
+${LangFileString} lng_pl "ƒ|[ƒ‰ƒ“ƒhŒê"
+${LangFileString} lng_pt "ƒ|ƒ‹ƒgƒKƒ‹Œê"
+${LangFileString} lng_pt_BR "ƒ|ƒ‹ƒgƒKƒ‹Œê (ƒuƒ‰ƒWƒ‹)"
+${LangFileString} lng_ro "ƒ‹[ƒ}ƒjƒAŒê"
+${LangFileString} lng_ru "ƒƒVƒAŒê"
+${LangFileString} lng_rw "ƒLƒjƒ„ƒ‹ƒƒ“ƒ_Œê"
+${LangFileString} lng_sk "ƒXƒƒoƒLƒAŒê"
+${LangFileString} lng_sl "ƒXƒƒxƒjƒAŒê"
+${LangFileString} lng_sq "ƒAƒ‹ƒoƒjƒAŒê"
+${LangFileString} lng_sr "ƒZƒ‹ƒrƒAŒê"
+${LangFileString} lng_sr@latin "ƒZƒ‹ƒrƒAŒêƒ‰ƒeƒ“•¶Žš"
+${LangFileString} lng_sv "ƒXƒEƒF[ƒfƒ“Œê"
+${LangFileString} lng_te_IN "ƒeƒ‹ƒOŒê"
+${LangFileString} lng_th "ƒ^ƒCŒê"
+${LangFileString} lng_tr "ƒgƒ‹ƒRŒê"
+${LangFileString} lng_uk "ƒEƒNƒ‰ƒCƒiŒê"
+${LangFileString} lng_vi "ƒxƒgƒiƒ€Œê"
+${LangFileString} lng_zh_CN "’†‘Œê (ŠÈ‘ÌŽš)"
+${LangFileString} lng_zh_TW "’†‘Œê (”ɑ̎š)"
+${LangFileString} UInstOpt "ƒAƒ“ƒCƒ“ƒXƒg[ƒ‹ƒIƒvƒVƒ‡ƒ“"
+${LangFileString} UInstOpt1 "•K—v‚Å‚ ‚ê‚Έȉº‚̃IƒvƒVƒ‡ƒ“‚ð‘I‘ð‚µ‚Ä‚­‚¾‚³‚¢"
+${LangFileString} PurgePrefs "ŒÂlÝ’è‚ðŽc‚·"
+${LangFileString} UninstallLogNotFound "$INSTDIR\uninstall.log ‚ªŒ©‚‚©‚è‚Ü‚¹‚ñ!$\r$\nƒfƒBƒŒƒNƒgƒŠ $INSTDIR ‚ðŽè“®‚Å휂µ‚ăAƒ“ƒCƒ“ƒXƒg[ƒ‹‚µ‚Ä‚­‚¾‚³‚¢!"
+${LangFileString} FileChanged "ƒtƒ@ƒCƒ‹ $filename ‚̓Cƒ“ƒXƒg[ƒ‹Œã‚É•ÏX‚³‚ê‚Ä‚¢‚Ü‚·B$\r$\n‚±‚̃tƒ@ƒCƒ‹‚ð휂µ‚Ü‚·‚©?"
+${LangFileString} Yes "‚Í‚¢"
+${LangFileString} AlwaysYes "‘S‚Ă͂¢"
+${LangFileString} No "‚¢‚¢‚¦"
+${LangFileString} AlwaysNo "‘S‚Ä‚¢‚¢‚¦"
diff --git a/packaging/win32/languages/SimpChinese.nsh b/packaging/win32/languages/SimpChinese.nsh
index 8beb75db7..85fce0208 100644
--- a/packaging/win32/languages/SimpChinese.nsh
+++ b/packaging/win32/languages/SimpChinese.nsh
@@ -1,113 +1,113 @@
-;Language: Simplified Chinese (2052, CP936)
-;By Liang Wang <fabienow@gmail.com>
-${LangFileString} CaptionDescription "??Ô´??Á¿??ͼ????"
-${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ??GNUͨ?ù???????֤???С? ??Щ?ṩ????֤?????Թ??ο??? $_CLICK"
-${LangFileString} DIFFERENT_USER "ʹ???? $0 ?Ѿ???װ Inkscape??$\r$\n???????????????޷??ɹ????ɣ?$\r$\n???? $0 ???ݵ?????????һ?Ρ?"
-${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ?Ѿ???װ?? $\n??Ҫ?ڰ?װ $(^Name) ֮ǰ?Ƴ???һ???汾??"
-${LangFileString} OK_CANCEL_DESC "$\n$\n????È·???????????ß°???È¡??????Ö¹??"
-${LangFileString} NO_ADMIN "??û??ϵͳ????ԱȨ?ޡ?$\r$\n??װ Inkscape ??????ʹ???߿????޷??ɹ????ɡ?$\r$\nȡ????ѡ????װ??????ʹ???ߡ?ѡ??."
-${LangFileString} NOT_SUPPORTED "Inkscape ?޷??? Windows 95/98/ME ??????!$\r$\n???鿴?ٷ???վ????ϸ??Ϣ??"
-${LangFileString} Full "????"
-${LangFileString} Optimal "????"
-${LangFileString} Minimal "??С"
-${LangFileString} Core "Inkscape SVG ?༭????(????)"
-${LangFileString} CoreDesc "Inkscape ???Ä¿??? DLL "
-${LangFileString} GTKFiles "GTK+ ִ?л???(????)"
-${LangFileString} GTKFilesDesc "Inkscape ʹ?õĿ?ƽ̨ GUI ??????"
-${LangFileString} Shortcuts "???ݷ?ʽ"
-${LangFileString} ShortcutsDesc "???? Inkscape ?Ŀ??ݷ?ʽ"
-${LangFileString} Alluser "??װ??????ʹ????"
-${LangFileString} AlluserDesc "??װ????Ӧ?ó??????κ?ʹ????̨???Ե???(????ʹ????)"
-${LangFileString} Desktop "????"
-${LangFileString} DesktopDesc "???????Ͻ?Á¢ Inkscape ???Ý·?ʽ"
-${LangFileString} Startmenu "??ʼ?˵?"
-${LangFileString} StartmenuDesc "?Ú¿?ʼ?˵???Á¢ Inkscape ??Ä¿"
-${LangFileString} Quicklaunch "????????À¸"
-${LangFileString} QuicklaunchDesc "?Ú¿???????À¸??Á¢ Inkscape ???Ý·?ʽ"
-${LangFileString} SVGWriter "?? Inkscape ???? SVG ?ĵ?"
-${LangFileString} SVGWriterDesc "ѡ?? Inkscape ??Ϊ SVG ?ļ????͵???ѡ?༭????"
-${LangFileString} ContextMenu "?Ҽ??˵?"
-${LangFileString} ContextMenuDesc "???? Inkscape ?? SVG ?ļ????͵??Ҽ??˵?"
-${LangFileString} DeletePrefs "ɾ??????ƫ???趨"
-${LangFileString} DeletePrefsDesc "ɾ????һ?ΰ?װ?????ĸ???ƫ???趨"
-${LangFileString} Addfiles "?????ļ?????"
-${LangFileString} AddfilesDesc "?????ļ?????"
-${LangFileString} Examples "????"
-${LangFileString} ExamplesDesc "Inkscape ʹ?÷???"
-${LangFileString} Tutorials "Ö¸???Ö²?"
-${LangFileString} TutorialsDesc "Inkscape ʹ??˵??"
-${LangFileString} Languages "????"
-${LangFileString} LanguagesDesc "??×° Inkscape ???????Ô·???"
-${LangFileString} lng_am "????????????"
-${LangFileString} lng_ar "??À­????"
-${LangFileString} lng_az "??????È»??"
-${LangFileString} lng_be "?׶???˹??"
-${LangFileString} lng_bg "??????????"
-${LangFileString} lng_bn "?ϼ?À­??"
-${LangFileString} lng_br "??????????"
-${LangFileString} lng_ca "??̩¡??"
-${LangFileString} lng_ca@valencia "?????????? ??Ì©????????"
-${LangFileString} lng_cs "?Ý¿???"
-${LangFileString} lng_da "??????"
-${LangFileString} lng_de "????"
-${LangFileString} lng_dz "?Ú¿???"
-${LangFileString} lng_el "Ï£À°??"
-${LangFileString} lng_en "Ó¢??"
-${LangFileString} lng_en_AU "Ó¢??(?Ä´?????)"
-${LangFileString} lng_en_CA "Ӣ??(???ô?)"
-${LangFileString} lng_en_GB "Ó¢??(Ó¢??)"
-${LangFileString} lng_en_US@piglatin "??À­????"
-${LangFileString} lng_eo "?À½???"
-${LangFileString} lng_es "????????"
-${LangFileString} lng_es_MX "????????(Ä«????)"
-${LangFileString} lng_et "??ɳ??????"
-${LangFileString} lng_eu "??˹????"
-${LangFileString} lng_fa "Farsi"
-${LangFileString} lng_fi "??À¼??"
-${LangFileString} lng_fr "????"
-${LangFileString} lng_ga "????À¼??"
-${LangFileString} lng_gl "??????????"
-${LangFileString} lng_he "Ï£??????"
-${LangFileString} lng_hr "???Þ°???????"
-${LangFileString} lng_hu "????????"
-${LangFileString} lng_id "Ó¡????"
-${LangFileString} lng_it "????????"
-${LangFileString} lng_ja "????"
-${LangFileString} lng_km "??????"
-${LangFileString} lng_ko "????"
-${LangFileString} lng_lt "Á¢??????"
-${LangFileString} lng_mk "????????"
-${LangFileString} lng_mn "?ɹ???"
-${LangFileString} lng_ne "?á²´????"
-${LangFileString} lng_nb "Ų?? Bokmal ??"
-${LangFileString} lng_nl "??À¼??"
-${LangFileString} lng_nn "Ų?? Nynorsk ??"
-${LangFileString} lng_pa "????????"
-${LangFileString} lng_pl "??À¼??"
-${LangFileString} lng_pt "????????"
-${LangFileString} lng_pt_BR "????????(????)"
-${LangFileString} lng_ro "??????????"
-${LangFileString} lng_ru "????"
-${LangFileString} lng_rw "????¬??????"
-${LangFileString} lng_sk "˹?巨????"
-${LangFileString} lng_sl "˹?已??????"
-${LangFileString} lng_sq "????????????"
-${LangFileString} lng_sr "????ά????"
-${LangFileString} lng_sr@latin "????ά????-À­??"
-${LangFileString} lng_sv "??????"
-${LangFileString} lng_te_IN "Telugu"
-${LangFileString} lng_th "Ì©??"
-${LangFileString} lng_tr "?Á¶?????"
-${LangFileString} lng_uk "?Ú¿?À¼??"
-${LangFileString} lng_vi "Ô½??Ô’"
-${LangFileString} lng_zh_CN "????????"
-${LangFileString} lng_zh_TW "????????"
-${LangFileString} UInstOpt "????×°Ñ¡??"
-${LangFileString} UInstOpt1 "??Ñ¡??????Ñ¡??"
-${LangFileString} PurgePrefs "????????ƫ???趨"
-${LangFileString} UninstallLogNotFound "û???Òµ? $INSTDIR\uninstall.log ??$\r$\n?????????? $INSTDIR ?ļ??Ðí·´??×°??"
-${LangFileString} FileChanged "??װ?? $filename ?ļ??????ѱ?????$\r$\n???Ƿ???ȻҪɾ???Ǹ??ļ????ͣ?"
-${LangFileString} Yes "??"
-${LangFileString} AlwaysYes "È«??????"
-${LangFileString} No "??"
-${LangFileString} AlwaysNo "È«???Ô·?"
+;Language: Simplified Chinese (2052, CP936)
+;By Liang Wang <fabienow@gmail.com>
+${LangFileString} CaptionDescription "??Ô´??Á¿??ͼ????"
+${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ??GNUͨ?ù???????֤???С? ??Щ?ṩ????֤?????Թ??ο??? $_CLICK"
+${LangFileString} DIFFERENT_USER "ʹ???? $0 ?Ѿ???װ Inkscape??$\r$\n???????????????޷??ɹ????ɣ?$\r$\n???? $0 ???ݵ?????????һ?Ρ?"
+${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ?Ѿ???װ?? $\n??Ҫ?ڰ?װ $(^Name) ֮ǰ?Ƴ???һ???汾??"
+${LangFileString} OK_CANCEL_DESC "$\n$\n????È·???????????ß°???È¡??????Ö¹??"
+${LangFileString} NO_ADMIN "??û??ϵͳ????ԱȨ?ޡ?$\r$\n??װ Inkscape ??????ʹ???߿????޷??ɹ????ɡ?$\r$\nȡ????ѡ????װ??????ʹ???ߡ?ѡ??."
+${LangFileString} NOT_SUPPORTED "Inkscape ?޷??? Windows 95/98/ME ??????!$\r$\n???鿴?ٷ???վ????ϸ??Ϣ??"
+${LangFileString} Full "????"
+${LangFileString} Optimal "????"
+${LangFileString} Minimal "??С"
+${LangFileString} Core "Inkscape SVG ?༭????(????)"
+${LangFileString} CoreDesc "Inkscape ???Ä¿??? DLL "
+${LangFileString} GTKFiles "GTK+ ִ?л???(????)"
+${LangFileString} GTKFilesDesc "Inkscape ʹ?õĿ?ƽ̨ GUI ??????"
+${LangFileString} Shortcuts "???ݷ?ʽ"
+${LangFileString} ShortcutsDesc "???? Inkscape ?Ŀ??ݷ?ʽ"
+${LangFileString} Alluser "??װ??????ʹ????"
+${LangFileString} AlluserDesc "??װ????Ӧ?ó??????κ?ʹ????̨???Ե???(????ʹ????)"
+${LangFileString} Desktop "????"
+${LangFileString} DesktopDesc "???????Ͻ?Á¢ Inkscape ???Ý·?ʽ"
+${LangFileString} Startmenu "??ʼ?˵?"
+${LangFileString} StartmenuDesc "?Ú¿?ʼ?˵???Á¢ Inkscape ??Ä¿"
+${LangFileString} Quicklaunch "????????À¸"
+${LangFileString} QuicklaunchDesc "?Ú¿???????À¸??Á¢ Inkscape ???Ý·?ʽ"
+${LangFileString} SVGWriter "?? Inkscape ???? SVG ?ĵ?"
+${LangFileString} SVGWriterDesc "ѡ?? Inkscape ??Ϊ SVG ?ļ????͵???ѡ?༭????"
+${LangFileString} ContextMenu "?Ҽ??˵?"
+${LangFileString} ContextMenuDesc "???? Inkscape ?? SVG ?ļ????͵??Ҽ??˵?"
+${LangFileString} DeletePrefs "ɾ??????ƫ???趨"
+${LangFileString} DeletePrefsDesc "ɾ????һ?ΰ?װ?????ĸ???ƫ???趨"
+${LangFileString} Addfiles "?????ļ?????"
+${LangFileString} AddfilesDesc "?????ļ?????"
+${LangFileString} Examples "????"
+${LangFileString} ExamplesDesc "Inkscape ʹ?÷???"
+${LangFileString} Tutorials "Ö¸???Ö²?"
+${LangFileString} TutorialsDesc "Inkscape ʹ??˵??"
+${LangFileString} Languages "????"
+${LangFileString} LanguagesDesc "??×° Inkscape ???????Ô·???"
+${LangFileString} lng_am "????????????"
+${LangFileString} lng_ar "??À­????"
+${LangFileString} lng_az "??????È»??"
+${LangFileString} lng_be "?׶???˹??"
+${LangFileString} lng_bg "??????????"
+${LangFileString} lng_bn "?ϼ?À­??"
+${LangFileString} lng_br "??????????"
+${LangFileString} lng_ca "??̩¡??"
+${LangFileString} lng_ca@valencia "?????????? ??Ì©????????"
+${LangFileString} lng_cs "?Ý¿???"
+${LangFileString} lng_da "??????"
+${LangFileString} lng_de "????"
+${LangFileString} lng_dz "?Ú¿???"
+${LangFileString} lng_el "Ï£À°??"
+${LangFileString} lng_en "Ó¢??"
+${LangFileString} lng_en_AU "Ó¢??(?Ä´?????)"
+${LangFileString} lng_en_CA "Ӣ??(???ô?)"
+${LangFileString} lng_en_GB "Ó¢??(Ó¢??)"
+${LangFileString} lng_en_US@piglatin "??À­????"
+${LangFileString} lng_eo "?À½???"
+${LangFileString} lng_es "????????"
+${LangFileString} lng_es_MX "????????(Ä«????)"
+${LangFileString} lng_et "??ɳ??????"
+${LangFileString} lng_eu "??˹????"
+${LangFileString} lng_fa "Farsi"
+${LangFileString} lng_fi "??À¼??"
+${LangFileString} lng_fr "????"
+${LangFileString} lng_ga "????À¼??"
+${LangFileString} lng_gl "??????????"
+${LangFileString} lng_he "Ï£??????"
+${LangFileString} lng_hr "???Þ°???????"
+${LangFileString} lng_hu "????????"
+${LangFileString} lng_id "Ó¡????"
+${LangFileString} lng_it "????????"
+${LangFileString} lng_ja "????"
+${LangFileString} lng_km "??????"
+${LangFileString} lng_ko "????"
+${LangFileString} lng_lt "Á¢??????"
+${LangFileString} lng_mk "????????"
+${LangFileString} lng_mn "?ɹ???"
+${LangFileString} lng_ne "?á²´????"
+${LangFileString} lng_nb "Ų?? Bokmal ??"
+${LangFileString} lng_nl "??À¼??"
+${LangFileString} lng_nn "Ų?? Nynorsk ??"
+${LangFileString} lng_pa "????????"
+${LangFileString} lng_pl "??À¼??"
+${LangFileString} lng_pt "????????"
+${LangFileString} lng_pt_BR "????????(????)"
+${LangFileString} lng_ro "??????????"
+${LangFileString} lng_ru "????"
+${LangFileString} lng_rw "????¬??????"
+${LangFileString} lng_sk "˹?巨????"
+${LangFileString} lng_sl "˹?已??????"
+${LangFileString} lng_sq "????????????"
+${LangFileString} lng_sr "????ά????"
+${LangFileString} lng_sr@latin "????ά????-À­??"
+${LangFileString} lng_sv "??????"
+${LangFileString} lng_te_IN "Telugu"
+${LangFileString} lng_th "Ì©??"
+${LangFileString} lng_tr "?Á¶?????"
+${LangFileString} lng_uk "?Ú¿?À¼??"
+${LangFileString} lng_vi "Ô½??Ô’"
+${LangFileString} lng_zh_CN "????????"
+${LangFileString} lng_zh_TW "????????"
+${LangFileString} UInstOpt "????×°Ñ¡??"
+${LangFileString} UInstOpt1 "??Ñ¡??????Ñ¡??"
+${LangFileString} PurgePrefs "????????ƫ???趨"
+${LangFileString} UninstallLogNotFound "û???Òµ? $INSTDIR\uninstall.log ??$\r$\n?????????? $INSTDIR ?ļ??Ðí·´??×°??"
+${LangFileString} FileChanged "??װ?? $filename ?ļ??????ѱ?????$\r$\n???Ƿ???ȻҪɾ???Ǹ??ļ????ͣ?"
+${LangFileString} Yes "??"
+${LangFileString} AlwaysYes "È«??????"
+${LangFileString} No "??"
+${LangFileString} AlwaysNo "È«???Ô·?"
diff --git a/packaging/win32/languages/TradChinese.nsh b/packaging/win32/languages/TradChinese.nsh
index 2db61420c..e8f1a260f 100644
--- a/packaging/win32/languages/TradChinese.nsh
+++ b/packaging/win32/languages/TradChinese.nsh
@@ -1,113 +1,113 @@
-;Language: Traditional Chinese (1028, CP950)
-;By Dong-Jun Wu <ziyawu@gmail.com>
-${LangFileString} CaptionDescription "¶}©ñ­ì©l½X¦V¶qø¹Ï³nÅé"
-${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ¬O¥H GNU ³q¥Î¤½¦@³\¥iÃÒ (GPL) µo¦æ¡C ³o¸Ì´£¨Ñªº³\¥iÃҶȬ°°Ñ¦Ò°T®§¡C $_CLICK"
-${LangFileString} DIFFERENT_USER "¨Ï¥ÎªÌ $0 ¤w¸g¦w¸Ë Inkscape¡C$\r$\n¦pªGÄ~Äò§A¥i¯àµLªk¦¨¥\§¹¦¨¡I$\r$\n½Ð¥H $0 ¨­¥÷µn¤J«á¦A¸Õ¤@¦¸¡C"
-${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ¤w¸g¦w¸Ë¡C $\n§A­n¦b¦w¸Ë $(^Name) ¤§«e²¾°£¤W¤@­Óª©¥»¡H"
-${LangFileString} OK_CANCEL_DESC "$\n$\n«ö¡u½T©w¡vÄ~Äò©ÎªÌ«ö¡u¨ú®ø¡v¤¤¤î¡C"
-${LangFileString} NO_ADMIN "§A¨S¦³¨t²ÎºÞ²z­ûÅv­­¡C$\r$\n¦w¸Ë Inkscape ¨ì©Ò¦³¨Ï¥ÎªÌ¥i¯àµLªk¦¨¥\§¹¦¨¡C$\r$\n¨ú®ø¤Ä¿ï¡u¦w¸Ëµ¹©Ò¦³¨Ï¥ÎªÌ¡v¿ï¶µ."
-${LangFileString} NOT_SUPPORTED "Inkscape µLªk©ó Windows 95/98/ME ¤U¹B¦æ!$\r$\n½Ð¬d¬Ý©x¤èºô¯¸ªº¸Ô²Ó«H®§¡C"
-${LangFileString} Full "§¹¾ã"
-${LangFileString} Optimal "²z·Q"
-${LangFileString} Minimal "³Ì¤p"
-${LangFileString} Core "Inkscape SVG ½s¿èµ{¦¡(¥²¶·)"
-${LangFileString} CoreDesc "Inkscape ®Ö¤ßÀɮשM DLL ÀÉ"
-${LangFileString} GTKFiles "GTK+ °õ¦æÀô¹Ò(¥²¶·)"
-${LangFileString} GTKFilesDesc "Inkscape ¨Ï¥Îªº¸ó¥­¥x GUI ¤u¨ã²Õ"
-${LangFileString} Shortcuts "±¶®|"
-${LangFileString} ShortcutsDesc "±Ò°Ê Inkscape ªº±¶®|"
-${LangFileString} Alluser "¦w¸Ëµ¹©Ò¦³¨Ï¥ÎªÌ"
-${LangFileString} AlluserDesc "¦w¸Ë³o­ÓÀ³¥Îµ{¦¡µ¹¥ô¦ó¨Ï¥Î³o¥x¹q¸£ªº¤H(©Ò¦³¨Ï¥ÎªÌ)"
-${LangFileString} Desktop "®à­±"
-${LangFileString} DesktopDesc "©ó®à­±¤W«Ø¥ß Inkscape ±¶®|"
-${LangFileString} Startmenu "¶}©l¥\¯àªí"
-${LangFileString} StartmenuDesc "©ó¶}©l¥\¯àªí«Ø¥ß Inkscape ¶µ¥Ø"
-${LangFileString} Quicklaunch "§Ö³t±Ò°Ê"
-${LangFileString} QuicklaunchDesc "©ó§Ö³t±Ò°Ê¦C«Ø¥ß Inkscape ±¶®|"
-${LangFileString} SVGWriter "¥Î Inkscape ¶}±Ò SVG ÀÉ"
-${LangFileString} SVGWriterDesc "¿ï¾Ü Inkscape §@¬° SVG Àɪº¹w³]½s¿èµ{¦¡"
-${LangFileString} ContextMenu "¥kÁä¥\¯àªí"
-${LangFileString} ContextMenuDesc "·s¼W Inkscape ¨ì SVG Àɪº¥kÁä¥\¯àªí"
-${LangFileString} DeletePrefs "§R°£­Ó¤H°¾¦n³]©w"
-${LangFileString} DeletePrefsDesc "§R°£¤W¤@¦¸¦w¸Ë¿ò¯dªº­Ó¤H°¾¦n³]©w"
-${LangFileString} Addfiles "¨ä¥LÀÉ®×"
-${LangFileString} AddfilesDesc "¨ä¥LÀÉ®×"
-${LangFileString} Examples "½d¨Ò"
-${LangFileString} ExamplesDesc "Inkscape ¨Ï¥Î½d¨Ò"
-${LangFileString} Tutorials "«ü¾É¤â¥U"
-${LangFileString} TutorialsDesc "Inkscape ¨Ï¥Î±Ð¾Ç"
-${LangFileString} Languages "»y¨¥"
-${LangFileString} LanguagesDesc "¦w¸Ë Inkscape ¦UºØ»y¨¥Â½Ä¶"
-${LangFileString} lng_am "ªü¤ñ¦è¥§¨È»y"
-${LangFileString} lng_ar "ªü©Ô§B»y"
-${LangFileString} lng_az "¨È¶ë«ôµM»y"
-${LangFileString} lng_be "¥Õ«Xù´µ»y"
-${LangFileString} lng_bg "«O¥[§Q¨È»y"
-${LangFileString} lng_bn "©s¥[©Ô»y"
-${LangFileString} lng_br "¤£¦C¶ð¥§»y"
-${LangFileString} lng_ca "¥[®õ¶©»y"
-${LangFileString} lng_ca@valencia "¥Ë­Û¦è¨È»y ¥[®õù¥§¨È»y"
-${LangFileString} lng_cs "±¶§J»y"
-${LangFileString} lng_da "¤¦³Á»y"
-${LangFileString} lng_de "¼w»y"
-${LangFileString} lng_dz "©v¥d»y"
-${LangFileString} lng_el "§ÆÃ¾»y"
-${LangFileString} lng_en "­^»y"
-${LangFileString} lng_en_AU "­^»y(¿D¤j§Q¨È)"
-${LangFileString} lng_en_CA "­^»y(¥[®³¤j)"
-${LangFileString} lng_en_GB "­^»y(¤£¦CÄA)"
-${LangFileString} lng_en_US@piglatin "½Þ©Ô¤B»y"
-${LangFileString} lng_eo "¥@¬É»y"
-${LangFileString} lng_es "¦è¯Z¤ú¤å"
-${LangFileString} lng_es_MX "¦è¯Z¤ú»y(¾¥¦è­ô)"
-${LangFileString} lng_et "·R¨F¥§¨È»y"
-${LangFileString} lng_eu "¤Ú´µ§J»y"
-${LangFileString} lng_fa "Farsi"
-${LangFileString} lng_fi "ªâÄõ»y"
-${LangFileString} lng_fr "ªk¤å"
-${LangFileString} lng_ga "·Rº¸Äõ»y"
-${LangFileString} lng_gl "¥[¨½¦è¨È»y"
-${LangFileString} lng_he "§Æ§B¨Ó»y"
-${LangFileString} lng_hr "§Jù®J¦è¨È»y"
-${LangFileString} lng_hu "¦I¤ú§Q»y"
-${LangFileString} lng_id "¦L¥§»y"
-${LangFileString} lng_it "¸q¤j§Q¤å"
-${LangFileString} lng_ja "¤é¤å"
-${LangFileString} lng_km "°ª´Ö»y"
-${LangFileString} lng_ko "Áú¤å"
-${LangFileString} lng_lt "¥ß³³©{»y"
-${LangFileString} lng_mk "°¨¨ä¹y»y"
-${LangFileString} lng_mn "»X¥j»y"
-${LangFileString} lng_ne "¥§ªyº¸»y"
-${LangFileString} lng_nb "®¿«Â Bokmal »y"
-${LangFileString} lng_nl "²üÄõ»y"
-${LangFileString} lng_nn "®¿«Â Nynorsk »y"
-${LangFileString} lng_pa "®Ç¾B´¶»y"
-${LangFileString} lng_pl "ªiÄõ»y"
-${LangFileString} lng_pt "¸²µå¤ú¤å"
-${LangFileString} lng_pt_BR "¸²µå¤ú¤å(¤Ú¦è)"
-${LangFileString} lng_ro "ù°¨¥§¨È»y"
-${LangFileString} lng_ru "«X¤å"
-${LangFileString} lng_rw "ª÷¨È¿c¦w¹F»y"
-${LangFileString} lng_sk "´µ¬¥ªk§J»y"
-${LangFileString} lng_sl "´µ¬¥¤Z¥§¨È»y"
-${LangFileString} lng_sq "ªüº¸¤Ú¥§¨È»y"
-${LangFileString} lng_sr "Áɺ¸ºû¨È»y"
-${LangFileString} lng_sr@latin "¶ëº¸ºû¨È¤å-©Ô¤B"
-${LangFileString} lng_sv "·ç¨å»y"
-${LangFileString} lng_te_IN "Telugu"
-${LangFileString} lng_th "®õ»y"
-${LangFileString} lng_tr "¤g¦Õ¨ä»y"
-${LangFileString} lng_uk "¯Q§JÄõ»y"
-${LangFileString} lng_vi "¶V«n¸Ü"
-${LangFileString} lng_zh_CN "²Å餤¤å"
-${LangFileString} lng_zh_TW "ÁcÅ餤¤å"
-${LangFileString} UInstOpt "¤Ï¦w¸Ë¿ï¶µ"
-${LangFileString} UInstOpt1 "½Ð¿ï¾Ü¨ä¥L¿ï¶µ"
-${LangFileString} PurgePrefs "«O¯d­Ó¤H°¾¦n³]©w"
-${LangFileString} UninstallLogNotFound "¨S¦³§ä¨ì $INSTDIR\uninstall.log ¡I$\r$\n½Ð¦Û¦æ²M°£ $INSTDIR ¸ê®Æ§¨¨Ó¤Ï¦w¸Ë¡I"
-${LangFileString} FileChanged "¦w¸Ë«á $filename ÀɮפwÅܧó¡C$\r$\n§A¬O§_¤´µM­n§R°£¨º­ÓÀɮסH"
-${LangFileString} Yes "¬O"
-${LangFileString} AlwaysYes "¥þ³¡¬Ò¬O"
-${LangFileString} No "§_"
-${LangFileString} AlwaysNo "¥þ³¡¬Ò§_"
+;Language: Traditional Chinese (1028, CP950)
+;By Dong-Jun Wu <ziyawu@gmail.com>
+${LangFileString} CaptionDescription "¶}©ñ­ì©l½X¦V¶qø¹Ï³nÅé"
+${LangFileString} LICENSE_BOTTOM_TEXT "$(^Name) ¬O¥H GNU ³q¥Î¤½¦@³\¥iÃÒ (GPL) µo¦æ¡C ³o¸Ì´£¨Ñªº³\¥iÃҶȬ°°Ñ¦Ò°T®§¡C $_CLICK"
+${LangFileString} DIFFERENT_USER "¨Ï¥ÎªÌ $0 ¤w¸g¦w¸Ë Inkscape¡C$\r$\n¦pªGÄ~Äò§A¥i¯àµLªk¦¨¥\§¹¦¨¡I$\r$\n½Ð¥H $0 ¨­¥÷µn¤J«á¦A¸Õ¤@¦¸¡C"
+${LangFileString} WANT_UNINSTALL_BEFORE "$R1 ¤w¸g¦w¸Ë¡C $\n§A­n¦b¦w¸Ë $(^Name) ¤§«e²¾°£¤W¤@­Óª©¥»¡H"
+${LangFileString} OK_CANCEL_DESC "$\n$\n«ö¡u½T©w¡vÄ~Äò©ÎªÌ«ö¡u¨ú®ø¡v¤¤¤î¡C"
+${LangFileString} NO_ADMIN "§A¨S¦³¨t²ÎºÞ²z­ûÅv­­¡C$\r$\n¦w¸Ë Inkscape ¨ì©Ò¦³¨Ï¥ÎªÌ¥i¯àµLªk¦¨¥\§¹¦¨¡C$\r$\n¨ú®ø¤Ä¿ï¡u¦w¸Ëµ¹©Ò¦³¨Ï¥ÎªÌ¡v¿ï¶µ."
+${LangFileString} NOT_SUPPORTED "Inkscape µLªk©ó Windows 95/98/ME ¤U¹B¦æ!$\r$\n½Ð¬d¬Ý©x¤èºô¯¸ªº¸Ô²Ó«H®§¡C"
+${LangFileString} Full "§¹¾ã"
+${LangFileString} Optimal "²z·Q"
+${LangFileString} Minimal "³Ì¤p"
+${LangFileString} Core "Inkscape SVG ½s¿èµ{¦¡(¥²¶·)"
+${LangFileString} CoreDesc "Inkscape ®Ö¤ßÀɮשM DLL ÀÉ"
+${LangFileString} GTKFiles "GTK+ °õ¦æÀô¹Ò(¥²¶·)"
+${LangFileString} GTKFilesDesc "Inkscape ¨Ï¥Îªº¸ó¥­¥x GUI ¤u¨ã²Õ"
+${LangFileString} Shortcuts "±¶®|"
+${LangFileString} ShortcutsDesc "±Ò°Ê Inkscape ªº±¶®|"
+${LangFileString} Alluser "¦w¸Ëµ¹©Ò¦³¨Ï¥ÎªÌ"
+${LangFileString} AlluserDesc "¦w¸Ë³o­ÓÀ³¥Îµ{¦¡µ¹¥ô¦ó¨Ï¥Î³o¥x¹q¸£ªº¤H(©Ò¦³¨Ï¥ÎªÌ)"
+${LangFileString} Desktop "®à­±"
+${LangFileString} DesktopDesc "©ó®à­±¤W«Ø¥ß Inkscape ±¶®|"
+${LangFileString} Startmenu "¶}©l¥\¯àªí"
+${LangFileString} StartmenuDesc "©ó¶}©l¥\¯àªí«Ø¥ß Inkscape ¶µ¥Ø"
+${LangFileString} Quicklaunch "§Ö³t±Ò°Ê"
+${LangFileString} QuicklaunchDesc "©ó§Ö³t±Ò°Ê¦C«Ø¥ß Inkscape ±¶®|"
+${LangFileString} SVGWriter "¥Î Inkscape ¶}±Ò SVG ÀÉ"
+${LangFileString} SVGWriterDesc "¿ï¾Ü Inkscape §@¬° SVG Àɪº¹w³]½s¿èµ{¦¡"
+${LangFileString} ContextMenu "¥kÁä¥\¯àªí"
+${LangFileString} ContextMenuDesc "·s¼W Inkscape ¨ì SVG Àɪº¥kÁä¥\¯àªí"
+${LangFileString} DeletePrefs "§R°£­Ó¤H°¾¦n³]©w"
+${LangFileString} DeletePrefsDesc "§R°£¤W¤@¦¸¦w¸Ë¿ò¯dªº­Ó¤H°¾¦n³]©w"
+${LangFileString} Addfiles "¨ä¥LÀÉ®×"
+${LangFileString} AddfilesDesc "¨ä¥LÀÉ®×"
+${LangFileString} Examples "½d¨Ò"
+${LangFileString} ExamplesDesc "Inkscape ¨Ï¥Î½d¨Ò"
+${LangFileString} Tutorials "«ü¾É¤â¥U"
+${LangFileString} TutorialsDesc "Inkscape ¨Ï¥Î±Ð¾Ç"
+${LangFileString} Languages "»y¨¥"
+${LangFileString} LanguagesDesc "¦w¸Ë Inkscape ¦UºØ»y¨¥Â½Ä¶"
+${LangFileString} lng_am "ªü¤ñ¦è¥§¨È»y"
+${LangFileString} lng_ar "ªü©Ô§B»y"
+${LangFileString} lng_az "¨È¶ë«ôµM»y"
+${LangFileString} lng_be "¥Õ«Xù´µ»y"
+${LangFileString} lng_bg "«O¥[§Q¨È»y"
+${LangFileString} lng_bn "©s¥[©Ô»y"
+${LangFileString} lng_br "¤£¦C¶ð¥§»y"
+${LangFileString} lng_ca "¥[®õ¶©»y"
+${LangFileString} lng_ca@valencia "¥Ë­Û¦è¨È»y ¥[®õù¥§¨È»y"
+${LangFileString} lng_cs "±¶§J»y"
+${LangFileString} lng_da "¤¦³Á»y"
+${LangFileString} lng_de "¼w»y"
+${LangFileString} lng_dz "©v¥d»y"
+${LangFileString} lng_el "§ÆÃ¾»y"
+${LangFileString} lng_en "­^»y"
+${LangFileString} lng_en_AU "­^»y(¿D¤j§Q¨È)"
+${LangFileString} lng_en_CA "­^»y(¥[®³¤j)"
+${LangFileString} lng_en_GB "­^»y(¤£¦CÄA)"
+${LangFileString} lng_en_US@piglatin "½Þ©Ô¤B»y"
+${LangFileString} lng_eo "¥@¬É»y"
+${LangFileString} lng_es "¦è¯Z¤ú¤å"
+${LangFileString} lng_es_MX "¦è¯Z¤ú»y(¾¥¦è­ô)"
+${LangFileString} lng_et "·R¨F¥§¨È»y"
+${LangFileString} lng_eu "¤Ú´µ§J»y"
+${LangFileString} lng_fa "Farsi"
+${LangFileString} lng_fi "ªâÄõ»y"
+${LangFileString} lng_fr "ªk¤å"
+${LangFileString} lng_ga "·Rº¸Äõ»y"
+${LangFileString} lng_gl "¥[¨½¦è¨È»y"
+${LangFileString} lng_he "§Æ§B¨Ó»y"
+${LangFileString} lng_hr "§Jù®J¦è¨È»y"
+${LangFileString} lng_hu "¦I¤ú§Q»y"
+${LangFileString} lng_id "¦L¥§»y"
+${LangFileString} lng_it "¸q¤j§Q¤å"
+${LangFileString} lng_ja "¤é¤å"
+${LangFileString} lng_km "°ª´Ö»y"
+${LangFileString} lng_ko "Áú¤å"
+${LangFileString} lng_lt "¥ß³³©{»y"
+${LangFileString} lng_mk "°¨¨ä¹y»y"
+${LangFileString} lng_mn "»X¥j»y"
+${LangFileString} lng_ne "¥§ªyº¸»y"
+${LangFileString} lng_nb "®¿«Â Bokmal »y"
+${LangFileString} lng_nl "²üÄõ»y"
+${LangFileString} lng_nn "®¿«Â Nynorsk »y"
+${LangFileString} lng_pa "®Ç¾B´¶»y"
+${LangFileString} lng_pl "ªiÄõ»y"
+${LangFileString} lng_pt "¸²µå¤ú¤å"
+${LangFileString} lng_pt_BR "¸²µå¤ú¤å(¤Ú¦è)"
+${LangFileString} lng_ro "ù°¨¥§¨È»y"
+${LangFileString} lng_ru "«X¤å"
+${LangFileString} lng_rw "ª÷¨È¿c¦w¹F»y"
+${LangFileString} lng_sk "´µ¬¥ªk§J»y"
+${LangFileString} lng_sl "´µ¬¥¤Z¥§¨È»y"
+${LangFileString} lng_sq "ªüº¸¤Ú¥§¨È»y"
+${LangFileString} lng_sr "Áɺ¸ºû¨È»y"
+${LangFileString} lng_sr@latin "¶ëº¸ºû¨È¤å-©Ô¤B"
+${LangFileString} lng_sv "·ç¨å»y"
+${LangFileString} lng_te_IN "Telugu"
+${LangFileString} lng_th "®õ»y"
+${LangFileString} lng_tr "¤g¦Õ¨ä»y"
+${LangFileString} lng_uk "¯Q§JÄõ»y"
+${LangFileString} lng_vi "¶V«n¸Ü"
+${LangFileString} lng_zh_CN "²Å餤¤å"
+${LangFileString} lng_zh_TW "ÁcÅ餤¤å"
+${LangFileString} UInstOpt "¤Ï¦w¸Ë¿ï¶µ"
+${LangFileString} UInstOpt1 "½Ð¿ï¾Ü¨ä¥L¿ï¶µ"
+${LangFileString} PurgePrefs "«O¯d­Ó¤H°¾¦n³]©w"
+${LangFileString} UninstallLogNotFound "¨S¦³§ä¨ì $INSTDIR\uninstall.log ¡I$\r$\n½Ð¦Û¦æ²M°£ $INSTDIR ¸ê®Æ§¨¨Ó¤Ï¦w¸Ë¡I"
+${LangFileString} FileChanged "¦w¸Ë«á $filename ÀɮפwÅܧó¡C$\r$\n§A¬O§_¤´µM­n§R°£¨º­ÓÀɮסH"
+${LangFileString} Yes "¬O"
+${LangFileString} AlwaysYes "¥þ³¡¬Ò¬O"
+${LangFileString} No "§_"
+${LangFileString} AlwaysNo "¥þ³¡¬Ò§_"
diff --git a/packaging/win32/md5dll.txt b/packaging/win32/md5dll.txt
index 7d6992186..a8d3572c7 100644
--- a/packaging/win32/md5dll.txt
+++ b/packaging/win32/md5dll.txt
@@ -1,68 +1,68 @@
-Calculates the md5sum of a file or string.
-Has been tested to work with NSIS 2.0+
-
-
-Derived from the RSA Data Security, Inc. MD5 Message-Digest Algorithm
-
-[Md5Dll]
-Matthew "IGx89" Lieder
- -Original plugin Author
-
-Sunjammer (12th May 2002)
- -Original usage notes and example script
-
-[Md5Dll.0.1]
-KJD (2004)
- -Modified to reduce size and use exdll.h
- (reduced to about 6KB uncompressed, by removing CRTL dependency)
-
-[Md5dll.0.2]
-Davy Durham (2004)
- -MD5.cpp fix (correct for loop used to replace memset, exceeded bounds)
-
-[Md5dll.0.3]
-Shengalts Aleksander aka Instructor (2005)
- -New command: "GetMD5Random"
- -Changed names: "GetFileMD5" -> "GetMD5File", "GetMD5" -> "GetMD5String"
- -Fixed: string length error
-
-[Md5dll.0.4]
-KJD (2005)
- -Added dual name to exports for backwards compatibility
-
-
---------------------------------
-
-Usage:
-
-Push $1 ;string
-CallInstDll "md5dll" GetMD5String
-Pop $1 ;md5 of string
-
--or-
-
-Push $1 ;filename
-CallInstDll "md5dll" GetMD5File
-Pop $1 ;md5 of file
-
---------------------------------
-
-Example usage in recent NSIS versions
-
-OutFile "md5test.exe"
-Section ""
- #generate MD5sum of a string
- md5dll::GetMD5String "md5me"
- Pop $0
- DetailPrint "md5: [$0]"
-
- # generate MD5sum of a file
- md5dll::GetMD5File "${NSISDIR}\makensis.exe"
- Pop $0
- DetailPrint "md5: [$0]"
-
- #generate random MD5sum
- md5dll::GetMD5Random
- Pop $0
- DetailPrint "md5: [$0]"
-SectionEnd
+Calculates the md5sum of a file or string.
+Has been tested to work with NSIS 2.0+
+
+
+Derived from the RSA Data Security, Inc. MD5 Message-Digest Algorithm
+
+[Md5Dll]
+Matthew "IGx89" Lieder
+ -Original plugin Author
+
+Sunjammer (12th May 2002)
+ -Original usage notes and example script
+
+[Md5Dll.0.1]
+KJD (2004)
+ -Modified to reduce size and use exdll.h
+ (reduced to about 6KB uncompressed, by removing CRTL dependency)
+
+[Md5dll.0.2]
+Davy Durham (2004)
+ -MD5.cpp fix (correct for loop used to replace memset, exceeded bounds)
+
+[Md5dll.0.3]
+Shengalts Aleksander aka Instructor (2005)
+ -New command: "GetMD5Random"
+ -Changed names: "GetFileMD5" -> "GetMD5File", "GetMD5" -> "GetMD5String"
+ -Fixed: string length error
+
+[Md5dll.0.4]
+KJD (2005)
+ -Added dual name to exports for backwards compatibility
+
+
+--------------------------------
+
+Usage:
+
+Push $1 ;string
+CallInstDll "md5dll" GetMD5String
+Pop $1 ;md5 of string
+
+-or-
+
+Push $1 ;filename
+CallInstDll "md5dll" GetMD5File
+Pop $1 ;md5 of file
+
+--------------------------------
+
+Example usage in recent NSIS versions
+
+OutFile "md5test.exe"
+Section ""
+ #generate MD5sum of a string
+ md5dll::GetMD5String "md5me"
+ Pop $0
+ DetailPrint "md5: [$0]"
+
+ # generate MD5sum of a file
+ md5dll::GetMD5File "${NSISDIR}\makensis.exe"
+ Pop $0
+ DetailPrint "md5: [$0]"
+
+ #generate random MD5sum
+ md5dll::GetMD5Random
+ Pop $0
+ DetailPrint "md5: [$0]"
+SectionEnd
diff --git a/packaging/win32/portable/App/AppInfo/appinfo.ini b/packaging/win32/portable/App/AppInfo/appinfo.ini
index 677489010..544a66584 100644
--- a/packaging/win32/portable/App/AppInfo/appinfo.ini
+++ b/packaging/win32/portable/App/AppInfo/appinfo.ini
@@ -1,26 +1,26 @@
-[Format]
-Type=PortableApps.comFormat
-Version=0.91
-
-[Details]
-Name=Inkscape Portable
-AppID=InkscapePortable
-Publisher=Inkscape.org & PortableApps.com
-Homepage=Inkscape.org
-Category=Graphics & Pictures
-Description=Inkscape is a powerful vector graphics editor.
-Language=Multilingual
-
-[License]
-Shareable=true
-OpenSource=true
-Freeware=true
-CommercialUse=true
-
-[Version]
-PackageVersion=0.47
-DisplayVersion=0.47
-
-[Control]
-Icons=1
-Start=InkscapePortable.exe
+[Format]
+Type=PortableApps.comFormat
+Version=0.91
+
+[Details]
+Name=Inkscape Portable
+AppID=InkscapePortable
+Publisher=Inkscape.org & PortableApps.com
+Homepage=Inkscape.org
+Category=Graphics & Pictures
+Description=Inkscape is a powerful vector graphics editor.
+Language=Multilingual
+
+[License]
+Shareable=true
+OpenSource=true
+Freeware=true
+CommercialUse=true
+
+[Version]
+PackageVersion=0.47
+DisplayVersion=0.47
+
+[Control]
+Icons=1
+Start=InkscapePortable.exe
diff --git a/packaging/win32/portable/App/AppInfo/installer.ini b/packaging/win32/portable/App/AppInfo/installer.ini
index ad1918ecf..ffa60d15a 100644
--- a/packaging/win32/portable/App/AppInfo/installer.ini
+++ b/packaging/win32/portable/App/AppInfo/installer.ini
@@ -1,15 +1,15 @@
-[OptionalComponents]
-OptionalComponents=true
-OptionalDirectory1=App\Inkscape\locale
-OptionalDirectory2=App\Inkscape\share\locale
-OptionalFile1=App\Inkscape\share\clipart\draw-freely.*.svg
-OptionalFile2=App\Inkscape\share\screens\*.*.svg
-OptionalFile3=App\Inkscape\share\templates\default.*.svg
-OptionalFile4=App\Inkscape\share\tutorials\potrace-*.svg
-OptionalFile5=App\Inkscape\share\tutorials\*.*.svg
-
-[DirectoriesToPreserve]
-PreserveDirectory1=App\Inkscape\data
-PreserveDirectory2=App\Inkscape\modules
-PreserveDirectory3=App\Inkscape\plugins
-PreserveDirectory4=App\Inkscape\share\extensions
+[OptionalComponents]
+OptionalComponents=true
+OptionalDirectory1=App\Inkscape\locale
+OptionalDirectory2=App\Inkscape\share\locale
+OptionalFile1=App\Inkscape\share\clipart\draw-freely.*.svg
+OptionalFile2=App\Inkscape\share\screens\*.*.svg
+OptionalFile3=App\Inkscape\share\templates\default.*.svg
+OptionalFile4=App\Inkscape\share\tutorials\potrace-*.svg
+OptionalFile5=App\Inkscape\share\tutorials\*.*.svg
+
+[DirectoriesToPreserve]
+PreserveDirectory1=App\Inkscape\data
+PreserveDirectory2=App\Inkscape\modules
+PreserveDirectory3=App\Inkscape\plugins
+PreserveDirectory4=App\Inkscape\share\extensions
diff --git a/packaging/win32/portable/App/readme.txt b/packaging/win32/portable/App/readme.txt
index fd42dacfb..b67db5038 100644
--- a/packaging/win32/portable/App/readme.txt
+++ b/packaging/win32/portable/App/readme.txt
@@ -1 +1 @@
-The files in this directory are necessary for Inkscape Portable to function. There is normally no need to directly access or alter any of the files within these directories.
+The files in this directory are necessary for Inkscape Portable to function. There is normally no need to directly access or alter any of the files within these directories.
diff --git a/packaging/win32/portable/Other/Source/InkscapePortable.ini b/packaging/win32/portable/Other/Source/InkscapePortable.ini
index b734190da..0ddd34b4a 100644
--- a/packaging/win32/portable/Other/Source/InkscapePortable.ini
+++ b/packaging/win32/portable/Other/Source/InkscapePortable.ini
@@ -1,6 +1,6 @@
-[InkscapePortable]
-AdditionalParameters=
-DisableSplashScreen=false
-
-# This INI is an example only and will not work until placed according to the directions in readme.txt
-# The above options are explained in the included readme.txt
+[InkscapePortable]
+AdditionalParameters=
+DisableSplashScreen=false
+
+# This INI is an example only and will not work until placed according to the directions in readme.txt
+# The above options are explained in the included readme.txt
diff --git a/packaging/win32/portable/Other/Source/InkscapePortable.nsi b/packaging/win32/portable/Other/Source/InkscapePortable.nsi
index c9081207d..673d49c51 100644
--- a/packaging/win32/portable/Other/Source/InkscapePortable.nsi
+++ b/packaging/win32/portable/Other/Source/InkscapePortable.nsi
@@ -1,130 +1,130 @@
-;Copyright (C) 2004-2008 John T. Haller of PortableApps.com
-;Copyright (C) 2008-2009 Chris Morgan of PortableApps.com and Inkscape.org
-
-;Website: http://PortableApps.com/InkscapePortable
-
-;This software is OSI Certified Open Source Software.
-;OSI Certified is a certification mark of the Open Source Initiative.
-
-;This program is free software; you can redistribute it and/or
-;modify it under the terms of the GNU General Public License
-;as published by the Free Software Foundation; either version 2
-;of the License, or (at your option) any later version.
-
-;This program is distributed in the hope that it will be useful,
-;but WITHOUT ANY WARRANTY; without even the implied warranty of
-;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-;GNU General Public License for more details.
-
-;You should have received a copy of the GNU General Public License
-;along with this program; if not, write to the Free Software
-;Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-!define PORTABLEAPPNAME "Inkscape Portable"
-!define NAME InkscapePortable
-!define VER "1.6.6.0"
-!define LAUNCHERLANGUAGE English
-
-;=== Program Details
-Name "${PORTABLEAPPNAME}"
-OutFile "..\..\${NAME}.exe"
-VIProductVersion "${VER}"
-VIAddVersionKey ProductName "${PORTABLEAPPNAME}"
-VIAddVersionKey Comments "Allows Inkscape to be run from a removable drive. For additional details, visit Inkscape.org"
-VIAddVersionKey CompanyName "PortableApps.com"
-VIAddVersionKey LegalCopyright "PortableApps.com & Inkscape.org"
-VIAddVersionKey FileDescription "${PORTABLEAPPNAME}"
-VIAddVersionKey FileVersion "${VER}"
-VIAddVersionKey ProductVersion "${VER}"
-VIAddVersionKey InternalName "${PORTABLEAPPNAME}"
-VIAddVersionKey LegalTrademarks "PortableApps.com is a Trademark of Rare Ideas, LLC."
-VIAddVersionKey OriginalFilename "${NAME}.exe"
-;VIAddVersionKey PrivateBuild ""
-;VIAddVersionKey SpecialBuild ""
-
-;=== Runtime Switches
-CRCCheck On
-WindowIcon Off
-SilentInstall Silent
-AutoCloseWindow True
-RequestExecutionLevel user
-
-; Best Compression
-SetCompress Auto
-SetCompressor /SOLID lzma
-SetCompressorDictSize 32
-SetDatablockOptimize On
-
-;=== Include
-;(Standard NSIS)
-!include FileFunc.nsh
-!insertmacro GetParameters
-!insertmacro GetRoot
-
-;(NSIS Plugins)
-!include TextReplace.nsh
-
-;(Custom)
-!include ReplaceInFileWithTextReplace.nsh
-
-;=== Program Icon
-Icon "..\..\App\AppInfo\appicon.ico"
-
-;=== Icon & Stye ===
-;!define MUI_ICON "..\..\App\AppInfo\appicon.ico"
-
-;=== Languages
-LoadLanguageFile "${NSISDIR}\Contrib\Language files\${LAUNCHERLANGUAGE}.nlf"
-!include PortableApps.comLauncherLANG_${LAUNCHERLANGUAGE}.nsh
-
-Var MISSINGFILEORPATH
-
-Section Main
- IfFileExists "$EXEDIR\App\Inkscape\inkscape.exe" DisplaySplash
- StrCpy $MISSINGFILEORPATH "inkscape.exe"
- MessageBox MB_OK|MB_ICONEXCLAMATION `$(LauncherFileNotFound)`
- Abort
-
- DisplaySplash:
- ReadINIStr $0 "$EXEDIR\${NAME}.ini" "${NAME}" DisableSplashScreen
- StrCmp $0 "true" SettingsDirectory
- ;=== Show the splash screen while processing registry entries
- InitPluginsDir
- File /oname=$PLUGINSDIR\splash.jpg "${NAME}.jpg"
- newadvsplash::show /NOUNLOAD 1200 0 0 -1 /L $PLUGINSDIR\splash.jpg
-
- SettingsDirectory:
- CreateDirectory $EXEDIR\Data\settings
- System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("INKSCAPE_PORTABLE_PROFILE_DIR", "$EXEDIR\Data\settings").n'
- System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("HOME", "$EXEDIR\Data\settings").n' ; possibly some GTK stuff
- System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("APPDATA", "$EXEDIR\Data\settings").n' ; Just to be on the safe side
-
- ;InkscapeLanguage:
- ReadEnvStr $0 "PortableApps.comLocaleglibc"
- StrCmp $0 "" InkscapeLanguageSettingsFile
- StrCmp $0 "en_US" SetInkscapeLanguageVariable
- IfFileExists "$EXEDIR\App\Inkscape\locale\$0\*.*" SetInkscapeLanguageVariable
-
- InkscapeLanguageSettingsFile:
- ReadINIStr $0 "$EXEDIR\Data\settings\${NAME}Settings.ini" Language LANG
- StrCmp $0 "" AdjustPaths
- StrCmp $0 "en_US" SetInkscapeLanguageVariable
- IfFileExists "$EXEDIR\App\Inkscape\locale\$0\*.*" SetInkscapeLanguageVariable AdjustPaths
-
- SetInkscapeLanguageVariable:
- System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("LANG", r0).n'
-
- AdjustPaths:
- ReadINIStr $0 "$EXEDIR\Data\settings\${NAME}Settings.ini" "${NAME}Settings" LastDrive
- ${GetRoot} $EXEDIR $1
- StrCmp $0 $1 Launch
- WriteINIStr "$EXEDIR\Data\settings\${NAME}Settings.ini" "${NAME}Settings" LastDrive $1
- ${ReplaceInFile} "$EXEDIR\Data\settings\preferences.xml" "$0\" "$1\"
- ${ReplaceInFile} "$EXEDIR\Data\settings\.recently-used.xbel" "file:///$0/" "file:///$1/"
-
- Launch:
- ${GetParameters} $0
- ReadINIStr $1 "$EXEDIR\${NAME}.ini" "${NAME}" AdditionalParameters
- Exec `"$EXEDIR\App\Inkscape\inkscape.exe" $0 $1`
- newadvsplash::stop /WAIT
-SectionEnd
+;Copyright (C) 2004-2008 John T. Haller of PortableApps.com
+;Copyright (C) 2008-2009 Chris Morgan of PortableApps.com and Inkscape.org
+
+;Website: http://PortableApps.com/InkscapePortable
+
+;This software is OSI Certified Open Source Software.
+;OSI Certified is a certification mark of the Open Source Initiative.
+
+;This program is free software; you can redistribute it and/or
+;modify it under the terms of the GNU General Public License
+;as published by the Free Software Foundation; either version 2
+;of the License, or (at your option) any later version.
+
+;This program is distributed in the hope that it will be useful,
+;but WITHOUT ANY WARRANTY; without even the implied warranty of
+;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;GNU General Public License for more details.
+
+;You should have received a copy of the GNU General Public License
+;along with this program; if not, write to the Free Software
+;Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+!define PORTABLEAPPNAME "Inkscape Portable"
+!define NAME InkscapePortable
+!define VER "1.6.6.0"
+!define LAUNCHERLANGUAGE English
+
+;=== Program Details
+Name "${PORTABLEAPPNAME}"
+OutFile "..\..\${NAME}.exe"
+VIProductVersion "${VER}"
+VIAddVersionKey ProductName "${PORTABLEAPPNAME}"
+VIAddVersionKey Comments "Allows Inkscape to be run from a removable drive. For additional details, visit Inkscape.org"
+VIAddVersionKey CompanyName "PortableApps.com"
+VIAddVersionKey LegalCopyright "PortableApps.com & Inkscape.org"
+VIAddVersionKey FileDescription "${PORTABLEAPPNAME}"
+VIAddVersionKey FileVersion "${VER}"
+VIAddVersionKey ProductVersion "${VER}"
+VIAddVersionKey InternalName "${PORTABLEAPPNAME}"
+VIAddVersionKey LegalTrademarks "PortableApps.com is a Trademark of Rare Ideas, LLC."
+VIAddVersionKey OriginalFilename "${NAME}.exe"
+;VIAddVersionKey PrivateBuild ""
+;VIAddVersionKey SpecialBuild ""
+
+;=== Runtime Switches
+CRCCheck On
+WindowIcon Off
+SilentInstall Silent
+AutoCloseWindow True
+RequestExecutionLevel user
+
+; Best Compression
+SetCompress Auto
+SetCompressor /SOLID lzma
+SetCompressorDictSize 32
+SetDatablockOptimize On
+
+;=== Include
+;(Standard NSIS)
+!include FileFunc.nsh
+!insertmacro GetParameters
+!insertmacro GetRoot
+
+;(NSIS Plugins)
+!include TextReplace.nsh
+
+;(Custom)
+!include ReplaceInFileWithTextReplace.nsh
+
+;=== Program Icon
+Icon "..\..\App\AppInfo\appicon.ico"
+
+;=== Icon & Stye ===
+;!define MUI_ICON "..\..\App\AppInfo\appicon.ico"
+
+;=== Languages
+LoadLanguageFile "${NSISDIR}\Contrib\Language files\${LAUNCHERLANGUAGE}.nlf"
+!include PortableApps.comLauncherLANG_${LAUNCHERLANGUAGE}.nsh
+
+Var MISSINGFILEORPATH
+
+Section Main
+ IfFileExists "$EXEDIR\App\Inkscape\inkscape.exe" DisplaySplash
+ StrCpy $MISSINGFILEORPATH "inkscape.exe"
+ MessageBox MB_OK|MB_ICONEXCLAMATION `$(LauncherFileNotFound)`
+ Abort
+
+ DisplaySplash:
+ ReadINIStr $0 "$EXEDIR\${NAME}.ini" "${NAME}" DisableSplashScreen
+ StrCmp $0 "true" SettingsDirectory
+ ;=== Show the splash screen while processing registry entries
+ InitPluginsDir
+ File /oname=$PLUGINSDIR\splash.jpg "${NAME}.jpg"
+ newadvsplash::show /NOUNLOAD 1200 0 0 -1 /L $PLUGINSDIR\splash.jpg
+
+ SettingsDirectory:
+ CreateDirectory $EXEDIR\Data\settings
+ System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("INKSCAPE_PORTABLE_PROFILE_DIR", "$EXEDIR\Data\settings").n'
+ System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("HOME", "$EXEDIR\Data\settings").n' ; possibly some GTK stuff
+ System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("APPDATA", "$EXEDIR\Data\settings").n' ; Just to be on the safe side
+
+ ;InkscapeLanguage:
+ ReadEnvStr $0 "PortableApps.comLocaleglibc"
+ StrCmp $0 "" InkscapeLanguageSettingsFile
+ StrCmp $0 "en_US" SetInkscapeLanguageVariable
+ IfFileExists "$EXEDIR\App\Inkscape\locale\$0\*.*" SetInkscapeLanguageVariable
+
+ InkscapeLanguageSettingsFile:
+ ReadINIStr $0 "$EXEDIR\Data\settings\${NAME}Settings.ini" Language LANG
+ StrCmp $0 "" AdjustPaths
+ StrCmp $0 "en_US" SetInkscapeLanguageVariable
+ IfFileExists "$EXEDIR\App\Inkscape\locale\$0\*.*" SetInkscapeLanguageVariable AdjustPaths
+
+ SetInkscapeLanguageVariable:
+ System::Call 'Kernel32::SetEnvironmentVariableA(t, t) i("LANG", r0).n'
+
+ AdjustPaths:
+ ReadINIStr $0 "$EXEDIR\Data\settings\${NAME}Settings.ini" "${NAME}Settings" LastDrive
+ ${GetRoot} $EXEDIR $1
+ StrCmp $0 $1 Launch
+ WriteINIStr "$EXEDIR\Data\settings\${NAME}Settings.ini" "${NAME}Settings" LastDrive $1
+ ${ReplaceInFile} "$EXEDIR\Data\settings\preferences.xml" "$0\" "$1\"
+ ${ReplaceInFile} "$EXEDIR\Data\settings\.recently-used.xbel" "file:///$0/" "file:///$1/"
+
+ Launch:
+ ${GetParameters} $0
+ ReadINIStr $1 "$EXEDIR\${NAME}.ini" "${NAME}" AdditionalParameters
+ Exec `"$EXEDIR\App\Inkscape\inkscape.exe" $0 $1`
+ newadvsplash::stop /WAIT
+SectionEnd
diff --git a/packaging/win32/portable/Other/Source/License.txt b/packaging/win32/portable/Other/Source/License.txt
index d6a3987f4..f119115a6 100644
--- a/packaging/win32/portable/Other/Source/License.txt
+++ b/packaging/win32/portable/Other/Source/License.txt
@@ -1,344 +1,344 @@
- GNU GENERAL PUBLIC LICENSE
- Version 2, June 1991
-
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
- Preamble
-
- The licenses for most software are designed to take away your
-freedom to share and change it. By contrast, the GNU General Public
-License is intended to guarantee your freedom to share and change free
-software--to make sure the software is free for all its users. This
-General Public License applies to most of the Free Software
-Foundation's software and to any other program whose authors commit to
-using it. (Some other Free Software Foundation software is covered by
-the GNU Library General Public License instead.) You can apply it to
-your programs, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-this service if you wish), that you receive source code or can get it
-if you want it, that you can change the software or use pieces of it
-in new free programs; and that you know you can do these things.
-
- To protect your rights, we need to make restrictions that forbid
-anyone to deny you these rights or to ask you to surrender the rights.
-These restrictions translate to certain responsibilities for you if you
-distribute copies of the software, or if you modify it.
-
- For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must give the recipients all the rights that
-you have. You must make sure that they, too, receive or can get the
-source code. And you must show them these terms so they know their
-rights.
-
- We protect your rights with two steps: (1) copyright the software, and
-(2) offer you this license which gives you legal permission to copy,
-distribute and/or modify the software.
-
- Also, for each author's protection and ours, we want to make certain
-that everyone understands that there is no warranty for this free
-software. If the software is modified by someone else and passed on, we
-want its recipients to know that what they have is not the original, so
-that any problems introduced by others will not reflect on the original
-authors' reputations.
-
- Finally, any free program is threatened constantly by software
-patents. We wish to avoid the danger that redistributors of a free
-program will individually obtain patent licenses, in effect making the
-program proprietary. To prevent this, we have made it clear that any
-patent must be licensed for everyone's free use or not licensed at all.
-
- The precise terms and conditions for copying, distribution and
-modification follow.
-
- GNU GENERAL PUBLIC LICENSE
- TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
- 0. This License applies to any program or other work which contains
-a notice placed by the copyright holder saying it may be distributed
-under the terms of this General Public License. The "Program", below,
-refers to any such program or work, and a "work based on the Program"
-means either the Program or any derivative work under copyright law:
-that is to say, a work containing the Program or a portion of it,
-either verbatim or with modifications and/or translated into another
-language. (Hereinafter, translation is included without limitation in
-the term "modification".) Each licensee is addressed as "you".
-
-Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope. The act of
-running the Program is not restricted, and the output from the Program
-is covered only if its contents constitute a work based on the
-Program (independent of having been made by running the Program).
-Whether that is true depends on what the Program does.
-
- 1. You may copy and distribute verbatim copies of the Program's
-source code as you receive it, in any medium, provided that you
-conspicuously and appropriately publish on each copy an appropriate
-copyright notice and disclaimer of warranty; keep intact all the
-notices that refer to this License and to the absence of any warranty;
-and give any other recipients of the Program a copy of this License
-along with the Program.
-
-You may charge a fee for the physical act of transferring a copy, and
-you may at your option offer warranty protection in exchange for a fee.
-
- 2. You may modify your copy or copies of the Program or any portion
-of it, thus forming a work based on the Program, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
- a) You must cause the modified files to carry prominent notices
- stating that you changed the files and the date of any change.
-
- b) You must cause any work that you distribute or publish, that in
- whole or in part contains or is derived from the Program or any
- part thereof, to be licensed as a whole at no charge to all third
- parties under the terms of this License.
-
- c) If the modified program normally reads commands interactively
- when run, you must cause it, when started running for such
- interactive use in the most ordinary way, to print or display an
- announcement including an appropriate copyright notice and a
- notice that there is no warranty (or else, saying that you provide
- a warranty) and that users may redistribute the program under
- these conditions, and telling the user how to view a copy of this
- License. (Exception: if the Program itself is interactive but
- does not normally print such an announcement, your work based on
- the Program is not required to print an announcement.)
-
-These requirements apply to the modified work as a whole. If
-identifiable sections of that work are not derived from the Program,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works. But when you
-distribute the same sections as part of a whole which is a work based
-on the Program, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Program.
-
-In addition, mere aggregation of another work not based on the Program
-with the Program (or with a work based on the Program) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
- 3. You may copy and distribute the Program (or a work based on it,
-under Section 2) in object code or executable form under the terms of
-Sections 1 and 2 above provided that you also do one of the following:
-
- a) Accompany it with the complete corresponding machine-readable
- source code, which must be distributed under the terms of Sections
- 1 and 2 above on a medium customarily used for software interchange; or,
-
- b) Accompany it with a written offer, valid for at least three
- years, to give any third party, for a charge no more than your
- cost of physically performing source distribution, a complete
- machine-readable copy of the corresponding source code, to be
- distributed under the terms of Sections 1 and 2 above on a medium
- customarily used for software interchange; or,
-
- c) Accompany it with the information you received as to the offer
- to distribute corresponding source code. (This alternative is
- allowed only for noncommercial distribution and only if you
- received the program in object code or executable form with such
- an offer, in accord with Subsection b above.)
-
-The source code for a work means the preferred form of the work for
-making modifications to it. For an executable work, complete source
-code means all the source code for all modules it contains, plus any
-associated interface definition files, plus the scripts used to
-control compilation and installation of the executable. However, as a
-special exception, the source code distributed need not include
-anything that is normally distributed (in either source or binary
-form) with the major components (compiler, kernel, and so on) of the
-operating system on which the executable runs, unless that component
-itself accompanies the executable.
-
-If distribution of executable or object code is made by offering
-access to copy from a designated place, then offering equivalent
-access to copy the source code from the same place counts as
-distribution of the source code, even though third parties are not
-compelled to copy the source along with the object code.
-
- 4. You may not copy, modify, sublicense, or distribute the Program
-except as expressly provided under this License. Any attempt
-otherwise to copy, modify, sublicense or distribute the Program is
-void, and will automatically terminate your rights under this License.
-However, parties who have received copies, or rights, from you under
-this License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
- 5. You are not required to accept this License, since you have not
-signed it. However, nothing else grants you permission to modify or
-distribute the Program or its derivative works. These actions are
-prohibited by law if you do not accept this License. Therefore, by
-modifying or distributing the Program (or any work based on the
-Program), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Program or works based on it.
-
- 6. Each time you redistribute the Program (or any work based on the
-Program), the recipient automatically receives a license from the
-original licensor to copy, distribute or modify the Program subject to
-these terms and conditions. You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties to
-this License.
-
- 7. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License. If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Program at all. For example, if a patent
-license would not permit royalty-free redistribution of the Program by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Program.
-
-If any portion of this section is held invalid or unenforceable under
-any particular circumstance, the balance of the section is intended to
-apply and the section as a whole is intended to apply in other
-circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system, which is
-implemented by public license practices. Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-
- 8. If the distribution and/or use of the Program is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Program under this License
-may add an explicit geographical distribution limitation excluding
-those countries, so that distribution is permitted only in or among
-countries not thus excluded. In such case, this License incorporates
-the limitation as if written in the body of this License.
-
- 9. The Free Software Foundation may publish revised and/or new versions
-of the General Public License from time to time. Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
-Each version is given a distinguishing version number. If the Program
-specifies a version number of this License which applies to it and "any
-later version", you have the option of following the terms and conditions
-either of that version or of any later version published by the Free
-Software Foundation. If the Program does not specify a version number of
-this License, you may choose any version ever published by the Free Software
-Foundation.
-
- 10. If you wish to incorporate parts of the Program into other free
-programs whose distribution conditions are different, write to the author
-to ask for permission. For software which is copyrighted by the Free
-Software Foundation, write to the Free Software Foundation; we sometimes
-make exceptions for this. Our decision will be guided by the two goals
-of preserving the free status of all derivatives of our free software and
-of promoting the sharing and reuse of software generally.
-
- NO WARRANTY
-
- 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE,
-THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT
-PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED
-IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
-PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND,
-EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY
-AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
-PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL
-NECESSARY SERVICING, REPAIR OR CORRECTION.
-
- 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR
-AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY
-OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM
-AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING
-ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES
-ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM
-(INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
-RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
-PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY
-OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS
-BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
-
- END OF TERMS AND CONDITIONS
-
- How to Apply These Terms to Your New Programs
-
- If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
- To do so, attach the following notices to the program. It is safest
-to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
- <one line to give the program's name and a brief idea of what it does.>
- Copyright (C) 19yy <name of author>
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
-
-Also add information on how to contact you by electronic and paper mail.
-
-If the program is interactive, make it output a short notice like this
-when it starts in an interactive mode:
-
- Gnomovision version 69, Copyright (C) 19yy name of author
- Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
- This is free software, and you are welcome to redistribute it
- under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License. Of course, the commands you use may
-be called something other than `show w' and `show c'; they could even be
-mouse-clicks or menu items--whatever suits your program.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the program, if
-necessary. Here is a sample; alter the names:
-
- Yoyodyne, Inc., hereby disclaims all copyright interest in the program
- `Gnomovision' (which makes passes at compilers) written by James Hacker.
-
- <signature of Ty Coon>, 1 April 1989
- Ty Coon, President of Vice
-
-This General Public License does not permit incorporating your program into
-proprietary programs. If your program is a subroutine library, you may
-consider it more useful to permit linking proprietary applications with the
-library. If this is what you want to do, use the GNU Library General
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+ 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Library General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE,
+THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT
+PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED
+IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND,
+EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY
+AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL
+NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR
+AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY
+OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM
+AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING
+ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES
+ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM
+(INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
+RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY
+OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS
+BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) 19yy <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) 19yy name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Library General
Public License instead of this License. \ No newline at end of file
diff --git a/packaging/win32/portable/Other/Source/PortableApps.comInstallerCustom.nsh b/packaging/win32/portable/Other/Source/PortableApps.comInstallerCustom.nsh
index 1cce3522c..456f6c600 100644
--- a/packaging/win32/portable/Other/Source/PortableApps.comInstallerCustom.nsh
+++ b/packaging/win32/portable/Other/Source/PortableApps.comInstallerCustom.nsh
@@ -1,12 +1,12 @@
-!macro CustomCodePostInstall
- ${If} ${FileExists} "$INSTDIR\Data\settings\AppData" ; 0.46 Development Tests
- Rename "$INSTDIR\Data\settings\AppData" "$INSTDIR\Data\_settings"
- ${ElseIf} ${FileExists} "$INSTDIR\Data\settings\InkscapePortableAppData" ; 0.46 Pre-Release 1
- Rename "$INSTDIR\Data\settings\InkscapePortableAppData" "$INSTDIR\Data\_settings"
- ${EndIf}
- ${If} ${FileExists} "$INSTDIR\Data\_settings"
- Rename "$INSTDIR\Data\settings\InkscapePortableSettings.ini" "$INSTDIR\Data\_settings\InkscapePortableSettings.ini"
- RMDir /r "$INSTDIR\Data\settings"
- Rename "$INSTDIR\Data\settings" "$INSTDIR\Data\_settings"
- ${EndIf}
-!macroend
+!macro CustomCodePostInstall
+ ${If} ${FileExists} "$INSTDIR\Data\settings\AppData" ; 0.46 Development Tests
+ Rename "$INSTDIR\Data\settings\AppData" "$INSTDIR\Data\_settings"
+ ${ElseIf} ${FileExists} "$INSTDIR\Data\settings\InkscapePortableAppData" ; 0.46 Pre-Release 1
+ Rename "$INSTDIR\Data\settings\InkscapePortableAppData" "$INSTDIR\Data\_settings"
+ ${EndIf}
+ ${If} ${FileExists} "$INSTDIR\Data\_settings"
+ Rename "$INSTDIR\Data\settings\InkscapePortableSettings.ini" "$INSTDIR\Data\_settings\InkscapePortableSettings.ini"
+ RMDir /r "$INSTDIR\Data\settings"
+ Rename "$INSTDIR\Data\settings" "$INSTDIR\Data\_settings"
+ ${EndIf}
+!macroend
diff --git a/packaging/win32/portable/Other/Source/PortableApps.comLauncherLANG_ENGLISH.nsh b/packaging/win32/portable/Other/Source/PortableApps.comLauncherLANG_ENGLISH.nsh
index 79679e26d..71bdbbaa4 100644
--- a/packaging/win32/portable/Other/Source/PortableApps.comLauncherLANG_ENGLISH.nsh
+++ b/packaging/win32/portable/Other/Source/PortableApps.comLauncherLANG_ENGLISH.nsh
@@ -1,6 +1,6 @@
-LangString LauncherFileNotFound ${LANG_ENGLISH} "${PORTABLEAPPNAME} cannot be started. You may wish to re-install to fix this issue. (ERROR: $MISSINGFILEORPATH could not be found)"
-LangString LauncherAlreadyRunning ${LANG_ENGLISH} "Another instance of ${APPNAME} is already running. Please close other instances of ${APPNAME} before launching ${PORTABLEAPPNAME}."
-LangString LauncherAskCopyLocal ${LANG_ENGLISH} "${PORTABLEAPPNAME} appears to be running from a location that is read-only. Would you like to temporarily copy it to the local hard drive and run it from there?$\n$\nPrivacy Note: If you say Yes, your personal data within ${PORTABLEAPPNAME} will be temporarily copied to a local drive. Although this copy of your data will be deleted when you close ${PORTABLEAPPNAME}, it may be possible for someone else to access your data later."
-LangString LauncherNoReadOnly ${LANG_ENGLISH} "${PORTABLEAPPNAME} can not run directly from a read-only location and will now close."
-LangString LauncherPathTooLong ${LANG_ENGLISH} "The path to ${PORTABLEAPPNAME} is too long. Please shorten the path by eliminating some parent directories or shortening directory names."
-LangString LauncherNextButton ${LANG_ENGLISH} "&Next >"
+LangString LauncherFileNotFound ${LANG_ENGLISH} "${PORTABLEAPPNAME} cannot be started. You may wish to re-install to fix this issue. (ERROR: $MISSINGFILEORPATH could not be found)"
+LangString LauncherAlreadyRunning ${LANG_ENGLISH} "Another instance of ${APPNAME} is already running. Please close other instances of ${APPNAME} before launching ${PORTABLEAPPNAME}."
+LangString LauncherAskCopyLocal ${LANG_ENGLISH} "${PORTABLEAPPNAME} appears to be running from a location that is read-only. Would you like to temporarily copy it to the local hard drive and run it from there?$\n$\nPrivacy Note: If you say Yes, your personal data within ${PORTABLEAPPNAME} will be temporarily copied to a local drive. Although this copy of your data will be deleted when you close ${PORTABLEAPPNAME}, it may be possible for someone else to access your data later."
+LangString LauncherNoReadOnly ${LANG_ENGLISH} "${PORTABLEAPPNAME} can not run directly from a read-only location and will now close."
+LangString LauncherPathTooLong ${LANG_ENGLISH} "The path to ${PORTABLEAPPNAME} is too long. Please shorten the path by eliminating some parent directories or shortening directory names."
+LangString LauncherNextButton ${LANG_ENGLISH} "&Next >"
diff --git a/packaging/win32/portable/Other/Source/Readme.txt b/packaging/win32/portable/Other/Source/Readme.txt
index 201ffd1b0..67d4500f4 100644
--- a/packaging/win32/portable/Other/Source/Readme.txt
+++ b/packaging/win32/portable/Other/Source/Readme.txt
@@ -1,67 +1,67 @@
-Inkscape Portable
-=================
-Copyright 2004-2008 John T. Haller
-Copyright 2008-2009 Chris Morgan
-
-Website: http://Inkscape.org/
-
-This software is OSI Certified Open Source Software.
-OSI Certified is a certification mark of the Open Source Initiative.
-
-This program is free software; you can redistribute it and/or
-modify it under the terms of the GNU General Public License
-as published by the Free Software Foundation; either version 2
-of the License, or (at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-ABOUT INKSCAPE PORTABLE
-=======================
-The Inkscape Portable launcher allows you to run Inkscape from a
-removable drive whose letter changes as you move it to another
-computer. The program can be entirely self-contained on the drive
-and then used on any Windows computer.
-
-
-LICENSE
-=======
-This code is released under the GPL.
-The full code is included with this package as InkscapePortable.nsi.
-
-
-INSTALLATION / DIRECTORY STRUCTURE
-==================================
-The program expects the following directory structure:
-
--\ <--- Directory with InkscapePortable.exe
- +\App\
- +\Inkscape\
- +\Data\
- +\settings\
-
-
-INKSCAPEPORTABLE.INI CONFIGURATION
-==================================
-The Inkscape Portable launcher will look for an ini file called
-InkscapePortable.ini in the directory which contains InkscapePortable.exe.
-If you are happy with the default options, it is not necessary, though.
-The INI file is formatted as follows:
-
-[InkscapePortable]
-AdditionalParameters=
-DisableSplashScreen=false
-
-The AdditionalParameters entry allows you to pass additional command-line
-parameter entries to inkscape.exe. Whatever you enter here will be
-appended to the call to inkscape.exe.
-
-The DisableSplashScreen entry allows you to run the Inkscape Portable
-launcher without the splash screen showing up. The default is false.
+Inkscape Portable
+=================
+Copyright 2004-2008 John T. Haller
+Copyright 2008-2009 Chris Morgan
+
+Website: http://Inkscape.org/
+
+This software is OSI Certified Open Source Software.
+OSI Certified is a certification mark of the Open Source Initiative.
+
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+
+ABOUT INKSCAPE PORTABLE
+=======================
+The Inkscape Portable launcher allows you to run Inkscape from a
+removable drive whose letter changes as you move it to another
+computer. The program can be entirely self-contained on the drive
+and then used on any Windows computer.
+
+
+LICENSE
+=======
+This code is released under the GPL.
+The full code is included with this package as InkscapePortable.nsi.
+
+
+INSTALLATION / DIRECTORY STRUCTURE
+==================================
+The program expects the following directory structure:
+
+-\ <--- Directory with InkscapePortable.exe
+ +\App\
+ +\Inkscape\
+ +\Data\
+ +\settings\
+
+
+INKSCAPEPORTABLE.INI CONFIGURATION
+==================================
+The Inkscape Portable launcher will look for an ini file called
+InkscapePortable.ini in the directory which contains InkscapePortable.exe.
+If you are happy with the default options, it is not necessary, though.
+The INI file is formatted as follows:
+
+[InkscapePortable]
+AdditionalParameters=
+DisableSplashScreen=false
+
+The AdditionalParameters entry allows you to pass additional command-line
+parameter entries to inkscape.exe. Whatever you enter here will be
+appended to the call to inkscape.exe.
+
+The DisableSplashScreen entry allows you to run the Inkscape Portable
+launcher without the splash screen showing up. The default is false.
diff --git a/packaging/win32/portable/Other/Source/ReplaceInFileWithTextReplace.nsh b/packaging/win32/portable/Other/Source/ReplaceInFileWithTextReplace.nsh
index ab81f62fc..3157f3eae 100644
--- a/packaging/win32/portable/Other/Source/ReplaceInFileWithTextReplace.nsh
+++ b/packaging/win32/portable/Other/Source/ReplaceInFileWithTextReplace.nsh
@@ -1,64 +1,64 @@
-; ReplaceInFile wrapper for testreplace function
-; John T. Haller of PortableApps.com
-; BSD License
-; Requires TextReplace plugin installed in NSIS and !include "TextReplace.nsh" in main nsi
-;
-; Usage: ${ReplaceInFile} SOURCE_FILE SEARCH_TEXT REPLACEMENT
-; or use ReplaceInFileCS for case-sensitive (use when possible, it's faster)
-; No return variable. Error will be set if unable to do the replacement (invalid file, locked file, etc)
-
-Function ReplaceInFile
- Exch $0 ;REPLACEMENT
- Exch
- Exch $1 ;SEARCH_TEXT
- Exch 2
- Exch $2 ;SOURCE_FILE
- Exch 3
- Exch $3 ;CASE_INSENSITIVE
- Push $4 ;NEW_FILE
- Push $5 ;RETURN_VALUE
-
- StrCpy $4 `$2.OldReplaceInFile`
-
- ${textreplace::ReplaceInFile} "$2" "$4" "$1" "$0" "$3 /C=0" $5
-
- IntCmp $5 0 StackCleanup ReturnError RenameToOriginal
-
- ReturnError:
- SetErrors
- Goto StackCleanup
-
- RenameToOriginal:
- Delete $2
- Rename $4 $2
-
- StackCleanup:
- Pop $5
- Pop $4
- Pop $3
- Pop $0
- Pop $1
- Pop $2
-
- ${textreplace::Unload}
-FunctionEnd
-
-!macro ReplaceInFileCS SOURCE_FILE SEARCH_TEXT REPLACEMENT
- Push `/S=1`
- Push `${SOURCE_FILE}`
- Push `${SEARCH_TEXT}`
- Push `${REPLACEMENT}`
- Call ReplaceInFile
-!macroend
-
-!macro ReplaceInFile SOURCE_FILE SEARCH_TEXT REPLACEMENT
- Push `/S=0`
- Push `${SOURCE_FILE}`
- Push `${SEARCH_TEXT}`
- Push `${REPLACEMENT}`
- Call ReplaceInFile
-!macroend
-
-!define ReplaceInFileCS '!insertmacro "ReplaceInFileCS"'
-
+; ReplaceInFile wrapper for testreplace function
+; John T. Haller of PortableApps.com
+; BSD License
+; Requires TextReplace plugin installed in NSIS and !include "TextReplace.nsh" in main nsi
+;
+; Usage: ${ReplaceInFile} SOURCE_FILE SEARCH_TEXT REPLACEMENT
+; or use ReplaceInFileCS for case-sensitive (use when possible, it's faster)
+; No return variable. Error will be set if unable to do the replacement (invalid file, locked file, etc)
+
+Function ReplaceInFile
+ Exch $0 ;REPLACEMENT
+ Exch
+ Exch $1 ;SEARCH_TEXT
+ Exch 2
+ Exch $2 ;SOURCE_FILE
+ Exch 3
+ Exch $3 ;CASE_INSENSITIVE
+ Push $4 ;NEW_FILE
+ Push $5 ;RETURN_VALUE
+
+ StrCpy $4 `$2.OldReplaceInFile`
+
+ ${textreplace::ReplaceInFile} "$2" "$4" "$1" "$0" "$3 /C=0" $5
+
+ IntCmp $5 0 StackCleanup ReturnError RenameToOriginal
+
+ ReturnError:
+ SetErrors
+ Goto StackCleanup
+
+ RenameToOriginal:
+ Delete $2
+ Rename $4 $2
+
+ StackCleanup:
+ Pop $5
+ Pop $4
+ Pop $3
+ Pop $0
+ Pop $1
+ Pop $2
+
+ ${textreplace::Unload}
+FunctionEnd
+
+!macro ReplaceInFileCS SOURCE_FILE SEARCH_TEXT REPLACEMENT
+ Push `/S=1`
+ Push `${SOURCE_FILE}`
+ Push `${SEARCH_TEXT}`
+ Push `${REPLACEMENT}`
+ Call ReplaceInFile
+!macroend
+
+!macro ReplaceInFile SOURCE_FILE SEARCH_TEXT REPLACEMENT
+ Push `/S=0`
+ Push `${SOURCE_FILE}`
+ Push `${SEARCH_TEXT}`
+ Push `${REPLACEMENT}`
+ Call ReplaceInFile
+!macroend
+
+!define ReplaceInFileCS '!insertmacro "ReplaceInFileCS"'
+
!define ReplaceInFile '!insertmacro "ReplaceInFile"' \ No newline at end of file
diff --git a/packaging/win32/portable/help.html b/packaging/win32/portable/help.html
index eec89c5bb..7e7ee0fbf 100644
--- a/packaging/win32/portable/help.html
+++ b/packaging/win32/portable/help.html
@@ -1,178 +1,178 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-<html lang="en-US"><head><title>Inkscape Portable Help</title>
- <link rel="alternate" type="application/rss+xml" title="PortableApps.com" href="http://portableapps.com/feeds/general">
- <link rel="SHORTCUT ICON" href="Other/Help/images/favicon.ico">
-<style>body {
- font-family: Verdana,Arial,Helvetica,sans-serif;
- font-size: 76%;
- color: #000;
- margin: 20px;
- background: #E6E8EA;
- text-align: center;
-}
-a
-{
- color: #B31616;
- font-weight: bold;
-}
-a:link {
- }
-a:visited {
- }
-a:active {
- }
-a:hover {
- color: red;
- }
-h1, h2, h3, h4, h5, h6 {
- font-family: Arial, sans-serif;
- font-weight: normal;
-}
-h1 {
- color: #B31616;
- font-weight: bold;
- letter-spacing: -2px;
- font-size: 2.2em;
- border-bottom: 1px solid silver;
- padding-bottom: 5px;
- }
-h2 {
- font-size: 1.5em;
- border-bottom: 1px solid silver;
- padding-bottom: 3px;
- clear: both;
- }
-h3 {
- font-size: 1.2em;
- }
-h4 {
- font-size: 1.1em;
- }
-h5 {
- font-size: 1.0em;
- }
-h6 {
- font-size: 0.8em;
- }
-img {
- border: 0;
- }
-ol, ul, li {
- font-size: 1.0em;
- }
-p, table, tr, td, th {
- font-size: 1.0em;
- }
-pre {
- font-family: Courier New,Courier,monospace;
- font-size: 1.0em;
- }
-strong, b {
- font-weight: bold;
- }
-table, tr, td {
- font-size: 1.0em;
- border-collapse: collapse;
-}
-td, th {
- border: 1px solid #aaaaaa;
- border-collapse: collapse;
- padding: 3px;
-}
-th {
- background: #3667A8;
- color: white;
-}
-ol ol {
- list-style-type: lower-alpha;
-}
-.content {
- text-align: left;
- margin-left: auto;
- margin-right: auto;
- width: 780px;
- background-color: #FFFFFF;
- border-left: 1px solid Black;
- border-right: 1px solid Black;
- padding: 12px 30px;
- line-height: 150%;
-}
-.logo {
- background: #ffffff url("Other/Help/images/help_background_header.png") repeat-x;
- width: 840px;
- margin-top: 20px;
- margin-left: auto;
- margin-right: auto;
- text-align: left;
- border-right: 1px solid black;
- border-left: 1px solid black;
-}
-.footer {
- background: #ffffff url("Other/Help/images/help_background_footer.png") repeat-x;
- width: 840px;
- height: 16px;
- margin-left: auto;
- margin-right: auto;
- text-align: left;
- border-right: 1px solid black;
- border-left: 1px solid black;
-}
-.logo img {
- padding-left: 0px;
- border: none;
- position: relative;
- top: -4px;
-}
-* html .content {
- width: 760px;
-}
-* html .logo, * html .footer {
- width: 820px;
-}
-.content h1 {
- margin: 0px;
-}
-h1.hastagline {
- border: 0;
-}
-h2.tagline {
- color: #747673;
- clear: none;
- margin-top: 0em;
-}
-/*printer styles*/
-@media print{
-body, .content {margin: 0; padding: 0;}
-.navigation, .locator, .footer a, .message, .footer-links {display:none;}
-.footer, .content, .header {border: none;}
-a {text-decoration: none; font-weight: normal; color: black;}
-}</style>
-</head>
-<body>
-<div class="logo"><a href="http://portableapps.com/"><img src="Other/Help/images/help_logo_top.png" width="229" height="47" alt="PortableApps.com - Your Digital Life, Anywhere"></a></div>
-<div class="content">
-<h1 class="hastagline">Inkscape Portable Help</h1>
-<h2 class="tagline">amazing vector graphics - everywhere!</h2>
-<p>Inkscape Portable is the popular Inkscape vector graphics editor packaged with a PortableApps.com launcher as a <a href="http://portableapps.com/about/what_is_a_portable_app">portable app</a>, to help you design on your iPod, USB flash drive, portable hard drive, etc. It has all the same great features as Inkscape including editing vector graphics, designing things and more. Plus, it leaves no personal information behind on the machine you run it on, so you can take it with you wherever you go. <a href="http://inkscape.org/">Learn more about Inkscape...</a></p>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html lang="en-US"><head><title>Inkscape Portable Help</title>
+ <link rel="alternate" type="application/rss+xml" title="PortableApps.com" href="http://portableapps.com/feeds/general">
+ <link rel="SHORTCUT ICON" href="Other/Help/images/favicon.ico">
+<style>body {
+ font-family: Verdana,Arial,Helvetica,sans-serif;
+ font-size: 76%;
+ color: #000;
+ margin: 20px;
+ background: #E6E8EA;
+ text-align: center;
+}
+a
+{
+ color: #B31616;
+ font-weight: bold;
+}
+a:link {
+ }
+a:visited {
+ }
+a:active {
+ }
+a:hover {
+ color: red;
+ }
+h1, h2, h3, h4, h5, h6 {
+ font-family: Arial, sans-serif;
+ font-weight: normal;
+}
+h1 {
+ color: #B31616;
+ font-weight: bold;
+ letter-spacing: -2px;
+ font-size: 2.2em;
+ border-bottom: 1px solid silver;
+ padding-bottom: 5px;
+ }
+h2 {
+ font-size: 1.5em;
+ border-bottom: 1px solid silver;
+ padding-bottom: 3px;
+ clear: both;
+ }
+h3 {
+ font-size: 1.2em;
+ }
+h4 {
+ font-size: 1.1em;
+ }
+h5 {
+ font-size: 1.0em;
+ }
+h6 {
+ font-size: 0.8em;
+ }
+img {
+ border: 0;
+ }
+ol, ul, li {
+ font-size: 1.0em;
+ }
+p, table, tr, td, th {
+ font-size: 1.0em;
+ }
+pre {
+ font-family: Courier New,Courier,monospace;
+ font-size: 1.0em;
+ }
+strong, b {
+ font-weight: bold;
+ }
+table, tr, td {
+ font-size: 1.0em;
+ border-collapse: collapse;
+}
+td, th {
+ border: 1px solid #aaaaaa;
+ border-collapse: collapse;
+ padding: 3px;
+}
+th {
+ background: #3667A8;
+ color: white;
+}
+ol ol {
+ list-style-type: lower-alpha;
+}
+.content {
+ text-align: left;
+ margin-left: auto;
+ margin-right: auto;
+ width: 780px;
+ background-color: #FFFFFF;
+ border-left: 1px solid Black;
+ border-right: 1px solid Black;
+ padding: 12px 30px;
+ line-height: 150%;
+}
+.logo {
+ background: #ffffff url("Other/Help/images/help_background_header.png") repeat-x;
+ width: 840px;
+ margin-top: 20px;
+ margin-left: auto;
+ margin-right: auto;
+ text-align: left;
+ border-right: 1px solid black;
+ border-left: 1px solid black;
+}
+.footer {
+ background: #ffffff url("Other/Help/images/help_background_footer.png") repeat-x;
+ width: 840px;
+ height: 16px;
+ margin-left: auto;
+ margin-right: auto;
+ text-align: left;
+ border-right: 1px solid black;
+ border-left: 1px solid black;
+}
+.logo img {
+ padding-left: 0px;
+ border: none;
+ position: relative;
+ top: -4px;
+}
+* html .content {
+ width: 760px;
+}
+* html .logo, * html .footer {
+ width: 820px;
+}
+.content h1 {
+ margin: 0px;
+}
+h1.hastagline {
+ border: 0;
+}
+h2.tagline {
+ color: #747673;
+ clear: none;
+ margin-top: 0em;
+}
+/*printer styles*/
+@media print{
+body, .content {margin: 0; padding: 0;}
+.navigation, .locator, .footer a, .message, .footer-links {display:none;}
+.footer, .content, .header {border: none;}
+a {text-decoration: none; font-weight: normal; color: black;}
+}</style>
+</head>
+<body>
+<div class="logo"><a href="http://portableapps.com/"><img src="Other/Help/images/help_logo_top.png" width="229" height="47" alt="PortableApps.com - Your Digital Life, Anywhere"></a></div>
+<div class="content">
+<h1 class="hastagline">Inkscape Portable Help</h1>
+<h2 class="tagline">amazing vector graphics - everywhere!</h2>
+<p>Inkscape Portable is the popular Inkscape vector graphics editor packaged with a PortableApps.com launcher as a <a href="http://portableapps.com/about/what_is_a_portable_app">portable app</a>, to help you design on your iPod, USB flash drive, portable hard drive, etc. It has all the same great features as Inkscape including editing vector graphics, designing things and more. Plus, it leaves no personal information behind on the machine you run it on, so you can take it with you wherever you go. <a href="http://inkscape.org/">Learn more about Inkscape...</a></p>
-<p><a href="http://inkscape.org/donate.php"><img src="Other/Help/images/donation_button.png" width="110" height="23" border="0" align="top" alt="Make a Donation"></a> - Support Inkscape Development</p>
-<p><a href="http://portableapps.com/donate"><img src="Other/Help/images/donation_button.png" width="110" height="23" border="0" align="top" alt="Make a Donation"></a> - Support PortableApps.com's Hosting and Development</p>
-
-<p><a href="http://inkscape.org/">Go to the Inkscape Portable Homepage &gt;&gt;</a></p>
-
-<p><a href="http://PortableApps.com/">Get more portable apps at PortableApps.com</a></p>
-
-<p>This software is OSI Certified Open Source Software. OSI Certified is a certification mark of the Open Source Initiative.</p>
-
-<h2>Portable App Issues</h2>
-<ul>
- <li><a href="http://portableapps.com/support/portable_app#downloading">Downloading a Portable App</a></li>
- <li><a href="http://portableapps.com/support/portable_app#installing">Installing a Portable App</a></li>
- <li><a href="http://portableapps.com/support/portable_app#using">Using a Portable App</a></li>
- <li><a href="http://portableapps.com/support/portable_app#upgrading">Upgrading a Portable App</a></li>
-</ul>
-<p>You can read about advanced configuration options for the Inkscape Portable launcher in its <a href="Other\Source\Readme.txt">readme file</a>.
-</div>
-<div class="footer"></div>
-</body>
-</html>
+<p><a href="http://inkscape.org/donate.php"><img src="Other/Help/images/donation_button.png" width="110" height="23" border="0" align="top" alt="Make a Donation"></a> - Support Inkscape Development</p>
+<p><a href="http://portableapps.com/donate"><img src="Other/Help/images/donation_button.png" width="110" height="23" border="0" align="top" alt="Make a Donation"></a> - Support PortableApps.com's Hosting and Development</p>
+
+<p><a href="http://inkscape.org/">Go to the Inkscape Portable Homepage &gt;&gt;</a></p>
+
+<p><a href="http://PortableApps.com/">Get more portable apps at PortableApps.com</a></p>
+
+<p>This software is OSI Certified Open Source Software. OSI Certified is a certification mark of the Open Source Initiative.</p>
+
+<h2>Portable App Issues</h2>
+<ul>
+ <li><a href="http://portableapps.com/support/portable_app#downloading">Downloading a Portable App</a></li>
+ <li><a href="http://portableapps.com/support/portable_app#installing">Installing a Portable App</a></li>
+ <li><a href="http://portableapps.com/support/portable_app#using">Using a Portable App</a></li>
+ <li><a href="http://portableapps.com/support/portable_app#upgrading">Upgrading a Portable App</a></li>
+</ul>
+<p>You can read about advanced configuration options for the Inkscape Portable launcher in its <a href="Other\Source\Readme.txt">readme file</a>.
+</div>
+<div class="footer"></div>
+</body>
+</html>
diff --git a/share/extensions/Poly3DObjects/cube.obj b/share/extensions/Poly3DObjects/cube.obj
index ed249d456..b577ce11d 100644
--- a/share/extensions/Poly3DObjects/cube.obj
+++ b/share/extensions/Poly3DObjects/cube.obj
@@ -1,19 +1,19 @@
-#Name:Cube
-#Type:Face-specified
-#Direction:Clockwise
-
-v -0.5 -0.5 -0.5
-v -0.5 -0.5 0.5
-v -0.5 0.5 -0.5
-v -0.5 0.5 0.5
-v 0.5 -0.5 -0.5
-v 0.5 -0.5 0.5
-v 0.5 0.5 -0.5
-v 0.5 0.5 0.5
-
-f 8 4 2 6
-f 8 6 5 7
-f 8 7 3 4
-f 4 3 1 2
-f 1 3 7 5
+#Name:Cube
+#Type:Face-specified
+#Direction:Clockwise
+
+v -0.5 -0.5 -0.5
+v -0.5 -0.5 0.5
+v -0.5 0.5 -0.5
+v -0.5 0.5 0.5
+v 0.5 -0.5 -0.5
+v 0.5 -0.5 0.5
+v 0.5 0.5 -0.5
+v 0.5 0.5 0.5
+
+f 8 4 2 6
+f 8 6 5 7
+f 8 7 3 4
+f 4 3 1 2
+f 1 3 7 5
f 2 1 5 6 \ No newline at end of file
diff --git a/share/extensions/Poly3DObjects/cuboct.obj b/share/extensions/Poly3DObjects/cuboct.obj
index 030743f92..709606bca 100644
--- a/share/extensions/Poly3DObjects/cuboct.obj
+++ b/share/extensions/Poly3DObjects/cuboct.obj
@@ -1,30 +1,30 @@
-#Name:Cuboctahedron
-#Type:Face_specified
-
-v -1. 0 0
-v -0.5 -0.5 -0.70710678
-v -0.5 -0.5 0.70710678
-v -0.5 0.5 -0.70710678
-v -0.5 0.5 0.70710678
-v 0 -1. 0
-v 0 1. 0
-v 0.5 -0.5 -0.70710678
-v 0.5 -0.5 0.70710678
-v 0.5 0.5 -0.70710678
-v 0.5 0.5 0.70710678
-v 1. 0 0
-
-f 12 11 9
-f 3 5 1
-f 6 9 3
-f 5 11 7
-f 8 10 12
-f 1 4 2
-f 2 8 6
-f 7 10 4
-f 4 10 8 2
-f 3 9 11 5
-f 9 6 8 12
-f 3 1 2 6
-f 5 7 4 1
-f 11 12 10 7
+#Name:Cuboctahedron
+#Type:Face_specified
+
+v -1. 0 0
+v -0.5 -0.5 -0.70710678
+v -0.5 -0.5 0.70710678
+v -0.5 0.5 -0.70710678
+v -0.5 0.5 0.70710678
+v 0 -1. 0
+v 0 1. 0
+v 0.5 -0.5 -0.70710678
+v 0.5 -0.5 0.70710678
+v 0.5 0.5 -0.70710678
+v 0.5 0.5 0.70710678
+v 1. 0 0
+
+f 12 11 9
+f 3 5 1
+f 6 9 3
+f 5 11 7
+f 8 10 12
+f 1 4 2
+f 2 8 6
+f 7 10 4
+f 4 10 8 2
+f 3 9 11 5
+f 9 6 8 12
+f 3 1 2 6
+f 5 7 4 1
+f 11 12 10 7
diff --git a/share/extensions/Poly3DObjects/dodec.obj b/share/extensions/Poly3DObjects/dodec.obj
index 823f53911..5b66f09e0 100644
--- a/share/extensions/Poly3DObjects/dodec.obj
+++ b/share/extensions/Poly3DObjects/dodec.obj
@@ -1,36 +1,36 @@
-#NameDodecahedron
-#Type:Face_specified
-
-v 0 0 1.4012585
-v 0 0 -1.4012585
-v 0.17841104 -1.3090170 0.46708618
-v 0.17841104 1.3090170 0.46708618
-v 0.46708618 -0.80901699 -1.0444364
-v 0.46708618 0.80901699 -1.0444364
-v 1.0444364 -0.80901699 0.46708618
-v 1.0444364 0.80901699 0.46708618
-v -1.2228475 -0.5 0.46708618
-v -1.2228475 0.5 0.46708618
-v 1.2228475 -0.5 -0.46708618
-v 1.2228475 0.5 -0.46708618
-v -0.93417236 0 -1.0444364
-v -0.46708618 -0.80901699 1.0444364
-v -0.46708618 0.80901699 1.0444364
-v 0.93417236 0 1.0444364
-v -1.0444364 -0.80901699 -0.46708618
-v -1.0444364 0.80901699 -0.46708618
-v -0.17841104 -1.3090170 -0.46708618
-v -0.17841104 1.3090170 -0.46708618
-
-f 15 10 9 14 1
-f 2 6 12 11 5
-f 5 11 7 3 19
-f 11 12 8 16 7
-f 12 6 20 4 8
-f 6 2 13 18 20
-f 2 5 19 17 13
-f 4 20 18 10 15
-f 18 13 17 9 10
-f 17 19 3 14 9
-f 3 7 16 1 14
-f 16 8 4 15 1
+#NameDodecahedron
+#Type:Face_specified
+
+v 0 0 1.4012585
+v 0 0 -1.4012585
+v 0.17841104 -1.3090170 0.46708618
+v 0.17841104 1.3090170 0.46708618
+v 0.46708618 -0.80901699 -1.0444364
+v 0.46708618 0.80901699 -1.0444364
+v 1.0444364 -0.80901699 0.46708618
+v 1.0444364 0.80901699 0.46708618
+v -1.2228475 -0.5 0.46708618
+v -1.2228475 0.5 0.46708618
+v 1.2228475 -0.5 -0.46708618
+v 1.2228475 0.5 -0.46708618
+v -0.93417236 0 -1.0444364
+v -0.46708618 -0.80901699 1.0444364
+v -0.46708618 0.80901699 1.0444364
+v 0.93417236 0 1.0444364
+v -1.0444364 -0.80901699 -0.46708618
+v -1.0444364 0.80901699 -0.46708618
+v -0.17841104 -1.3090170 -0.46708618
+v -0.17841104 1.3090170 -0.46708618
+
+f 15 10 9 14 1
+f 2 6 12 11 5
+f 5 11 7 3 19
+f 11 12 8 16 7
+f 12 6 20 4 8
+f 6 2 13 18 20
+f 2 5 19 17 13
+f 4 20 18 10 15
+f 18 13 17 9 10
+f 17 19 3 14 9
+f 3 7 16 1 14
+f 16 8 4 15 1
diff --git a/share/extensions/Poly3DObjects/great_dodec.obj b/share/extensions/Poly3DObjects/great_dodec.obj
index 8feac9c6c..2d12f028e 100644
--- a/share/extensions/Poly3DObjects/great_dodec.obj
+++ b/share/extensions/Poly3DObjects/great_dodec.obj
@@ -1,96 +1,96 @@
-#Name:Great Dodecahedron
-#Type:Face_specified
-
-v 0. 0. -0.951057
-v 0. 0. 0.951057
-v -0.425325 -0.309017 -0.100406
-v -0.425325 0.309017 -0.100406
-v 0.425325 -0.309017 0.100406
-v 0.425325 0.309017 0.100406
-v -0.688191 -0.5 0.425325
-v -0.688191 0.5 0.425325
-v 0.688191 -0.5 -0.425325
-v 0.688191 0.5 -0.425325
-v -0.850651 0. -0.425325
-v 0.850651 0. 0.425325
-v -0.100406 -0.309017 0.425325
-v -0.100406 0.309017 0.425325
-v 0.100406 -0.309017 -0.425325
-v 0.100406 0.309017 -0.425325
-v -0.32492 0. 0.425325
-v -0.16246 -0.5 0.100406
-v -0.16246 0.5 0.100406
-v 0.16246 -0.5 -0.100406
-v 0.16246 0.5 -0.100406
-v 0.32492 0. -0.425325
-v -0.525731 0. 0.100406
-v -0.262866 -0.809017 -0.425325
-v -0.262866 0.190983 -0.425325
-v -0.262866 -0.190983 -0.425325
-v -0.262866 0.809017 -0.425325
-v 0.262866 -0.809017 0.425325
-v 0.262866 0.190983 0.425325
-v 0.262866 -0.190983 0.425325
-v 0.262866 0.809017 0.425325
-v 0.525731 0. -0.100406
-
-f 14 2 31
-f 14 31 8
-f 14 8 2
-f 17 2 8
-f 17 8 7
-f 17 7 2
-f 13 2 7
-f 13 7 28
-f 13 28 2
-f 30 2 28
-f 30 28 12
-f 30 12 2
-f 29 2 12
-f 29 12 31
-f 29 31 2
-f 15 9 24
-f 15 24 1
-f 15 1 9
-f 22 10 9
-f 22 9 1
-f 22 1 10
-f 16 27 10
-f 16 10 1
-f 16 1 27
-f 25 11 27
-f 25 27 1
-f 25 1 11
-f 26 24 11
-f 26 11 1
-f 26 1 24
-f 19 31 27
-f 19 27 8
-f 19 8 31
-f 23 8 11
-f 23 11 7
-f 23 7 8
-f 18 7 24
-f 18 24 28
-f 18 28 7
-f 5 28 9
-f 5 9 12
-f 5 12 28
-f 6 12 10
-f 6 10 31
-f 6 31 12
-f 20 9 28
-f 20 28 24
-f 20 24 9
-f 32 10 12
-f 32 12 9
-f 32 9 10
-f 21 27 31
-f 21 31 10
-f 21 10 27
-f 4 11 8
-f 4 8 27
-f 4 27 11
-f 3 24 7
-f 3 7 11
-f 3 11 24
+#Name:Great Dodecahedron
+#Type:Face_specified
+
+v 0. 0. -0.951057
+v 0. 0. 0.951057
+v -0.425325 -0.309017 -0.100406
+v -0.425325 0.309017 -0.100406
+v 0.425325 -0.309017 0.100406
+v 0.425325 0.309017 0.100406
+v -0.688191 -0.5 0.425325
+v -0.688191 0.5 0.425325
+v 0.688191 -0.5 -0.425325
+v 0.688191 0.5 -0.425325
+v -0.850651 0. -0.425325
+v 0.850651 0. 0.425325
+v -0.100406 -0.309017 0.425325
+v -0.100406 0.309017 0.425325
+v 0.100406 -0.309017 -0.425325
+v 0.100406 0.309017 -0.425325
+v -0.32492 0. 0.425325
+v -0.16246 -0.5 0.100406
+v -0.16246 0.5 0.100406
+v 0.16246 -0.5 -0.100406
+v 0.16246 0.5 -0.100406
+v 0.32492 0. -0.425325
+v -0.525731 0. 0.100406
+v -0.262866 -0.809017 -0.425325
+v -0.262866 0.190983 -0.425325
+v -0.262866 -0.190983 -0.425325
+v -0.262866 0.809017 -0.425325
+v 0.262866 -0.809017 0.425325
+v 0.262866 0.190983 0.425325
+v 0.262866 -0.190983 0.425325
+v 0.262866 0.809017 0.425325
+v 0.525731 0. -0.100406
+
+f 14 2 31
+f 14 31 8
+f 14 8 2
+f 17 2 8
+f 17 8 7
+f 17 7 2
+f 13 2 7
+f 13 7 28
+f 13 28 2
+f 30 2 28
+f 30 28 12
+f 30 12 2
+f 29 2 12
+f 29 12 31
+f 29 31 2
+f 15 9 24
+f 15 24 1
+f 15 1 9
+f 22 10 9
+f 22 9 1
+f 22 1 10
+f 16 27 10
+f 16 10 1
+f 16 1 27
+f 25 11 27
+f 25 27 1
+f 25 1 11
+f 26 24 11
+f 26 11 1
+f 26 1 24
+f 19 31 27
+f 19 27 8
+f 19 8 31
+f 23 8 11
+f 23 11 7
+f 23 7 8
+f 18 7 24
+f 18 24 28
+f 18 28 7
+f 5 28 9
+f 5 9 12
+f 5 12 28
+f 6 12 10
+f 6 10 31
+f 6 31 12
+f 20 9 28
+f 20 28 24
+f 20 24 9
+f 32 10 12
+f 32 12 9
+f 32 9 10
+f 21 27 31
+f 21 31 10
+f 21 10 27
+f 4 11 8
+f 4 8 27
+f 4 27 11
+f 3 24 7
+f 3 7 11
+f 3 11 24
diff --git a/share/extensions/Poly3DObjects/great_rhombicosidodec.obj b/share/extensions/Poly3DObjects/great_rhombicosidodec.obj
index 7dffdd757..88bdccc55 100644
--- a/share/extensions/Poly3DObjects/great_rhombicosidodec.obj
+++ b/share/extensions/Poly3DObjects/great_rhombicosidodec.obj
@@ -1,185 +1,185 @@
-#Name:Great Rhombicosidodecahedron
-#Type:face_specified
-v -1. -1.30902 -3.42705
-v -1. -1.30902 3.42705
-v -1. 1.30902 -3.42705
-v -1. 1.30902 3.42705
-v -0.5 -0.5 -3.73607
-v -0.5 -0.5 3.73607
-v -0.5 0.5 -3.73607
-v -0.5 0.5 3.73607
-v -0.5 -3.73607 -0.5
-v -0.5 -3.73607 0.5
-v -0.5 -2.11803 -3.11803
-v -0.5 -2.11803 3.11803
-v -0.5 3.73607 -0.5
-v -0.5 3.73607 0.5
-v -0.5 2.11803 -3.11803
-v -0.5 2.11803 3.11803
-v 0.5 -0.5 -3.73607
-v 0.5 -0.5 3.73607
-v 0.5 0.5 -3.73607
-v 0.5 0.5 3.73607
-v 0.5 -3.73607 -0.5
-v 0.5 -3.73607 0.5
-v 0.5 -2.11803 -3.11803
-v 0.5 -2.11803 3.11803
-v 0.5 3.73607 -0.5
-v 0.5 3.73607 0.5
-v 0.5 2.11803 -3.11803
-v 0.5 2.11803 3.11803
-v 1. -1.30902 -3.42705
-v 1. -1.30902 3.42705
-v 1. 1.30902 -3.42705
-v 1. 1.30902 3.42705
-v -3.42705 -1. -1.30902
-v -3.42705 -1. 1.30902
-v -3.42705 1. -1.30902
-v -3.42705 1. 1.30902
-v -2.92705 -1.80902 -1.61803
-v -2.92705 -1.80902 1.61803
-v -2.92705 1.80902 -1.61803
-v -2.92705 1.80902 1.61803
-v -1.80902 -1.61803 -2.92705
-v -1.80902 -1.61803 2.92705
-v -1.80902 1.61803 -2.92705
-v -1.80902 1.61803 2.92705
-v -1.30902 -3.42705 -1.
-v -1.30902 -3.42705 1.
-v -1.30902 -2.42705 -2.61803
-v -1.30902 -2.42705 2.61803
-v -1.30902 2.42705 -2.61803
-v -1.30902 2.42705 2.61803
-v -1.30902 3.42705 -1.
-v -1.30902 3.42705 1.
-v -2.61803 -1.30902 -2.42705
-v -2.61803 -1.30902 2.42705
-v -2.61803 1.30902 -2.42705
-v -2.61803 1.30902 2.42705
-v -3.73607 -0.5 -0.5
-v -3.73607 -0.5 0.5
-v -3.73607 0.5 -0.5
-v -3.73607 0.5 0.5
-v -1.61803 -2.92705 -1.80902
-v -1.61803 -2.92705 1.80902
-v -1.61803 2.92705 -1.80902
-v -1.61803 2.92705 1.80902
-v -3.11803 -0.5 -2.11803
-v -3.11803 -0.5 2.11803
-v -3.11803 0.5 -2.11803
-v -3.11803 0.5 2.11803
-v -2.11803 -3.11803 -0.5
-v -2.11803 -3.11803 0.5
-v -2.11803 3.11803 -0.5
-v -2.11803 3.11803 0.5
-v -2.42705 -2.61803 -1.30902
-v -2.42705 -2.61803 1.30902
-v -2.42705 2.61803 -1.30902
-v -2.42705 2.61803 1.30902
-v 1.61803 -2.92705 -1.80902
-v 1.61803 -2.92705 1.80902
-v 1.61803 2.92705 -1.80902
-v 1.61803 2.92705 1.80902
-v 2.42705 -2.61803 -1.30902
-v 2.42705 -2.61803 1.30902
-v 2.42705 2.61803 -1.30902
-v 2.42705 2.61803 1.30902
-v 3.73607 -0.5 -0.5
-v 3.73607 -0.5 0.5
-v 3.73607 0.5 -0.5
-v 3.73607 0.5 0.5
-v 2.11803 -3.11803 -0.5
-v 2.11803 -3.11803 0.5
-v 2.11803 3.11803 -0.5
-v 2.11803 3.11803 0.5
-v 1.30902 -3.42705 -1.
-v 1.30902 -3.42705 1.
-v 1.30902 -2.42705 -2.61803
-v 1.30902 -2.42705 2.61803
-v 1.30902 2.42705 -2.61803
-v 1.30902 2.42705 2.61803
-v 1.30902 3.42705 -1.
-v 1.30902 3.42705 1.
-v 2.61803 -1.30902 -2.42705
-v 2.61803 -1.30902 2.42705
-v 2.61803 1.30902 -2.42705
-v 2.61803 1.30902 2.42705
-v 3.11803 -0.5 -2.11803
-v 3.11803 -0.5 2.11803
-v 3.11803 0.5 -2.11803
-v 3.11803 0.5 2.11803
-v 1.80902 -1.61803 -2.92705
-v 1.80902 -1.61803 2.92705
-v 1.80902 1.61803 -2.92705
-v 1.80902 1.61803 2.92705
-v 2.92705 -1.80902 -1.61803
-v 2.92705 -1.80902 1.61803
-v 2.92705 1.80902 -1.61803
-v 2.92705 1.80902 1.61803
-v 3.42705 -1. -1.30902
-v 3.42705 -1. 1.30902
-v 3.42705 1. -1.30902
-v 3.42705 1. 1.30902
-
-f 2 6 8 4 44 56 68 66 54 42
-f 109 29 17 19 31 111 103 107 105 101
-f 24 30 18 6 2 12
-f 7 3 15 27 31 19
-f 58 57 33 37 73 69 70 74 38 34
-f 84 116 120 88 87 119 115 83 91 92
-f 90 89 81 113 117 85 86 118 114 82
-f 36 40 76 72 71 75 39 35 59 60
-f 5 17 29 23 11 1
-f 4 8 20 32 28 16
-f 67 55 43 3 7 5 1 41 53 65
-f 18 30 110 102 106 108 104 112 32 20
-f 79 83 115 103 111 97
-f 38 74 62 48 42 54
-f 4 16 50 44
-f 23 29 109 95
-f 96 110 30 24
-f 43 49 15 3
-f 53 41 47 61 73 37
-f 98 112 104 116 84 80
-f 69 45 9 10 46 70
-f 26 100 92 91 99 25
-f 82 114 102 110 96 78
-f 55 39 75 63 49 43
-f 1 11 47 41
-f 28 32 112 98
-f 61 47 11 23 95 77 93 21 9 45
-f 50 16 28 98 80 100 26 14 52 64
-f 97 111 31 27
-f 42 48 12 2
-f 44 50 64 76 40 56
-f 77 95 109 101 113 81
-f 63 51 13 25 99 79 97 27 15 49
-f 46 10 22 94 78 96 24 12 48 62
-f 52 14 13 51 71 72
-f 22 21 93 89 90 94
-f 115 119 107 103
-f 34 38 54 66
-f 71 51 63 75
-f 94 90 82 78
-f 114 118 106 102
-f 35 39 55 67
-f 70 46 62 74
-f 99 91 83 79
-f 65 53 37 33
-f 104 108 120 116
-f 77 81 89 93
-f 76 64 52 72
-f 59 35 67 65 33 57
-f 106 118 86 88 120 108
-f 68 56 40 36
-f 101 105 117 113
-f 80 84 92 100
-f 73 61 45 69
-f 34 66 68 36 60 58
-f 105 107 119 87 85 117
-f 7 19 17 5
-f 6 18 20 8
-f 14 26 25 13
-f 9 21 22 10
-f 58 60 59 57
-f 85 87 88 86
+#Name:Great Rhombicosidodecahedron
+#Type:face_specified
+v -1. -1.30902 -3.42705
+v -1. -1.30902 3.42705
+v -1. 1.30902 -3.42705
+v -1. 1.30902 3.42705
+v -0.5 -0.5 -3.73607
+v -0.5 -0.5 3.73607
+v -0.5 0.5 -3.73607
+v -0.5 0.5 3.73607
+v -0.5 -3.73607 -0.5
+v -0.5 -3.73607 0.5
+v -0.5 -2.11803 -3.11803
+v -0.5 -2.11803 3.11803
+v -0.5 3.73607 -0.5
+v -0.5 3.73607 0.5
+v -0.5 2.11803 -3.11803
+v -0.5 2.11803 3.11803
+v 0.5 -0.5 -3.73607
+v 0.5 -0.5 3.73607
+v 0.5 0.5 -3.73607
+v 0.5 0.5 3.73607
+v 0.5 -3.73607 -0.5
+v 0.5 -3.73607 0.5
+v 0.5 -2.11803 -3.11803
+v 0.5 -2.11803 3.11803
+v 0.5 3.73607 -0.5
+v 0.5 3.73607 0.5
+v 0.5 2.11803 -3.11803
+v 0.5 2.11803 3.11803
+v 1. -1.30902 -3.42705
+v 1. -1.30902 3.42705
+v 1. 1.30902 -3.42705
+v 1. 1.30902 3.42705
+v -3.42705 -1. -1.30902
+v -3.42705 -1. 1.30902
+v -3.42705 1. -1.30902
+v -3.42705 1. 1.30902
+v -2.92705 -1.80902 -1.61803
+v -2.92705 -1.80902 1.61803
+v -2.92705 1.80902 -1.61803
+v -2.92705 1.80902 1.61803
+v -1.80902 -1.61803 -2.92705
+v -1.80902 -1.61803 2.92705
+v -1.80902 1.61803 -2.92705
+v -1.80902 1.61803 2.92705
+v -1.30902 -3.42705 -1.
+v -1.30902 -3.42705 1.
+v -1.30902 -2.42705 -2.61803
+v -1.30902 -2.42705 2.61803
+v -1.30902 2.42705 -2.61803
+v -1.30902 2.42705 2.61803
+v -1.30902 3.42705 -1.
+v -1.30902 3.42705 1.
+v -2.61803 -1.30902 -2.42705
+v -2.61803 -1.30902 2.42705
+v -2.61803 1.30902 -2.42705
+v -2.61803 1.30902 2.42705
+v -3.73607 -0.5 -0.5
+v -3.73607 -0.5 0.5
+v -3.73607 0.5 -0.5
+v -3.73607 0.5 0.5
+v -1.61803 -2.92705 -1.80902
+v -1.61803 -2.92705 1.80902
+v -1.61803 2.92705 -1.80902
+v -1.61803 2.92705 1.80902
+v -3.11803 -0.5 -2.11803
+v -3.11803 -0.5 2.11803
+v -3.11803 0.5 -2.11803
+v -3.11803 0.5 2.11803
+v -2.11803 -3.11803 -0.5
+v -2.11803 -3.11803 0.5
+v -2.11803 3.11803 -0.5
+v -2.11803 3.11803 0.5
+v -2.42705 -2.61803 -1.30902
+v -2.42705 -2.61803 1.30902
+v -2.42705 2.61803 -1.30902
+v -2.42705 2.61803 1.30902
+v 1.61803 -2.92705 -1.80902
+v 1.61803 -2.92705 1.80902
+v 1.61803 2.92705 -1.80902
+v 1.61803 2.92705 1.80902
+v 2.42705 -2.61803 -1.30902
+v 2.42705 -2.61803 1.30902
+v 2.42705 2.61803 -1.30902
+v 2.42705 2.61803 1.30902
+v 3.73607 -0.5 -0.5
+v 3.73607 -0.5 0.5
+v 3.73607 0.5 -0.5
+v 3.73607 0.5 0.5
+v 2.11803 -3.11803 -0.5
+v 2.11803 -3.11803 0.5
+v 2.11803 3.11803 -0.5
+v 2.11803 3.11803 0.5
+v 1.30902 -3.42705 -1.
+v 1.30902 -3.42705 1.
+v 1.30902 -2.42705 -2.61803
+v 1.30902 -2.42705 2.61803
+v 1.30902 2.42705 -2.61803
+v 1.30902 2.42705 2.61803
+v 1.30902 3.42705 -1.
+v 1.30902 3.42705 1.
+v 2.61803 -1.30902 -2.42705
+v 2.61803 -1.30902 2.42705
+v 2.61803 1.30902 -2.42705
+v 2.61803 1.30902 2.42705
+v 3.11803 -0.5 -2.11803
+v 3.11803 -0.5 2.11803
+v 3.11803 0.5 -2.11803
+v 3.11803 0.5 2.11803
+v 1.80902 -1.61803 -2.92705
+v 1.80902 -1.61803 2.92705
+v 1.80902 1.61803 -2.92705
+v 1.80902 1.61803 2.92705
+v 2.92705 -1.80902 -1.61803
+v 2.92705 -1.80902 1.61803
+v 2.92705 1.80902 -1.61803
+v 2.92705 1.80902 1.61803
+v 3.42705 -1. -1.30902
+v 3.42705 -1. 1.30902
+v 3.42705 1. -1.30902
+v 3.42705 1. 1.30902
+
+f 2 6 8 4 44 56 68 66 54 42
+f 109 29 17 19 31 111 103 107 105 101
+f 24 30 18 6 2 12
+f 7 3 15 27 31 19
+f 58 57 33 37 73 69 70 74 38 34
+f 84 116 120 88 87 119 115 83 91 92
+f 90 89 81 113 117 85 86 118 114 82
+f 36 40 76 72 71 75 39 35 59 60
+f 5 17 29 23 11 1
+f 4 8 20 32 28 16
+f 67 55 43 3 7 5 1 41 53 65
+f 18 30 110 102 106 108 104 112 32 20
+f 79 83 115 103 111 97
+f 38 74 62 48 42 54
+f 4 16 50 44
+f 23 29 109 95
+f 96 110 30 24
+f 43 49 15 3
+f 53 41 47 61 73 37
+f 98 112 104 116 84 80
+f 69 45 9 10 46 70
+f 26 100 92 91 99 25
+f 82 114 102 110 96 78
+f 55 39 75 63 49 43
+f 1 11 47 41
+f 28 32 112 98
+f 61 47 11 23 95 77 93 21 9 45
+f 50 16 28 98 80 100 26 14 52 64
+f 97 111 31 27
+f 42 48 12 2
+f 44 50 64 76 40 56
+f 77 95 109 101 113 81
+f 63 51 13 25 99 79 97 27 15 49
+f 46 10 22 94 78 96 24 12 48 62
+f 52 14 13 51 71 72
+f 22 21 93 89 90 94
+f 115 119 107 103
+f 34 38 54 66
+f 71 51 63 75
+f 94 90 82 78
+f 114 118 106 102
+f 35 39 55 67
+f 70 46 62 74
+f 99 91 83 79
+f 65 53 37 33
+f 104 108 120 116
+f 77 81 89 93
+f 76 64 52 72
+f 59 35 67 65 33 57
+f 106 118 86 88 120 108
+f 68 56 40 36
+f 101 105 117 113
+f 80 84 92 100
+f 73 61 45 69
+f 34 66 68 36 60 58
+f 105 107 119 87 85 117
+f 7 19 17 5
+f 6 18 20 8
+f 14 26 25 13
+f 9 21 22 10
+f 58 60 59 57
+f 85 87 88 86
diff --git a/share/extensions/Poly3DObjects/great_rhombicuboct.obj b/share/extensions/Poly3DObjects/great_rhombicuboct.obj
index eb9bdb714..1ef7b4c79 100644
--- a/share/extensions/Poly3DObjects/great_rhombicuboct.obj
+++ b/share/extensions/Poly3DObjects/great_rhombicuboct.obj
@@ -1,77 +1,77 @@
-#Name:Great Rhombicuboctahedron
-#Type:face_specified
-v -0.5 1.20711 -1.91421
-v -0.5 1.20711 1.91421
-v -0.5 -1.20711 -1.91421
-v -0.5 -1.20711 1.91421
-v -0.5 -1.91421 1.20711
-v -0.5 -1.91421 -1.20711
-v -0.5 1.91421 1.20711
-v -0.5 1.91421 -1.20711
-v 0.5 1.20711 -1.91421
-v 0.5 1.20711 1.91421
-v 0.5 -1.20711 -1.91421
-v 0.5 -1.20711 1.91421
-v 0.5 -1.91421 1.20711
-v 0.5 -1.91421 -1.20711
-v 0.5 1.91421 1.20711
-v 0.5 1.91421 -1.20711
-v 1.20711 -0.5 -1.91421
-v 1.20711 -0.5 1.91421
-v 1.20711 0.5 -1.91421
-v 1.20711 0.5 1.91421
-v 1.20711 -1.91421 -0.5
-v 1.20711 -1.91421 0.5
-v 1.20711 1.91421 -0.5
-v 1.20711 1.91421 0.5
-v -1.20711 -0.5 -1.91421
-v -1.20711 -0.5 1.91421
-v -1.20711 0.5 -1.91421
-v -1.20711 0.5 1.91421
-v -1.20711 -1.91421 -0.5
-v -1.20711 -1.91421 0.5
-v -1.20711 1.91421 -0.5
-v -1.20711 1.91421 0.5
-v -1.91421 -0.5 1.20711
-v -1.91421 -0.5 -1.20711
-v -1.91421 0.5 1.20711
-v -1.91421 0.5 -1.20711
-v -1.91421 1.20711 -0.5
-v -1.91421 1.20711 0.5
-v -1.91421 -1.20711 -0.5
-v -1.91421 -1.20711 0.5
-v 1.91421 -0.5 1.20711
-v 1.91421 -0.5 -1.20711
-v 1.91421 0.5 1.20711
-v 1.91421 0.5 -1.20711
-v 1.91421 1.20711 -0.5
-v 1.91421 1.20711 0.5
-v 1.91421 -1.20711 -0.5
-v 1.91421 -1.20711 0.5
-
-f 44 42 17 19
-f 14 6 3 11
-f 34 36 27 25
-f 8 16 9 1
-f 20 18 41 43
-f 12 4 5 13
-f 26 28 35 33
-f 2 10 15 7
-f 45 23 24 46
-f 39 29 30 40
-f 48 22 21 47
-f 38 32 31 37
-f 9 19 17 11 3 25 27 1
-f 2 28 26 4 12 18 20 10
-f 41 48 47 42 44 45 46 43
-f 35 38 37 36 34 39 40 33
-f 15 24 23 16 8 31 32 7
-f 5 30 29 6 14 21 22 13
-f 46 24 15 10 20 43
-f 35 28 2 7 32 38
-f 41 18 12 13 22 48
-f 40 30 5 4 26 33
-f 44 19 9 16 23 45
-f 37 31 8 1 27 36
-f 47 21 14 11 17 42
-f 34 25 3 6 29 39
+#Name:Great Rhombicuboctahedron
+#Type:face_specified
+v -0.5 1.20711 -1.91421
+v -0.5 1.20711 1.91421
+v -0.5 -1.20711 -1.91421
+v -0.5 -1.20711 1.91421
+v -0.5 -1.91421 1.20711
+v -0.5 -1.91421 -1.20711
+v -0.5 1.91421 1.20711
+v -0.5 1.91421 -1.20711
+v 0.5 1.20711 -1.91421
+v 0.5 1.20711 1.91421
+v 0.5 -1.20711 -1.91421
+v 0.5 -1.20711 1.91421
+v 0.5 -1.91421 1.20711
+v 0.5 -1.91421 -1.20711
+v 0.5 1.91421 1.20711
+v 0.5 1.91421 -1.20711
+v 1.20711 -0.5 -1.91421
+v 1.20711 -0.5 1.91421
+v 1.20711 0.5 -1.91421
+v 1.20711 0.5 1.91421
+v 1.20711 -1.91421 -0.5
+v 1.20711 -1.91421 0.5
+v 1.20711 1.91421 -0.5
+v 1.20711 1.91421 0.5
+v -1.20711 -0.5 -1.91421
+v -1.20711 -0.5 1.91421
+v -1.20711 0.5 -1.91421
+v -1.20711 0.5 1.91421
+v -1.20711 -1.91421 -0.5
+v -1.20711 -1.91421 0.5
+v -1.20711 1.91421 -0.5
+v -1.20711 1.91421 0.5
+v -1.91421 -0.5 1.20711
+v -1.91421 -0.5 -1.20711
+v -1.91421 0.5 1.20711
+v -1.91421 0.5 -1.20711
+v -1.91421 1.20711 -0.5
+v -1.91421 1.20711 0.5
+v -1.91421 -1.20711 -0.5
+v -1.91421 -1.20711 0.5
+v 1.91421 -0.5 1.20711
+v 1.91421 -0.5 -1.20711
+v 1.91421 0.5 1.20711
+v 1.91421 0.5 -1.20711
+v 1.91421 1.20711 -0.5
+v 1.91421 1.20711 0.5
+v 1.91421 -1.20711 -0.5
+v 1.91421 -1.20711 0.5
+
+f 44 42 17 19
+f 14 6 3 11
+f 34 36 27 25
+f 8 16 9 1
+f 20 18 41 43
+f 12 4 5 13
+f 26 28 35 33
+f 2 10 15 7
+f 45 23 24 46
+f 39 29 30 40
+f 48 22 21 47
+f 38 32 31 37
+f 9 19 17 11 3 25 27 1
+f 2 28 26 4 12 18 20 10
+f 41 48 47 42 44 45 46 43
+f 35 38 37 36 34 39 40 33
+f 15 24 23 16 8 31 32 7
+f 5 30 29 6 14 21 22 13
+f 46 24 15 10 20 43
+f 35 28 2 7 32 38
+f 41 18 12 13 22 48
+f 40 30 5 4 26 33
+f 44 19 9 16 23 45
+f 37 31 8 1 27 36
+f 47 21 14 11 17 42
+f 34 25 3 6 29 39
diff --git a/share/extensions/Poly3DObjects/great_stel_dodec.obj b/share/extensions/Poly3DObjects/great_stel_dodec.obj
index 443abd5aa..b0e542996 100644
--- a/share/extensions/Poly3DObjects/great_stel_dodec.obj
+++ b/share/extensions/Poly3DObjects/great_stel_dodec.obj
@@ -1,96 +1,96 @@
-#Name:Great Stellated Dodecahedron
-#Type:face_specified
-
-v 0. 0. -0.951057
-v 0. 0. 0.951057
-v -0.425325 -1.30902 1.80171
-v -0.425325 1.30902 1.80171
-v 0.425325 -1.30902 -1.80171
-v 0.425325 1.30902 -1.80171
-v -0.688191 -0.5 0.425325
-v -0.688191 0.5 0.425325
-v -0.688191 -2.11803 0.425325
-v -0.688191 2.11803 0.425325
-v 0.688191 -0.5 -0.425325
-v 0.688191 0.5 -0.425325
-v 0.688191 -2.11803 -0.425325
-v 0.688191 2.11803 -0.425325
-v -0.850651 0. -0.425325
-v 0.850651 0. 0.425325
-v -1.11352 -0.809017 -1.80171
-v -1.11352 0.809017 -1.80171
-v 1.11352 -0.809017 1.80171
-v 1.11352 0.809017 1.80171
-v -1.80171 -1.30902 -0.425325
-v -1.80171 1.30902 -0.425325
-v 1.80171 -1.30902 0.425325
-v 1.80171 1.30902 0.425325
-v -2.22703 0. 0.425325
-v 2.22703 0. -0.425325
-v -0.262866 -0.809017 -0.425325
-v -0.262866 0.809017 -0.425325
-v 0.262866 -0.809017 0.425325
-v 0.262866 0.809017 0.425325
-v -1.37638 0. 1.80171
-v 1.37638 0. -1.80171
-
-f 4 2 30
-f 4 30 8
-f 4 8 2
-f 31 2 8
-f 31 8 7
-f 31 7 2
-f 3 2 7
-f 3 7 29
-f 3 29 2
-f 19 2 29
-f 19 29 16
-f 19 16 2
-f 20 2 16
-f 20 16 30
-f 20 30 2
-f 5 11 27
-f 5 27 1
-f 5 1 11
-f 32 12 11
-f 32 11 1
-f 32 1 12
-f 6 28 12
-f 6 12 1
-f 6 1 28
-f 18 15 28
-f 18 28 1
-f 18 1 15
-f 17 27 15
-f 17 15 1
-f 17 1 27
-f 10 30 28
-f 10 28 8
-f 10 8 30
-f 25 8 15
-f 25 15 7
-f 25 7 8
-f 9 7 27
-f 9 27 29
-f 9 29 7
-f 23 29 11
-f 23 11 16
-f 23 16 29
-f 24 16 12
-f 24 12 30
-f 24 30 16
-f 13 11 29
-f 13 29 27
-f 13 27 11
-f 26 12 16
-f 26 16 11
-f 26 11 12
-f 14 28 30
-f 14 30 12
-f 14 12 28
-f 22 15 8
-f 22 8 28
-f 22 28 15
-f 21 27 7
-f 21 7 15
-f 21 15 27
+#Name:Great Stellated Dodecahedron
+#Type:face_specified
+
+v 0. 0. -0.951057
+v 0. 0. 0.951057
+v -0.425325 -1.30902 1.80171
+v -0.425325 1.30902 1.80171
+v 0.425325 -1.30902 -1.80171
+v 0.425325 1.30902 -1.80171
+v -0.688191 -0.5 0.425325
+v -0.688191 0.5 0.425325
+v -0.688191 -2.11803 0.425325
+v -0.688191 2.11803 0.425325
+v 0.688191 -0.5 -0.425325
+v 0.688191 0.5 -0.425325
+v 0.688191 -2.11803 -0.425325
+v 0.688191 2.11803 -0.425325
+v -0.850651 0. -0.425325
+v 0.850651 0. 0.425325
+v -1.11352 -0.809017 -1.80171
+v -1.11352 0.809017 -1.80171
+v 1.11352 -0.809017 1.80171
+v 1.11352 0.809017 1.80171
+v -1.80171 -1.30902 -0.425325
+v -1.80171 1.30902 -0.425325
+v 1.80171 -1.30902 0.425325
+v 1.80171 1.30902 0.425325
+v -2.22703 0. 0.425325
+v 2.22703 0. -0.425325
+v -0.262866 -0.809017 -0.425325
+v -0.262866 0.809017 -0.425325
+v 0.262866 -0.809017 0.425325
+v 0.262866 0.809017 0.425325
+v -1.37638 0. 1.80171
+v 1.37638 0. -1.80171
+
+f 4 2 30
+f 4 30 8
+f 4 8 2
+f 31 2 8
+f 31 8 7
+f 31 7 2
+f 3 2 7
+f 3 7 29
+f 3 29 2
+f 19 2 29
+f 19 29 16
+f 19 16 2
+f 20 2 16
+f 20 16 30
+f 20 30 2
+f 5 11 27
+f 5 27 1
+f 5 1 11
+f 32 12 11
+f 32 11 1
+f 32 1 12
+f 6 28 12
+f 6 12 1
+f 6 1 28
+f 18 15 28
+f 18 28 1
+f 18 1 15
+f 17 27 15
+f 17 15 1
+f 17 1 27
+f 10 30 28
+f 10 28 8
+f 10 8 30
+f 25 8 15
+f 25 15 7
+f 25 7 8
+f 9 7 27
+f 9 27 29
+f 9 29 7
+f 23 29 11
+f 23 11 16
+f 23 16 29
+f 24 16 12
+f 24 12 30
+f 24 30 16
+f 13 11 29
+f 13 29 27
+f 13 27 11
+f 26 12 16
+f 26 16 11
+f 26 11 12
+f 14 28 30
+f 14 30 12
+f 14 12 28
+f 22 15 8
+f 22 8 28
+f 22 28 15
+f 21 27 7
+f 21 7 15
+f 21 15 27
diff --git a/share/extensions/Poly3DObjects/icos.obj b/share/extensions/Poly3DObjects/icos.obj
index d0e991a77..ed55ea4fc 100644
--- a/share/extensions/Poly3DObjects/icos.obj
+++ b/share/extensions/Poly3DObjects/icos.obj
@@ -1,36 +1,36 @@
-#Name:Icosahedron
-#Type:face_specified
-
-v 0 0 -0.95105652
-v 0 0 0.95105652
-v -0.85065081 0 -0.42532540
-v 0.85065081 0 0.42532540
-v 0.68819096 -0.50000000 -0.42532540
-v 0.68819096 0.50000000 -0.42532540
-v -0.68819096 -0.50000000 0.42532540
-v -0.68819096 0.50000000 0.42532540
-v -0.26286556 -0.80901699 -0.42532540
-v -0.26286556 0.80901699 -0.42532540
-v 0.26286556 -0.80901699 0.42532540
-v 0.26286556 0.80901699 0.42532540
-
-f 2 12 8
-f 2 8 7
-f 2 7 11
-f 2 11 4
-f 2 4 12
-f 5 9 1
-f 6 5 1
-f 10 6 1
-f 3 10 1
-f 9 3 1
-f 12 10 8
-f 8 3 7
-f 7 9 11
-f 11 5 4
-f 4 6 12
-f 5 11 9
-f 6 4 5
-f 10 12 6
-f 3 8 10
-f 9 7 3
+#Name:Icosahedron
+#Type:face_specified
+
+v 0 0 -0.95105652
+v 0 0 0.95105652
+v -0.85065081 0 -0.42532540
+v 0.85065081 0 0.42532540
+v 0.68819096 -0.50000000 -0.42532540
+v 0.68819096 0.50000000 -0.42532540
+v -0.68819096 -0.50000000 0.42532540
+v -0.68819096 0.50000000 0.42532540
+v -0.26286556 -0.80901699 -0.42532540
+v -0.26286556 0.80901699 -0.42532540
+v 0.26286556 -0.80901699 0.42532540
+v 0.26286556 0.80901699 0.42532540
+
+f 2 12 8
+f 2 8 7
+f 2 7 11
+f 2 11 4
+f 2 4 12
+f 5 9 1
+f 6 5 1
+f 10 6 1
+f 3 10 1
+f 9 3 1
+f 12 10 8
+f 8 3 7
+f 7 9 11
+f 11 5 4
+f 4 6 12
+f 5 11 9
+f 6 4 5
+f 10 12 6
+f 3 8 10
+f 9 7 3
diff --git a/share/extensions/Poly3DObjects/icosidodec.obj b/share/extensions/Poly3DObjects/icosidodec.obj
index a7489219b..961bec20f 100644
--- a/share/extensions/Poly3DObjects/icosidodec.obj
+++ b/share/extensions/Poly3DObjects/icosidodec.obj
@@ -1,65 +1,65 @@
-#Name:Icosidodecahedron
-#Type:face_specified
-v 0. -1.61803 0.
-v 0. 1.61803 0.
-v 0.262866 -0.809017 -1.37638
-v 0.262866 0.809017 -1.37638
-v 0.425325 -1.30902 0.850651
-v 0.425325 1.30902 0.850651
-v 0.688191 -0.5 1.37638
-v 0.688191 0.5 1.37638
-v 1.11352 -0.809017 -0.850651
-v 1.11352 0.809017 -0.850651
-v -1.37638 0. -0.850651
-v -0.688191 -0.5 -1.37638
-v -0.688191 0.5 -1.37638
-v 1.37638 0. 0.850651
-v 0.951057 -1.30902 0.
-v 0.951057 1.30902 0.
-v 0.850651 0. -1.37638
-v -0.951057 -1.30902 0.
-v -0.951057 1.30902 0.
-v -1.53884 -0.5 0.
-v -1.53884 0.5 0.
-v 1.53884 -0.5 0.
-v 1.53884 0.5 0.
-v -0.850651 0. 1.37638
-v -1.11352 -0.809017 0.850651
-v -1.11352 0.809017 0.850651
-v -0.425325 -1.30902 -0.850651
-v -0.425325 1.30902 -0.850651
-v -0.262866 -0.809017 1.37638
-v -0.262866 0.809017 1.37638
-
-f 30 24 29 7 8
-f 26 24 30
-f 25 29 24
-f 5 7 29
-f 14 8 7
-f 6 30 8
-f 16 2 6
-f 19 21 26
-f 20 18 25
-f 1 15 5
-f 22 23 14
-f 2 19 26 30 6
-f 21 20 25 24 26
-f 18 1 5 29 25
-f 15 22 14 7 5
-f 23 16 6 8 14
-f 12 13 4 17 3
-f 3 17 9
-f 17 4 10
-f 4 13 28
-f 13 12 11
-f 12 3 27
-f 27 1 18
-f 9 22 15
-f 10 16 23
-f 28 19 2
-f 11 20 21
-f 27 3 9 15 1
-f 9 17 10 23 22
-f 10 4 28 2 16
-f 28 13 11 21 19
-f 11 12 27 18 20
+#Name:Icosidodecahedron
+#Type:face_specified
+v 0. -1.61803 0.
+v 0. 1.61803 0.
+v 0.262866 -0.809017 -1.37638
+v 0.262866 0.809017 -1.37638
+v 0.425325 -1.30902 0.850651
+v 0.425325 1.30902 0.850651
+v 0.688191 -0.5 1.37638
+v 0.688191 0.5 1.37638
+v 1.11352 -0.809017 -0.850651
+v 1.11352 0.809017 -0.850651
+v -1.37638 0. -0.850651
+v -0.688191 -0.5 -1.37638
+v -0.688191 0.5 -1.37638
+v 1.37638 0. 0.850651
+v 0.951057 -1.30902 0.
+v 0.951057 1.30902 0.
+v 0.850651 0. -1.37638
+v -0.951057 -1.30902 0.
+v -0.951057 1.30902 0.
+v -1.53884 -0.5 0.
+v -1.53884 0.5 0.
+v 1.53884 -0.5 0.
+v 1.53884 0.5 0.
+v -0.850651 0. 1.37638
+v -1.11352 -0.809017 0.850651
+v -1.11352 0.809017 0.850651
+v -0.425325 -1.30902 -0.850651
+v -0.425325 1.30902 -0.850651
+v -0.262866 -0.809017 1.37638
+v -0.262866 0.809017 1.37638
+
+f 30 24 29 7 8
+f 26 24 30
+f 25 29 24
+f 5 7 29
+f 14 8 7
+f 6 30 8
+f 16 2 6
+f 19 21 26
+f 20 18 25
+f 1 15 5
+f 22 23 14
+f 2 19 26 30 6
+f 21 20 25 24 26
+f 18 1 5 29 25
+f 15 22 14 7 5
+f 23 16 6 8 14
+f 12 13 4 17 3
+f 3 17 9
+f 17 4 10
+f 4 13 28
+f 13 12 11
+f 12 3 27
+f 27 1 18
+f 9 22 15
+f 10 16 23
+f 28 19 2
+f 11 20 21
+f 27 3 9 15 1
+f 9 17 10 23 22
+f 10 4 28 2 16
+f 28 13 11 21 19
+f 11 12 27 18 20
diff --git a/share/extensions/Poly3DObjects/jessens_orthog_icos.obj b/share/extensions/Poly3DObjects/jessens_orthog_icos.obj
index b08b2c4d1..41aff7a62 100644
--- a/share/extensions/Poly3DObjects/jessens_orthog_icos.obj
+++ b/share/extensions/Poly3DObjects/jessens_orthog_icos.obj
@@ -1,35 +1,35 @@
-#Name:Jessen's Orthogonal Icosahedron
-#Type:face_specified
-v 0. -0.809017 0.5
-v 0. -0.809017 -0.5
-v 0. 0.809017 0.5
-v 0. 0.809017 -0.5
-v 0.5 0. -0.809017
-v 0.5 0. 0.809017
-v -0.5 0. -0.809017
-v -0.5 0. 0.809017
-v -0.809017 0.5 0.
-v -0.809017 -0.5 0.
-v 0.809017 0.5 0.
-v 0.809017 -0.5 0.
-
-f 3 1 6
-f 6 1 12
-f 6 12 5
-f 11 3 6
-f 6 5 11
-f 12 1 10
-f 12 10 2
-f 5 12 2
-f 3 11 9
-f 1 3 8
-f 8 10 1
-f 7 2 10
-f 10 8 7
-f 3 9 8
-f 7 8 9
-f 5 2 4
-f 2 7 4
-f 7 9 4
-f 4 9 11
+#Name:Jessen's Orthogonal Icosahedron
+#Type:face_specified
+v 0. -0.809017 0.5
+v 0. -0.809017 -0.5
+v 0. 0.809017 0.5
+v 0. 0.809017 -0.5
+v 0.5 0. -0.809017
+v 0.5 0. 0.809017
+v -0.5 0. -0.809017
+v -0.5 0. 0.809017
+v -0.809017 0.5 0.
+v -0.809017 -0.5 0.
+v 0.809017 0.5 0.
+v 0.809017 -0.5 0.
+
+f 3 1 6
+f 6 1 12
+f 6 12 5
+f 11 3 6
+f 6 5 11
+f 12 1 10
+f 12 10 2
+f 5 12 2
+f 3 11 9
+f 1 3 8
+f 8 10 1
+f 7 2 10
+f 10 8 7
+f 3 9 8
+f 7 8 9
+f 5 2 4
+f 2 7 4
+f 7 9 4
+f 4 9 11
f 5 4 11 \ No newline at end of file
diff --git a/share/extensions/Poly3DObjects/methane.obj b/share/extensions/Poly3DObjects/methane.obj
index 2a89979ab..0b2d74411 100644
--- a/share/extensions/Poly3DObjects/methane.obj
+++ b/share/extensions/Poly3DObjects/methane.obj
@@ -1,13 +1,13 @@
-#Name:Methane Molecule
-#Type:edge_specified
-
-v 0 0 0
-v 0 0 0.61237244
-v -0.28867513 -0.50000000 -0.20412415
-v -0.28867513 0.50000000 -0.20412415
-v 0.57735027 0 -0.20412415
-
-l 1 2
-l 1 3
-l 1 4
-l 1 5
+#Name:Methane Molecule
+#Type:edge_specified
+
+v 0 0 0
+v 0 0 0.61237244
+v -0.28867513 -0.50000000 -0.20412415
+v -0.28867513 0.50000000 -0.20412415
+v 0.57735027 0 -0.20412415
+
+l 1 2
+l 1 3
+l 1 4
+l 1 5
diff --git a/share/extensions/Poly3DObjects/oct.obj b/share/extensions/Poly3DObjects/oct.obj
index 3f98f6840..f356b6986 100644
--- a/share/extensions/Poly3DObjects/oct.obj
+++ b/share/extensions/Poly3DObjects/oct.obj
@@ -1,17 +1,17 @@
-#Name:Octahedron
-#Type:face_specified
-v -0.5 -0.5 0
-v -0.5 0.5 0
-v 0 0 -0.70710678
-v 0 0 0.70710678
-v 0.5 -0.5 0
-v 0.5 0.5 0
-
-f 4 5 6
-f 4 6 2
-f 4 2 1
-f 4 1 5
-f 5 1 3
-f 5 3 6
-f 3 1 2
-f 6 3 2
+#Name:Octahedron
+#Type:face_specified
+v -0.5 -0.5 0
+v -0.5 0.5 0
+v 0 0 -0.70710678
+v 0 0 0.70710678
+v 0.5 -0.5 0
+v 0.5 0.5 0
+
+f 4 5 6
+f 4 6 2
+f 4 2 1
+f 4 1 5
+f 5 1 3
+f 5 3 6
+f 3 1 2
+f 6 3 2
diff --git a/share/extensions/Poly3DObjects/rh_axes.obj b/share/extensions/Poly3DObjects/rh_axes.obj
index 23042c170..cc6623fc2 100644
--- a/share/extensions/Poly3DObjects/rh_axes.obj
+++ b/share/extensions/Poly3DObjects/rh_axes.obj
@@ -1,12 +1,12 @@
-#Name:Right Handed Coordinate Axes
-#Type:Edge_specified
-
-v 0 0 0
-v 1 0 0
-v 0 1 0
-v 0 0 1
-
-l 1 2
-l 1 3
-l 1 4
-
+#Name:Right Handed Coordinate Axes
+#Type:Edge_specified
+
+v 0 0 0
+v 1 0 0
+v 0 1 0
+v 0 0 1
+
+l 1 2
+l 1 3
+l 1 4
+
diff --git a/share/extensions/Poly3DObjects/rhomb_dodec.obj b/share/extensions/Poly3DObjects/rhomb_dodec.obj
index 353c6e6c0..9fde9d669 100644
--- a/share/extensions/Poly3DObjects/rhomb_dodec.obj
+++ b/share/extensions/Poly3DObjects/rhomb_dodec.obj
@@ -1,29 +1,29 @@
-#Name:Rhombic Dodecahedron
-#Type:face_specified
-v -0.816497 -0.816497 0.
-v -0.816497 0. -0.57735
-v -0.816497 0. 0.57735
-v -0.816497 0.816497 0.
-v 0. -0.816497 -0.57735
-v 0. -0.816497 0.57735
-v 0. 0. -1.1547
-v 0. 0. 1.1547
-v 0. 0.816497 -0.57735
-v 0. 0.816497 0.57735
-v 0.816497 -0.816497 0.
-v 0.816497 0. -0.57735
-v 0.816497 0. 0.57735
-v 0.816497 0.816497 0.
-
-f 2 1 3 4
-f 1 2 7 5
-f 6 8 3 1
-f 2 4 9 7
-f 8 10 4 3
-f 11 6 1 5
-f 9 4 10 14
-f 5 7 12 11
-f 11 13 8 6
-f 7 9 14 12
-f 13 14 10 8
+#Name:Rhombic Dodecahedron
+#Type:face_specified
+v -0.816497 -0.816497 0.
+v -0.816497 0. -0.57735
+v -0.816497 0. 0.57735
+v -0.816497 0.816497 0.
+v 0. -0.816497 -0.57735
+v 0. -0.816497 0.57735
+v 0. 0. -1.1547
+v 0. 0. 1.1547
+v 0. 0.816497 -0.57735
+v 0. 0.816497 0.57735
+v 0.816497 -0.816497 0.
+v 0.816497 0. -0.57735
+v 0.816497 0. 0.57735
+v 0.816497 0.816497 0.
+
+f 2 1 3 4
+f 1 2 7 5
+f 6 8 3 1
+f 2 4 9 7
+f 8 10 4 3
+f 11 6 1 5
+f 9 4 10 14
+f 5 7 12 11
+f 11 13 8 6
+f 7 9 14 12
+f 13 14 10 8
f 14 13 11 12 \ No newline at end of file
diff --git a/share/extensions/Poly3DObjects/rhomb_triacont.obj b/share/extensions/Poly3DObjects/rhomb_triacont.obj
index 9fd85d07f..70acebf54 100644
--- a/share/extensions/Poly3DObjects/rhomb_triacont.obj
+++ b/share/extensions/Poly3DObjects/rhomb_triacont.obj
@@ -1,65 +1,65 @@
-#Name:Rhombic Triacontahedron
-#Type:face_specified
-v 0. 0. -1.61803
-v 0. 0. 1.61803
-v 0.276393 -0.850651 1.17082
-v 0.276393 0.850651 1.17082
-v 0.894427 0. 1.17082
-v 1.17082 -0.850651 0.723607
-v 1.17082 -0.850651 -0.276393
-v 1.17082 0.850651 0.723607
-v 1.17082 0.850651 -0.276393
-v -0.894427 0. -1.17082
-v -0.447214 -1.37638 0.723607
-v -0.447214 -1.37638 -0.276393
-v -0.447214 1.37638 0.723607
-v -0.447214 1.37638 -0.276393
-v 0.447214 -1.37638 0.276393
-v 0.447214 -1.37638 -0.723607
-v 0.447214 1.37638 0.276393
-v 0.447214 1.37638 -0.723607
-v -1.44721 0. 0.723607
-v -1.44721 0. -0.276393
-v -0.723607 -0.525731 1.17082
-v -0.723607 0.525731 1.17082
-v 0.723607 -0.525731 -1.17082
-v 0.723607 0.525731 -1.17082
-v 1.44721 0. 0.276393
-v 1.44721 0. -0.723607
-v -1.17082 -0.850651 0.276393
-v -1.17082 -0.850651 -0.723607
-v -1.17082 0.850651 0.276393
-v -1.17082 0.850651 -0.723607
-v -0.276393 -0.850651 -1.17082
-v -0.276393 0.850651 -1.17082
-
-f 16 15 11 12
-f 14 13 17 18
-f 10 28 20 30
-f 8 5 6 25
-f 12 28 31 16
-f 32 30 14 18
-f 6 3 11 15
-f 8 17 13 4
-f 11 21 19 27
-f 13 29 19 22
-f 7 16 23 26
-f 24 18 9 26
-f 12 11 27 28
-f 30 29 13 14
-f 7 6 15 16
-f 18 17 8 9
-f 2 22 19 21
-f 23 1 24 26
-f 3 2 21 11
-f 4 13 22 2
-f 16 31 1 23
-f 1 32 18 24
-f 31 28 10 1
-f 10 30 32 1
-f 6 5 2 3
-f 8 4 2 5
-f 28 27 19 20
-f 20 19 29 30
-f 26 25 6 7
-f 9 8 25 26
+#Name:Rhombic Triacontahedron
+#Type:face_specified
+v 0. 0. -1.61803
+v 0. 0. 1.61803
+v 0.276393 -0.850651 1.17082
+v 0.276393 0.850651 1.17082
+v 0.894427 0. 1.17082
+v 1.17082 -0.850651 0.723607
+v 1.17082 -0.850651 -0.276393
+v 1.17082 0.850651 0.723607
+v 1.17082 0.850651 -0.276393
+v -0.894427 0. -1.17082
+v -0.447214 -1.37638 0.723607
+v -0.447214 -1.37638 -0.276393
+v -0.447214 1.37638 0.723607
+v -0.447214 1.37638 -0.276393
+v 0.447214 -1.37638 0.276393
+v 0.447214 -1.37638 -0.723607
+v 0.447214 1.37638 0.276393
+v 0.447214 1.37638 -0.723607
+v -1.44721 0. 0.723607
+v -1.44721 0. -0.276393
+v -0.723607 -0.525731 1.17082
+v -0.723607 0.525731 1.17082
+v 0.723607 -0.525731 -1.17082
+v 0.723607 0.525731 -1.17082
+v 1.44721 0. 0.276393
+v 1.44721 0. -0.723607
+v -1.17082 -0.850651 0.276393
+v -1.17082 -0.850651 -0.723607
+v -1.17082 0.850651 0.276393
+v -1.17082 0.850651 -0.723607
+v -0.276393 -0.850651 -1.17082
+v -0.276393 0.850651 -1.17082
+
+f 16 15 11 12
+f 14 13 17 18
+f 10 28 20 30
+f 8 5 6 25
+f 12 28 31 16
+f 32 30 14 18
+f 6 3 11 15
+f 8 17 13 4
+f 11 21 19 27
+f 13 29 19 22
+f 7 16 23 26
+f 24 18 9 26
+f 12 11 27 28
+f 30 29 13 14
+f 7 6 15 16
+f 18 17 8 9
+f 2 22 19 21
+f 23 1 24 26
+f 3 2 21 11
+f 4 13 22 2
+f 16 31 1 23
+f 1 32 18 24
+f 31 28 10 1
+f 10 30 32 1
+f 6 5 2 3
+f 8 4 2 5
+f 28 27 19 20
+f 20 19 29 30
+f 26 25 6 7
+f 9 8 25 26
diff --git a/share/extensions/Poly3DObjects/small_rhombicosidodec.obj b/share/extensions/Poly3DObjects/small_rhombicosidodec.obj
index 94cb91ce7..a209ba2c2 100644
--- a/share/extensions/Poly3DObjects/small_rhombicosidodec.obj
+++ b/share/extensions/Poly3DObjects/small_rhombicosidodec.obj
@@ -1,127 +1,127 @@
-#Name:Small Rhombicosidodecahedron
-#Type:face_specified
-
-v -0.5 -0.5 -2.11803
-v -0.5 -0.5 2.11803
-v -0.5 0.5 -2.11803
-v -0.5 0.5 2.11803
-v -0.5 -2.11803 -0.5
-v -0.5 -2.11803 0.5
-v -0.5 2.11803 -0.5
-v -0.5 2.11803 0.5
-v 0. -1.30902 -1.80902
-v 0. -1.30902 1.80902
-v 0. 1.30902 -1.80902
-v 0. 1.30902 1.80902
-v 0.5 -0.5 -2.11803
-v 0.5 -0.5 2.11803
-v 0.5 0.5 -2.11803
-v 0.5 0.5 2.11803
-v 0.5 -2.11803 -0.5
-v 0.5 -2.11803 0.5
-v 0.5 2.11803 -0.5
-v 0.5 2.11803 0.5
-v -1.80902 0. -1.30902
-v -1.80902 0. 1.30902
-v -0.809017 -1.61803 -1.30902
-v -0.809017 -1.61803 1.30902
-v -0.809017 1.61803 -1.30902
-v -0.809017 1.61803 1.30902
-v -1.61803 -1.30902 -0.809017
-v -1.61803 -1.30902 0.809017
-v -1.61803 1.30902 -0.809017
-v -1.61803 1.30902 0.809017
-v -2.11803 -0.5 -0.5
-v -2.11803 -0.5 0.5
-v -2.11803 0.5 -0.5
-v -2.11803 0.5 0.5
-v -1.30902 -1.80902 0.
-v -1.30902 -0.809017 -1.61803
-v -1.30902 -0.809017 1.61803
-v -1.30902 0.809017 -1.61803
-v -1.30902 0.809017 1.61803
-v -1.30902 1.80902 0.
-v 0.809017 -1.61803 -1.30902
-v 0.809017 -1.61803 1.30902
-v 0.809017 1.61803 -1.30902
-v 0.809017 1.61803 1.30902
-v 1.61803 -1.30902 -0.809017
-v 1.61803 -1.30902 0.809017
-v 1.61803 1.30902 -0.809017
-v 1.61803 1.30902 0.809017
-v 2.11803 -0.5 -0.5
-v 2.11803 -0.5 0.5
-v 2.11803 0.5 -0.5
-v 2.11803 0.5 0.5
-v 1.30902 -1.80902 0.
-v 1.30902 -0.809017 -1.61803
-v 1.30902 -0.809017 1.61803
-v 1.30902 0.809017 -1.61803
-v 1.30902 0.809017 1.61803
-v 1.30902 1.80902 0.
-v 1.80902 0. -1.30902
-v 1.80902 0. 1.30902
-
-f 36 23 27
-f 37 28 24
-f 40 8 7
-f 35 5 6
-f 38 29 25
-f 39 26 30
-f 10 14 2
-f 9 1 13
-f 12 4 16
-f 11 15 3
-f 54 45 41
-f 55 42 46
-f 58 19 20
-f 53 18 17
-f 56 43 47
-f 57 48 44
-f 34 32 22
-f 33 21 31
-f 59 51 49
-f 60 50 52
-f 27 31 21 36
-f 23 36 1 9
-f 10 2 37 24
-f 37 22 32 28
-f 8 40 30 26
-f 25 29 40 7
-f 35 27 23 5
-f 6 24 28 35
-f 3 38 25 11
-f 21 33 29 38
-f 39 30 34 22
-f 12 26 39 4
-f 55 14 10 42
-f 41 9 13 54
-f 57 44 12 16
-f 15 11 43 56
-f 45 54 59 49
-f 50 60 55 46
-f 48 58 20 44
-f 43 19 58 47
-f 53 17 41 45
-f 46 42 18 53
-f 59 56 47 51
-f 52 48 57 60
-f 31 32 34 33
-f 17 18 6 5
-f 1 3 15 13
-f 14 16 4 2
-f 7 8 20 19
-f 51 52 50 49
-f 3 1 36 21 38
-f 22 37 2 4 39
-f 29 33 34 30 40
-f 27 35 28 32 31
-f 42 10 24 6 18
-f 41 17 5 23 9
-f 20 8 26 12 44
-f 11 25 7 19 43
-f 56 59 54 13 15
-f 57 16 14 55 60
-f 58 48 52 51 47
-f 49 50 46 53 45
-
+#Name:Small Rhombicosidodecahedron
+#Type:face_specified
+
+v -0.5 -0.5 -2.11803
+v -0.5 -0.5 2.11803
+v -0.5 0.5 -2.11803
+v -0.5 0.5 2.11803
+v -0.5 -2.11803 -0.5
+v -0.5 -2.11803 0.5
+v -0.5 2.11803 -0.5
+v -0.5 2.11803 0.5
+v 0. -1.30902 -1.80902
+v 0. -1.30902 1.80902
+v 0. 1.30902 -1.80902
+v 0. 1.30902 1.80902
+v 0.5 -0.5 -2.11803
+v 0.5 -0.5 2.11803
+v 0.5 0.5 -2.11803
+v 0.5 0.5 2.11803
+v 0.5 -2.11803 -0.5
+v 0.5 -2.11803 0.5
+v 0.5 2.11803 -0.5
+v 0.5 2.11803 0.5
+v -1.80902 0. -1.30902
+v -1.80902 0. 1.30902
+v -0.809017 -1.61803 -1.30902
+v -0.809017 -1.61803 1.30902
+v -0.809017 1.61803 -1.30902
+v -0.809017 1.61803 1.30902
+v -1.61803 -1.30902 -0.809017
+v -1.61803 -1.30902 0.809017
+v -1.61803 1.30902 -0.809017
+v -1.61803 1.30902 0.809017
+v -2.11803 -0.5 -0.5
+v -2.11803 -0.5 0.5
+v -2.11803 0.5 -0.5
+v -2.11803 0.5 0.5
+v -1.30902 -1.80902 0.
+v -1.30902 -0.809017 -1.61803
+v -1.30902 -0.809017 1.61803
+v -1.30902 0.809017 -1.61803
+v -1.30902 0.809017 1.61803
+v -1.30902 1.80902 0.
+v 0.809017 -1.61803 -1.30902
+v 0.809017 -1.61803 1.30902
+v 0.809017 1.61803 -1.30902
+v 0.809017 1.61803 1.30902
+v 1.61803 -1.30902 -0.809017
+v 1.61803 -1.30902 0.809017
+v 1.61803 1.30902 -0.809017
+v 1.61803 1.30902 0.809017
+v 2.11803 -0.5 -0.5
+v 2.11803 -0.5 0.5
+v 2.11803 0.5 -0.5
+v 2.11803 0.5 0.5
+v 1.30902 -1.80902 0.
+v 1.30902 -0.809017 -1.61803
+v 1.30902 -0.809017 1.61803
+v 1.30902 0.809017 -1.61803
+v 1.30902 0.809017 1.61803
+v 1.30902 1.80902 0.
+v 1.80902 0. -1.30902
+v 1.80902 0. 1.30902
+
+f 36 23 27
+f 37 28 24
+f 40 8 7
+f 35 5 6
+f 38 29 25
+f 39 26 30
+f 10 14 2
+f 9 1 13
+f 12 4 16
+f 11 15 3
+f 54 45 41
+f 55 42 46
+f 58 19 20
+f 53 18 17
+f 56 43 47
+f 57 48 44
+f 34 32 22
+f 33 21 31
+f 59 51 49
+f 60 50 52
+f 27 31 21 36
+f 23 36 1 9
+f 10 2 37 24
+f 37 22 32 28
+f 8 40 30 26
+f 25 29 40 7
+f 35 27 23 5
+f 6 24 28 35
+f 3 38 25 11
+f 21 33 29 38
+f 39 30 34 22
+f 12 26 39 4
+f 55 14 10 42
+f 41 9 13 54
+f 57 44 12 16
+f 15 11 43 56
+f 45 54 59 49
+f 50 60 55 46
+f 48 58 20 44
+f 43 19 58 47
+f 53 17 41 45
+f 46 42 18 53
+f 59 56 47 51
+f 52 48 57 60
+f 31 32 34 33
+f 17 18 6 5
+f 1 3 15 13
+f 14 16 4 2
+f 7 8 20 19
+f 51 52 50 49
+f 3 1 36 21 38
+f 22 37 2 4 39
+f 29 33 34 30 40
+f 27 35 28 32 31
+f 42 10 24 6 18
+f 41 17 5 23 9
+f 20 8 26 12 44
+f 11 25 7 19 43
+f 56 59 54 13 15
+f 57 16 14 55 60
+f 58 48 52 51 47
+f 49 50 46 53 45
+
diff --git a/share/extensions/Poly3DObjects/small_rhombicuboct.obj b/share/extensions/Poly3DObjects/small_rhombicuboct.obj
index 24da8f4a3..2d064aba8 100644
--- a/share/extensions/Poly3DObjects/small_rhombicuboct.obj
+++ b/share/extensions/Poly3DObjects/small_rhombicuboct.obj
@@ -1,54 +1,54 @@
-#Name:Small Rhombicuboctahedron
-#Type:face_specified
-
-v -0.5 -0.5 -1.20711
-v -0.5 -0.5 1.20711
-v -0.5 0.5 -1.20711
-v -0.5 0.5 1.20711
-v -0.5 -1.20711 -0.5
-v -0.5 -1.20711 0.5
-v -0.5 1.20711 -0.5
-v -0.5 1.20711 0.5
-v 0.5 -0.5 -1.20711
-v 0.5 -0.5 1.20711
-v 0.5 0.5 -1.20711
-v 0.5 0.5 1.20711
-v 0.5 -1.20711 -0.5
-v 0.5 -1.20711 0.5
-v 0.5 1.20711 -0.5
-v 0.5 1.20711 0.5
-v -1.20711 -0.5 -0.5
-v -1.20711 -0.5 0.5
-v -1.20711 0.5 -0.5
-v -1.20711 0.5 0.5
-v 1.20711 -0.5 -0.5
-v 1.20711 -0.5 0.5
-v 1.20711 0.5 -0.5
-v 1.20711 0.5 0.5
-
-f 3 11 9 1
-f 2 10 12 4
-f 24 22 21 23
-f 19 17 18 20
-f 5 13 14 6
-f 8 16 15 7
-f 13 21 22 14
-f 16 24 23 15
-f 6 18 17 5
-f 7 19 20 8
-f 6 14 10 2
-f 4 12 16 8
-f 22 24 12 10
-f 2 4 20 18
-f 1 9 13 5
-f 7 15 11 3
-f 9 11 23 21
-f 17 19 3 1
-f 22 10 14
-f 16 12 24
-f 6 2 18
-f 20 4 8
-f 13 9 21
-f 23 11 15
-f 17 1 5
-f 7 3 19
+#Name:Small Rhombicuboctahedron
+#Type:face_specified
+
+v -0.5 -0.5 -1.20711
+v -0.5 -0.5 1.20711
+v -0.5 0.5 -1.20711
+v -0.5 0.5 1.20711
+v -0.5 -1.20711 -0.5
+v -0.5 -1.20711 0.5
+v -0.5 1.20711 -0.5
+v -0.5 1.20711 0.5
+v 0.5 -0.5 -1.20711
+v 0.5 -0.5 1.20711
+v 0.5 0.5 -1.20711
+v 0.5 0.5 1.20711
+v 0.5 -1.20711 -0.5
+v 0.5 -1.20711 0.5
+v 0.5 1.20711 -0.5
+v 0.5 1.20711 0.5
+v -1.20711 -0.5 -0.5
+v -1.20711 -0.5 0.5
+v -1.20711 0.5 -0.5
+v -1.20711 0.5 0.5
+v 1.20711 -0.5 -0.5
+v 1.20711 -0.5 0.5
+v 1.20711 0.5 -0.5
+v 1.20711 0.5 0.5
+
+f 3 11 9 1
+f 2 10 12 4
+f 24 22 21 23
+f 19 17 18 20
+f 5 13 14 6
+f 8 16 15 7
+f 13 21 22 14
+f 16 24 23 15
+f 6 18 17 5
+f 7 19 20 8
+f 6 14 10 2
+f 4 12 16 8
+f 22 24 12 10
+f 2 4 20 18
+f 1 9 13 5
+f 7 15 11 3
+f 9 11 23 21
+f 17 19 3 1
+f 22 10 14
+f 16 12 24
+f 6 2 18
+f 20 4 8
+f 13 9 21
+f 23 11 15
+f 17 1 5
+f 7 3 19
diff --git a/share/extensions/Poly3DObjects/small_triam_icos.obj b/share/extensions/Poly3DObjects/small_triam_icos.obj
index d7094cc8e..1d366ff25 100644
--- a/share/extensions/Poly3DObjects/small_triam_icos.obj
+++ b/share/extensions/Poly3DObjects/small_triam_icos.obj
@@ -1,95 +1,95 @@
-#Name:Small Triambic Icosahedron
-#Type:face_specified
-v 0. 0. -0.951057
-v 0. 0. 0.951057
-v 0.262866 -0.809017 0.425325
-v 0.262866 0.809017 0.425325
-v 0.688191 -0.5 -0.425325
-v 0.688191 0.5 -0.425325
-v 0.995959 0. -0.190211
-v -0.688191 -0.5 0.425325
-v -0.688191 0.5 0.425325
-v -0.49798 -0.361803 -0.805748
-v -0.49798 0.361803 -0.805748
-v 0.49798 -0.361803 0.805748
-v 0.49798 0.361803 0.805748
-v 0.190211 -0.58541 -0.805748
-v 0.190211 0.58541 -0.805748
-v 0.850651 0. 0.425325
-v -0.190211 -0.58541 0.805748
-v -0.190211 0.58541 0.805748
-v -0.615537 0. 0.805748
-v -0.307768 -0.947214 0.190211
-v -0.307768 0.947214 0.190211
-v 0.307768 -0.947214 -0.190211
-v 0.307768 0.947214 -0.190211
-v 0.615537 0. -0.805748
-v 0.805748 -0.58541 0.190211
-v 0.805748 0.58541 0.190211
-v -0.850651 0. -0.425325
-v -0.262866 -0.809017 -0.425325
-v -0.262866 0.809017 -0.425325
-v -0.995959 0. 0.190211
-v -0.805748 -0.58541 -0.190211
-v -0.805748 0.58541 -0.190211
-
-f 18 2 4
-f 18 4 9
-f 18 9 2
-f 19 2 9
-f 19 9 8
-f 19 8 2
-f 17 2 8
-f 17 8 3
-f 17 3 2
-f 12 2 3
-f 12 3 16
-f 12 16 2
-f 13 2 16
-f 13 16 4
-f 13 4 2
-f 14 5 28
-f 14 28 1
-f 14 1 5
-f 24 6 5
-f 24 5 1
-f 24 1 6
-f 15 29 6
-f 15 6 1
-f 15 1 29
-f 11 27 29
-f 11 29 1
-f 11 1 27
-f 10 28 27
-f 10 27 1
-f 10 1 28
-f 21 4 29
-f 21 29 9
-f 21 9 4
-f 30 9 27
-f 30 27 8
-f 30 8 9
-f 20 8 28
-f 20 28 3
-f 20 3 8
-f 25 3 5
-f 25 5 16
-f 25 16 3
-f 26 16 6
-f 26 6 4
-f 26 4 16
-f 22 5 3
-f 22 3 28
-f 22 28 5
-f 7 6 16
-f 7 16 5
-f 7 5 6
-f 23 29 4
-f 23 4 6
-f 23 6 29
-f 32 27 9
-f 32 9 29
-f 32 29 27
-f 31 28 8
-f 31 8 27
-f 31 27 28
+#Name:Small Triambic Icosahedron
+#Type:face_specified
+v 0. 0. -0.951057
+v 0. 0. 0.951057
+v 0.262866 -0.809017 0.425325
+v 0.262866 0.809017 0.425325
+v 0.688191 -0.5 -0.425325
+v 0.688191 0.5 -0.425325
+v 0.995959 0. -0.190211
+v -0.688191 -0.5 0.425325
+v -0.688191 0.5 0.425325
+v -0.49798 -0.361803 -0.805748
+v -0.49798 0.361803 -0.805748
+v 0.49798 -0.361803 0.805748
+v 0.49798 0.361803 0.805748
+v 0.190211 -0.58541 -0.805748
+v 0.190211 0.58541 -0.805748
+v 0.850651 0. 0.425325
+v -0.190211 -0.58541 0.805748
+v -0.190211 0.58541 0.805748
+v -0.615537 0. 0.805748
+v -0.307768 -0.947214 0.190211
+v -0.307768 0.947214 0.190211
+v 0.307768 -0.947214 -0.190211
+v 0.307768 0.947214 -0.190211
+v 0.615537 0. -0.805748
+v 0.805748 -0.58541 0.190211
+v 0.805748 0.58541 0.190211
+v -0.850651 0. -0.425325
+v -0.262866 -0.809017 -0.425325
+v -0.262866 0.809017 -0.425325
+v -0.995959 0. 0.190211
+v -0.805748 -0.58541 -0.190211
+v -0.805748 0.58541 -0.190211
+
+f 18 2 4
+f 18 4 9
+f 18 9 2
+f 19 2 9
+f 19 9 8
+f 19 8 2
+f 17 2 8
+f 17 8 3
+f 17 3 2
+f 12 2 3
+f 12 3 16
+f 12 16 2
+f 13 2 16
+f 13 16 4
+f 13 4 2
+f 14 5 28
+f 14 28 1
+f 14 1 5
+f 24 6 5
+f 24 5 1
+f 24 1 6
+f 15 29 6
+f 15 6 1
+f 15 1 29
+f 11 27 29
+f 11 29 1
+f 11 1 27
+f 10 28 27
+f 10 27 1
+f 10 1 28
+f 21 4 29
+f 21 29 9
+f 21 9 4
+f 30 9 27
+f 30 27 8
+f 30 8 9
+f 20 8 28
+f 20 28 3
+f 20 3 8
+f 25 3 5
+f 25 5 16
+f 25 16 3
+f 26 16 6
+f 26 6 4
+f 26 4 16
+f 22 5 3
+f 22 3 28
+f 22 28 5
+f 7 6 16
+f 7 16 5
+f 7 5 6
+f 23 29 4
+f 23 4 6
+f 23 6 29
+f 32 27 9
+f 32 9 29
+f 32 29 27
+f 31 28 8
+f 31 8 27
+f 31 27 28
diff --git a/share/extensions/Poly3DObjects/snub_cube.obj b/share/extensions/Poly3DObjects/snub_cube.obj
index d144c7e36..de018af23 100644
--- a/share/extensions/Poly3DObjects/snub_cube.obj
+++ b/share/extensions/Poly3DObjects/snub_cube.obj
@@ -1,65 +1,65 @@
-#Name:Snub Cube
-#Type:face_specified
-v -1.1426135 -0.33775397 -0.62122641
-v -1.1426135 0.33775397 0.62122641
-v -1.1426135 -0.62122641 0.33775397
-v -1.1426135 0.62122641 -0.33775397
-v 1.1426135 -0.33775397 0.62122641
-v 1.1426135 0.33775397 -0.62122641
-v 1.1426135 -0.62122641 -0.33775397
-v 1.1426135 0.62122641 0.33775397
-v -0.33775397 -1.1426135 0.62122641
-v -0.33775397 1.1426135 -0.62122641
-v -0.33775397 -0.62122641 -1.1426135
-v -0.33775397 0.62122641 1.1426135
-v 0.33775397 -1.1426135 -0.62122641
-v 0.33775397 1.1426135 0.62122641
-v 0.33775397 -0.62122641 1.1426135
-v 0.33775397 0.62122641 -1.1426135
-v -0.62122641 -1.1426135 -0.33775397
-v -0.62122641 1.1426135 0.33775397
-v -0.62122641 -0.33775397 1.1426135
-v -0.62122641 0.33775397 -1.1426135
-v 0.62122641 -1.1426135 0.33775397
-v 0.62122641 1.1426135 -0.33775397
-v 0.62122641 -0.33775397 -1.1426135
-v 0.62122641 0.33775397 1.1426135
-
-f 3 1 17
-f 3 17 9
-f 3 19 2
-f 3 9 19
-f 1 4 20
-f 1 20 11
-f 1 11 17
-f 2 19 12
-f 2 18 4
-f 2 12 18
-f 4 18 10
-f 4 10 20
-f 17 11 13
-f 19 9 15
-f 18 12 14
-f 20 10 16
-f 9 21 15
-f 11 23 13
-f 12 24 14
-f 10 22 16
-f 13 23 7
-f 13 7 21
-f 15 21 5
-f 15 5 24
-f 16 22 6
-f 16 6 23
-f 14 24 8
-f 14 8 22
-f 21 7 5
-f 23 6 7
-f 24 5 8
-f 22 8 6
-f 1 3 2 4
-f 21 9 17 13
-f 24 12 19 15
-f 10 18 14 22
-f 11 20 16 23
-f 8 5 7 6
+#Name:Snub Cube
+#Type:face_specified
+v -1.1426135 -0.33775397 -0.62122641
+v -1.1426135 0.33775397 0.62122641
+v -1.1426135 -0.62122641 0.33775397
+v -1.1426135 0.62122641 -0.33775397
+v 1.1426135 -0.33775397 0.62122641
+v 1.1426135 0.33775397 -0.62122641
+v 1.1426135 -0.62122641 -0.33775397
+v 1.1426135 0.62122641 0.33775397
+v -0.33775397 -1.1426135 0.62122641
+v -0.33775397 1.1426135 -0.62122641
+v -0.33775397 -0.62122641 -1.1426135
+v -0.33775397 0.62122641 1.1426135
+v 0.33775397 -1.1426135 -0.62122641
+v 0.33775397 1.1426135 0.62122641
+v 0.33775397 -0.62122641 1.1426135
+v 0.33775397 0.62122641 -1.1426135
+v -0.62122641 -1.1426135 -0.33775397
+v -0.62122641 1.1426135 0.33775397
+v -0.62122641 -0.33775397 1.1426135
+v -0.62122641 0.33775397 -1.1426135
+v 0.62122641 -1.1426135 0.33775397
+v 0.62122641 1.1426135 -0.33775397
+v 0.62122641 -0.33775397 -1.1426135
+v 0.62122641 0.33775397 1.1426135
+
+f 3 1 17
+f 3 17 9
+f 3 19 2
+f 3 9 19
+f 1 4 20
+f 1 20 11
+f 1 11 17
+f 2 19 12
+f 2 18 4
+f 2 12 18
+f 4 18 10
+f 4 10 20
+f 17 11 13
+f 19 9 15
+f 18 12 14
+f 20 10 16
+f 9 21 15
+f 11 23 13
+f 12 24 14
+f 10 22 16
+f 13 23 7
+f 13 7 21
+f 15 21 5
+f 15 5 24
+f 16 22 6
+f 16 6 23
+f 14 24 8
+f 14 8 22
+f 21 7 5
+f 23 6 7
+f 24 5 8
+f 22 8 6
+f 1 3 2 4
+f 21 9 17 13
+f 24 12 19 15
+f 10 18 14 22
+f 11 20 16 23
+f 8 5 7 6
diff --git a/share/extensions/Poly3DObjects/snub_dodec.obj b/share/extensions/Poly3DObjects/snub_dodec.obj
index 8dfbda342..d8309789b 100644
--- a/share/extensions/Poly3DObjects/snub_dodec.obj
+++ b/share/extensions/Poly3DObjects/snub_dodec.obj
@@ -1,156 +1,156 @@
-#Name:Snub Dodecahedron
-#Type:face_specified
-
-v -2.0502159 -0.64302961 0.17539263
-v 2.0502159 -0.64302961 -0.17539263
-v -1.6450691 0.64302961 1.2360806
-v 1.6450691 0.64302961 -1.2360806
-v -2.0927544 0.33092102 0.39812710
-v 2.0927544 0.33092102 -0.39812710
-v -1.3329632 1.6469179 -0.39812710
-v 1.3329632 1.6469179 0.39812710
-v -1.8252651 -0.33092102 1.0984232
-v 1.8252651 -0.33092102 -1.0984232
-v -0.62604653 1.7461864 -1.0984232
-v 0.62604653 1.7461864 1.0984232
-v -1.0622158 1.4540242 1.1853886
-v 1.0622158 1.4540242 -1.1853886
-v -1.9321359 0.84755005 -0.44288192
-v 1.9321359 0.84755005 0.44288192
-v -1.1448745 -0.84755005 1.6181953
-v 1.1448745 -0.84755005 -1.6181953
-v -1.5819879 -1.4540242 -0.17539263
-v 1.5819879 -1.4540242 0.17539263
-v -1.0574124 0.37482166 -1.8409298
-v 1.0574124 0.37482166 1.8409298
-v -0.43913786 -0.37482166 -2.0770897
-v 0.43913786 -0.37482166 2.0770897
-v -1.5624104 -1.2495038 0.80327387
-v 1.5624104 -1.2495038 -0.80327387
-v -1.8633072 -0.72833518 -0.80327387
-v 1.8633072 -0.72833518 0.80327387
-v -1.7000678 1.2495038 0.44288192
-v 1.7000678 1.2495038 -0.44288192
-v -0.72811404 -1.6469179 1.1853886
-v 0.72811404 -1.6469179 -1.1853886
-v -0.26565458 -1.7461864 -1.2360806
-v 0.26565458 -1.7461864 1.2360806
-v -0.75979117 -1.9778390 -0.39812710
-v 0.75979117 -1.9778390 0.39812710
-v -1.1992186 -1.4152654 -1.0984232
-v 1.1992186 -1.4152654 1.0984232
-v -1.7903298 0.19289371 -1.1853886
-v 1.7903298 0.19289371 1.1853886
-v -1.3064371 -0.56771537 -1.6181953
-v 1.3064371 -0.56771537 1.6181953
-v -0.85331128 0.72833518 1.8409298
-v 0.85331128 0.72833518 -1.8409298
-v -1.3794145 1.1031568 -1.2360806
-v 1.3794145 1.1031568 1.2360806
-v -0.10503615 0.56771537 -2.0770897
-v 0.10503615 0.56771537 2.0770897
-v -0.46822796 2.0970538 -0.17539263
-v 0.46822796 2.0970538 0.17539263
-v -0.30089684 1.9778390 0.80327387
-v 0.30089684 1.9778390 -0.80327387
-v -0.16156263 1.4152654 1.6181953
-v 0.16156263 1.4152654 -1.6181953
-v -0.54417401 -0.19289371 2.0770897
-v 0.54417401 -0.19289371 -2.0770897
-v -0.23206810 -2.0970538 0.44288192
-v 0.23206810 -2.0970538 -0.44288192
-v -0.20410113 -1.1031568 1.8409298
-v 0.20410113 -1.1031568 -1.8409298
-
-f 5 1 9
-f 5 9 3
-f 5 29 15
-f 5 3 29
-f 1 27 19
-f 1 19 25
-f 1 25 9
-f 15 29 7
-f 15 45 39
-f 15 7 45
-f 27 39 41
-f 27 41 37
-f 27 37 19
-f 9 25 17
-f 39 45 21
-f 39 21 41
-f 29 3 13
-f 3 43 13
-f 19 37 35
-f 25 31 17
-f 45 7 11
-f 7 49 11
-f 41 21 23
-f 37 33 35
-f 17 31 59
-f 17 59 55
-f 13 43 53
-f 13 53 51
-f 21 47 23
-f 43 55 48
-f 43 48 53
-f 35 33 58
-f 35 58 57
-f 31 57 34
-f 31 34 59
-f 11 49 52
-f 11 52 54
-f 55 59 24
-f 55 24 48
-f 49 51 50
-f 49 50 52
-f 23 47 56
-f 23 56 60
-f 51 53 12
-f 51 12 50
-f 33 60 32
-f 33 32 58
-f 57 58 36
-f 57 36 34
-f 47 54 44
-f 47 44 56
-f 48 24 22
-f 54 52 14
-f 54 14 44
-f 60 56 18
-f 60 18 32
-f 34 36 38
-f 24 42 22
-f 50 12 8
-f 12 46 8
-f 32 18 26
-f 36 20 38
-f 44 14 4
-f 22 42 40
-f 22 40 46
-f 14 30 4
-f 18 10 26
-f 38 20 28
-f 38 28 42
-f 42 28 40
-f 8 46 16
-f 8 16 30
-f 46 40 16
-f 26 10 2
-f 26 2 20
-f 20 2 28
-f 4 30 6
-f 4 6 10
-f 30 16 6
-f 10 6 2
-f 39 27 1 5 15
-f 3 9 17 55 43
-f 51 49 7 29 13
-f 57 31 25 19 35
-f 47 21 45 11 54
-f 33 37 41 23 60
-f 42 24 59 34 38
-f 46 12 53 48 22
-f 36 58 32 26 20
-f 14 52 50 8 30
-f 44 4 10 18 56
-f 16 40 28 2 6
+#Name:Snub Dodecahedron
+#Type:face_specified
+
+v -2.0502159 -0.64302961 0.17539263
+v 2.0502159 -0.64302961 -0.17539263
+v -1.6450691 0.64302961 1.2360806
+v 1.6450691 0.64302961 -1.2360806
+v -2.0927544 0.33092102 0.39812710
+v 2.0927544 0.33092102 -0.39812710
+v -1.3329632 1.6469179 -0.39812710
+v 1.3329632 1.6469179 0.39812710
+v -1.8252651 -0.33092102 1.0984232
+v 1.8252651 -0.33092102 -1.0984232
+v -0.62604653 1.7461864 -1.0984232
+v 0.62604653 1.7461864 1.0984232
+v -1.0622158 1.4540242 1.1853886
+v 1.0622158 1.4540242 -1.1853886
+v -1.9321359 0.84755005 -0.44288192
+v 1.9321359 0.84755005 0.44288192
+v -1.1448745 -0.84755005 1.6181953
+v 1.1448745 -0.84755005 -1.6181953
+v -1.5819879 -1.4540242 -0.17539263
+v 1.5819879 -1.4540242 0.17539263
+v -1.0574124 0.37482166 -1.8409298
+v 1.0574124 0.37482166 1.8409298
+v -0.43913786 -0.37482166 -2.0770897
+v 0.43913786 -0.37482166 2.0770897
+v -1.5624104 -1.2495038 0.80327387
+v 1.5624104 -1.2495038 -0.80327387
+v -1.8633072 -0.72833518 -0.80327387
+v 1.8633072 -0.72833518 0.80327387
+v -1.7000678 1.2495038 0.44288192
+v 1.7000678 1.2495038 -0.44288192
+v -0.72811404 -1.6469179 1.1853886
+v 0.72811404 -1.6469179 -1.1853886
+v -0.26565458 -1.7461864 -1.2360806
+v 0.26565458 -1.7461864 1.2360806
+v -0.75979117 -1.9778390 -0.39812710
+v 0.75979117 -1.9778390 0.39812710
+v -1.1992186 -1.4152654 -1.0984232
+v 1.1992186 -1.4152654 1.0984232
+v -1.7903298 0.19289371 -1.1853886
+v 1.7903298 0.19289371 1.1853886
+v -1.3064371 -0.56771537 -1.6181953
+v 1.3064371 -0.56771537 1.6181953
+v -0.85331128 0.72833518 1.8409298
+v 0.85331128 0.72833518 -1.8409298
+v -1.3794145 1.1031568 -1.2360806
+v 1.3794145 1.1031568 1.2360806
+v -0.10503615 0.56771537 -2.0770897
+v 0.10503615 0.56771537 2.0770897
+v -0.46822796 2.0970538 -0.17539263
+v 0.46822796 2.0970538 0.17539263
+v -0.30089684 1.9778390 0.80327387
+v 0.30089684 1.9778390 -0.80327387
+v -0.16156263 1.4152654 1.6181953
+v 0.16156263 1.4152654 -1.6181953
+v -0.54417401 -0.19289371 2.0770897
+v 0.54417401 -0.19289371 -2.0770897
+v -0.23206810 -2.0970538 0.44288192
+v 0.23206810 -2.0970538 -0.44288192
+v -0.20410113 -1.1031568 1.8409298
+v 0.20410113 -1.1031568 -1.8409298
+
+f 5 1 9
+f 5 9 3
+f 5 29 15
+f 5 3 29
+f 1 27 19
+f 1 19 25
+f 1 25 9
+f 15 29 7
+f 15 45 39
+f 15 7 45
+f 27 39 41
+f 27 41 37
+f 27 37 19
+f 9 25 17
+f 39 45 21
+f 39 21 41
+f 29 3 13
+f 3 43 13
+f 19 37 35
+f 25 31 17
+f 45 7 11
+f 7 49 11
+f 41 21 23
+f 37 33 35
+f 17 31 59
+f 17 59 55
+f 13 43 53
+f 13 53 51
+f 21 47 23
+f 43 55 48
+f 43 48 53
+f 35 33 58
+f 35 58 57
+f 31 57 34
+f 31 34 59
+f 11 49 52
+f 11 52 54
+f 55 59 24
+f 55 24 48
+f 49 51 50
+f 49 50 52
+f 23 47 56
+f 23 56 60
+f 51 53 12
+f 51 12 50
+f 33 60 32
+f 33 32 58
+f 57 58 36
+f 57 36 34
+f 47 54 44
+f 47 44 56
+f 48 24 22
+f 54 52 14
+f 54 14 44
+f 60 56 18
+f 60 18 32
+f 34 36 38
+f 24 42 22
+f 50 12 8
+f 12 46 8
+f 32 18 26
+f 36 20 38
+f 44 14 4
+f 22 42 40
+f 22 40 46
+f 14 30 4
+f 18 10 26
+f 38 20 28
+f 38 28 42
+f 42 28 40
+f 8 46 16
+f 8 16 30
+f 46 40 16
+f 26 10 2
+f 26 2 20
+f 20 2 28
+f 4 30 6
+f 4 6 10
+f 30 16 6
+f 10 6 2
+f 39 27 1 5 15
+f 3 9 17 55 43
+f 51 49 7 29 13
+f 57 31 25 19 35
+f 47 21 45 11 54
+f 33 37 41 23 60
+f 42 24 59 34 38
+f 46 12 53 48 22
+f 36 58 32 26 20
+f 14 52 50 8 30
+f 44 4 10 18 56
+f 16 40 28 2 6
diff --git a/share/extensions/Poly3DObjects/szilassi.obj b/share/extensions/Poly3DObjects/szilassi.obj
index 00639b85b..9dbce05a6 100644
--- a/share/extensions/Poly3DObjects/szilassi.obj
+++ b/share/extensions/Poly3DObjects/szilassi.obj
@@ -1,24 +1,24 @@
-#Face:Szilassi Polyhedron
-#Type:face_specified
-v -4.8 0. 4.8
-v -2.8 -1. 0.8
-v -2.8 0. 0.8
-v -1.8 1. 0.8
-v -1.5 -1.5 -1.2
-v -0.8 2. -3.2
-v 0. -5.04 -4.8
-v 0. 5.04 -4.8
-v 0.8 -2. -3.2
-v 1.5 1.5 -1.2
-v 1.8 -1. 0.8
-v 2.8 0. 0.8
-v 2.8 1. 0.8
-v 4.8 0. 4.8
-
-f 4 10 6 1 14 13
-f 3 2 1 6 8 7
-f 5 10 4 3 7 9
-f 10 5 11 12 8 6
-f 12 13 14 9 7 8
-f 11 5 9 14 1 2
-f 13 12 11 2 3 4
+#Face:Szilassi Polyhedron
+#Type:face_specified
+v -4.8 0. 4.8
+v -2.8 -1. 0.8
+v -2.8 0. 0.8
+v -1.8 1. 0.8
+v -1.5 -1.5 -1.2
+v -0.8 2. -3.2
+v 0. -5.04 -4.8
+v 0. 5.04 -4.8
+v 0.8 -2. -3.2
+v 1.5 1.5 -1.2
+v 1.8 -1. 0.8
+v 2.8 0. 0.8
+v 2.8 1. 0.8
+v 4.8 0. 4.8
+
+f 4 10 6 1 14 13
+f 3 2 1 6 8 7
+f 5 10 4 3 7 9
+f 10 5 11 12 8 6
+f 12 13 14 9 7 8
+f 11 5 9 14 1 2
+f 13 12 11 2 3 4
diff --git a/share/extensions/Poly3DObjects/tet.obj b/share/extensions/Poly3DObjects/tet.obj
index 75d90ff96..3bd8f0ea4 100644
--- a/share/extensions/Poly3DObjects/tet.obj
+++ b/share/extensions/Poly3DObjects/tet.obj
@@ -1,12 +1,12 @@
-#Name:Tetrahedron
-#Type:face_specified
-
-v 0 0 0.61237244
-v -0.28867513 -0.50000000 -0.20412415
-v -0.28867513 0.50000000 -0.20412415
-v 0.57735027 0 -0.20412415
-
-f 2 3 4
-f 3 2 1
-f 4 1 2
-f 1 4 3
+#Name:Tetrahedron
+#Type:face_specified
+
+v 0 0 0.61237244
+v -0.28867513 -0.50000000 -0.20412415
+v -0.28867513 0.50000000 -0.20412415
+v 0.57735027 0 -0.20412415
+
+f 2 3 4
+f 3 2 1
+f 4 1 2
+f 1 4 3
diff --git a/share/extensions/Poly3DObjects/trunc_cube.obj b/share/extensions/Poly3DObjects/trunc_cube.obj
index 59ce6d07e..1dbcfa60b 100644
--- a/share/extensions/Poly3DObjects/trunc_cube.obj
+++ b/share/extensions/Poly3DObjects/trunc_cube.obj
@@ -1,42 +1,42 @@
-#Name:Truncated Cube
-#Type:face_specified
-
-v -0.5 1.2071068 1.2071068
-v -0.5 1.2071068 -1.2071068
-v -0.5 -1.2071068 1.2071068
-v -0.5 -1.2071068 -1.2071068
-v 0.5 1.2071068 1.2071068
-v 0.5 1.2071068 -1.2071068
-v 0.5 -1.2071068 1.2071068
-v 0.5 -1.2071068 -1.2071068
-v 1.2071068 -0.5 1.2071068
-v 1.2071068 -0.5 -1.2071068
-v 1.2071068 0.5 1.2071068
-v 1.2071068 0.5 -1.2071068
-v 1.2071068 1.2071068 -0.5
-v 1.2071068 1.2071068 0.5
-v 1.2071068 -1.2071068 -0.5
-v 1.2071068 -1.2071068 0.5
-v -1.2071068 -0.5 1.2071068
-v -1.2071068 -0.5 -1.2071068
-v -1.2071068 0.5 1.2071068
-v -1.2071068 0.5 -1.2071068
-v -1.2071068 1.2071068 -0.5
-v -1.2071068 1.2071068 0.5
-v -1.2071068 -1.2071068 -0.5
-v -1.2071068 -1.2071068 0.5
-
-f 6 12 10 8 4 18 20 2
-f 1 19 17 3 7 9 11 5
-f 3 24 23 4 8 15 16 7
-f 5 14 13 6 2 21 22 1
-f 9 16 15 10 12 13 14 11
-f 19 22 21 20 18 23 24 17
-f 16 9 7
-f 5 11 14
-f 3 17 24
-f 22 19 1
-f 8 10 15
-f 13 12 6
-f 23 18 4
-f 2 20 21
+#Name:Truncated Cube
+#Type:face_specified
+
+v -0.5 1.2071068 1.2071068
+v -0.5 1.2071068 -1.2071068
+v -0.5 -1.2071068 1.2071068
+v -0.5 -1.2071068 -1.2071068
+v 0.5 1.2071068 1.2071068
+v 0.5 1.2071068 -1.2071068
+v 0.5 -1.2071068 1.2071068
+v 0.5 -1.2071068 -1.2071068
+v 1.2071068 -0.5 1.2071068
+v 1.2071068 -0.5 -1.2071068
+v 1.2071068 0.5 1.2071068
+v 1.2071068 0.5 -1.2071068
+v 1.2071068 1.2071068 -0.5
+v 1.2071068 1.2071068 0.5
+v 1.2071068 -1.2071068 -0.5
+v 1.2071068 -1.2071068 0.5
+v -1.2071068 -0.5 1.2071068
+v -1.2071068 -0.5 -1.2071068
+v -1.2071068 0.5 1.2071068
+v -1.2071068 0.5 -1.2071068
+v -1.2071068 1.2071068 -0.5
+v -1.2071068 1.2071068 0.5
+v -1.2071068 -1.2071068 -0.5
+v -1.2071068 -1.2071068 0.5
+
+f 6 12 10 8 4 18 20 2
+f 1 19 17 3 7 9 11 5
+f 3 24 23 4 8 15 16 7
+f 5 14 13 6 2 21 22 1
+f 9 16 15 10 12 13 14 11
+f 19 22 21 20 18 23 24 17
+f 16 9 7
+f 5 11 14
+f 3 17 24
+f 22 19 1
+f 8 10 15
+f 13 12 6
+f 23 18 4
+f 2 20 21
diff --git a/share/extensions/Poly3DObjects/trunc_dodec.obj b/share/extensions/Poly3DObjects/trunc_dodec.obj
index 1e21c798e..9a5743afe 100644
--- a/share/extensions/Poly3DObjects/trunc_dodec.obj
+++ b/share/extensions/Poly3DObjects/trunc_dodec.obj
@@ -1,96 +1,96 @@
-#Name:Truncated Dodecahedron
-#Type:face_specified
-
-v 0 -1.6180340 2.4898983
-v 0 -1.6180340 -2.4898983
-v 0 1.6180340 2.4898983
-v 0 1.6180340 -2.4898983
-v 0.42532540 -2.9270510 0.26286556
-v 0.42532540 2.9270510 0.26286556
-v 0.68819096 -2.1180340 1.9641672
-v 0.68819096 2.1180340 1.9641672
-v -2.7527638 0 -1.1135164
-v -2.0645729 -2.1180340 0.26286556
-v -2.0645729 2.1180340 0.26286556
-v -1.3763819 -2.6180340 -0.26286556
-v -1.3763819 2.6180340 -0.26286556
-v -0.68819096 -2.1180340 -1.9641672
-v -0.68819096 2.1180340 -1.9641672
-v 1.3763819 -2.6180340 0.26286556
-v 1.3763819 2.6180340 0.26286556
-v 2.7527638 0 1.1135164
-v 1.8017073 -1.3090170 -1.9641672
-v 1.8017073 1.3090170 -1.9641672
-v 2.0645729 -2.1180340 -0.26286556
-v 2.0645729 2.1180340 -0.26286556
-v 2.2270327 0 1.9641672
-v 2.2270327 -1.6180340 -1.1135164
-v 2.2270327 1.6180340 -1.1135164
-v -2.6523581 -1.3090170 0.26286556
-v -2.6523581 1.3090170 0.26286556
-v 2.6523581 -1.3090170 -0.26286556
-v 2.6523581 1.3090170 -0.26286556
-v 2.9152237 -0.5 0.26286556
-v 2.9152237 0.5 0.26286556
-v -2.9152237 -0.5 -0.26286556
-v -2.9152237 0.5 -0.26286556
-v 0.95105652 -1.3090170 2.4898983
-v 0.95105652 -1.3090170 -2.4898983
-v 0.95105652 1.3090170 2.4898983
-v 0.95105652 1.3090170 -2.4898983
-v 0.85065081 -2.6180340 1.1135164
-v 0.85065081 2.6180340 1.1135164
-v -0.95105652 -1.3090170 2.4898983
-v -0.95105652 -1.3090170 -2.4898983
-v -0.95105652 1.3090170 2.4898983
-v -0.95105652 1.3090170 -2.4898983
-v -1.5388418 -0.5 2.4898983
-v -1.5388418 -0.5 -2.4898983
-v -1.5388418 0.5 2.4898983
-v -1.5388418 0.5 -2.4898983
-v 1.5388418 -0.5 2.4898983
-v 1.5388418 -0.5 -2.4898983
-v 1.5388418 0.5 2.4898983
-v 1.5388418 0.5 -2.4898983
-v -2.2270327 0 -1.9641672
-v -2.2270327 -1.6180340 1.1135164
-v -2.2270327 1.6180340 1.1135164
-v -0.85065081 -2.6180340 -1.1135164
-v -0.85065081 2.6180340 -1.1135164
-v -1.8017073 -1.3090170 1.9641672
-v -1.8017073 1.3090170 1.9641672
-v -0.42532540 -2.9270510 -0.26286556
-v -0.42532540 2.9270510 -0.26286556
-
-f 3 42 46 44 40 1 34 48 50 36
-f 47 43 4 37 51 49 35 2 41 45
-f 2 35 19 24 21 16 5 59 55 14
-f 49 51 20 25 29 31 30 28 24 19
-f 37 4 15 56 60 6 17 22 25 20
-f 43 47 52 9 33 27 11 13 56 15
-f 45 41 14 55 12 10 26 32 9 52
-f 6 60 13 11 54 58 42 3 8 39
-f 27 33 32 26 53 57 44 46 58 54
-f 10 12 59 5 38 7 1 40 57 53
-f 16 21 28 30 18 23 48 34 7 38
-f 31 29 22 17 39 8 36 50 23 18
-f 9 32 33
-f 18 30 31
-f 47 45 52
-f 50 48 23
-f 10 53 26
-f 27 54 11
-f 21 24 28
-f 29 25 22
-f 40 44 57
-f 58 46 42
-f 35 49 19
-f 20 51 37
-f 12 55 59
-f 60 56 13
-f 41 2 14
-f 15 4 43
-f 34 1 7
-f 8 3 36
-f 38 5 16
-f 17 6 39
+#Name:Truncated Dodecahedron
+#Type:face_specified
+
+v 0 -1.6180340 2.4898983
+v 0 -1.6180340 -2.4898983
+v 0 1.6180340 2.4898983
+v 0 1.6180340 -2.4898983
+v 0.42532540 -2.9270510 0.26286556
+v 0.42532540 2.9270510 0.26286556
+v 0.68819096 -2.1180340 1.9641672
+v 0.68819096 2.1180340 1.9641672
+v -2.7527638 0 -1.1135164
+v -2.0645729 -2.1180340 0.26286556
+v -2.0645729 2.1180340 0.26286556
+v -1.3763819 -2.6180340 -0.26286556
+v -1.3763819 2.6180340 -0.26286556
+v -0.68819096 -2.1180340 -1.9641672
+v -0.68819096 2.1180340 -1.9641672
+v 1.3763819 -2.6180340 0.26286556
+v 1.3763819 2.6180340 0.26286556
+v 2.7527638 0 1.1135164
+v 1.8017073 -1.3090170 -1.9641672
+v 1.8017073 1.3090170 -1.9641672
+v 2.0645729 -2.1180340 -0.26286556
+v 2.0645729 2.1180340 -0.26286556
+v 2.2270327 0 1.9641672
+v 2.2270327 -1.6180340 -1.1135164
+v 2.2270327 1.6180340 -1.1135164
+v -2.6523581 -1.3090170 0.26286556
+v -2.6523581 1.3090170 0.26286556
+v 2.6523581 -1.3090170 -0.26286556
+v 2.6523581 1.3090170 -0.26286556
+v 2.9152237 -0.5 0.26286556
+v 2.9152237 0.5 0.26286556
+v -2.9152237 -0.5 -0.26286556
+v -2.9152237 0.5 -0.26286556
+v 0.95105652 -1.3090170 2.4898983
+v 0.95105652 -1.3090170 -2.4898983
+v 0.95105652 1.3090170 2.4898983
+v 0.95105652 1.3090170 -2.4898983
+v 0.85065081 -2.6180340 1.1135164
+v 0.85065081 2.6180340 1.1135164
+v -0.95105652 -1.3090170 2.4898983
+v -0.95105652 -1.3090170 -2.4898983
+v -0.95105652 1.3090170 2.4898983
+v -0.95105652 1.3090170 -2.4898983
+v -1.5388418 -0.5 2.4898983
+v -1.5388418 -0.5 -2.4898983
+v -1.5388418 0.5 2.4898983
+v -1.5388418 0.5 -2.4898983
+v 1.5388418 -0.5 2.4898983
+v 1.5388418 -0.5 -2.4898983
+v 1.5388418 0.5 2.4898983
+v 1.5388418 0.5 -2.4898983
+v -2.2270327 0 -1.9641672
+v -2.2270327 -1.6180340 1.1135164
+v -2.2270327 1.6180340 1.1135164
+v -0.85065081 -2.6180340 -1.1135164
+v -0.85065081 2.6180340 -1.1135164
+v -1.8017073 -1.3090170 1.9641672
+v -1.8017073 1.3090170 1.9641672
+v -0.42532540 -2.9270510 -0.26286556
+v -0.42532540 2.9270510 -0.26286556
+
+f 3 42 46 44 40 1 34 48 50 36
+f 47 43 4 37 51 49 35 2 41 45
+f 2 35 19 24 21 16 5 59 55 14
+f 49 51 20 25 29 31 30 28 24 19
+f 37 4 15 56 60 6 17 22 25 20
+f 43 47 52 9 33 27 11 13 56 15
+f 45 41 14 55 12 10 26 32 9 52
+f 6 60 13 11 54 58 42 3 8 39
+f 27 33 32 26 53 57 44 46 58 54
+f 10 12 59 5 38 7 1 40 57 53
+f 16 21 28 30 18 23 48 34 7 38
+f 31 29 22 17 39 8 36 50 23 18
+f 9 32 33
+f 18 30 31
+f 47 45 52
+f 50 48 23
+f 10 53 26
+f 27 54 11
+f 21 24 28
+f 29 25 22
+f 40 44 57
+f 58 46 42
+f 35 49 19
+f 20 51 37
+f 12 55 59
+f 60 56 13
+f 41 2 14
+f 15 4 43
+f 34 1 7
+f 8 3 36
+f 38 5 16
+f 17 6 39
diff --git a/share/extensions/Poly3DObjects/trunc_icos.obj b/share/extensions/Poly3DObjects/trunc_icos.obj
index f325bef3b..4b535ba5a 100644
--- a/share/extensions/Poly3DObjects/trunc_icos.obj
+++ b/share/extensions/Poly3DObjects/trunc_icos.obj
@@ -1,96 +1,96 @@
-#Name:Truncated Icosahedron
-#Type:Face_specified
-
-v -0.16245985 -2.1180340 1.2759762
-v -0.16245985 2.1180340 1.2759762
-v 0.16245985 -2.1180340 -1.2759762
-v 0.16245985 2.1180340 -1.2759762
-v -0.26286556 -0.80901699 -2.3274384
-v -0.26286556 -2.4270510 -0.42532540
-v -0.26286556 0.80901699 -2.3274384
-v -0.26286556 2.4270510 -0.42532540
-v 0.26286556 -0.80901699 2.3274384
-v 0.26286556 -2.4270510 0.42532540
-v 0.26286556 0.80901699 2.3274384
-v 0.26286556 2.4270510 0.42532540
-v 0.68819096 -0.5 -2.3274384
-v 0.68819096 0.5 -2.3274384
-v 1.2139221 -2.1180340 0.42532540
-v 1.2139221 2.1180340 0.42532540
-v -2.0645729 -0.5 1.2759762
-v -2.0645729 0.5 1.2759762
-v -1.3763819 -1.0 1.8017073
-v -1.3763819 1.0 1.8017073
-v -1.3763819 -1.6180340 -1.2759762
-v -1.3763819 1.6180340 -1.2759762
-v -0.68819096 -0.5 2.3274384
-v -0.68819096 0.5 2.3274384
-v 1.3763819 -1.0 -1.8017073
-v 1.3763819 1.0 -1.8017073
-v 1.3763819 -1.6180340 1.2759762
-v 1.3763819 1.6180340 1.2759762
-v -1.7013016 0 -1.8017073
-v 1.7013016 0 1.8017073
-v -1.2139221 -2.1180340 -0.42532540
-v -1.2139221 2.1180340 -0.42532540
-v -1.9641672 -0.80901699 -1.2759762
-v -1.9641672 0.80901699 -1.2759762
-v 2.0645729 -0.5 -1.2759762
-v 2.0645729 0.5 -1.2759762
-v 2.2270327 -1.0 -0.42532540
-v 2.2270327 1.0 -0.42532540
-v 2.3894926 -0.5 0.42532540
-v 2.3894926 0.5 0.42532540
-v -1.1135164 -1.8090170 1.2759762
-v -1.1135164 1.8090170 1.2759762
-v 1.1135164 -1.8090170 -1.2759762
-v 1.1135164 1.8090170 -1.2759762
-v -2.3894926 -0.5 -0.42532540
-v -2.3894926 0.5 -0.42532540
-v -1.6392475 -1.8090170 0.42532540
-v -1.6392475 1.8090170 0.42532540
-v 1.6392475 -1.8090170 -0.42532540
-v 1.6392475 1.8090170 -0.42532540
-v 1.9641672 -0.80901699 1.2759762
-v 1.9641672 0.80901699 1.2759762
-v 0.85065081 0 2.3274384
-v -2.2270327 -1.0 0.42532540
-v -2.2270327 1.0 0.42532540
-v -0.85065081 0 -2.3274384
-v -0.52573111 -1.6180340 -1.8017073
-v -0.52573111 1.6180340 -1.8017073
-v 0.52573111 -1.6180340 1.8017073
-v 0.52573111 1.6180340 1.8017073
-
-f 53 11 24 23 9
-f 51 39 40 52 30
-f 60 28 16 12 2
-f 20 42 48 55 18
-f 19 17 54 47 41
-f 1 10 15 27 59
-f 36 26 44 50 38
-f 4 58 22 32 8
-f 34 29 33 45 46
-f 21 57 3 6 31
-f 37 49 43 25 35
-f 13 5 56 7 14
-f 9 59 27 51 30 53
-f 53 30 52 28 60 11
-f 11 60 2 42 20 24
-f 24 20 18 17 19 23
-f 23 19 41 1 59 9
-f 13 25 43 3 57 5
-f 5 57 21 33 29 56
-f 56 29 34 22 58 7
-f 7 58 4 44 26 14
-f 14 26 36 35 25 13
-f 40 38 50 16 28 52
-f 16 50 44 4 8 12
-f 12 8 32 48 42 2
-f 48 32 22 34 46 55
-f 55 46 45 54 17 18
-f 54 45 33 21 31 47
-f 47 31 6 10 1 41
-f 10 6 3 43 49 15
-f 15 49 37 39 51 27
-f 39 37 35 36 38 40
+#Name:Truncated Icosahedron
+#Type:Face_specified
+
+v -0.16245985 -2.1180340 1.2759762
+v -0.16245985 2.1180340 1.2759762
+v 0.16245985 -2.1180340 -1.2759762
+v 0.16245985 2.1180340 -1.2759762
+v -0.26286556 -0.80901699 -2.3274384
+v -0.26286556 -2.4270510 -0.42532540
+v -0.26286556 0.80901699 -2.3274384
+v -0.26286556 2.4270510 -0.42532540
+v 0.26286556 -0.80901699 2.3274384
+v 0.26286556 -2.4270510 0.42532540
+v 0.26286556 0.80901699 2.3274384
+v 0.26286556 2.4270510 0.42532540
+v 0.68819096 -0.5 -2.3274384
+v 0.68819096 0.5 -2.3274384
+v 1.2139221 -2.1180340 0.42532540
+v 1.2139221 2.1180340 0.42532540
+v -2.0645729 -0.5 1.2759762
+v -2.0645729 0.5 1.2759762
+v -1.3763819 -1.0 1.8017073
+v -1.3763819 1.0 1.8017073
+v -1.3763819 -1.6180340 -1.2759762
+v -1.3763819 1.6180340 -1.2759762
+v -0.68819096 -0.5 2.3274384
+v -0.68819096 0.5 2.3274384
+v 1.3763819 -1.0 -1.8017073
+v 1.3763819 1.0 -1.8017073
+v 1.3763819 -1.6180340 1.2759762
+v 1.3763819 1.6180340 1.2759762
+v -1.7013016 0 -1.8017073
+v 1.7013016 0 1.8017073
+v -1.2139221 -2.1180340 -0.42532540
+v -1.2139221 2.1180340 -0.42532540
+v -1.9641672 -0.80901699 -1.2759762
+v -1.9641672 0.80901699 -1.2759762
+v 2.0645729 -0.5 -1.2759762
+v 2.0645729 0.5 -1.2759762
+v 2.2270327 -1.0 -0.42532540
+v 2.2270327 1.0 -0.42532540
+v 2.3894926 -0.5 0.42532540
+v 2.3894926 0.5 0.42532540
+v -1.1135164 -1.8090170 1.2759762
+v -1.1135164 1.8090170 1.2759762
+v 1.1135164 -1.8090170 -1.2759762
+v 1.1135164 1.8090170 -1.2759762
+v -2.3894926 -0.5 -0.42532540
+v -2.3894926 0.5 -0.42532540
+v -1.6392475 -1.8090170 0.42532540
+v -1.6392475 1.8090170 0.42532540
+v 1.6392475 -1.8090170 -0.42532540
+v 1.6392475 1.8090170 -0.42532540
+v 1.9641672 -0.80901699 1.2759762
+v 1.9641672 0.80901699 1.2759762
+v 0.85065081 0 2.3274384
+v -2.2270327 -1.0 0.42532540
+v -2.2270327 1.0 0.42532540
+v -0.85065081 0 -2.3274384
+v -0.52573111 -1.6180340 -1.8017073
+v -0.52573111 1.6180340 -1.8017073
+v 0.52573111 -1.6180340 1.8017073
+v 0.52573111 1.6180340 1.8017073
+
+f 53 11 24 23 9
+f 51 39 40 52 30
+f 60 28 16 12 2
+f 20 42 48 55 18
+f 19 17 54 47 41
+f 1 10 15 27 59
+f 36 26 44 50 38
+f 4 58 22 32 8
+f 34 29 33 45 46
+f 21 57 3 6 31
+f 37 49 43 25 35
+f 13 5 56 7 14
+f 9 59 27 51 30 53
+f 53 30 52 28 60 11
+f 11 60 2 42 20 24
+f 24 20 18 17 19 23
+f 23 19 41 1 59 9
+f 13 25 43 3 57 5
+f 5 57 21 33 29 56
+f 56 29 34 22 58 7
+f 7 58 4 44 26 14
+f 14 26 36 35 25 13
+f 40 38 50 16 28 52
+f 16 50 44 4 8 12
+f 12 8 32 48 42 2
+f 48 32 22 34 46 55
+f 55 46 45 54 17 18
+f 54 45 33 21 31 47
+f 47 31 6 10 1 41
+f 10 6 3 43 49 15
+f 15 49 37 39 51 27
+f 39 37 35 36 38 40
diff --git a/share/extensions/Poly3DObjects/trunc_oct.obj b/share/extensions/Poly3DObjects/trunc_oct.obj
index e7b0df593..0c7c8ad91 100644
--- a/share/extensions/Poly3DObjects/trunc_oct.obj
+++ b/share/extensions/Poly3DObjects/trunc_oct.obj
@@ -1,42 +1,42 @@
-#Name:Truncated Octahedron
-#Type:face_specified
-
-v -1.5 -0.5 0
-v -1.5 0.5 0
-v -1. -1. -0.70710678
-v -1. -1. 0.70710678
-v -1. 1. -0.70710678
-v -1. 1. 0.70710678
-v -0.5 -1.5 0
-v -0.5 -0.5 -1.4142136
-v -0.5 -0.5 1.4142136
-v -0.5 0.5 -1.4142136
-v -0.5 0.5 1.4142136
-v -0.5 1.5 0
-v 0.5 -1.5 0
-v 0.5 -0.5 -1.4142136
-v 0.5 -0.5 1.4142136
-v 0.5 0.5 -1.4142136
-v 0.5 0.5 1.4142136
-v 0.5 1.5 0
-v 1. -1. -0.70710678
-v 1. -1. 0.70710678
-v 1. 1. -0.70710678
-v 1. 1. 0.70710678
-v 1.5 -0.5 0
-v 1.5 0.5 0
-
-f 17 11 9 15
-f 14 8 10 16
-f 22 24 21 18
-f 12 5 2 6
-f 13 19 23 20
-f 4 1 3 7
-f 19 13 7 3 8 14
-f 15 9 4 7 13 20
-f 16 10 5 12 18 21
-f 22 18 12 6 11 17
-f 20 23 24 22 17 15
-f 14 16 21 24 23 19
-f 9 11 6 2 1 4
+#Name:Truncated Octahedron
+#Type:face_specified
+
+v -1.5 -0.5 0
+v -1.5 0.5 0
+v -1. -1. -0.70710678
+v -1. -1. 0.70710678
+v -1. 1. -0.70710678
+v -1. 1. 0.70710678
+v -0.5 -1.5 0
+v -0.5 -0.5 -1.4142136
+v -0.5 -0.5 1.4142136
+v -0.5 0.5 -1.4142136
+v -0.5 0.5 1.4142136
+v -0.5 1.5 0
+v 0.5 -1.5 0
+v 0.5 -0.5 -1.4142136
+v 0.5 -0.5 1.4142136
+v 0.5 0.5 -1.4142136
+v 0.5 0.5 1.4142136
+v 0.5 1.5 0
+v 1. -1. -0.70710678
+v 1. -1. 0.70710678
+v 1. 1. -0.70710678
+v 1. 1. 0.70710678
+v 1.5 -0.5 0
+v 1.5 0.5 0
+
+f 17 11 9 15
+f 14 8 10 16
+f 22 24 21 18
+f 12 5 2 6
+f 13 19 23 20
+f 4 1 3 7
+f 19 13 7 3 8 14
+f 15 9 4 7 13 20
+f 16 10 5 12 18 21
+f 22 18 12 6 11 17
+f 20 23 24 22 17 15
+f 14 16 21 24 23 19
+f 9 11 6 2 1 4
f 3 1 2 5 10 8 \ No newline at end of file
diff --git a/share/extensions/Poly3DObjects/trunc_tet.obj b/share/extensions/Poly3DObjects/trunc_tet.obj
index eaa9233ad..d2c9cebb1 100644
--- a/share/extensions/Poly3DObjects/trunc_tet.obj
+++ b/share/extensions/Poly3DObjects/trunc_tet.obj
@@ -1,24 +1,24 @@
-#Name:Truncated Tetrahedron
-#Type:face_specified
-
-v 0 -1. -0.61237244
-v 0 1. -0.61237244
-v -0.57735027 -1. 0.20412415
-v -0.57735027 1. 0.20412415
-v -0.28867513 -0.5 1.0206207
-v -0.28867513 0.5 1.0206207
-v 0.57735027 0 1.0206207
-v 1.1547005 0 0.20412415
-v -0.86602540 -0.5 -0.61237244
-v -0.86602540 0.5 -0.61237244
-v 0.86602540 -0.5 -0.61237244
-v 0.86602540 0.5 -0.61237244
-
-f 11 12 8
-f 3 9 1
-f 2 10 4
-f 6 5 7
-f 11 8 7 5 3 1
-f 2 4 6 7 8 12
-f 9 3 5 6 4 10
+#Name:Truncated Tetrahedron
+#Type:face_specified
+
+v 0 -1. -0.61237244
+v 0 1. -0.61237244
+v -0.57735027 -1. 0.20412415
+v -0.57735027 1. 0.20412415
+v -0.28867513 -0.5 1.0206207
+v -0.28867513 0.5 1.0206207
+v 0.57735027 0 1.0206207
+v 1.1547005 0 0.20412415
+v -0.86602540 -0.5 -0.61237244
+v -0.86602540 0.5 -0.61237244
+v 0.86602540 -0.5 -0.61237244
+v 0.86602540 0.5 -0.61237244
+
+f 11 12 8
+f 3 9 1
+f 2 10 4
+f 6 5 7
+f 11 8 7 5 3 1
+f 2 4 6 7 8 12
+f 9 3 5 6 4 10
f 2 12 11 1 9 10 \ No newline at end of file
diff --git a/share/extensions/gcodetools.py b/share/extensions/gcodetools.py
index f99c050bd..e5f1944b0 100644
--- a/share/extensions/gcodetools.py
+++ b/share/extensions/gcodetools.py
@@ -1,5 +1,44 @@
#!/usr/bin/env python
"""
+Comments starting "#LT" or "#CLT" are by Chris Lusby Taylor who rewrote the engraving function in 2011.
+History of CLT changes to engraving and other functions it uses:
+9 May 2011 Changed test of tool diameter to square it
+10 May Note that there are many unused functions, including:
+ bound_to_bound_distance, csp_curvature_radius_at_t,
+ csp_special_points, csplength, rebuild_csp, csp_slope,
+ csp_simple_bound_to_point_distance, csp_bound_to_point_distance,
+ bez_at_t, bez_to_point_distance, bez_normalized_slope, matrix_mul, transpose
+ Fixed csp_point_inside_bound() to work if x outside bounds
+20 May Now encoding the bisectors of angles.
+23 May Using r/cos(a) instead of normalised normals for bisectors of angles.
+23 May Note that Z values generated for engraving are in pixels, not mm.
+ Removed the biarc curves - straight lines are better.
+24 May Changed Bezier slope calculation to be less sensitive to tiny differences in points.
+ Added use of self.options.engraving_newton_iterations to control accuracy
+25 May Big restructure and new recursive function.
+ Changed the way I treat corners - I now find if the centre of a proposed circle is
+ within the area bounded by the line being tested and the two angle bisectors at
+ its ends. See get_radius_to_line().
+29 May Eliminating redundant points. If A,B,C colinear, drop B
+30 May Eliminating redundant lines in divided Beziers. Changed subdivision of lines
+ 7Jun Try to show engraving in 3D
+ 8 Jun Displaying in stereo 3D.
+ Fixed a bug in bisect - it could go wrong due to rounding errors if
+ 1+x1.x2+y1.y2<0 which should never happen. BTW, I spotted a non-normalised normal
+ returned by csp_normalized_normal. Need to check for that.
+ 9 Jun Corrected spelling of 'definition' but still match previous 'defention' and 'defenition' if found in file
+ Changed get_tool to find 1.6.04 tools or new tools with corrected spelling
+10 Jun Put 3D into a separate layer called 3D, created unless it already exists
+ Changed csp_normalized_slope to reject lines shorter than 1e-9.
+10 Jun Changed all dimensions seen by user to be mm/inch, not pixels. This includes
+ tool diameter, maximum engraving distance, tool shape and all Z values.
+12 Jun ver 208 Now scales correctly if orientation points moved or stretched.
+12 Jun ver 209. Now detect if engraving toolshape not a function of radius
+ Graphics now indicate Gcode toolpath, limited by min(tool diameter/2,max-dist)
+TODO Change line division to be recursive, depending on what line is touched. See line_divide
+
+
+engraving() functions (c) 2011 Chris Lusby Taylor, clusbytaylor@enterprise.net
Copyright (C) 2009 Nick Drobchenko, nick@cnc-club.ru
based on gcode.py (C) 2007 hugomatic...
based on addnodes.py (C) 2005,2007 Aaron Spike, aaron@ekips.org
@@ -24,9 +63,10 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"""
###
-### Gcodetools v 1.6.03
+### Gcodetools v 1.7
###
-gcodetools_current_version = "1.6.03"
+
+gcodetools_current_version = "1.7"
import inkex, simplestyle, simplepath
import cubicsuperpath, simpletransform, bezmisc
@@ -46,7 +86,7 @@ import gettext
_ = gettext.gettext
-### Check if inkex has errormsg (0.46 version doesnot have one.) Could be removed later.
+### Check if inkex has errormsg (0.46 version does not have one.) Could be removed later.
if "errormsg" not in dir(inkex):
inkex.errormsg = lambda msg: sys.stderr.write((unicode(msg) + "\n").encode("UTF-8"))
@@ -74,6 +114,11 @@ def ireplace(self,old,new,count=0):
pattern = re.compile(re.escape(old),re.I)
return re.sub(pattern,new,self,count)
+def isset(variable):
+ # VARIABLE NAME SHOULD BE A STRING! Like isset("foobar")
+ return variable in locals() or variable in globals()
+
+
################################################################################
###
### Styles and additional parameters
@@ -85,6 +130,9 @@ straight_tolerance = 0.0001
straight_distance_tolerance = 0.0001
engraving_tolerance = 0.0001
loft_lengths_tolerance = 0.0000001
+
+EMC_TOLERANCE_EQUAL = 0.00001
+
options = {}
defaults = {
'header': """%
@@ -108,6 +156,8 @@ intersection_recursion_depth = 10
intersection_tolerance = 0.00001
styles = {
+ "in_out_path_style" : simplestyle.formatStyle({ 'stroke': '#0072a7', 'fill': 'none', 'stroke-width':'1', 'marker-mid':'url(#InOutPathMarker)' }),
+
"loft_style" : {
'main curve': simplestyle.formatStyle({ 'stroke': '#88f', 'fill': 'none', 'stroke-width':'1', 'marker-end':'url(#Arrow2Mend)' }),
},
@@ -166,10 +216,114 @@ styles = {
}
+
+################################################################################
+### Gcode additional functions
+################################################################################
+
+def gcode_comment_str(s, replace_new_line = False):
+ if replace_new_line :
+ s = re.sub(r"[\n\r]+", ".", s)
+ res = ""
+ if s[-1] == "\n" : s = s[:-1]
+ for a in s.split("\n") :
+ if a != "" :
+ res += "(" + re.sub(r"[\(\)\\\n\r]", ".", a) + ")\n"
+ else :
+ res += "\n"
+ return res
+
+
################################################################################
### Cubic Super Path additional functions
################################################################################
+
+def csp_from_polyline(line) :
+ return [ [ [point[:] for k in range(3) ] for point in subline ] for subline in line ]
+
+def csp_remove_zerro_segments(csp, tolerance = 1e-7):
+ res = []
+ for subpath in csp:
+ if len(subpath) > 0 :
+ res.append([subpath[0]])
+ for sp1,sp2 in zip(subpath,subpath[1:]) :
+ if point_to_point_d2(sp1[1],sp2[1])<=tolerance and point_to_point_d2(sp1[2],sp2[1])<=tolerance and point_to_point_d2(sp1[1],sp2[0])<=tolerance :
+ res[-1][-1][2] = sp2[2]
+ else :
+ res[-1].append(sp2)
+ return res
+
+
+
+
+
+def point_inside_csp(p,csp, on_the_path = True) :
+ # we'll do the raytracing and see how many intersections are there on the ray's way.
+ # if number of intersections is even then point is outside.
+ # ray will be x=p.x and y=>p.y
+ # you can assing any value to on_the_path, by dfault if point is on the path
+ # function will return thai it's inside the path.
+ x,y = p
+ ray_intersections_count = 0
+ for subpath in csp :
+
+ for i in range(1, len(subpath)) :
+ sp1, sp2 = subpath[i-1], subpath[i]
+ ax,ay,bx,by,cx,cy,dx,dy = csp_parameterize(sp1,sp2)
+ if ax==0 and bx==0 and cx==0 and dx==x :
+ #we've got a special case here
+ b = csp_true_bounds( [[sp1,sp2]])
+ if b[1][1]<=y<=b[3][1] :
+ # points is on the path
+ return on_the_path
+ else :
+ # we can skip this segment because it wont influence the answer.
+ pass
+ else:
+ for t in csp_line_intersection([x,y],[x,y+5],sp1,sp2) :
+ if t == 0 or t == 1 :
+ #we've got another special case here
+ x1,y1 = csp_at_t(sp1,sp2,t)
+ if y1==y :
+ # the point is on the path
+ return on_the_path
+ # if t == 0 we sould have considered this case previously.
+ if t == 1 :
+ # we have to check the next segmant if it is on the same side of the ray
+ st_d = csp_normalized_slope(sp1,sp2,1)[0]
+ if st_d == 0 : st_d = csp_normalized_slope(sp1,sp2,0.99)[0]
+
+ for j in range(1, len(subpath)+1):
+ if (i+j) % len(subpath) == 0 : continue # skip the closing segment
+ sp11,sp22 = subpath[(i-1+j) % len(subpath)], subpath[(i+j) % len(subpath)]
+ ax1,ay1,bx1,by1,cx1,cy1,dx1,dy1 = csp_parameterize(sp1,sp2)
+ if ax1==0 and bx1==0 and cx1==0 and dx1==x : continue # this segment parallel to the ray, so skip it
+ en_d = csp_normalized_slope(sp11,sp22,0)[0]
+ if en_d == 0 : en_d = csp_normalized_slope(sp11,sp22,0.01)[0]
+ if st_d*en_d <=0 :
+ ray_intersections_count += 1
+ break
+ else :
+ x1,y1 = csp_at_t(sp1,sp2,t)
+ if y1==y :
+ # the point is on the path
+ return on_the_path
+ else :
+ if y1>y and 3*ax*t**2 + 2*bx*t + cx !=0 : # if it's 0 the path only touches the ray
+ ray_intersections_count += 1
+ return ray_intersections_count%2 == 1
+
+def csp_close_all_subpaths(csp, tolerance = 0.000001):
+ for i in range(len(csp)):
+ if point_to_point_d2(csp[i][0][1] , csp[i][-1][1])> tolerance**2 :
+ csp[i][-1][2] = csp[i][-1][1][:]
+ csp[i] += [ [csp[i][0][1][:] for j in range(3)] ]
+ else:
+ if csp[i][0][1] != csp[i][-1][1] :
+ csp[i][-1][1] = csp[i][0][1][:]
+ return csp
+
def csp_simple_bound(csp):
minx,miny,maxx,maxy = None,None,None,None
for subpath in csp:
@@ -333,6 +487,7 @@ def csp_split(sp1,sp2,t=.5) :
y = y1223+(y2334-y1223)*t
return [sp1[0],sp1[1],[x12,y12]], [[x1223,y1223],[x,y],[x2334,y2334]], [[x34,y34],sp2[1],sp2[2]]
+
def csp_true_bounds(csp) :
# Finds minx,miny,maxx,maxy of the csp and return their (x,y,i,j,t)
minx = [float("inf"), 0, 0, 0]
@@ -603,6 +758,11 @@ def csp_at_t(sp1,sp2,t):
x,y = x4+(x5-x4)*t, y4+(y5-y4)*t
return [x,y]
+def csp_at_length(sp1,sp2,l=0.5, tolerance = 0.01):
+ bez = (sp1[1][:],sp1[2][:],sp2[0][:],sp2[1][:])
+ t = bezmisc.beziertatlength(bez, l, tolerance)
+ return csp_at_t(sp1,sp2,t)
+
def csp_splitatlength(sp1, sp2, l = 0.5, tolerance = 0.01):
bez = (sp1[1][:],sp1[2][:],sp2[0][:],sp2[1][:])
@@ -610,7 +770,7 @@ def csp_splitatlength(sp1, sp2, l = 0.5, tolerance = 0.01):
return csp_split(sp1, sp2, t)
-def cspseglength(sp1,sp2, tolerance = 0.001):
+def cspseglength(sp1,sp2, tolerance = 0.01):
bez = (sp1[1][:],sp1[2][:],sp2[0][:],sp2[1][:])
return bezmisc.bezierlength(bez, tolerance)
@@ -712,6 +872,20 @@ def csp_split_by_two_points(sp1,sp2,t1,t2) :
sp2,sp3,sp4 = csp_split(sp2,sp3,(t2-t1)/(1-t1) )
return [sp1,sp2,sp3,sp4]
+def csp_seg_split(sp1,sp2, points):
+ # points is float=t or list [t1, t2, ..., tn]
+ if type(points) is float :
+ points = [points]
+ points.sort()
+ res = [sp1,sp2]
+ last_t = 0
+ for t in points:
+ if 1e-10<t<1.-1e-10 :
+ sp3,sp4,sp5 = csp_split(res[-2],res[-1], (t-last_t)/(1-last_t))
+ last_t = t
+ res[-2:] = [sp3,sp4,sp5]
+ return res
+
def csp_subpath_split_by_points(subpath, points) :
# points are [[i,t]...] where i-segment's number
@@ -745,6 +919,22 @@ def csp_subpath_split_by_points(subpath, points) :
return parts
+def arc_from_s_r_n_l(s,r,n,l) :
+ if abs(n[0]**2+n[1]**2 - 1) > 1e-10 : n = normalize(n)
+ return arc_from_c_s_l([s[0]+n[0]*r, s[1]+n[1]*r],s,l)
+
+
+def arc_from_c_s_l(c,s,l) :
+ r = point_to_point_d(c,s)
+ if r == 0 : return []
+ alpha = l/r
+ cos_, sin_ = math.cos(alpha), math.sin(alpha)
+ e = [ c[0] + (s[0]-c[0])*cos_ - (s[1]-c[1])*sin_, c[1] + (s[0]-c[0])*sin_ + (s[1]-c[1])*cos_]
+ n = [c[0]-s[0],c[1]-s[1]]
+ slope = rotate_cw(n) if l>0 else rotate_ccw(n)
+ return csp_from_arc(s, e, c, r, slope)
+
+
def csp_from_arc(start, end, center, r, slope_st) :
# Creates csp that approximise specified arc
r = abs(r)
@@ -828,11 +1018,16 @@ def csp_point_inside_bound(sp1, sp2, p):
bez = [sp1[1],sp1[2],sp2[0],sp2[1]]
x,y = p
c = 0
+ #CLT added test of x in range
+ xmin=1e100
+ xmax=-1e100
for i in range(4):
[x0,y0], [x1,y1] = bez[i-1], bez[i]
+ xmin=min(xmin,x0)
+ xmax=max(xmax,x0)
if x0-x1!=0 and (y-y0)*(x1-x0)>=(x-x0)*(y1-y0) and x>min(x0,x1) and x<=max(x0,x1) :
c +=1
- return c%2==0
+ return xmin<=x<=xmax and c%2==0
def csp_bound_to_point_distance(sp1, sp2, p):
@@ -962,14 +1157,14 @@ def csp_normalized_slope(sp1,sp2,t) :
if sp1[1]==sp2[1]==sp1[2]==sp2[0] : return [1.,0.]
f1x = 3*ax*t*t+2*bx*t+cx
f1y = 3*ay*t*t+2*by*t+cy
- if abs(f1x*f1x+f1y*f1y) > 1e-20 :
+ if abs(f1x*f1x+f1y*f1y) > 1e-9 : #LT changed this from 1e-20, which caused problems
l = math.sqrt(f1x*f1x+f1y*f1y)
return [f1x/l, f1y/l]
if t == 0 :
f1x = sp2[0][0]-sp1[1][0]
f1y = sp2[0][1]-sp1[1][1]
- if abs(f1x*f1x+f1y*f1y) > 1e-20 :
+ if abs(f1x*f1x+f1y*f1y) > 1e-9 : #LT changed this from 1e-20, which caused problems
l = math.sqrt(f1x*f1x+f1y*f1y)
return [f1x/l, f1y/l]
else :
@@ -981,7 +1176,7 @@ def csp_normalized_slope(sp1,sp2,t) :
elif t == 1 :
f1x = sp2[1][0]-sp1[2][0]
f1y = sp2[1][1]-sp1[2][1]
- if abs(f1x*f1x+f1y*f1y) > 1e-20 :
+ if abs(f1x*f1x+f1y*f1y) > 1e-9 :
l = math.sqrt(f1x*f1x+f1y*f1y)
return [f1x/l, f1y/l]
else :
@@ -1020,16 +1215,6 @@ def csp_concat_subpaths(*s):
result = concat(result,s1)
return result
-
-def csp_draw(csp, color="#05f", group = None, style="fill:none;", width = .1, comment = "") :
- if csp!=[] and csp!=[[]] :
- if group == None : group = options.doc_root
- style += "stroke:"+color+";"+ "stroke-width:%0.4fpx;"%width
- args = {"d": cubicsuperpath.formatPath(csp), "style":style}
- if comment!="" : args["comment"] = str(comment)
- inkex.etree.SubElement( group, inkex.addNS('path','svg'), args )
-
-
def csp_subpaths_end_to_start_distance2(s1,s2):
return (s1[-1][1][0]-s2[0][1][0])**2 + (s1[-1][1][1]-s2[0][1][1])**2
@@ -1054,16 +1239,25 @@ def csp_clip_by_line(csp,l1,l2) :
return result
-def csp_subpath_line_to(subpath, points) :
+def csp_subpath_line_to(subpath, points, prepend = False) :
# Appends subpath with line or polyline.
if len(points)>0 :
- if len(subpath)>0:
- subpath[-1][2] = subpath[-1][1][:]
- if type(points[0]) == type([1,1]) :
- for p in points :
- subpath += [ [p[:],p[:],p[:]] ]
- else:
- subpath += [ [points,points,points] ]
+ if not prepend :
+ if len(subpath)>0:
+ subpath[-1][2] = subpath[-1][1][:]
+ if type(points[0]) == type([1,1]) :
+ for p in points :
+ subpath += [ [p[:],p[:],p[:]] ]
+ else:
+ subpath += [ [points,points,points] ]
+ else :
+ if len(subpath)>0:
+ subpath[0][0] = subpath[0][1][:]
+ if type(points[0]) == type([1,1]) :
+ for p in points :
+ subpath = [ [p[:],p[:],p[:]] ] + subpath
+ else:
+ subpath = [ [points,points,points] ] + subpath
return subpath
@@ -1198,10 +1392,19 @@ def dot(a,b) :
def rotate_ccw(d) :
return [-d[1],d[0]]
+def rotate_cw(d) :
+ return [d[1],-d[0]]
+
def vectors_ccw(a,b):
return a[0]*b[1]-b[0]*a[1] < 0
+def vector_add(a,b) :
+ return [a[0]+b[0],a[1]+b[1]]
+
+def vector_mul(a,b) :
+ return [a[0]*b,a[1]*b]
+
def vector_from_to_length(a,b):
return math.sqrt((a[0]-b[0])*(a[0]-b[0]) + (a[1]-b[1])*(a[1]-b[1]))
@@ -1265,36 +1468,83 @@ def atan2(*arg):
else :
raise ValueError, "Bad argumets for atan! (%s)" % arg
+def get_text(node) :
+ value = None
+ if node.text!=None : value = value +"\n" + node.text if value != None else node.text
+ for k in node :
+ if k.tag == inkex.addNS('tspan','svg'):
+ if k.text!=None : value = value +"\n" + k.text if value != None else k.text
+ return value
+
+
-def draw_text(text,x,y,style = None, font_size = 20) :
+def draw_text(text,x,y, group = None, style = None, font_size = 10, gcodetools_tag = None) :
if style == None :
- style = "font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;"
+ style = "font-family:DejaVu Sans;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:DejaVu Sans;fill:#000000;fill-opacity:1;stroke:none;"
style += "font-size:%fpx;"%font_size
- t = inkex.etree.SubElement( options.doc_root, inkex.addNS('text','svg'), {
- 'x': str(x),
+ attributes = { 'x': str(x),
inkex.addNS("space","xml"):"preserve",
- 'y': str(y)
- })
+ 'y': str(y),
+ 'style' : style
+ }
+ if gcodetools_tag!=None :
+ attributes["gcodetools"] = str(gcodetools_tag)
+
+ if group == None:
+ group = options.doc_root
+
+ t = inkex.etree.SubElement( group, inkex.addNS('text','svg'), attributes)
text = str(text).split("\n")
for s in text :
span = inkex.etree.SubElement( t, inkex.addNS('tspan','svg'),
{
'x': str(x),
- 'y': str(+y),
+ 'y': str(y),
inkex.addNS("role","sodipodi"):"line",
})
y += font_size
- span.text = s
-
+ span.text = str(s)
-def draw_pointer(x,color = "#f00", figure = "cross", comment = "", width = .1) :
- if figure == "line" :
+def draw_csp(csp, stroke = "#f00", fill = "none", comment = "", width = 0.354, group = None, style = None, gcodetools_tag = None) :
+ if style == None :
+ style = "fill:%s;fill-opacity:1;stroke:%s;stroke-width:%s"%(fill,stroke,width)
+ attributes = { 'd': cubicsuperpath.formatPath(csp),
+ 'style' : style
+ }
+ if comment != '':
+ attributes['comment'] = comment
+ if group == None :
+ group = options.doc_root
+
+ return inkex.etree.SubElement( group, inkex.addNS('path','svg'), attributes)
+
+def draw_pointer(x,color = "#f00", figure = "cross", group = None, comment = "", fill=None, width = .1, size = 10., text = None, font_size=None, pointer_type=None, attrib = None) :
+ size = size/2
+ if attrib == None : attrib = {}
+ if pointer_type == None:
+ pointer_type = "Pointer"
+ attrib["gcodetools"] = pointer_type
+ if group == None:
+ group = options.self.current_layer
+ if text != None :
+ if font_size == None : font_size = 7
+ group = inkex.etree.SubElement( group, inkex.addNS('g','svg'), {"gcodetools": pointer_type+" group"} )
+ draw_text(text,x[0]+size*2.2,x[1]-size, group = group, font_size = font_size)
+ if figure == "line" :
s = ""
for i in range(1,len(x)/2) :
s+= " %s, %s " %(x[i*2],x[i*2+1])
- inkex.etree.SubElement( options.doc_root, inkex.addNS('path','svg'), {"d": "M %s,%s L %s"%(x[0],x[1],s), "style":"fill:none;stroke:%s;stroke-width:%f;"%(color,width),"comment":str(comment)} )
+ attrib.update({"d": "M %s,%s L %s"%(x[0],x[1],s), "style":"fill:none;stroke:%s;stroke-width:%f;"%(color,width),"comment":str(comment)})
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attrib)
+ elif figure == "arrow" :
+ if fill == None : fill = "#12b3ff"
+ fill_opacity = "0.8"
+ d = "m %s,%s " % (x[0],x[1]) + re.sub("([0-9\-.e]+)",(lambda match: str(float(match.group(1))*size*2.)), "0.88464,-0.40404 c -0.0987,-0.0162 -0.186549,-0.0589 -0.26147,-0.1173 l 0.357342,-0.35625 c 0.04631,-0.039 0.0031,-0.13174 -0.05665,-0.12164 -0.0029,-1.4e-4 -0.0058,-1.4e-4 -0.0087,0 l -2.2e-5,2e-5 c -0.01189,0.004 -0.02257,0.0119 -0.0305,0.0217 l -0.357342,0.35625 c -0.05818,-0.0743 -0.102813,-0.16338 -0.117662,-0.26067 l -0.409636,0.88193 z")
+ attrib.update({"d": d, "style":"fill:%s;stroke:none;fill-opacity:%s;"%(fill,fill_opacity),"comment":str(comment)})
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attrib)
else :
- inkex.etree.SubElement( options.doc_root, inkex.addNS('path','svg'), {"d": "m %s,%s l 10,10 -20,-20 10,10 -10,10, 20,-20"%(x[0],x[1]), "style":"fill:none;stroke:%s;stroke-width:%f;"%(color,width),"comment":str(comment)} )
+ attrib.update({"d": "m %s,%s l %f,%f %f,%f %f,%f %f,%f , %f,%f"%(x[0],x[1], size,size, -2*size,-2*size, size,size, size,-size, -2*size,2*size ), "style":"fill:none;stroke:%s;stroke-width:%f;"%(color,width),"comment":str(comment)})
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attrib)
def straight_segments_intersection(a,b, true_intersection = True) : # (True intersection means check ta and tb are in [0,1])
@@ -1320,7 +1570,19 @@ def isinf(x): inf = 1e5000; return x == inf or x == -inf
def between(c,x,y):
return x-straight_tolerance<=c<=y+straight_tolerance or y-straight_tolerance<=c<=x+straight_tolerance
-
+def cubic_solver_real(a,b,c,d):
+ # returns only real roots of a cubic equation.
+ roots = cubic_solver(a,b,c,d)
+ res = []
+ for root in roots :
+ if type(root) is complex :
+ if -1e-10<root.imag<1e-10 :
+ res.append(root.real)
+ else :
+ res.append(root)
+ return res
+
+
def cubic_solver(a,b,c,d):
if a!=0:
# Monics formula see http://en.wikipedia.org/wiki/Cubic_function#Monic_formula_of_roots
@@ -1402,6 +1664,223 @@ class P:
def to_list(self): return [self.x, self.y]
def ccw(self): return P(-self.y,self.x)
def l2(self): return self.x*self.x + self.y*self.y
+
+
+class Arc():
+ def __init__(self,st,end,c,a):
+ self.st = P(st)
+ self.end = P(end)
+ self.c = P(c)
+ self.r = (P(st)-P(c)).mag()
+ self.a = ( (self.st-self.c).angle() - (self.end-self.c).angle() ) % math.pi2
+ if a<0 : self.a -= math.pi2
+
+ def offset(self, r):
+ if self.a>0 :
+ r += self.r
+ else :
+ r = self.r - r
+
+ if self.r != 0 :
+ self.st = self.c + (self.st-self.c)*r/self.r
+ self.end = self.c + (self.end-self.c)*r/self.r
+ self.r = r
+
+ def length(self):
+ return abs(self.a*self.r)
+
+
+ def draw(self, group, style, layer, transform, num = 0, reverse_angle = 1):
+ st = P(gcodetools.transform(self.st.to_list(), layer, True))
+ c = P(gcodetools.transform(self.c.to_list(), layer, True))
+ a = self.a * reverse_angle
+ r = (st-c)
+ a_st = (math.atan2(r.x,-r.y) - math.pi/2) % (math.pi*2)
+ r = r.mag()
+ if a<0:
+ a_end = a_st+a
+ style = style['biarc%s'%(num%2)]
+ else:
+ a_end = a_st
+ a_st = a_st+a
+ style = style['biarc%s_r'%(num%2)]
+
+ attr = {
+ 'style': style,
+ inkex.addNS('cx','sodipodi'): str(c.x),
+ inkex.addNS('cy','sodipodi'): str(c.y),
+ inkex.addNS('rx','sodipodi'): str(r),
+ inkex.addNS('ry','sodipodi'): str(r),
+ inkex.addNS('start','sodipodi'): str(a_st),
+ inkex.addNS('end','sodipodi'): str(a_end),
+ inkex.addNS('open','sodipodi'): 'true',
+ inkex.addNS('type','sodipodi'): 'arc',
+ "gcodetools": "Preview",
+ }
+ if transform != [] :
+ attr["transform"] = transform
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attr)
+
+ def intersect(self,b) :
+ return []
+
+
+class Line():
+ def __init__(self,st,end):
+ if st.__class__ == P :
+ st = st.to_list()
+ if end.__class__ == P :
+ end = end.to_list()
+ self.st = P(st)
+ self.end = P(end)
+ self.l = self.length()
+ if self.l != 0 :
+ self.n = ((self.end-self.st)/self.l).ccw()
+ else:
+ self.n = [0,1]
+
+ def offset(self, r):
+ self.st -= self.n*r
+ self.end -= self.n*r
+
+ def l2(self): return (self.st-self.end).l2()
+ def length(self): return (self.st-self.end).mag()
+
+ def draw(self, group, style, layer, transform, num = 0, reverse_angle = 1):
+ st = gcodetools.transform(self.st.to_list(), layer, True)
+ end = gcodetools.transform(self.end.to_list(), layer, True)
+
+
+ attr = { 'style': style['line'],
+ 'd':'M %s,%s L %s,%s' % (st[0],st[1],end[0],end[1]),
+ "gcodetools": "Preview",
+ }
+ if transform != [] :
+ attr["transform"] = transform
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attr )
+
+ def intersect(self,b) :
+ if b.__class__ == Line :
+ if self.l < 10e-8 or b.l < 10e-8 : return []
+ v1 = self.end - self.st
+ v2 = b.end - b.st
+ x = v1.x*v2.y - v2.x*v1.y
+ if x == 0 :
+ # lines are parallel
+ res = []
+
+ if (self.st.x-b.st.x)*v1.y - (self.st.y-b.st.y)*v1.x == 0:
+ # lines are the same
+ if v1.x != 0 :
+ if 0<=(self.st.x-b.st.x)/v2.x<=1 : res.append(self.st)
+ if 0<=(self.end.x-b.st.x)/v2.x<=1 : res.append(self.end)
+ if 0<=(b.st.x-self.st.x)/v1.x<=1 : res.append(b.st)
+ if 0<=(b.end.x-b.st.x)/v1.x<=1 : res.append(b.end)
+ else :
+ if 0<=(self.st.y-b.st.y)/v2.y<=1 : res.append(self.st)
+ if 0<=(self.end.y-b.st.y)/v2.y<=1 : res.append(self.end)
+ if 0<=(b.st.y-self.st.y)/v1.y<=1 : res.append(b.st)
+ if 0<=(b.end.y-b.st.y)/v1.y<=1 : res.append(b.end)
+ return res
+ else :
+ t1 = ( -v1.x*(b.end.y-self.end.y) + v1.y*(b.end.x-self.end.x) ) / x
+ t2 = ( -v1.y*(self.st.x-b.st.x) + v1.x*(self.st.y-b.st.y) ) / x
+
+ gcodetools.error((x,t1,t2), "warning")
+ if 0<=t1<=1 and 0<=t2<=1 : return [ self.st+v1*t1 ]
+ else : return []
+ else: return []
+
+
+
+
+class Biarc:
+ def __init__(self, items=None):
+ if items == None :
+ self.items = []
+ else:
+ self.items = items
+
+ def l(self) :
+ return sum([i.length() for i in items])
+
+ def close(self) :
+ for subitems in self.items:
+ if (subitems[0].st-subitems[-1].end).l2()>10e-16 :
+ subitems.append(Line(subitems[-1].end,subitems[0].st))
+
+ def offset(self,r) :
+ # offset each element
+ self.close()
+ for subitems in self.items :
+ for item in subitems :
+ item.offset(r)
+ self.connect(r)
+
+ def connect(self, r) :
+ for subitems in self.items :
+ for a,b in zip(subitems, subitems[1:]) :
+ i = a.intersect(b)
+ for p in i :
+ draw_pointer(p.to_list())
+
+
+
+
+ def clip_offset(self):
+ pass
+
+ def draw(self, layer, group=None, style=styles["biarc_style"]):
+ global gcodetools
+ gcodetools.set_markers()
+
+ for i in [0,1]:
+ style['biarc%s_r'%i] = simplestyle.parseStyle(style['biarc%s'%i])
+ style['biarc%s_r'%i]["marker-start"] = "url(#DrawCurveMarker_r)"
+ del(style['biarc%s_r'%i]["marker-end"])
+ style['biarc%s_r'%i] = simplestyle.formatStyle(style['biarc%s_r'%i])
+
+ if group==None:
+ if "preview_groups" not in dir(options.self) :
+ gcodetools.preview_groups = { layer: inkex.etree.SubElement( gcodetools.layers[min(1,len(gcodetools.layers)-1)], inkex.addNS('g','svg'), {"gcodetools": "Preview group"} ) }
+ elif layer not in gcodetools.preview_groups :
+ gcodetools.preview_groups[layer] = inkex.etree.SubElement( gcodetools.layers[min(1,len(gcodetools.layers)-1)], inkex.addNS('g','svg'), {"gcodetools": "Preview group"} )
+ group = gcodetools.preview_groups[layer]
+
+ transform = gcodetools.get_transforms(group)
+ if transform != [] :
+ transform = gcodetools.reverse_transform(transform)
+ transform = simpletransform.formatTransform(transform)
+
+ a,b,c = [0.,0.], [1.,0.], [0.,1.]
+ k = (b[0]-a[0])*(c[1]-a[1])-(c[0]-a[0])*(b[1]-a[1])
+ a,b,c = gcodetools.transform(a, layer, True), gcodetools.transform(b, layer, True), gcodetools.transform(c, layer, True)
+ if ((b[0]-a[0])*(c[1]-a[1])-(c[0]-a[0])*(b[1]-a[1]))*k > 0 : reverse_angle = -1
+ else : reverse_angle = 1
+
+
+ num = 0
+ for subitems in self.items :
+ for item in subitems :
+ num += 1
+ #if num>1 : break
+ item.draw(group, style, layer, transform, num, reverse_angle)
+
+ def from_old_style(self, curve) :
+ #Crve defenitnion [start point, type = {'arc','line','move','end'}, arc center, arc angle, end point, [zstart, zend]]
+ self.items = []
+ for sp in curve:
+ print_(sp)
+ if sp[1] == 'move':
+ self.items.append([])
+ if sp[1] == 'arc':
+ self.items[-1].append(Arc(sp[0],sp[4],sp[2],sp[3]))
+ if sp[1] == 'line':
+ self.items[-1].append(Line(sp[0],sp[4]))
+
+
+
+
################################################################################
###
@@ -1454,7 +1933,7 @@ def csp_offset(csp, r) :
else :
pass # ???
#raise ValueError, "Offset curvature clipping error"
- #csp_draw([result])
+ #draw_csp([result])
return result
@@ -1558,7 +2037,7 @@ def csp_offset(csp, r) :
r2 = offset_segment_recursion(sp4,sp5,r, depth-1, tolerance)
return r1[:-1]+ [[r1[-1][0],r1[-1][1],r2[0][2]]] + r2[1:]
else :
- #csp_draw([[sp1_r,sp2_r]])
+ #draw_csp([[sp1_r,sp2_r]])
#draw_pointer(sp1[1]+sp1_r[1], "#057", "line")
#draw_pointer(sp2[1]+sp2_r[1], "#705", "line")
return [sp1_r,sp2_r]
@@ -1618,8 +2097,8 @@ def csp_offset(csp, r) :
prev_l = len(subpath_offset)
else :
prev, arc, next = csp_join_offsets(subpath_offset[-prev_l:],segment_offset,sp1,sp2,sp1_l,sp2_l,r)
- #csp_draw([prev],"Blue")
- #csp_draw([arc],"Magenta")
+ #draw_csp([prev],"Blue")
+ #draw_csp([arc],"Magenta")
subpath_offset = csp_concat_subpaths(subpath_offset[:-prev_l+1],prev,arc,next)
prev_l = len(next)
sp1_l, sp2_l = sp1[:], sp2[:]
@@ -1629,9 +2108,9 @@ def csp_offset(csp, r) :
prev, arc, next = csp_join_offsets(subpath_offset[-prev_l:], subpath_offset[:2], subpath[0], subpath[1], sp1_l,sp2_l, r)
subpath_offset[:2] = next[:]
subpath_offset = csp_concat_subpaths(subpath_offset[:-prev_l+1],prev,arc)
- #csp_draw([prev],"Blue")
- #csp_draw([arc],"Red")
- #csp_draw([next],"Red")
+ #draw_csp([prev],"Blue")
+ #draw_csp([arc],"Red")
+ #draw_csp([next],"Red")
# Collect subpath's offset and save it to unclipped offset list.
unclipped_offset[i] = subpath_offset[:]
@@ -1644,7 +2123,7 @@ def csp_offset(csp, r) :
time_ = time.time()
#for i in range(len(unclipped_offset)):
- # csp_draw([unclipped_offset[i]], color = ["Green","Red","Blue"][i%3], width = .1)
+ # draw_csp([unclipped_offset[i]], color = ["Green","Red","Blue"][i%3], width = .1)
#return []
############################################################################
# Now to the clipping.
@@ -1716,7 +2195,7 @@ def csp_offset(csp, r) :
splitted_offset += [subpath[:]]
#for i in range(len(splitted_offset)):
- # csp_draw([splitted_offset[i]], color = ["Green","Red","Blue"][i%3])
+ # draw_csp([splitted_offset[i]], color = ["Green","Red","Blue"][i%3])
print_("Splitted in %s"%(time.time()-time_))
time_ = time.time()
@@ -1742,7 +2221,7 @@ def csp_offset(csp, r) :
if not clip :
result += [s1[:]]
elif options.offset_draw_clippend_path :
- csp_draw([s1],color="Red",width=.1)
+ draw_csp([s1],color="Red",width=.1)
draw_pointer( csp_at_t(s2[-2],s2[-1],1.)+
(P(csp_at_t(s2[-2],s2[-1],1.))+ P(csp_normalized_normal(s2[-2],s2[-1],1.))*10).to_list(),"Green", "line" )
draw_pointer( csp_at_t(s1[0],s1[1],0.)+
@@ -1751,14 +2230,14 @@ def csp_offset(csp, r) :
# Now join all together and check closure and orientation of result
joined_result = csp_join_subpaths(result)
# Check if each subpath from joined_result is closed
- #csp_draw(joined_result,color="Green",width=1)
+ #draw_csp(joined_result,color="Green",width=1)
for s in joined_result[:] :
if csp_subpaths_end_to_start_distance2(s,s) > 0.001 :
# Remove open parts
if options.offset_draw_clippend_path:
- csp_draw([s],color="Orange",width=1)
+ draw_csp([s],color="Orange",width=1)
draw_pointer(s[0][1], comment= csp_subpaths_end_to_start_distance2(s,s))
draw_pointer(s[-1][1], comment = csp_subpaths_end_to_start_distance2(s,s))
joined_result.remove(s)
@@ -1781,7 +2260,7 @@ def csp_offset(csp, r) :
if not r1 < dist[0] < r2 :
joined_result.remove(s)
if options.offset_draw_clippend_path:
- csp_draw([s], comment = math.sqrt(dist[0]))
+ draw_csp([s], comment = math.sqrt(dist[0]))
draw_pointer(csp_at_t(csp[dist[1]][dist[2]-1],csp[dist[1]][dist[2]],dist[3])+s[int(len(s)/2)][1],"blue", "line", comment = [math.sqrt(dist[0]),i,j,sp] )
print_("-----------------------------")
@@ -1867,7 +2346,7 @@ def biarc(sp1, sp2, z1, z2, depth=0):
alpha = (p2a - p0a) % (2*math.pi)
if (p0a<p2a and (p1a<p0a or p2a<p1a)) or (p2a<p1a<p0a) :
alpha = -2*math.pi+alpha
- if abs(R.x)>1000000 or abs(R.y)>1000000 or (R-P0).mag<options.min_arc_radius :
+ if abs(R.x)>1000000 or abs(R.y)>1000000 or (R-P0).mag<options.min_arc_radius**2 :
return None, None
else :
return R, alpha
@@ -1880,7 +2359,22 @@ def biarc(sp1, sp2, z1, z2, depth=0):
else:
if R2.mag()*a2 == 0 : zm = z2
else : zm = z1 + (z2-z1)*(abs(R1.mag()*a1))/(abs(R2.mag()*a2)+abs(R1.mag()*a1))
- return [ [ sp1[1], 'arc', [R1.x,R1.y], a1, [P2.x,P2.y], [z1,zm] ], [ [P2.x,P2.y], 'arc', [R2.x,R2.y], a2, [P4.x,P4.y], [zm,z2] ] ]
+
+ l = (P0-P2).l2()
+ if l < EMC_TOLERANCE_EQUAL**2 or l<EMC_TOLERANCE_EQUAL**2 * R1.l2() /100 :
+ # arc should be straight otherwise it could be threated as full circle
+ arc1 = [ sp1[1], 'line', 0, 0, [P2.x,P2.y], [z1,zm] ]
+ else :
+ arc1 = [ sp1[1], 'arc', [R1.x,R1.y], a1, [P2.x,P2.y], [z1,zm] ]
+
+ l = (P4-P2).l2()
+ if l < EMC_TOLERANCE_EQUAL**2 or l<EMC_TOLERANCE_EQUAL**2 * R2.l2() /100 :
+ # arc should be straight otherwise it could be threated as full circle
+ arc2 = [ [P2.x,P2.y], 'line', 0, 0, [P4.x,P4.y], [zm,z2] ]
+ else :
+ arc2 = [ [P2.x,P2.y], 'arc', [R2.x,R2.y], a2, [P4.x,P4.y], [zm,z2] ]
+
+ return [ arc1, arc2 ]
def biarc_curve_segment_length(seg):
@@ -1948,7 +2442,8 @@ class Postprocessor():
"flip" : self.flip_axis,
"flip_axis" : self.flip_axis,
"round" : self.round_coordinates,
- "parameterize" : self.parameterize,
+ "parameterize" : self.parameterize,
+ "regex" : self.re_sub_on_gcode_lines
}
@@ -1976,11 +2471,15 @@ class Postprocessor():
self.error("Unrecognized function '%s' while postprocessing.\n(Command: '%s')"%(function,command), "error")
- def re_sub_on_gcode_lines(self, pattern,replacemant):
+ def re_sub_on_gcode_lines(self, parameters):
gcode = self.gcode.split("\n")
self.gcode = ""
- for i in range(len(gcode)) :
- self.gcode += re.sub(pattern,replacement,gcode[i])
+ try :
+ for line in gcode :
+ self.gcode += eval( "re.sub(%s,line)"%parameters) +"\n"
+
+ except Exception as ex :
+ self.error("Bad parameters for regexp. They should be as re.sub pattern and replacement parameters! For example: r\"G0(\d)\", r\"G\\1\" \n(Parameters: '%s')\n %s"%(parameters, ex), "error")
def remapi(self,parameters):
@@ -2230,12 +2729,13 @@ class Polygon:
def rotate_(self,sin,cos) :
- for i in range(len(self.polygon)) :
- for j in range(len(self.polygon[i])) :
- x,y = self.polygon[i][j][0], self.polygon[i][j][1]
- self.polygon[i][j][0] = x*cos - y*sin
- self.polygon[i][j][1] = x*sin + y*cos
-
+ self.polygon = [
+ [
+ [point[0]*cos - point[1]*sin,point[0]*sin + point[1]*cos] for point in subpoly
+ ]
+ for subpoly in self.polygon
+ ]
+
def rotate(self, a):
cos, sin = math.cos(a), math.sin(a)
@@ -2322,9 +2822,10 @@ class Polygon:
self.move(0, -dist)
- def draw(self,color="#075",width=.1) :
- for poly in self.polygon :
- csp_draw( [csp_subpath_line_to([],poly+[poly[0]])], color=color,width=width )
+ def draw(self,color="#075",width=.1, group = None) :
+ csp = [csp_subpath_line_to([],poly+[poly[0]]) for poly in self.polygon]
+ draw_csp( csp, color=color,width=width, group = group)
+
def add(self, add) :
@@ -2593,7 +3094,8 @@ class Arangement_Genetic:
self.incest_mutation_multiplyer = 2.
self.incest_mutation_count_multiplyer = 2.
else :
- if random.random()<.01 : print_(self.species_distance2(parent1, parent2))
+ pass
+# if random.random()<.01 : print_(self.species_distance2(parent1, parent2))
start_gene = random.randint(0,self.genes_count)
end_gene = (max(1,random.randint(0,self.genes_count),int(self.genes_count/4))+start_gene) % self.genes_count
if end_gene<start_gene :
@@ -2643,6 +3145,7 @@ class Arangement_Genetic:
def test(self,test_function):
+ time_ = time.time()
for i in range(len(self.population)) :
if self.population[i][0] == None :
surface = test_function(self.population[i][1])
@@ -2650,24 +3153,82 @@ class Arangement_Genetic:
self.population[i][0] = (b[3]-b[1])*(b[2]-b[0])
self.population.sort()
-
def test_spiece_centroid(self,spiece) :
- poly = Polygon(copy.deepcopy(self.polygons[spiece[0][0]].polygon))
- poly.rotate(spiece[0][2]*math.pi2)
+ poly = Polygon( self.polygons[spiece[0][0]].polygon[:])
+ poly.rotate(spiece[0][1]*math.pi2)
surface = Polygon(poly.polygon)
- i = 0
for p in spiece[1:] :
- i += 1
- poly = Polygon(copy.deepcopy(self.polygons[p[0]].polygon))
- poly.rotate(p[2]*math.pi2)
+ poly = Polygon(self.polygons[p[0]].polygon[:])
c = surface.centroid()
+ surface.move(-c[0],-c[1])
c1 = poly.centroid()
- direction = [math.cos(p[1]*math.pi2), -math.sin(p[1]*math.pi2)]
- poly.move(c[0]-c1[0]-direction[0]*100,c[1]-c1[1]-direction[1]*100)
- poly.drop_into_direction(direction,surface)
+ poly.move(-c1[0],-c1[1])
+ poly.rotate(p[1]*math.pi2+p[2]*math.pi2)
+ surface.rotate(p[2]*math.pi2)
+ poly.drop_down(surface)
surface.add(poly)
+ surface.rotate(-p[2]*math.pi2)
return surface
+
+ def test_inline(self) :
+ ###
+ ### Fast test function using weave's from scipy inline function
+ ###
+ try :
+ converters is None
+ except :
+ try:
+ from scipy import weave
+ from scipy.weave import converters
+ except:
+ options.self.error("For this function Scipy is needed. See http://www.cnc-club.ru/gcodetools for details.","error")
+
+ # Prepare vars
+ poly_, subpoly_, points_ = [], [], []
+ for poly in self.polygons :
+ p = poly.polygon
+ poly_ += [len(subpoly_), len(subpoly_)+len(p)*2]
+ for subpoly in p :
+ subpoly_ += [len(points_), len(points_)+len(subpoly)*2+2]
+ for point in subpoly :
+ points_ += point
+ points_ += subpoly[0] # Close subpolygon
+
+ test_ = []
+ population_ = []
+ for spiece in self.population:
+ test_.append( spiece[0] if spiece[0] != None else -1)
+ for sp in spiece[1]:
+ population_ += sp
+
+ lp_, ls_, l_, lt_ = len(poly_), len(subpoly_), len(points_), len(test_)
+
+ f = open('inline_test.c', 'r')
+ code = f.read()
+ f.close()
+
+ f = open('inline_test_functions.c', 'r')
+ functions = f.read()
+ f.close()
+
+ stdout_ = sys.stdout
+ s = ''
+ sys.stdout = s
+
+ test = weave.inline(
+ code,
+ ['points_','subpoly_','poly_', 'lp_', 'ls_', 'l_', 'lt_','test_', 'population_'],
+ compiler='gcc',
+ support_code = functions,
+ )
+ if s!='' : options.self.error(s,"warning")
+ sys.stdout = stdout_
+
+ for i in range(len(test_)):
+ self.population[i][0] = test_[i]
+
+
#surface.draw()
@@ -2681,7 +3242,7 @@ class Arangement_Genetic:
class Gcodetools(inkex.Effect):
- def export_gcode(self,gcode) :
+ def export_gcode(self,gcode, no_headers = False) :
if self.options.postprocessor != "" or self.options.postprocessor_custom != "" :
postprocessor = Postprocessor(self.error)
postprocessor.gcode = gcode
@@ -2689,13 +3250,169 @@ class Gcodetools(inkex.Effect):
postprocessor.process(self.options.postprocessor)
if self.options.postprocessor_custom != "" :
postprocessor.process(self.options.postprocessor_custom)
- postprocessor.gcode = self.header + postprocessor.gcode + self.footer
+
+ if not no_headers :
+ postprocessor.gcode = self.header + postprocessor.gcode + self.footer
+
f = open(self.options.directory+self.options.file, "w")
f.write(postprocessor.gcode)
f.close()
################################################################################
+### In/out paths:
+### TODO move it to the bottom
+################################################################################
+ def plasma_prepare_path(self) :
+
+ def add_arc(sp1,sp2,end = False,l=10.,r=10.) :
+ if not end :
+ n = csp_normalized_normal(sp1,sp2,0.)
+ return csp_reverse([arc_from_s_r_n_l(sp1[1],r,n,-l)])[0]
+ else:
+ n = csp_normalized_normal(sp1,sp2,1.)
+ return arc_from_s_r_n_l(sp2[1],r,n,l)
+
+ def add_normal(sp1,sp2,end = False,l=10.,r=10.) :
+ # r is needed only for be compatible with add_arc
+ if not end :
+ n = csp_normalized_normal(sp1,sp2,0.)
+ p = [n[0]*l+sp1[1][0],n[1]*l+sp1[1][1]]
+ return csp_subpath_line_to([], [p,sp1[1]])
+ else:
+ n = csp_normalized_normal(sp1,sp2,1.)
+ p = [n[0]*l+sp2[1][0],n[1]*l+sp2[1][1]]
+ return csp_subpath_line_to([], [sp2[1],p])
+
+ def add_tangent(sp1,sp2,end = False,l=10.,r=10.) :
+ # r is needed only for be compatible with add_arc
+ if not end :
+ n = csp_normalized_slope(sp1,sp2,0.)
+ p = [-n[0]*l+sp1[1][0],-n[1]*l+sp1[1][1]]
+ return csp_subpath_line_to([], [p,sp1[1]])
+ else:
+ n = csp_normalized_slope(sp1,sp2,1.)
+ p = [n[0]*l+sp2[1][0],n[1]*l+sp2[1][1]]
+ return csp_subpath_line_to([], [sp2[1],p])
+
+ if not self.options.in_out_path and not self.options.plasma_prepare_corners and self.options.in_out_path_do_not_add_reference_point:
+ self.error("Warning! Extenstion is not said to do anything! Enable one of Create in-out paths or Prepare corners checkboxes or disable Do not add in-out referense point!")
+ return
+
+ # Add in-out-reference point if there is no one yet.
+ if ( (len(self.in_out_reference_points)==0 and self.options.in_out_path
+ or not self.options.in_out_path and not self.options.plasma_prepare_corners )
+ and not self.options.in_out_path_do_not_add_reference_point) :
+ self.options.orientation_points_count = "in-out reference point"
+ self.orientation()
+
+ if self.options.in_out_path or self.options.plasma_prepare_corners:
+ self.set_markers()
+ add_func = {"Round":add_arc, "Perpendicular": add_normal, "Tangent": add_tangent}[self.options.in_out_path_type]
+ if self.options.in_out_path_type == "Round" and self.options.in_out_path_len > self.options.in_out_path_radius*3/2*math.pi :
+ self.error("In-out len is to big for in-out radius will cropp it to be r*3/2*pi!", "warning")
+
+ if self.selected_paths == {} and self.options.auto_select_paths:
+ self.selected_paths = self.paths
+ self.error(_("No paths are selected! Trying to work on all available paths."),"warning")
+
+ if self.selected_paths == {}:
+ self.error(_("Noting is selected. Please select something."),"warning")
+ a = self.options.plasma_prepare_corners_tolerance
+ corner_tolerance = cross([1.,0.], [math.cos(a),math.sin(a)])
+
+ for layer in self.layers :
+ if layer in self.selected_paths :
+ max_dist = self.transform_scalar(self.options.in_out_path_point_max_dist, layer, reverse=True)
+ l = self.transform_scalar(self.options.in_out_path_len, layer, reverse=True)
+ plasma_l = self.transform_scalar(self.options.plasma_prepare_corners_distance, layer, reverse=True)
+ r = self.transform_scalar(self.options.in_out_path_radius, layer, reverse=True)
+ l = min(l,r*3/2*math.pi)
+
+ for path in self.selected_paths[layer]:
+ csp = self.apply_transforms( path, cubicsuperpath.parsePath(path.get("d")) )
+ csp = csp_remove_zerro_segments(csp)
+ res = []
+
+ for subpath in csp :
+ # Find closes point to in-out reference point
+ # If subpath is open skip this step
+ if self.options.in_out_path :
+ # split and reverse path for further add in-out points
+ if point_to_point_d2(subpath[0][1], subpath[-1][1]) < 1.e-10 :
+ d = [1e100,1,1,1.]
+ for p in self.in_out_reference_points :
+ d1 = csp_to_point_distance([subpath], p, dist_bounds = [0,max_dist], tolerance=.01)
+ if d1[0] < d[0] :
+ d = d1[:]
+ p_ = p
+ if d[0] < max_dist**2 :
+ # Lets find is there any angles near this point to put in-out path in
+ # the angle if it's possible
+ # remove last node to make iterations easier
+ subpath[0][0] = subpath[-1][0]
+ del subpath[-1]
+ max_cross = [-1e100, None]
+ for j in range(len(subpath)) :
+ sp1,sp2,sp3 = subpath[j-2],subpath[j-1],subpath[j]
+ if point_to_point_d2(sp2[1],p_)<max_dist**2:
+ s1,s2 = csp_normalized_slope(sp1,sp2,1.), csp_normalized_slope(sp2,sp3,0.)
+ max_cross = max(max_cross,[cross(s1,s2),j-1])
+ # return back last point
+ subpath.append(subpath[0])
+ if max_cross[1] !=None and max_cross[0]>corner_tolerance :
+ # there's an angle near the point
+ j = max_cross[1]
+ if j<0 : j -= 1
+ if j!=0 :
+ subpath = csp_concat_subpaths(subpath[j:],subpath[:j+1])
+ else :
+ # have to cut path's segment
+ d,i,j,t = d
+ sp1,sp2,sp3 = csp_split(subpath[j-1],subpath[j],t)
+ subpath = csp_concat_subpaths([sp2,sp3], subpath[j:], subpath[:j], [sp1,sp2])
+
+ if self.options.plasma_prepare_corners :
+ # prepare corners
+ # find corners and add some nodes
+ # corner at path's start/end is ignored
+ res_ = [subpath[0]]
+ for sp2, sp3 in zip(subpath[1:],subpath[2:]) :
+ sp1 = res_[-1]
+ s1,s2 = csp_normalized_slope(sp1,sp2,1.), csp_normalized_slope(sp2,sp3,0.)
+ if cross(s1,s2) > corner_tolerance :
+ # got a corner to process
+ S1,S2 = P(s1),P(s2)
+ N = (S1-S2).unit()*plasma_l
+ SP2= P(sp2[1])
+ P1 = (SP2 + N)
+ res_ += [
+ [sp2[0],sp2[1], (SP2+S1*plasma_l).to_list() ],
+ [ (P1-N.ccw()/2 ).to_list(), P1.to_list(), (P1+N.ccw()/2).to_list()],
+ [(SP2-S2*plasma_l).to_list(), sp2[1],sp2[2]]
+ ]
+ else:
+ res_ += [sp2]
+ res_ += [sp3]
+ subpath = res_
+ if self.options.in_out_path :
+ # finally add let's add in-out paths...
+ subpath = csp_concat_subpaths(
+ add_func(subpath[0],subpath[1],False,l,r),
+ subpath,
+ add_func(subpath[-2],subpath[-1],True,l,r)
+ )
+
+
+ res += [ subpath ]
+
+
+ if self.options.in_out_path_replace_original_path :
+ path.set("d", cubicsuperpath.formatPath( self.apply_transforms(path,res,True) ))
+ else:
+ draw_csp(res, width=1, style=styles["in_out_path_style"] )
+
+################################################################################
### Arrangement: arranges paths by givven params
### TODO move it to the bottom
################################################################################
@@ -2732,18 +3449,19 @@ class Gcodetools(inkex.Effect):
population = Arangement_Genetic(polygons, material_width)
- print_("Genetic alhorithm start at %s"%(time_))
+ print_("Genetic algorithm start at %s"%(time_))
+ start_time = time.time()
time_ = time.time()
population.add_random_species(50)
- population.test(population.test_spiece_centroid)
+ #population.test(population.test_spiece_centroid)
print_("Initial population done in %s"%(time.time()-time_))
time_ = time.time()
pop = copy.deepcopy(population)
population_count = self.options.arrangement_population_count
- last_champ = []
+ last_champ = -1
champions_count = 0
@@ -2757,6 +3475,7 @@ class Gcodetools(inkex.Effect):
population.move_mutation_factor = 1.
population.mutation_genes_count = [1,2]
population.populate_species(250, 20)
+ print_("Populate done at %s"%(time.time()-time_))
"""
randomize = i%100 < 40
if i%100 < 40 :
@@ -2768,26 +3487,27 @@ class Gcodetools(inkex.Effect):
population.order_mutation_factor = 1./(i%100-79) if 80<=i%100<100 else 1.
population.populate_species(250, 10)
"""
- population.test(population.test_spiece_centroid)
+ if self.options.arrangement_inline_test :
+ population.test_inline()
+ else:
+ population.test(population.test_spiece_centroid)
+
+ print_("Test done at %s"%(time.time()-time_))
draw_new_champ = False
print_()
- for x in population.population[:10]:
- print_(x[0])
+
if population.population[0][0]!= last_champ :
draw_new_champ = True
+ improve = last_champ-population.population[0][0]
last_champ = population.population[0][0]*1
-
- k = ""
- #for j in range(10) :
- # k += "%s " % population.population[j][0]
+
print_("Cicle %s done in %s"%(i,time.time()-time_))
time_ = time.time()
print_("%s incests been found"%population.inc)
print_()
- #print_(k)
- #print_()
+
if i == 0 or i == population_count-1 or draw_new_champ :
colors = ["blue"]
@@ -2796,9 +3516,9 @@ class Gcodetools(inkex.Effect):
x,y = 400* (champions_count%10), 700*int(champions_count/10)
surface.move(x-b[0],y-b[1])
surface.draw(width=2, color=colors[0])
- draw_text("Step = %s\nSquare = %f"%(i,(b[2]-b[0])*(b[3]-b[1])),x,y-40)
+ draw_text("Step = %s\nSquare = %f\nSquare improvement = %f\nTime from start = %f"%(i,(b[2]-b[0])*(b[3]-b[1]),improve,time.time()-start_time),x,y-50)
champions_count += 1
-
+ """
spiece = population.population[0][1]
poly = Polygon(copy.deepcopy(population.polygons[spiece[0][0]].polygon))
poly.rotate(spiece[0][2]*math.pi2)
@@ -2831,7 +3551,7 @@ class Gcodetools(inkex.Effect):
poly.drop_into_direction(direction,surface)
surface.add(poly)
-
+ """
# Now we'll need apply transforms to original paths
@@ -2850,15 +3570,27 @@ class Gcodetools(inkex.Effect):
self.OptionParser.add_option("", "--biarc-tolerance", action="store", type="float", dest="biarc_tolerance", default="1", help="Tolerance used when calculating biarc interpolation.")
self.OptionParser.add_option("", "--biarc-max-split-depth", action="store", type="int", dest="biarc_max_split_depth", default="4", help="Defines maximum depth of splitting while approximating using biarcs.")
+ self.OptionParser.add_option("", "--path-to-gcode-order", action="store", type="string", dest="path_to_gcode_order", default="path by path", help="Defines cutting order path by path or layer by layer.")
+ self.OptionParser.add_option("", "--path-to-gcode-depth-function",action="store", type="string", dest="path_to_gcode_depth_function", default="zd", help="Path to gcode depth function.")
+ self.OptionParser.add_option("", "--path-to-gcode-sort-paths", action="store", type="inkbool", dest="path_to_gcode_sort_paths", default=True, help="Sort paths to reduse rapid distance.")
+ self.OptionParser.add_option("", "--comment-gcode", action="store", type="string", dest="comment_gcode", default="", help="Comment Gcode")
+ self.OptionParser.add_option("", "--comment-gcode-from-properties",action="store", type="inkbool", dest="comment_gcode_from_properties", default=False,help="Get additional comments from Object Properties")
+
+
self.OptionParser.add_option("", "--tool-diameter", action="store", type="float", dest="tool_diameter", default="3", help="Tool diameter used for area cutting")
self.OptionParser.add_option("", "--max-area-curves", action="store", type="int", dest="max_area_curves", default="100", help="Maximum area curves for each area")
- self.OptionParser.add_option("", "--area-inkscape-radius", action="store", type="float", dest="area_inkscape_radius", default="-10", help="Radius for preparing curves using inkscape")
+ self.OptionParser.add_option("", "--area-inkscape-radius", action="store", type="float", dest="area_inkscape_radius", default="0", help="Area curves overlaping (depends on tool diameter [0,0.9])")
+ self.OptionParser.add_option("", "--area-tool-overlap", action="store", type="float", dest="area_tool_overlap", default="-10", help="Radius for preparing curves using inkscape")
self.OptionParser.add_option("", "--unit", action="store", type="string", dest="unit", default="G21 (All units in mm)", help="Units")
self.OptionParser.add_option("", "--active-tab", action="store", type="string", dest="active_tab", default="", help="Defines which tab is active")
- self.OptionParser.add_option("", "--area-find-artefacts-diameter",action="store", type="float", dest="area_find_artefacts_diameter", default="1", help="artefacts seeking radius")
- self.OptionParser.add_option("", "--area-find-artefacts-action", action="store", type="string", dest="area_find_artefacts_action", default="mark with an arrow", help="artefacts action type")
+ self.OptionParser.add_option("", "--area-fill-angle", action="store", type="float", dest="area_fill_angle", default="0", help="Fill area with lines heading this angle")
+ self.OptionParser.add_option("", "--area-fill-shift", action="store", type="float", dest="area_fill_shift", default="0", help="Shift the lines by tool d * shift")
+ self.OptionParser.add_option("", "--area-fill-method", action="store", type="string", dest="area_fill_method", default="zig-zag", help="Filling method either zig-zag or spiral")
+
+ self.OptionParser.add_option("", "--area-find-artefacts-diameter",action="store", type="float", dest="area_find_artefacts_diameter", default="1", help="Artefacts seeking radius")
+ self.OptionParser.add_option("", "--area-find-artefacts-action", action="store", type="string", dest="area_find_artefacts_action", default="mark with an arrow", help="Artefacts action type")
self.OptionParser.add_option("", "--auto_select_paths", action="store", type="inkbool", dest="auto_select_paths", default=True, help="Select all paths if nothing is selected.")
@@ -2881,11 +3613,13 @@ class Gcodetools(inkex.Effect):
self.OptionParser.add_option("", "--lathe-x-axis-remap", action="store", type="string", dest="lathe_x_axis_remap", default="X", help="Lathe X axis remap")
self.OptionParser.add_option("", "--lathe-z-axis-remap", action="store", type="string", dest="lathe_z_axis_remap", default="Z", help="Lathe Z axis remap")
+ self.OptionParser.add_option("", "--lathe-rectangular-cutter-width",action="store", type="float", dest="lathe_rectangular_cutter_width", default="4", help="Rectangular cutter width")
+
self.OptionParser.add_option("", "--create-log", action="store", type="inkbool", dest="log_create_log", default=False, help="Create log files")
self.OptionParser.add_option("", "--log-filename", action="store", type="string", dest="log_filename", default='', help="Create log files")
- self.OptionParser.add_option("", "--orientation-points-count", action="store", type="int", dest="orientation_points_count", default='2', help="Orientation points count")
- self.OptionParser.add_option("", "--tools-library-type", action="store", type="string", dest="tools_library_type", default='cylinder cutter', help="Create tools defention")
+ self.OptionParser.add_option("", "--orientation-points-count", action="store", type="string", dest="orientation_points_count", default="2", help="Orientation points count")
+ self.OptionParser.add_option("", "--tools-library-type", action="store", type="string", dest="tools_library_type", default='cylinder cutter', help="Create tools definition")
self.OptionParser.add_option("", "--dxfpoints-action", action="store", type="string", dest="dxfpoints_action", default='replace', help="dxfpoint sign toggle")
@@ -2898,11 +3632,32 @@ class Gcodetools(inkex.Effect):
self.OptionParser.add_option("", "--arrangement-material-width", action="store", type="float", dest="arrangement_material_width", default=500, help="Materials width for arrangement")
self.OptionParser.add_option("", "--arrangement-population-count",action="store", type="int", dest="arrangement_population_count", default=100, help="Genetic algorithm populations count")
+ self.OptionParser.add_option("", "--arrangement-inline-test", action="store", type="inkbool", dest="arrangement_inline_test", default=False, help="Use C-inline test (some additional packets will be needed)")
+
self.OptionParser.add_option("", "--postprocessor", action="store", type="string", dest="postprocessor", default='', help="Postprocessor command.")
self.OptionParser.add_option("", "--postprocessor-custom", action="store", type="string", dest="postprocessor_custom", default='', help="Postprocessor custom command.")
-
+ self.OptionParser.add_option("", "--graffiti-max-seg-length", action="store", type="float", dest="graffiti_max_seg_length", default=1., help="Graffiti maximum segment length.")
+ self.OptionParser.add_option("", "--graffiti-min-radius", action="store", type="float", dest="graffiti_min_radius", default=10., help="Graffiti minimal connector's radius.")
+ self.OptionParser.add_option("", "--graffiti-start-pos", action="store", type="string", dest="graffiti_start_pos", default="(0;0)", help="Graffiti Start position (x;y).")
+ self.OptionParser.add_option("", "--graffiti-create-linearization-preview", action="store", type="inkbool", dest="graffiti_create_linearization_preview", default=True, help="Graffiti create linearization preview.")
+ self.OptionParser.add_option("", "--graffiti-create-preview", action="store", type="inkbool", dest="graffiti_create_preview", default=True, help="Graffiti create preview.")
+ self.OptionParser.add_option("", "--graffiti-preview-size", action="store", type="int", dest="graffiti_preview_size", default=800, help="Graffiti preview's size.")
+ self.OptionParser.add_option("", "--graffiti-preview-emmit", action="store", type="int", dest="graffiti_preview_emmit", default=800, help="Preview's paint emmit (pts/s).")
+
+
+ self.OptionParser.add_option("", "--in-out-path", action="store", type="inkbool", dest="in_out_path", default=True, help="Create in-out paths")
+ self.OptionParser.add_option("", "--in-out-path-do-not-add-reference-point", action="store", type="inkbool", dest="in_out_path_do_not_add_reference_point", default=False, help="Just add reference in-out point")
+ self.OptionParser.add_option("", "--in-out-path-point-max-dist", action="store", type="float", dest="in_out_path_point_max_dist", default=10., help="In-out path max distance to reference point")
+ self.OptionParser.add_option("", "--in-out-path-type", action="store", type="string", dest="in_out_path_type", default="Round", help="In-out path type")
+ self.OptionParser.add_option("", "--in-out-path-len", action="store", type="float", dest="in_out_path_len", default=10., help="In-out path length")
+ self.OptionParser.add_option("", "--in-out-path-replace-original-path",action="store", type="inkbool", dest="in_out_path_replace_original_path", default=False, help="Replace original path")
+ self.OptionParser.add_option("", "--in-out-path-radius", action="store", type="float", dest="in_out_path_radius", default=10., help="In-out path radius for round path")
+
+ self.OptionParser.add_option("", "--plasma-prepare-corners", action="store", type="inkbool", dest="plasma_prepare_corners", default=True, help="Prepare corners")
+ self.OptionParser.add_option("", "--plasma-prepare-corners-distance", action="store", type="float", dest="plasma_prepare_corners_distance", default=10.,help="Stepout distance for corners")
+ self.OptionParser.add_option("", "--plasma-prepare-corners-tolerance", action="store", type="float", dest="plasma_prepare_corners_tolerance", default=10.,help="Maximum angle for corner (0-180 deg)")
self.default_tool = {
"name": "Default tool",
@@ -2979,24 +3734,29 @@ class Gcodetools(inkex.Effect):
return c
+################################################################################
+### Draw csp
+################################################################################
+
+ def draw_csp(self, csp, layer=None, group=None, fill='none', stroke='#178ade', width=0.354, style=None):
+ if layer!=None :
+ csp = self.transform_csp(csp,layer,reverse=True)
+ if group==None and layer==None:
+ group = self.document.getroot()
+ elif group==None and layer!=None :
+ group = layer
+ csp = self.apply_transforms(group,csp, reverse=True)
+ if style!=None :
+ return draw_csp(csp, group=group, style=style)
+ else :
+ return draw_csp(csp, group=group, fill=fill, stroke=stroke, width=width)
+
+
+
+
def draw_curve(self, curve, layer, group=None, style=styles["biarc_style"]):
-
- self.get_defs()
- # Add marker to defs if it doesnot exists
- if "DrawCurveMarker" not in self.defs :
- defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
- marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"DrawCurveMarker","orient":"auto","refX":"-8","refY":"-2.41063","style":"overflow:visible"})
- inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
- { "d":"m -6.55552,-2.41063 0,0 L -13.11104,0 c 1.0473,-1.42323 1.04126,-3.37047 0,-4.82126",
- "style": "fill:#000044; fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;" }
- )
- if "DrawCurveMarker_r" not in self.defs :
- defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
- marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"DrawCurveMarker_r","orient":"auto","refX":"8","refY":"-2.41063","style":"overflow:visible"})
- inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
- { "d":"m 6.55552,-2.41063 0,0 L 13.11104,0 c -1.0473,-1.42323 -1.04126,-3.37047 0,-4.82126",
- "style": "fill:#000044; fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;" }
- )
+ self.set_markers()
+
for i in [0,1]:
style['biarc%s_r'%i] = simplestyle.parseStyle(style['biarc%s'%i])
style['biarc%s_r'%i]["marker-start"] = "url(#DrawCurveMarker_r)"
@@ -3004,9 +3764,18 @@ class Gcodetools(inkex.Effect):
style['biarc%s_r'%i] = simplestyle.formatStyle(style['biarc%s_r'%i])
if group==None:
- group = inkex.etree.SubElement( self.layers[min(1,len(self.layers)-1)], inkex.addNS('g','svg'), {"gcodetools": "Preview group"} )
+ if "preview_groups" not in dir(self) :
+ self.preview_groups = { layer: inkex.etree.SubElement( self.layers[min(1,len(self.layers)-1)], inkex.addNS('g','svg'), {"gcodetools": "Preview group"} ) }
+ elif layer not in self.preview_groups :
+ self.preview_groups[layer] = inkex.etree.SubElement( self.layers[min(1,len(self.layers)-1)], inkex.addNS('g','svg'), {"gcodetools": "Preview group"} )
+ group = self.preview_groups[layer]
+
s, arcn = '', 0
+ transform = self.get_transforms(group)
+ if transform != [] :
+ transform = self.reverse_transform(transform)
+ transform = simpletransform.formatTransform(transform)
a,b,c = [0.,0.], [1.,0.], [0.,1.]
k = (b[0]-a[0])*(c[1]-a[1])-(c[0]-a[0])*(b[1]-a[1])
@@ -3019,13 +3788,13 @@ class Gcodetools(inkex.Effect):
if s!='':
if s[1] == 'line':
- inkex.etree.SubElement( group, inkex.addNS('path','svg'),
- {
- 'style': style['line'],
+ attr = { 'style': style['line'],
'd':'M %s,%s L %s,%s' % (s[0][0], s[0][1], si[0][0], si[0][1]),
"gcodetools": "Preview",
}
- )
+ if transform != [] :
+ attr["transform"] = transform
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attr )
elif s[1] == 'arc':
arcn += 1
sp = s[0]
@@ -3046,8 +3815,8 @@ class Gcodetools(inkex.Effect):
a_end = a_st*1
a_st = a_st+a
st = style['biarc%s_r'%(arcn%2)]
- inkex.etree.SubElement( group, inkex.addNS('path','svg'),
- {
+
+ attr = {
'style': st,
inkex.addNS('cx','sodipodi'): str(c[0]),
inkex.addNS('cy','sodipodi'): str(c[1]),
@@ -3057,8 +3826,12 @@ class Gcodetools(inkex.Effect):
inkex.addNS('end','sodipodi'): str(a_end),
inkex.addNS('open','sodipodi'): 'true',
inkex.addNS('type','sodipodi'): 'arc',
- "gcodetools": "Preview",
- })
+ "gcodetools": "Preview",
+ }
+
+ if transform != [] :
+ attr["transform"] = transform
+ inkex.etree.SubElement( group, inkex.addNS('path','svg'), attr)
s = si
@@ -3068,10 +3841,10 @@ class Gcodetools(inkex.Effect):
self.options.directory += "\\"
else :
self.options.directory += "/"
- print_("Checking direcrory: '%s'"%self.options.directory)
+ print_("Checking directory: '%s'"%self.options.directory)
if (os.path.isdir(self.options.directory)):
if (os.path.isfile(self.options.directory+'header')):
- f = open(self.options.directory+slash+'header', 'r')
+ f = open(self.options.directory+'header', 'r')
self.header = f.read()
f.close()
else:
@@ -3103,8 +3876,13 @@ class Gcodetools(inkex.Effect):
max_n = max(max_n,int(r.group(1)))
filename = name + "_" + ( "0"*(4-len(str(max_n+1))) + str(max_n+1) ) + ext
self.options.file = filename
-
- print_("Testing writing rights on '%s'"%(self.options.directory+self.options.file))
+
+ if self.options.directory[-1] not in ["/","\\"]:
+ if "\\" in self.options.directory :
+ self.options.directory += "\\"
+ else :
+ self.options.directory += "/"
+
try:
f = open(self.options.directory+self.options.file, "w")
f.close()
@@ -3120,12 +3898,13 @@ class Gcodetools(inkex.Effect):
### Generate Gcode
### Generates Gcode on given curve.
###
-### Crve defenitnion [start point, type = {'arc','line','move','end'}, arc center, arc angle, end point, [zstart, zend]]
+### Curve definition [start point, type = {'arc','line','move','end'}, arc center, arc angle, end point, [zstart, zend]]
###
################################################################################
def generate_gcode(self, curve, layer, depth):
Zauto_scale = self.Zauto_scale[layer]
tool = self.tools[layer][0]
+ g = ""
def c(c):
c = [c[i] if i<len(c) else None for i in range(6)]
@@ -3151,8 +3930,10 @@ class Gcodetools(inkex.Effect):
self.last_used_tool = None
print_("working on curve")
print_(curve)
- g = tool['tool change gcode'] +"\n" if tool != self.last_used_tool else "\n"
+ if tool != self.last_used_tool :
+ g += ( "(Change tool to %s)\n" % re.sub("\"'\(\)\\\\"," ",tool["name"]) ) + tool["tool change gcode"] + "\n"
+
lg, zs, f = 'G00', self.options.Zsafe, " F%f"%tool['feed']
current_a = 0
go_to_safe_distance = "G00" + c([None,None,zs]) + "\n"
@@ -3173,7 +3954,7 @@ class Gcodetools(inkex.Effect):
a = calculate_angle(a, current_a)
g+="G01 A%s\n" % (a*tool['4th axis scale']+tool['4th axis offset'])
current_a = a
- if lg=="G00": g += "G01" + c([None,None,s[5][0]+depth]) + penetration_feed +"\n"
+ if lg=="G00": g += "G01" + c([None,None,s[5][0]+depth]) + penetration_feed +"(Penetrate)\n"
g += "G01" +c(si[0]+[s[5][1]+depth]) + feed + "\n"
lg = 'G01'
elif s[1] == 'arc':
@@ -3189,8 +3970,8 @@ class Gcodetools(inkex.Effect):
axis4 = " A%s"%((current_a+s[3])*tool['4th axis scale']+tool['4th axis offset'])
current_a = current_a+s[3]
else : axis4 = ""
- if lg=="G00": g += "G01" + c([None,None,s[5][0]+depth]) + penetration_feed + "\n"
- if (r[0]**2 + r[1]**2)>self.options.min_arc_radius:
+ if lg=="G00": g += "G01" + c([None,None,s[5][0]+depth]) + penetration_feed + "(Penetrate)\n"
+ if (r[0]**2 + r[1]**2)>self.options.min_arc_radius**2:
r1, r2 = (P(s[0])-P(s[2])), (P(si[0])-P(s[2]))
if abs(r1.mag()-r2.mag()) < 0.001 :
g += ("G02" if s[3]<0 else "G03") + c(si[0]+[ s[5][1]+depth, (s[2][0]-s[0][0]),(s[2][1]-s[0][1]) ]) + feed + axis4 + "\n"
@@ -3222,14 +4003,29 @@ class Gcodetools(inkex.Effect):
print_(trans)
g=g.getparent()
return trans
+
+ def reverse_transform(self,transform):
+ trans = numpy.array(transform + [[0,0,1]])
+ if numpy.linalg.det(trans)!=0 :
+ trans = numpy.linalg.inv(trans).tolist()[:2]
+ return trans
+ else :
+ return transform
- def apply_transforms(self,g,csp):
+ def apply_transforms(self,g,csp, reverse=False):
trans = self.get_transforms(g)
if trans != []:
- simpletransform.applyTransformToPath(trans, csp)
+ if not reverse :
+ simpletransform.applyTransformToPath(trans, csp)
+ else :
+ simpletransform.applyTransformToPath(self.reverse_transform(trans), csp)
return csp
+
+
+ def transform_scalar(self,x,layer,reverse=False):
+ return self.transform([x,0],layer,reverse)[0] - self.transform([0,0],layer,reverse)[0]
def transform(self,source_point, layer, reverse=False):
if layer not in self.transform_matrix:
@@ -3240,6 +4036,7 @@ class Gcodetools(inkex.Effect):
self.error(_("Orientation points for '%s' layer have not been found! Please add orientation points using Orientation tab!") % layer.get(inkex.addNS('label','inkscape')),"no_orientation_points")
elif self.layers[i] in self.transform_matrix :
self.transform_matrix[layer] = self.transform_matrix[self.layers[i]]
+ self.Zcoordinates[layer] = self.Zcoordinates[self.layers[i]]
else :
orientation_layer = self.layers[i]
if len(self.orientation_points[orientation_layer])>1 :
@@ -3274,9 +4071,9 @@ class Gcodetools(inkex.Effect):
self.transform_matrix[layer] = [[m[j*3+i][0] for i in range(3)] for j in range(3)]
else :
- self.error(_("Orientation points are wrong! (if there are two orientation points they sould not be the same. If there are three orientation points they should not be in a straight line.)"),"wrong_orientation_points")
+ self.error(_("Orientation points are wrong! (if there are two orientation points they should not be the same. If there are three orientation points they should not be in a straight line.)"),"wrong_orientation_points")
else :
- self.error(_("Orientation points are wrong! (if there are two orientation points they sould not be the same. If there are three orientation points they should not be in a straight line.)"),"wrong_orientation_points")
+ self.error(_("Orientation points are wrong! (if there are two orientation points they should not be the same. If there are three orientation points they should not be in a straight line.)"),"wrong_orientation_points")
self.transform_matrix_reverse[layer] = numpy.linalg.inv(self.transform_matrix[layer]).tolist()
print_("\n Layer '%s' transformation matrixes:" % layer.get(inkex.addNS('label','inkscape')) )
@@ -3316,6 +4113,7 @@ class Gcodetools(inkex.Effect):
notes = "Note "
warnings = """
Warning tools_warning
+ orientation_warning
bad_orientation_points_in_some_layers
more_than_one_orientation_point_groups
more_than_one_tool
@@ -3325,6 +4123,7 @@ class Gcodetools(inkex.Effect):
selection_does_not_contain_paths_will_take_all
selection_is_empty_will_comupe_drawing
selection_contains_objects_that_are_not_paths
+ Continue
"""
errors = """
Error
@@ -3334,6 +4133,7 @@ class Gcodetools(inkex.Effect):
active_layer_already_has_tool
active_layer_already_has_orientation_points
"""
+ s = str(s)
if type_.lower() in re.split("[\s\n,\.]+", errors.lower()) :
print_(s)
inkex.errormsg(s+"\n")
@@ -3348,6 +4148,47 @@ class Gcodetools(inkex.Effect):
inkex.errormsg(s)
sys.exit()
+
+################################################################################
+### Set markers
+################################################################################
+ def set_markers(self) :
+ self.get_defs()
+ # Add marker to defs if it doesnot exists
+ if "CheckToolsAndOPMarker" not in self.defs :
+ defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
+ marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"CheckToolsAndOPMarker","orient":"auto","refX":"-4","refY":"-1.687441","style":"overflow:visible"})
+ inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
+
+ { "d":" m -4.588864,-1.687441 0.0,0.0 L -9.177728,0.0 c 0.73311,-0.996261 0.728882,-2.359329 0.0,-3.374882",
+ "style": "fill:#000044; fill-rule:evenodd;stroke:none;" }
+ )
+
+ if "DrawCurveMarker" not in self.defs :
+ defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
+ marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"DrawCurveMarker","orient":"auto","refX":"-4","refY":"-1.687441","style":"overflow:visible"})
+ inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
+ { "d":"m -4.588864,-1.687441 0.0,0.0 L -9.177728,0.0 c 0.73311,-0.996261 0.728882,-2.359329 0.0,-3.374882",
+ "style": "fill:#000044; fill-rule:evenodd;stroke:none;" }
+ )
+
+ if "DrawCurveMarker_r" not in self.defs :
+ defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
+ marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"DrawCurveMarker_r","orient":"auto","refX":"4","refY":"-1.687441","style":"overflow:visible"})
+ inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
+ { "d":"m 4.588864,-1.687441 0.0,0.0 L 9.177728,0.0 c -0.73311,-0.996261 -0.728882,-2.359329 0.0,-3.374882",
+ "style": "fill:#000044; fill-rule:evenodd;stroke:none;" }
+ )
+
+ if "InOutPathMarker" not in self.defs :
+ defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
+ marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"InOutPathMarker","orient":"auto","refX":"-4","refY":"-1.687441","style":"overflow:visible"})
+ inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
+ { "d":"m -4.588864,-1.687441 0.0,0.0 L -9.177728,0.0 c 0.73311,-0.996261 0.728882,-2.359329 0.0,-3.374882",
+ "style": "fill:#0072a7; fill-rule:evenodd;stroke:none;" }
+ )
+
+
################################################################################
### Get defs from svg
@@ -3374,12 +4215,15 @@ class Gcodetools(inkex.Effect):
self.paths = {}
self.tools = {}
self.orientation_points = {}
+ self.graffiti_reference_points = {}
self.layers = [self.document.getroot()]
self.Zcoordinates = {}
self.transform_matrix = {}
self.transform_matrix_reverse = {}
self.Zauto_scale = {}
-
+ self.in_out_reference_points = []
+ self.my3Dlayer = None
+
def recursive_search(g, layer, selected=False):
items = g.getchildren()
items.reverse()
@@ -3387,8 +4231,12 @@ class Gcodetools(inkex.Effect):
if selected:
self.selected[i.get("id")] = i
if i.tag == inkex.addNS("g",'svg') and i.get(inkex.addNS('groupmode','inkscape')) == 'layer':
- self.layers += [i]
- recursive_search(i,i)
+ if i.get(inkex.addNS('label','inkscape')) == '3D' :
+ self.my3Dlayer=i
+ else :
+ self.layers += [i]
+ recursive_search(i,i)
+
elif i.get('gcodetools') == "Gcodetools orientation group" :
points = self.get_orientation_points(i)
if points != None :
@@ -3396,17 +4244,37 @@ class Gcodetools(inkex.Effect):
print_("Found orientation points in '%s' layer: %s" % (layer.get(inkex.addNS('label','inkscape')), points))
else :
self.error(_("Warning! Found bad orientation points in '%s' layer. Resulting Gcode could be corrupt!") % layer.get(inkex.addNS('label','inkscape')), "bad_orientation_points_in_some_layers")
- elif i.get("gcodetools") == "Gcodetools tool defenition" :
+
+ #Need to recognise old files ver 1.6.04 and earlier
+ elif i.get("gcodetools") == "Gcodetools tool definition" or i.get("gcodetools") == "Gcodetools tool defenition" :
tool = self.get_tool(i)
self.tools[layer] = self.tools[layer] + [tool.copy()] if layer in self.tools else [tool.copy()]
print_("Found tool in '%s' layer: %s" % (layer.get(inkex.addNS('label','inkscape')), tool))
+
+ elif i.get("gcodetools") == "Gcodetools graffiti reference point" :
+ point = self.get_graffiti_reference_points(i)
+ if point != [] :
+ self.graffiti_reference_points[layer] = self.graffiti_reference_points[layer]+[point[:]] if layer in self.graffiti_reference_points else [point]
+ else :
+ self.error(_("Warning! Found bad graffiti reference point in '%s' layer. Resulting Gcode could be corrupt!") % layer.get(inkex.addNS('label','inkscape')), "bad_orientation_points_in_some_layers")
+
elif i.tag == inkex.addNS('path','svg'):
if "gcodetools" not in i.keys() :
self.paths[layer] = self.paths[layer] + [i] if layer in self.paths else [i]
if i.get("id") in self.selected :
self.selected_paths[layer] = self.selected_paths[layer] + [i] if layer in self.selected_paths else [i]
+
+ elif i.get("gcodetools") == "In-out reference point group" :
+ items_ = i.getchildren()
+ items_.reverse()
+ for j in items_ :
+ if j.get("gcodetools") == "In-out reference point" :
+ self.in_out_reference_points.append( self.apply_transforms(j,cubicsuperpath.parsePath(j.get("d")))[0][0][1] )
+
+
elif i.tag == inkex.addNS("g",'svg'):
recursive_search(i,layer, (i.get("id") in self.selected) )
+
elif i.get("id") in self.selected :
# xgettext:no-pango-format
self.error(_("This extension works with Paths and Dynamic Offsets and groups of them only! All other objects will be ignored!\nSolution 1: press Path->Object to path or Shift+Ctrl+C.\nSolution 2: Path->Dynamic offset or Ctrl+J.\nSolution 3: export all contours to PostScript level 2 (File->Save As->.ps) and File->Import this file."),"selection_contains_objects_that_are_not_paths")
@@ -3414,6 +4282,27 @@ class Gcodetools(inkex.Effect):
recursive_search(self.document.getroot(),self.document.getroot())
+ if len(self.layers) == 1 :
+ self.error(_("Document has no layers! Add at least one layer using layers panel (Ctrl+Shift+L)"),"Error")
+ root = self.document.getroot()
+
+ if root in self.selected_paths or root in self.paths :
+ self.error(_("Warning! There are some paths in the root of the document, but not in any layer! Using bottom-most layer for them."), "tools_warning" )
+
+ if root in self.selected_paths :
+ if self.layers[-1] in self.selected_paths :
+ self.selected_paths[self.layers[-1]] += self.selected_paths[root][:]
+ else :
+ self.selected_paths[self.layers[-1]] = self.selected_paths[root][:]
+ del self.selected_paths[root]
+
+ if root in self.paths :
+ if self.layers[-1] in self.paths :
+ self.paths[self.layers[-1]] += self.paths[root][:]
+ else :
+ self.paths[self.layers[-1]] = self.paths[root][:]
+ del self.paths[root]
+
def get_orientation_points(self,g):
items = g.getchildren()
@@ -3435,12 +4324,21 @@ class Gcodetools(inkex.Effect):
if node.get('gcodetools') == "Gcodetools orientation point arrow":
point[0] = self.apply_transforms(node,cubicsuperpath.parsePath(node.get("d")))[0][0][1]
if node.get('gcodetools') == "Gcodetools orientation point text":
- r = re.match(r'(?i)\s*\(\s*(-?\s*\d*(?:,|\.)*\d*)\s*;\s*(-?\s*\d*(?:,|\.)*\d*)\s*;\s*(-?\s*\d*(?:,|\.)*\d*)\s*\)\s*',node.text)
+ r = re.match(r'(?i)\s*\(\s*(-?\s*\d*(?:,|\.)*\d*)\s*;\s*(-?\s*\d*(?:,|\.)*\d*)\s*;\s*(-?\s*\d*(?:,|\.)*\d*)\s*\)\s*',get_text(node))
point[1] = [float(r.group(1)),float(r.group(2)),float(r.group(3))]
if point[0]!=[] and point[1]!=[]: points += [point]
if len(points)==len(p2)==2 or len(points)==len(p3)==3 : return points
else : return None
-
+
+ def get_graffiti_reference_points(self,g):
+ point = [[], '']
+ for node in g :
+ if node.get('gcodetools') == "Gcodetools graffiti reference point arrow":
+ point[0] = self.apply_transforms(node,cubicsuperpath.parsePath(node.get("d")))[0][0][1]
+ if node.get('gcodetools') == "Gcodetools graffiti reference point text":
+ point[1] = get_text(node)
+ if point[0]!=[] and point[1]!='' : return point
+ else : return []
def get_tool(self, g):
tool = self.default_tool.copy()
@@ -3453,12 +4351,12 @@ class Gcodetools(inkex.Effect):
key = None
value = None
for j in i:
- if j.get("gcodetools") == "Gcodetools tool defention field name":
- key = j.text
- if j.get("gcodetools") == "Gcodetools tool defention field value":
- for k in j :
- if k.tag == inkex.addNS('tspan','svg') and k.get("gcodetools") == "Gcodetools tool defention field value":
- if k.text!=None : value = value +"\n" + k.text if value != None else k.text
+ #need to recognise old tools from ver 1.6.04
+ if j.get("gcodetools") == "Gcodetools tool definition field name" or j.get("gcodetools") == "Gcodetools tool defention field name":
+ key = get_text(j)
+ if j.get("gcodetools") == "Gcodetools tool definition field value" or j.get("gcodetools") == "Gcodetools tool defention field value":
+ value = get_text(j)
+ if value == "(None)": value = ""
if value == None or key == None: continue
#print_("Found tool parameter '%s':'%s'" % (key,value))
if key in self.default_tool.keys() :
@@ -3495,7 +4393,7 @@ class Gcodetools(inkex.Effect):
###
################################################################################
def path_to_gcode(self) :
-
+ from functools import partial
def get_boundaries(points):
minx,miny,maxx,maxy=None,None,None,None
out=[[],[],[],[]]
@@ -3579,6 +4477,26 @@ class Gcodetools(inkex.Effect):
return minimal_way
+ def sort_lines(lines):
+ if len(lines) == 0 : return []
+ lines = [ [key]+lines[key] for key in range(len(lines))]
+ keys = [0]
+ end_point = lines[0][3:]
+ print_("!!!",lines,"\n",end_point)
+ del lines[0]
+ while len(lines)>0:
+ dist = [ [point_to_point_d2(end_point,lines[i][1:3]),i] for i in range(len(lines))]
+ i = min(dist)[1]
+ keys.append(lines[i][0])
+ end_point = lines[i][3:]
+ del lines[i]
+ return keys
+
+ def sort_curves(curves):
+ lines = []
+ for curve in curves:
+ lines += [curve[0][0][0] + curve[-1][-1][0]]
+ return sort_lines(lines)
def print_dxfpoints(points):
gcode=""
@@ -3586,7 +4504,19 @@ class Gcodetools(inkex.Effect):
gcode +="(drilling dxfpoint)\nG00 Z%f\nG00 X%f Y%f\nG01 Z%f F%f\nG04 P%f\nG00 Z%f\n" % (self.options.Zsafe,point[0],point[1],self.Zcoordinates[layer][1],self.tools[layer][0]["penetration feed"],0.2,self.options.Zsafe)
# print_(("got dxfpoints array=",points))
return gcode
-
+
+ def get_path_properties(node, recursive=True, tags={inkex.addNS('desc','svg'):"Description",inkex.addNS('title','svg'):"Title"} ) :
+ res = {}
+ done = False
+ root = self.document.getroot()
+ while not done and node != root :
+ for i in node.getchildren():
+ if i.tag in tags:
+ res[tags[i.tag]] = i.text
+ done = True
+ node = node.getparent()
+ return res
+
if self.selected_paths == {} and self.options.auto_select_paths:
paths=self.paths
self.error(_("No paths are selected! Trying to work on all available paths."),"warning")
@@ -3594,24 +4524,52 @@ class Gcodetools(inkex.Effect):
paths = self.selected_paths
self.check_dir()
gcode = ""
-
+
biarc_group = inkex.etree.SubElement( self.selected_paths.keys()[0] if len(self.selected_paths.keys())>0 else self.layers[0], inkex.addNS('g','svg') )
print_(("self.layers=",self.layers))
print_(("paths=",paths))
+ colors = {}
for layer in self.layers :
-# print_(("processing layer",layer," of layers:",self.layers))
if layer in paths :
-# print_(("layer ",layer, " is in paths:",paths))
print_(("layer",layer))
+ # transform simple path to get all var about orientation
+ self.transform_csp([ [ [[0,0],[0,0],[0,0]], [[0,0],[0,0],[0,0]] ] ], layer)
+
self.set_tool(layer)
- p = []
+ curves = []
dxfpoints = []
+
+ try :
+ depth_func = eval('lambda c,d,s: ' + self.options.path_to_gcode_depth_function.strip('"'))
+ except:
+ self.error("Bad depth function! Enter correct function at Path to Gcode tab!")
+
for path in paths[layer] :
if "d" not in path.keys() :
- self.error(_("Warning: One or more paths dont have 'd' parameter, try to Ungroup (Ctrl+Shift+G) and Object to Path (Ctrl+Shift+C)!"),"selection_contains_objects_that_are_not_paths")
+ self.error(_("Warning: One or more paths do not have 'd' parameter, try to Ungroup (Ctrl+Shift+G) and Object to Path (Ctrl+Shift+C)!"),"selection_contains_objects_that_are_not_paths")
continue
csp = cubicsuperpath.parsePath(path.get("d"))
csp = self.apply_transforms(path, csp)
+ id_ = path.get("id")
+
+ def set_comment(match, path):
+ if match.group(1) in path.keys() :
+ return path.get(match.group(1))
+ else:
+ return "None"
+ if self.options.comment_gcode != "" :
+ comment = re.sub("\[([A-Za-z_\-\:]+)\]", partial(set_comment, path=path), self.options.comment_gcode)
+ comment = comment.replace(":newline:","\n")
+ comment = gcode_comment_str(comment)
+ else:
+ comment = ""
+ if self.options.comment_gcode_from_properties :
+ tags = get_path_properties(path)
+ for tag in tags :
+ comment += gcode_comment_str("%s: %s"%(tag,tags[tag]))
+
+ style = simplestyle.parseStyle(path.get("style"))
+ colors[id_] = simplestyle.parseColor(style['stroke'] if "stroke" in style and style['stroke']!='none' else "#000")
if path.get("dxfpoint") == "1":
tmp_curve=self.transform_csp(csp, layer)
x=tmp_curve[0][0][0][0]
@@ -3619,16 +4577,80 @@ class Gcodetools(inkex.Effect):
print_("got dxfpoint (scaled) at (%f,%f)" % (x,y))
dxfpoints += [[x,y]]
else:
- p += csp
+
+ zd,zs = self.Zcoordinates[layer][1], self.Zcoordinates[layer][0]
+ c = 1. - float(sum(colors[id_]))/255/3
+ curves += [
+ [
+ [id_, depth_func(c,zd,zs), comment],
+ [ self.parse_curve([subpath], layer) for subpath in csp ]
+ ]
+ ]
+# for c in curves :
+# print_(c)
dxfpoints=sort_dxfpoints(dxfpoints)
gcode+=print_dxfpoints(dxfpoints)
- curve = self.parse_curve(p, layer)
- self.draw_curve(curve, layer, biarc_group)
- if self.tools[layer][0]["depth step"] == 0 : self.tools[layer][0]["depth step"] = 1
- for step in range( 0, int(math.ceil( abs( (self.Zcoordinates[layer][1]-self.Zcoordinates[layer][0])/self.tools[layer][0]["depth step"] )) ) ):
- Zpos = max( self.Zcoordinates[layer][1], self.Zcoordinates[layer][0] - abs(self.tools[layer][0]["depth step"]*(step+1)) )
- gcode += self.generate_gcode(curve, layer, Zpos)
-
+
+
+ for curve in curves :
+ for subcurve in curve[1] :
+ self.draw_curve(subcurve, layer)
+
+ if self.options.path_to_gcode_order == 'subpath by subpath':
+ curves_ = []
+ for curve in curves :
+ curves_ += [ [curve[0],[subcurve]] for subcurve in curve[1] ]
+ curves = curves_
+
+ self.options.path_to_gcode_order = 'path by path'
+
+ if self.options.path_to_gcode_order == 'path by path':
+ if self.options.path_to_gcode_sort_paths :
+ keys = sort_curves( [curve[1] for curve in curves] )
+ else :
+ keys = range(len(curves))
+ for key in keys:
+ d = curves[key][0][1]
+ for step in range( 0, int(math.ceil( abs((zs-d)/self.tools[layer][0]["depth step"] )) ) ):
+ z = max(d, zs - abs(self.tools[layer][0]["depth step"]*(step+1)))
+
+ gcode += gcode_comment_str("\nStart cutting path id: %s"%curves[key][0][0])
+ if curves[key][0][2] != "()" :
+ gcode += curves[key][0][2] # add comment
+
+ for curve in curves[key][1]:
+ gcode += self.generate_gcode(curve, layer, z)
+
+ gcode += gcode_comment_str("End cutting path id: %s\n\n"%curves[key][0][0])
+
+ else: # pass by pass
+ mind = min( [curve[0][1] for curve in curves] )
+ for step in range( 0, int(math.ceil( abs((zs-mind)/self.tools[layer][0]["depth step"] )) ) ):
+ z = zs - abs(self.tools[layer][0]["depth step"]*(step))
+ curves_ = []
+ for curve in curves:
+ if curve[0][1]<z :
+ curves_.append(curve)
+
+ z = zs - abs(self.tools[layer][0]["depth step"]*(step+1))
+ gcode += "\n(Pass at depth %s)\n"%z
+
+ if self.options.path_to_gcode_sort_paths :
+ keys = sort_curves( [curve[1] for curve in curves_] )
+ else :
+ keys = range(len(curves_))
+ for key in keys:
+
+ gcode += gcode_comment_str("Start cutting path id: %s"%curves[key][0][0])
+ if curves[key][0][2] != "()" :
+ gcode += curves[key][0][2] # add comment
+
+ for subcurve in curves_[key][1]:
+ gcode += self.generate_gcode(subcurve, layer, max(z,curves_[key][0][1]))
+
+ gcode += gcode_comment_str("End cutting path id: %s\n\n"%curves[key][0][0])
+
+
self.export_gcode(gcode)
################################################################################
@@ -3638,7 +4660,7 @@ class Gcodetools(inkex.Effect):
################################################################################
def dxfpoints(self):
if self.selected_paths == {}:
- self.error(_("Nothing is selected. Please select something to convert to drill point (dxfpoint) or clear point sign."),"warning")
+ self.error(_("Noting is selected. Please select something to convert to drill point (dxfpoint) or clear point sign."),"warning")
for layer in self.layers :
if layer in self.selected_paths :
for path in self.selected_paths[layer]:
@@ -3679,28 +4701,38 @@ class Gcodetools(inkex.Effect):
parent = path.getparent()
style = path.get("style") if "style" in path.keys() else ""
if "d" not in path.keys() :
- self.error(_("Warning: One or more paths dont have 'd' parameter, try to Ungroup (Ctrl+Shift+G) and Object to Path (Ctrl+Shift+C)!"),"selection_contains_objects_that_are_not_paths")
+ self.error(_("Warning: One or more paths do not have 'd' parameter, try to Ungroup (Ctrl+Shift+G) and Object to Path (Ctrl+Shift+C)!"),"selection_contains_objects_that_are_not_paths")
continue
csp = cubicsuperpath.parsePath(path.get("d"))
- csp = self.apply_transforms(path, csp)
- for subpath in csp :
+ remove = []
+ for i in range(len(csp)) :
+ subpath = [ [point[:] for point in points] for points in csp[i]]
+ subpath = self.apply_transforms(path,[subpath])[0]
bounds = csp_simple_bound([subpath])
if (bounds[2]-bounds[0])**2+(bounds[3]-bounds[1])**2 < self.options.area_find_artefacts_diameter**2:
if self.options.area_find_artefacts_action == "mark with an arrow" :
+ arrow = cubicsuperpath.parsePath( 'm %s,%s 2.9375,-6.343750000001 0.8125,1.90625 6.843748640396,-6.84374864039 0,0 0.6875,0.6875 -6.84375,6.84375 1.90625,0.812500000001 z' % (subpath[0][1][0],subpath[0][1][1]) )
+ arrow = self.apply_transforms(path,arrow,True)
inkex.etree.SubElement(parent, inkex.addNS('path','svg'),
{
- 'd': 'm %s,%s 2.9375,-6.343750000001 0.8125,1.90625 6.843748640396,-6.84374864039 0,0 0.6875,0.6875 -6.84375,6.84375 1.90625,0.812500000001 z' % (subpath[0][1][0],subpath[0][1][1]),
+ 'd': cubicsuperpath.formatPath(arrow),
'style': styles["area artefact arrow"],
'gcodetools': 'area artefact arrow',
})
- inkex.etree.SubElement(parent, inkex.addNS('path','svg'), {'d': cubicsuperpath.formatPath([subpath]), 'style': style, "gcodetools_parameter":"area artefact"})
elif self.options.area_find_artefacts_action == "mark with style" :
- inkex.etree.SubElement(parent, inkex.addNS('path','svg'), {'d': cubicsuperpath.formatPath([subpath]), 'style': styles["area artefact"]})
+ inkex.etree.SubElement(parent, inkex.addNS('path','svg'), {'d': cubicsuperpath.formatPath(csp[i]), 'style': styles["area artefact"]})
+ remove.append(i)
elif self.options.area_find_artefacts_action == "delete" :
- print_("Deleted artifact %s" % subpath )
- else :
- inkex.etree.SubElement(parent, inkex.addNS('path','svg'), {'d': cubicsuperpath.formatPath([subpath]), 'style': style})
- parent.remove(path)
+ remove.append(i)
+ print_("Deleted artefact %s" % subpath )
+ remove.reverse()
+ for i in remove :
+ del csp[i]
+ if len(csp) == 0 :
+ parent.remove(path)
+ else :
+ path.set("d", cubicsuperpath.formatPath(csp))
+
return
@@ -3781,9 +4813,12 @@ class Gcodetools(inkex.Effect):
r = self.options.area_inkscape_radius * scale
sign=1 if r>0 else -1
print_("Tool diameter = %s, r = %s" % (tool_d, r))
-
+
+ # avoiding infinite loops
+ if self.options.area_tool_overlap>0.9 : self.options.area_tool_overlap = .9
+
for i in range(self.options.max_area_curves):
- radius = - tool_d * (i+0.5) * sign
+ radius = - tool_d * (i*(1-self.options.area_tool_overlap)+0.5) * sign
if abs(radius)>abs(r):
radius = -r
@@ -3800,275 +4835,967 @@ class Gcodetools(inkex.Effect):
################################################################################
###
-### Engraving
+### Polyline to biarc
###
+### Converts Polyline to Biarc
################################################################################
- def engraving(self) :
+ def polyline_to_biarc(self):
+
+
+
+ def biarc(sm, depth=0):
+ def biarc_split(sp1,sp2, z1, z2, depth):
+ if depth<options.biarc_max_split_depth:
+ sp1,sp2,sp3 = csp_split(sp1,sp2)
+ l1, l2 = cspseglength(sp1,sp2), cspseglength(sp2,sp3)
+ if l1+l2 == 0 : zm = z1
+ else : zm = z1+(z2-z1)*l1/(l1+l2)
+ return biarc(sp1,sp2,z1,zm,depth+1)+biarc(sp2,sp3,zm,z2,depth+1)
+ else: return [ [sp1[1],'line', 0, 0, sp2[1], [z1,z2]] ]
+
+ P0, P4 = P(sp1[1]), P(sp2[1])
+ TS, TE, v = (P(sp1[2])-P0), -(P(sp2[0])-P4), P0 - P4
+ tsa, tea, va = TS.angle(), TE.angle(), v.angle()
+ if TE.mag()<straight_distance_tolerance and TS.mag()<straight_distance_tolerance:
+ # Both tangents are zerro - line straight
+ return [ [sp1[1],'line', 0, 0, sp2[1], [z1,z2]] ]
+ if TE.mag() < straight_distance_tolerance:
+ TE = -(TS+v).unit()
+ r = TS.mag()/v.mag()*2
+ elif TS.mag() < straight_distance_tolerance:
+ TS = -(TE+v).unit()
+ r = 1/( TE.mag()/v.mag()*2 )
+ else:
+ r=TS.mag()/TE.mag()
+ TS, TE = TS.unit(), TE.unit()
+ tang_are_parallel = ((tsa-tea)%math.pi<straight_tolerance or math.pi-(tsa-tea)%math.pi<straight_tolerance )
+ if ( tang_are_parallel and
+ ((v.mag()<straight_distance_tolerance or TE.mag()<straight_distance_tolerance or TS.mag()<straight_distance_tolerance) or
+ 1-abs(TS*v/(TS.mag()*v.mag()))<straight_tolerance) ):
+ # Both tangents are parallel and start and end are the same - line straight
+ # or one of tangents still smaller then tollerance
+
+ # Both tangents and v are parallel - line straight
+ return [ [sp1[1],'line', 0, 0, sp2[1], [z1,z2]] ]
+
+ c,b,a = v*v, 2*v*(r*TS+TE), 2*r*(TS*TE-1)
+ if v.mag()==0:
+ return biarc_split(sp1, sp2, z1, z2, depth)
+ asmall, bsmall, csmall = abs(a)<10**-10,abs(b)<10**-10,abs(c)<10**-10
+ if asmall and b!=0: beta = -c/b
+ elif csmall and a!=0: beta = -b/a
+ elif not asmall:
+ discr = b*b-4*a*c
+ if discr < 0: raise ValueError, (a,b,c,discr)
+ disq = discr**.5
+ beta1 = (-b - disq) / 2 / a
+ beta2 = (-b + disq) / 2 / a
+ if beta1*beta2 > 0 : raise ValueError, (a,b,c,disq,beta1,beta2)
+ beta = max(beta1, beta2)
+ elif asmall and bsmall:
+ return biarc_split(sp1, sp2, z1, z2, depth)
+ alpha = beta * r
+ ab = alpha + beta
+ P1 = P0 + alpha * TS
+ P3 = P4 - beta * TE
+ P2 = (beta / ab) * P1 + (alpha / ab) * P3
+
+
+ def calculate_arc_params(P0,P1,P2):
+ D = (P0+P2)/2
+ if (D-P1).mag()==0: return None, None
+ R = D - ( (D-P0).mag()**2/(D-P1).mag() )*(P1-D).unit()
+ p0a, p1a, p2a = (P0-R).angle()%(2*math.pi), (P1-R).angle()%(2*math.pi), (P2-R).angle()%(2*math.pi)
+ alpha = (p2a - p0a) % (2*math.pi)
+ if (p0a<p2a and (p1a<p0a or p2a<p1a)) or (p2a<p1a<p0a) :
+ alpha = -2*math.pi+alpha
+ if abs(R.x)>1000000 or abs(R.y)>1000000 or (R-P0).mag<options.min_arc_radius**2 :
+ return None, None
+ else :
+ return R, alpha
+ R1,a1 = calculate_arc_params(P0,P1,P2)
+ R2,a2 = calculate_arc_params(P2,P3,P4)
+ if R1==None or R2==None or (R1-P0).mag()<straight_tolerance or (R2-P2).mag()<straight_tolerance : return [ [sp1[1],'line', 0, 0, sp2[1], [z1,z2]] ]
+
+ d = csp_to_arc_distance(sp1,sp2, [P0,P2,R1,a1],[P2,P4,R2,a2])
+ if d > options.biarc_tolerance and depth<options.biarc_max_split_depth : return biarc_split(sp1, sp2, z1, z2, depth)
+ else:
+ if R2.mag()*a2 == 0 : zm = z2
+ else : zm = z1 + (z2-z1)*(abs(R1.mag()*a1))/(abs(R2.mag()*a2)+abs(R1.mag()*a1))
+
+ l = (P0-P2).l2()
+ if l < EMC_TOLERANCE_EQUAL**2 or l<EMC_TOLERANCE_EQUAL**2 * R1.l2() /100 :
+ # arc should be straight otherwise it could be threated as full circle
+ arc1 = [ sp1[1], 'line', 0, 0, [P2.x,P2.y], [z1,zm] ]
+ else :
+ arc1 = [ sp1[1], 'arc', [R1.x,R1.y], a1, [P2.x,P2.y], [z1,zm] ]
+
+ l = (P4-P2).l2()
+ if l < EMC_TOLERANCE_EQUAL**2 or l<EMC_TOLERANCE_EQUAL**2 * R2.l2() /100 :
+ # arc should be straight otherwise it could be threated as full circle
+ arc2 = [ [P2.x,P2.y], 'line', 0, 0, [P4.x,P4.y], [zm,z2] ]
+ else :
+ arc2 = [ [P2.x,P2.y], 'arc', [R2.x,R2.y], a2, [P4.x,P4.y], [zm,z2] ]
+
+ return [ arc1, arc2 ]
+
+
+
+
+
+ for layer in self.layers :
+ if layer in self.selected_paths :
+ for path in self.selected_paths[layer]:
+ d = path.get('d')
+ if d==None:
+ print_("omitting non-path")
+ self.error(_("Warning: omitting non-path"),"selection_contains_objects_that_are_not_paths")
+ continue
+ csp = cubicsuperpath.parsePath(d)
+ csp = self.apply_transforms(path, csp)
+ csp = self.transform_csp(csp, layer)
+
+ # lets pretend that csp is a polyline
+ poly = [ [point[1] for point in subpath] for subpath in csp ]
+
+ self.draw_csp([ [ [point,point,point] for point in subpoly] for subpoly in poly ],layer)
+
+ # lets create biarcs
+ for subpoly in poly :
+ # lets split polyline into different smooth parths.
+
+ if len(subpoly)>2 :
+ smooth = [ [subpoly[0],subpoly[1]] ]
+ for p1,p2,p3 in zip(subpoly,subpoly[1:],subpoly[2:]) :
+ # normalize p1p2 and p2p3 to get angle
+ s1,s2 = normalize( p1[0]-p2[0], p1[1]-p2[1]), normalize( p3[0]-p2[0], p3[1]-p2[1])
+ if cross(s1,s2) > corner_tolerance :
+ #it's an angle
+ smooth += [ [p2,p3] ]
+ else:
+ smooth[-1].append(p3)
+ for sm in smooth :
+ smooth_polyline_to_biarc(sm)
+
+################################################################################
+###
+### Area fill
+###
+### Fills area with lines
+################################################################################
+
+
+ def area_fill(self):
+ # convert degrees into rad
+ self.options.area_fill_angle = self.options.area_fill_angle * math.pi / 180
if len(self.selected_paths)<=0:
self.error(_("This extension requires at least one selected path."),"warning")
return
- if not self.check_dir() : return
- gcode = ''
+ for layer in self.layers :
+ if layer in self.selected_paths :
+ self.set_tool(layer)
+ if self.tools[layer][0]['diameter']<=0 :
+ self.error(_("Tool diameter must be > 0 but tool's diameter on '%s' layer is not!") % layer.get(inkex.addNS('label','inkscape')),"area_tools_diameter_error")
+ tool = self.tools[layer][0]
+ for path in self.selected_paths[layer]:
+ lines = []
+ print_(("doing path", path.get("style"), path.get("d")))
+ area_group = inkex.etree.SubElement( path.getparent(), inkex.addNS('g','svg') )
+ d = path.get('d')
+ if d==None:
+ print_("omitting non-path")
+ self.error(_("Warning: omitting non-path"),"selection_contains_objects_that_are_not_paths")
+ continue
+ csp = cubicsuperpath.parsePath(d)
+ csp = self.apply_transforms(path, csp)
+ csp = csp_close_all_subpaths(csp)
+ csp = self.transform_csp(csp, layer)
+ #maxx = max([x,y,i,j,root],maxx)
+
+ # rotate the path to get bounds in defined direction.
+ a = - self.options.area_fill_angle
+ rotated_path = [ [ [ [point[0]*math.cos(a) - point[1]*math.sin(a), point[0]*math.sin(a)+point[1]*math.cos(a)] for point in sp] for sp in subpath] for subpath in csp ]
+ bounds = csp_true_bounds(rotated_path)
+
+ # Draw the lines
+ # Get path's bounds
+ b = [0.0, 0.0, 0.0, 0.0] # [minx,miny,maxx,maxy]
+ for k in range(4):
+ i, j, t = bounds[k][2], bounds[k][3], bounds[k][4]
+ b[k] = csp_at_t(rotated_path[i][j-1],rotated_path[i][j],t)[k%2]
- def find_cutter_center((x1,y1),(nx1,ny1), sp1,sp2, tool, t3 = .5):
- ####################################################################
- ### To find center of cutter a system of non linear equations
- ### will be solved using Newton's method
- ####################################################################
- bez = (sp1[1][:],sp1[2][:],sp2[0][:],sp2[1][:])
- ax,ay,bx,by,cx,cy,dx,dy=bezmisc.bezierparameterize(bez)
- fx=ax*(t3*t3*t3)+bx*(t3*t3)+cx*t3+dx
- fy=ay*(t3*t3*t3)+by*(t3*t3)+cy*t3+dy
-
- nx2,ny2 = csp_normalized_normal(sp1,sp2,t3)
- intersection, t1, t2 = straight_segments_intersection([[x1,y1],[x1+nx1,y1+ny1]],[[fx,fy],[fx+nx2,fy+ny2]], False)
- if not intersection or intersection == "Overlap" :
- if nx1!=0 :
- t1 = t2 = (x1-fx)/nx1
- else :
- t1 = t2 = (y1-fy)/ny1
+
+ # Zig-zag
+ r = tool['diameter']*(1-self.options.area_tool_overlap)
+ if r<=0 :
+ self.error('Tools diameter must be greater than 0!', 'error')
+ return
+
+ lines += [ [] ]
+
+ if self.options.area_fill_method == 'zig-zag' :
+ i = b[0] - self.options.area_fill_shift*r
+ top = True
+ last_one = True
+ while (i<b[2] or last_one) :
+ if i>=b[2] : last_one = False
+ if lines[-1] == [] :
+ lines[-1] += [ [i,b[3]] ]
+
+ if top :
+ lines[-1] += [ [i,b[1]],[i+r,b[1]] ]
+
+ else :
+ lines[-1] += [ [i,b[3]], [i+r,b[3]] ]
+
+ top = not top
+ i += r
+ else :
+
+ w, h = b[2]-b[0] + self.options.area_fill_shift*r , b[3]-b[1] + self.options.area_fill_shift*r
+ x,y = b[0] - self.options.area_fill_shift*r, b[1] - self.options.area_fill_shift*r
+ lines[-1] += [ [x,y] ]
+ stage = 0
+ start = True
+ while w>0 and h>0 :
+ stage = (stage+1)%4
+ if stage == 0 :
+ y -= h
+ h -= r
+ elif stage == 1:
+ x += w
+ if not start:
+ w -= r
+ start = False
+ elif stage == 2 :
+ y += h
+ h -= r
+ elif stage == 3:
+ x -= w
+ w -=r
+
+ lines[-1] += [ [x,y] ]
+
+ stage = (stage+1)%4
+ if w <= 0 and h>0 :
+ y = y-h if stage == 0 else y+h
+ if h <= 0 and w>0 :
+ x = x-w if stage == 3 else x+w
+ lines[-1] += [ [x,y] ]
+ # Rotate created paths back
+ a = self.options.area_fill_angle
+ lines = [ [ [point[0]*math.cos(a) - point[1]*math.sin(a), point[0]*math.sin(a)+point[1]*math.cos(a)] for point in subpath] for subpath in lines ]
+
+ # get the intersection points
+
+ splitted_line = [ [lines[0][0]] ]
+ intersections = {}
+ for l1,l2, in zip(lines[0],lines[0][1:]):
+ ints = []
+
+ if l1[0]==l2[0] and l1[1]==l2[1] : continue
+ for i in range(len(csp)) :
+ for j in range(1,len(csp[i])) :
+ sp1,sp2 = csp[i][j-1], csp[i][j]
+ roots = csp_line_intersection(l1,l2,sp1,sp2)
+ for t in roots :
+ p = tuple(csp_at_t(sp1,sp2,t))
+ if l1[0]==l2[0] :
+ t1 = (p[1]-l1[1])/(l2[1]-l1[1])
+ else :
+ t1 = (p[0]-l1[0])/(l2[0]-l1[0])
+ if 0<=t1<=1 :
+ ints += [[t1, p[0],p[1], i,j,t]]
+ if p in intersections :
+ intersections[p] += [ [i,j,t] ]
+ else :
+ intersections[p] = [ [i,j,t] ]
+ #p = self.transform(p,layer,True)
+ #draw_pointer(p)
+ ints.sort()
+ for i in ints:
+ splitted_line[-1] +=[ [ i[1], i[2]] ]
+ splitted_line += [ [ [ i[1], i[2]] ] ]
+ splitted_line[-1] += [ l2 ]
+ i = 0
+ print_(splitted_line)
+ while i < len(splitted_line) :
+ # check if the middle point of the first lines segment is inside the path.
+ # and remove the subline if not.
+ l1,l2 = splitted_line[i][0],splitted_line[i][1]
+ p = [(l1[0]+l2[0])/2, (l1[1]+l2[1])/2]
+ if not point_inside_csp(p, csp):
+ #i +=1
+ del splitted_line[i]
+ else :
+ i += 1
+
+
+
+ # if we've used spiral method we'll try to save the order of cutting
+ do_not_change_order = self.options.area_fill_method == 'spiral'
+ # now let's try connect splitted lines
+ #while len(splitted_line)>0 :
+ #TODO
+
+ # and apply back transrormations to draw them
+ csp_line = csp_from_polyline(splitted_line)
+ csp_line = self.transform_csp(csp_line, layer, True)
+
+ self.draw_csp(csp_line, group = area_group)
+# draw_csp(lines)
- t = [ t1, t2, t3 ]
- i = 0
- F = [0.,0.,0.]
- F1 = [[0.,0.,0.],[0.,0.,0.],[0.,0.,0.]]
- while i==0 or abs(F[0])+abs(F[1])+math.sqrt(abs(F[2])) >engraving_tolerance and i<10:
- t1,t2,t3 = t[0],t[1],t[2]
- fx=ax*(t3*t3*t3)+bx*(t3*t3)+cx*t3+dx
- fy=ay*(t3*t3*t3)+by*(t3*t3)+cy*t3+dy
- f1x=3*ax*(t3*t3)+2*bx*t3+cx
- f1y=3*ay*(t3*t3)+2*by*t3+cy
- i+=1
-
- tx = fx-x1-nx1*t1
- ty = fy-y1-ny1*t1
-
- F[0] = x1+nx1*t1-fx+t2*f1y
- F[1] = y1+ny1*t1-fy-t2*f1x
- F[2] = t1*t1 - tx*tx -ty*ty
-
- F1[0][0] = nx1
- F1[0][1] = f1y
- F1[0][2] = -f1x+t2*(6*ay*t3+2*by)
-
- F1[1][0] = ny1
- F1[1][1] = -f1x
- F1[1][2] = -f1y-t2*(6*ax*t3+2*bx)
-
- F1[2][0] = 2*t1+2*nx1*tx +2*ny1*ty
- F1[2][1] = 0
- F1[2][2] = -2*f1x*tx -2*f1y*ty
- F1 = inv_3x3(F1)
-
- if ( isnan(F[0]) or isnan(F[1]) or isnan(F[2]) or
- isinf(F[0]) or isinf(F[1]) or isinf(F[2]) ):
- return t+[1e100,i]
-
- if F1!= None :
- t[0] -= F1[0][0]*F[0] + F1[0][1]*F[1] + F1[0][2]*F[2]
- t[1] -= F1[1][0]*F[0] + F1[1][1]*F[1] + F1[1][2]*F[2]
- t[2] -= F1[2][0]*F[0] + F1[2][1]*F[1] + F1[2][2]*F[2]
- else: break
-
- return t+[abs(F[0])+abs(F[1])+math.sqrt(abs(F[2])),i]
+
+
+
+
+################################################################################
+###
+### Engraving
+###
+#LT Notes to self: See wiki.inkscape.org/wiki/index.php/PythonEffectTutorial
+# To create anything in the Inkscape document, look at the XML editor for
+# details of how such an element looks in XML, then follow this model.
+#layer number n appears in XML as <svg:g id="layern" inkscape:label="layername">
+#
+#to create it, use
+#Mylayer=inkex.etree.SubElement(self.document.getroot(), 'g') #Create a generic element
+#Mylayer.set(inkex.addNS('label', 'inkscape'), "layername") #Gives it a name
+#Mylayer.set(inkex.addNS('groupmode', 'inkscape'), 'layer') #Tells Inkscape it's a layer
+#
+#group appears in XML as <svg:g id="gnnnnn"> where nnnnn is a number
+#
+#to create it, use
+#Mygroup=inkex.etree.SubElement(parent, inkex.addNS('g','svg'), {"gcodetools":"My group label"})
+# where parent may be the layer or a parent group. To get the parent group, you can use
+#parent = self.selected_paths[layer][0].getparent()
+################################################################################
+ def engraving(self) :
+ #global x1,y1,rx,ry
+ global cspm, wl
+ global nlLT, i, j
+ global gcode_3Dleft ,gcode_3Dright
+ global max_dist #minimum of tool radius and user's requested maximum distance
+ global eye_dist
+ eye_dist = 100 #3D constant. Try varying it for your eyes
+
+
+ def bisect((nx1,ny1),(nx2,ny2)) :
+ """LT Find angle bisecting the normals n1 and n2
+
+ Parameters: Normalised normals
+ Returns: nx - Normal of bisector, normalised to 1/cos(a)
+ ny -
+ sinBis2 - sin(angle turned/2): positive if turning in
+ Note that bisect(n1,n2) and bisect(n2,n1) give opposite sinBis2 results
+ If sinturn is less than the user's requested angle tolerance, I return 0
+ """
+ #We can get absolute value of cos(bisector vector)
+ #Note: Need to use max in case of rounding errors
+ cosBis = math.sqrt(max(0,(1.0+nx1*nx2-ny1*ny2)/2.0))
+ #We can get correct sign of the sin, assuming cos is positive
+ if (abs(ny1-ny2)< engraving_tolerance) or (abs(cosBis) < engraving_tolerance) :
+ if (abs(nx1-nx2)< engraving_tolerance): return(nx1,ny1,0.0)
+ sinBis = math.copysign(1,ny1)
+ else :
+ sinBis = cosBis*(nx2-nx1)/(ny1-ny2)
+ #We can correct signs by noting that the dot product
+ # of bisector and either normal must be >0
+ costurn=cosBis*nx1+sinBis*ny1
+ if costurn == 0 : return (ny1*100,-nx1*100,1) #Path doubles back on itself
+ sinturn=sinBis*nx1-cosBis*ny1
+ if costurn<0 : sinturn=-sinturn
+ if 0 < sinturn*114.6 < (180-self.options.engraving_sharp_angle_tollerance) :
+ sinturn=0 #set to zero if less than the user wants to see.
+ return (cosBis/costurn,sinBis/costurn, sinturn)
+ #end bisect
+
+ def get_radius_to_line((x1,y1),(nx1,ny1), (nx2,ny2),(x2,y2),(nx23,ny23),(x3,y3),(nx3,ny3)):
+ """LT find biggest circle we can engrave here, if constrained by line 2-3
+
+ Parameters:
+ x1,y1,nx1,ny1 coordinates and normal of the line we're currently engraving
+ nx2,ny2 angle bisector at point 2
+ x2,y2 coordinates of first point of line 2-3
+ nx23,ny23 normal to the line 2-3
+ x3,y3 coordinates of the other end
+ nx3,ny3 angle bisector at point 3
+ Returns:
+ radius or self.options.engraving_max_dist if line doesn't limit radius
+ This function can be used in three ways:
+ - With nx1=ny1=0 it finds circle centred at x1,y1
+ - with nx1,ny1 normalised, it finds circle tangential at x1,y1
+ - with nx1,ny1 scaled by 1/cos(a) it finds circle centred on an angle bisector
+ where a is the angle between the bisector and the previous/next normals
+
+ If the centre of the circle tangential to the line 2-3 is outside the
+ angle bisectors at its ends, ignore this line.
+
+ # Note that it handles corners in the conventional manner of letter cutting
+ # by mitering, not rounding.
+ # Algorithm uses dot products of normals to find radius
+ # and hence coordinates of centre
+ """
+
+ global max_dist
+
+ #Start by converting coordinates to be relative to x1,y1
+ x2,y2= x2-x1, y2-y1
+ x3,y3= x3-x1, y3-y1
+
+ #The logic uses vector arithmetic.
+ #The dot product of two vectors gives the product of their lengths
+ #multiplied by the cos of the angle between them.
+ # So, the perpendicular distance from x1y1 to the line 2-3
+ # is equal to the dot product of its normal and x2y2 or x3y3
+ #It is also equal to the projection of x1y1-xcyc on the line's normal
+ # plus the radius. But, as the normal faces inside the path we must negate it.
+
+ #Make sure the line in question is facing x1,y1 and vice versa
+ dist=-x2*nx23-y2*ny23
+ if dist<0 : return max_dist
+ denom=1.-nx23*nx1-ny23*ny1
+ if denom < engraving_tolerance : return max_dist
+
+ #radius and centre are:
+ r=dist/denom
+ cx=r*nx1
+ cy=r*ny1
+ #if c is not between the angle bisectors at the ends of the line, ignore
+ #Use vector cross products. Not sure if I need the .0001 safety margins:
+ if (x2-cx)*ny2 > (y2-cy)*nx2 +0.0001 :
+ return max_dist
+ if (x3-cx)*ny3 < (y3-cy)*nx3 -0.0001 :
+ return max_dist
+ return min(r, max_dist)
+ #end of get_radius_to_line
+
+ def get_radius_to_point((x1,y1),(nx,ny), (x2,y2)):
+ """LT find biggest circle we can engrave here, constrained by point x2,y2
+
+ This function can be used in three ways:
+ - With nx=ny=0 it finds circle centred at x1,y1
+ - with nx,ny normalised, it finds circle tangential at x1,y1
+ - with nx,ny scaled by 1/cos(a) it finds circle centred on an angle bisector
+ where a is the angle between the bisector and the previous/next normals
+
+ Note that I wrote this to replace find_cutter_centre. It is far less
+ sophisticated but, I hope, far faster.
+ It turns out that finding a circle touching a point is harder than a circle
+ touching a line.
+ """
+
+ global max_dist
+
+ #Start by converting coordinates to be relative to x1,y1
+ x2,y2= x2-x1, y2-y1
+ denom=nx**2+ny**2-1
+ if denom<=engraving_tolerance : #Not a corner bisector
+ if denom==-1 : #Find circle centre x1,y1
+ return math.sqrt(x2**2+y2**2)
+ #if x2,y2 not in front of the normal...
+ if x2*nx+y2*ny <=0 : return max_dist
+ #print_("Straight",x1,y1,nx,ny,x2,y2)
+ return (x2**2+y2**2)/(2*(x2*nx+y2*ny) )
+ #It is a corner bisector, so..
+ discriminator = (x2*nx+y2*ny)**2 - denom*(x2**2+y2**2)
+ if discriminator < 0 :
+ return max_dist #this part irrelevant
+ r=(x2*nx+y2*ny -math.sqrt(discriminator))/denom
+ #print_("Corner",x1,y1,nx,ny,x1+x2,y1+y2,discriminator,r)
+ return min(r, max_dist)
+ #end of get_radius_to_point
+
+ def bez_divide(a,b,c,d):
+ """LT recursively divide a Bezier.
+
+ Divides until difference between each
+ part and a straight line is less than some limit
+ Note that, as simple as this code is, it is mathematically correct.
+ Parameters:
+ a,b,c and d are each a list of x,y real values
+ Bezier end points a and d, control points b and c
+ Returns:
+ a list of Beziers.
+ Each Bezier is a list with four members,
+ each a list holding a coordinate pair
+ Note that the final point of one member is the same as
+ the first point of the next, and the control points
+ there are smooth and symmetrical. I use this fact later.
+ """
+ bx=b[0]-a[0]
+ by=b[1]-a[1]
+ cx=c[0]-a[0]
+ cy=c[1]-a[1]
+ dx=d[0]-a[0]
+ dy=d[1]-a[1]
+ limit=8*math.hypot(dx,dy)/self.options.engraving_newton_iterations
+ #LT This is the only limit we get from the user currently
+ if abs(dx*by-bx*dy)<limit and abs(dx*cy-cx*dy)<limit :
+ return [[a,b,c,d]]
+ abx=(a[0]+b[0])/2.0
+ aby=(a[1]+b[1])/2.0
+ bcx=(b[0]+c[0])/2.0
+ bcy=(b[1]+c[1])/2.0
+ cdx=(c[0]+d[0])/2.0
+ cdy=(c[1]+d[1])/2.0
+ abcx=(abx+bcx)/2.0
+ abcy=(aby+bcy)/2.0
+ bcdx=(bcx+cdx)/2.0
+ bcdy=(bcy+cdy)/2.0
+ m=[(abcx+bcdx)/2.0,(abcy+bcdy)/2.0]
+ return bez_divide(a,[abx,aby],[abcx,abcy],m) + bez_divide(m,[bcdx,bcdy],[cdx,cdy],d)
+ #end of bez_divide
+
+ def get_biggest((x1,y1),(nx,ny)):
+ """LT Find biggest circle we can draw inside path at point x1,y1 normal nx,ny
+
+ Parameters:
+ point - either on a line or at a reflex corner
+ normal - normalised to 1 if on a line, to 1/cos(a) at a corner
+ Returns:
+ tuple (j,i,r)
+ ..where j and i are indices of limiting segment, r is radius
+ """
+ global max_dist, nlLT, i, j
+ n1 = nlLT[j][i-1] #current node
+ jjmin = -1
+ iimin = -1
+ r = max_dist
+ # set limits within which to look for lines
+ xmin, xmax = x1+r*nx-r, x1+r*nx+r
+ ymin, ymax = y1+r*ny-r, y1+r*ny+r
+ for jj in xrange(0,len(nlLT)) : #for every subpath of this object
+ for ii in xrange(0,len(nlLT[jj])) : #for every point and line
+ if nlLT[jj][ii-1][2] : #if a point
+ if jj==j : #except this one
+ if abs(ii-i)<3 or abs(ii-i)>len(nlLT[j])-3 : continue
+ t1=get_radius_to_point((x1,y1),(nx,ny),nlLT[jj][ii-1][0] )
+ #print_("Try pt i,ii,t1,x1,y1",i,ii,t1,x1,y1)
+ else: #doing a line
+ if jj==j : #except this one
+ if abs(ii-i)<2 or abs(ii-i)==len(nlLT[j])-1 : continue
+ if abs(ii-i)==2 and nlLT[j][(ii+i)/2-1][3]<=0 : continue
+ if (abs(ii-i)==len(nlLT[j])-2) and nlLT[j][-1][3]<=0 : continue
+ nx2,ny2 = nlLT[jj][ii-2][1]
+ x2,y2 = nlLT[jj][ii-1][0]
+ nx23,ny23 = nlLT[jj][ii-1][1]
+ x3,y3 = nlLT[jj][ii][0]
+ nx3,ny3 = nlLT[jj][ii][1]
+ if nlLT[jj][ii-2][3]>0 : #acute, so use normal, not bisector
+ nx2=nx23
+ ny2=ny23
+ if nlLT[jj][ii][3]>0 : #acute, so use normal, not bisector
+ nx3=nx23
+ ny3=ny23
+ x23min,x23max=min(x2,x3),max(x2,x3)
+ y23min,y23max=min(y2,y3),max(y2,y3)
+ #see if line in range
+ if n1[2]==False and (x23max<xmin or x23min>xmax or y23max<ymin or y23min>ymax) : continue
+ t1=get_radius_to_line((x1,y1),(nx,ny), (nx2,ny2),(x2,y2),(nx23,ny23), (x3,y3),(nx3,ny3))
+ #print_("Try line i,ii,t1,x1,y1",i,ii,t1,x1,y1)
+ if 0<=t1<r :
+ r = t1
+ iimin = ii
+ jjmin = jj
+ xmin, xmax = x1+r*nx-r, x1+r*nx+r
+ ymin, ymax = y1+r*ny-r, y1+r*ny+r
+ #next ii
+ #next jj
+ return (jjmin,iimin,r)
+ #end of get_biggest
+
+ def line_divide((x0,y0),j0,i0,(x1,y1),j1,i1,(nx,ny),length):
+ """LT recursively divide a line as much as necessary
+
+ NOTE: This function is not currently used
+ By noting which other path segment is touched by the circles at each end,
+ we can see if anything is to be gained by a further subdivision, since
+ if they touch the same bit of path we can move linearly between them.
+ Also, we can handle points correctly.
+ Parameters:
+ end points and indices of limiting path, normal, length
+ Returns:
+ list of toolpath points
+ each a list of 3 reals: x, y coordinates, radius
+
+ """
+ global nlLT, i, j, lmin
+ x2=(x0+x1)/2
+ y2=(y0+y1)/2
+ j2,i2,r2=get_biggest( (x2,y2), (nx,ny))
+ if length<lmin : return [ [x2, y2, r2] ]
+ if j2==j0 and i2==i0 : #Same as left end. Don't subdivide this part any more
+ return [ [x2, y2, r2], line_divide((x2,y2),j2,i2,(x1,y1),j1,i1,(nx,ny),length/2)]
+ if j2==j1 and i2==i1 : #Same as right end. Don't subdivide this part any more
+ return [ line_divide((x0,y0),j0,i0,(x2,y2),j2,i2,(nx,ny),length/2), [x2, y2, r2] ]
+ return [ line_divide((x0,y0),j0,i0,(x2,y2),j2,i2,(nx,ny),length/2), line_divide((x2,y2),j2,i2,(x1,y1),j1,i1,(nx,ny),length/2)]
+ #end of line_divide()
+
+ def save_point((x,y),w,i,j,ii,jj):
+ """LT Save this point and delete previous one if linear
+
+ The point is, we generate tons of points but many may be in a straight 3D line.
+ There is no benefit in saving the imtermediate points.
+ """
+ global wl, cspm
+ x=round(x,4) #round to 4 decimals
+ y=round(y,4) #round to 4 decimals
+ w=round(w,4) #round to 4 decimals
+ if len(cspm)>1 :
+ xy1a,xy1,xy1b,i1,j1,ii1,jj1=cspm[-1]
+ w1=wl[-1]
+ if i==i1 and j==j1 and ii==ii1 and jj==jj1 : #one match
+ xy1a,xy2,xy1b,i1,j1,ii1,jj1=cspm[-2]
+ w2=wl[-2]
+ if i==i1 and j==j1 and ii==ii1 and jj==jj1 : #two matches. Now test linearity
+ length1=math.hypot(xy1[0]-x,xy1[1]-y)
+ length2=math.hypot(xy2[0]-x,xy2[1]-y)
+ length12=math.hypot(xy2[0]-xy1[0],xy2[1]-xy1[1])
+ #get the xy distance of point 1 from the line 0-2
+ if length2>length1 and length2>length12 : #point 1 between them
+ xydist=abs( (xy2[0]-x)*(xy1[1]-y)-(xy1[0]-x)*(xy2[1]-y) )/length2
+ if xydist<engraving_tolerance : #so far so good
+ wdist=w2+(w-w2)*length1/length2 -w1
+ if abs(wdist)<engraving_tolerance :
+ #print_("pop",j,i,xy1)
+ cspm.pop()
+ wl.pop()
+ cspm+=[ [ [x,y],[x,y],[x,y],i,j,ii,jj ] ]
+ wl+=[w]
+ #end of save_point
+
+ def draw_point((x0,y0),(x,y),w,t):
+ """LT Draw this point as a circle with a 1px dot in the middle (x,y)
+ and a 3D line from (x0,y0) down to x,y. 3D line thickness should be t/2
+
+ Note that points that are subsequently erased as being unneeded do get
+ displayed, but this helps the user see the total area covered.
+ """
+ global gcode_3Dleft ,gcode_3Dright
+ if self.options.engraving_draw_calculation_paths :
+ inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
+ {"gcodetools": "Engraving calculation toolpath", 'style': "fill:#ff00ff; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(x), inkex.addNS('cy','sodipodi'): str(y), inkex.addNS('rx','sodipodi'): str(1), inkex.addNS('ry','sodipodi'): str(1), inkex.addNS('type','sodipodi'): 'arc'})
+ #Don't draw zero radius circles
+ if w:
+ inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
+ {"gcodetools": "Engraving calculation paths", 'style': "fill:none; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(x), inkex.addNS('cy','sodipodi'): str(y),inkex.addNS('rx','sodipodi'): str(w), inkex.addNS('ry','sodipodi'): str(w), inkex.addNS('type','sodipodi'): 'arc'})
+ # Find slope direction for shading
+ s=math.atan2(y-y0,x-x0) #-pi to pi
+ # convert to 2 hex digits as a shade of red
+ s2="#{0:x}0000".format(int(101*(1.5-math.sin(s+0.5))))
+ inkex.etree.SubElement( gcode_3Dleft , inkex.addNS('path','svg'),
+ { "d": "M %f,%f L %f,%f" %(x0-eye_dist,y0,x-eye_dist-0.14*w,y),
+ 'style': "stroke:" + s2 + "; stroke-opacity:1; stroke-width:" + str(t/2) +" ; fill:none",
+ "gcodetools": "Gcode G1R"
+ })
+ inkex.etree.SubElement( gcode_3Dright , inkex.addNS('path','svg'),
+ { "d": "M %f,%f L %f,%f" %(x0+eye_dist,y0,x+eye_dist+0.14*r,y),
+ 'style': "stroke:" + s2 + "; stroke-opacity:1; stroke-width:" + str(t/2) +" ; fill:none",
+ "gcodetools": "Gcode G1L"
+ })
+ #end of draw_point
+
+ #end of subfunction definitions. engraving() starts here:
+ gcode = ''
+ r,w, wmax = 0,0,0 #theoretical and tool-radius-limited radii in pixels
+ x1,y1,nx,ny =0,0,0,0
cspe =[]
we = []
+ if len(self.selected_paths)<=0:
+ self.error(_("Please select at least one path to engrave and run again."),"warning")
+ return
+ if not self.check_dir() : return
+ #Find what units the user uses
+ unit=" mm"
+ if self.options.unit == "G20 (All units in inches)" :
+ unit=" inches"
+ elif self.options.unit != "G21 (All units in mm)" :
+ self.error(_("Unknown unit selected. mm assumed"),"warning")
+ print_("engraving_max_dist mm/inch", self.options.engraving_max_dist )
+
+ #LT See if we can use this parameter for line and Bezier subdivision:
+ bitlen=20/self.options.engraving_newton_iterations
+
for layer in self.layers :
- if layer in self.selected_paths :
+ if layer in self.selected_paths :
+ #Calculate scale in pixels per user unit (mm or inch)
+ p1=self.orientation_points[layer][0][0]
+ p2=self.orientation_points[layer][0][1]
+ ol=math.hypot(p1[0][0]-p2[0][0],p1[0][1]-p2[0][1])
+ oluu=math.hypot(p1[1][0]-p2[1][0],p1[1][1]-p2[1][1])
+ print_("Orientation2 p1 p2 ol oluu",p1,p2,ol,oluu)
+ orientation_scale = ol/oluu
+
self.set_tool(layer)
+ shape = self.tools[layer][0]['shape']
+ if re.search('w', shape) :
+ toolshape = eval('lambda w: ' + shape.strip('"'))
+ else:
+ self.error(_("Tool '%s' has no shape. 45 degree cone assumed!") % self.tools[layer][0]['name'],"Continue")
+ toolshape = lambda w: w
+ #Get tool radius in pixels
+ toolr=self.tools[layer][0]['diameter'] * orientation_scale/2
+ print_("tool radius in pixels=", toolr)
+ #max dist from path to engrave in user's units
+ max_distuu = min(self.tools[layer][0]['diameter']/2, self.options.engraving_max_dist)
+ max_dist=max_distuu*orientation_scale
+ print_("max_dist pixels", max_dist )
+
engraving_group = inkex.etree.SubElement( self.selected_paths[layer][0].getparent(), inkex.addNS('g','svg') )
+ if self.options.engraving_draw_calculation_paths and (self.my3Dlayer == None) :
+ self.my3Dlayer=inkex.etree.SubElement(self.document.getroot(), 'g') #Create a generic element at root level
+ self.my3Dlayer.set(inkex.addNS('label', 'inkscape'), "3D") #Gives it a name
+ self.my3Dlayer.set(inkex.addNS('groupmode', 'inkscape'), 'layer') #Tells Inkscape it's a layer
+ #Create groups for left and right eyes
+ if self.options.engraving_draw_calculation_paths :
+ gcode_3Dleft = inkex.etree.SubElement(self.my3Dlayer, inkex.addNS('g','svg'), {"gcodetools":"Gcode 3D L"})
+ gcode_3Dright = inkex.etree.SubElement(self.my3Dlayer, inkex.addNS('g','svg'), {"gcodetools":"Gcode 3D R"})
+
for node in self.selected_paths[layer] :
if node.tag == inkex.addNS('path','svg'):
cspi = cubicsuperpath.parsePath(node.get('d'))
-
- for j in xrange(len(cspi)):
- # Remove zerro length segments
- i = 1
+ #LT: Create my own list. n1LT[j] is for subpath j
+ nlLT = []
+ for j in xrange(len(cspi)): #LT For each subpath...
+ # Remove zero length segments, assume closed path
+ i = 0 #LT was from i=1
while i<len(cspi[j]):
if abs(cspi[j][i-1][1][0]-cspi[j][i][1][0])<engraving_tolerance and abs(cspi[j][i-1][1][1]-cspi[j][i][1][1])<engraving_tolerance:
cspi[j][i-1][2] = cspi[j][i][2]
del cspi[j][i]
else:
i += 1
- for csp in cspi:
- # Create list containing normlas and points
- nl = []
- for i in range(1,len(csp)):
- n, n1 = [], []
- sp1, sp2 = csp[i-1], csp[i]
- for ti in [.0,.25,.75,1.]:
- # Is following string is nedded or not??? (It makes t depend on form of the curve)
- #ti = bezmisc.beziertatlength(bez,ti)
- x1,y1 = csp_at_t(sp1,sp2,ti)
- nx,ny = csp_normalized_normal(sp1,sp2,ti)
- n+=[ [ [x1,y1], [nx,ny], False, False, i] ] # [point coordinates, normal, is an inner corner, is an outer corner, csp's index]
- if ti==1 and i<len(csp)-1:
- nx2, ny2 = csp_normalized_slope(csp[i],csp[i+1],0)
- nx2,ny2 = -ny2,nx2
- ang = ny2*nx-ny*nx2
- ang1 = 180-math.acos(max(-1,min(1,nx*nx2+ny*ny2)))*180/math.pi
- if ang > 0 and ang1 < self.options.engraving_sharp_angle_tollerance : # inner angle
- n[-1][2] = True
- elif ang < 0 and ang1 < self.options.engraving_sharp_angle_tollerance : # outer angle
- a = -math.acos(nx*nx2+ny*ny2)
- for t in [.0,.25,.75,1.]:
- n1 += [ [ [x1,y1], [nx*math.cos(a*t)-ny*math.sin(a*t),nx*math.sin(a*t)+ny*math.cos(a*t)], False, True, i ] ]
- nl += [ n ] + ([ n1 ] if n1!=[] else [])
- # Modify first/last points if curve is closed
- if abs(csp[-1][1][0]-csp[0][1][0])<engraving_tolerance and abs(csp[-1][1][1]-csp[0][1][1])<engraving_tolerance :
- x1,y1 = csp_at_t(csp[-2],csp[-1],1)
- nx,ny = csp_normalized_slope(csp[-2],csp[-1],1)
- nx,ny = -ny,nx
- nx2,ny2 = csp_normalized_slope(csp[0],csp[1],0)
- nx2,ny2 = -ny2,nx2
- ang = ny2*nx-ny*nx2
- if ang > 0 and 180-math.acos(nx*nx2+ny*ny2)*180/math.pi < self.options.engraving_sharp_angle_tollerance : # inner angle
- nl[-1][-1][2] = True
- elif ang < 0 and 180-math.acos(nx*nx2+ny*ny2)*180/math.pi < self.options.engraving_sharp_angle_tollerance : # outer angle
- a = -math.acos(nx*nx2+ny*ny2)
- n1 = []
- for t in [.0,.25,.75,1.]:
- n1 += [ [ [x1,y1], [nx*math.cos(a*t)-ny*math.sin(a*t),nx*math.sin(a*t)+ny*math.cos(a*t)], False, True, i ] ]
- nl += [ n1 ]
-
-
- print_(("engraving_draw_calculation_paths=",self.options.engraving_draw_calculation_paths))
- if self.options.engraving_draw_calculation_paths==True:
- for i in nl:
- for p in i:
- inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
- {
- "d": "M %f,%f L %f,%f" %(p[0][0],p[0][1],p[0][0]+p[1][0]*10,p[0][1]+p[1][1]*10),
- 'style': "stroke:#0000ff; stroke-opacity:0.46; stroke-width:0.1; fill:none",
- "gcodetools": "Engraving calculation paths"
- })
-
-
- # Calculate offset points
- csp_points = []
- for ki in xrange(len(nl)):
- p = []
- for ti in xrange(3) if ki!=len(nl)-1 else xrange(4):
- n = nl[ki][ti]
- x1,y1 = n[0]
- nx,ny = n[1]
- d, r = 0, float("inf")
- if ti==0 and nl[ki-1][-1][2] == True or ti==3 and nl[ki][ti][2] == True:
- # Point is a sharp angle r=0p
- r = 0
- else :
- for j in xrange(0,len(cspi)):
- for i in xrange(1,len(cspi[j])):
- d = csp_bound_to_point_distance(cspi[j][i-1], cspi[j][i], [x1,y1])
- if d >= self.options.engraving_max_dist*2 :
- r = min(math.sqrt(d/2),r)
+ for csp in cspi: #LT6a For each subpath...
+ #Create copies in 3D layer
+ print_("csp is zz ",csp)
+ cspl=[]
+ cspr=[]
+ #create list containing lines and points, starting with a point
+ # line members: [x,y],[nx,ny],False,i
+ # x,y is start of line. Normal on engraved side.
+ # Normal is normalised (unit length)
+ #Note that Y axis increases down the page
+ # corner members: [x,y],[nx,ny],True,sin(halfangle)
+ # if halfangle>0: radius 0 here. normal is bisector
+ # if halfangle<0. reflex angle. normal is bisector
+ # corner normals are divided by cos(halfangle)
+ #so that they will engrave correctly
+ print_("csp is",csp)
+ nlLT.append ([])
+ for i in range(0,len(csp)): #LT for each point
+ #n = []
+ sp0, sp1, sp2 = csp[i-2], csp[i-1], csp[i]
+ if self.options.engraving_draw_calculation_paths:
+ #Copy it to 3D layer objects
+ spl=[]
+ spr=[]
+ for j in range(0,3) :
+ pl=[sp2[j][0]-eye_dist,sp2[j][1]]
+ pr=[sp2[j][0]+eye_dist,sp2[j][1]]
+ spl+=[pl]
+ spr+=[pr]
+ cspl+=[spl]
+ cspr+=[spr]
+ #LT find angle between this and previous segment
+ x0,y0 = sp1[1]
+ nx1,ny1 = csp_normalized_normal(sp1,sp2,0)
+ #I don't trust this function, so test result
+ if abs(1-math.hypot(nx1,ny1))> 0.00001 :
+ print_("csp_normalised_normal error t=0",nx1,ny1,sp1,sp2)
+ self.error(_("csp_normalised_normal error. See log."),"warning")
+
+ nx0, ny0 = csp_normalized_normal(sp0,sp1,1)
+ if abs(1-math.hypot(nx0,ny0))> 0.00001 :
+ print_("csp_normalised_normal error t=1",nx0,ny0,sp1,sp2)
+ self.error(_("csp_normalised_normal error. See log."),"warning")
+ bx,by,s=bisect((nx0,ny0),(nx1,ny1))
+ #record x,y,normal,ifCorner, sin(angle-turned/2)
+ nlLT[-1] += [[ [x0,y0],[bx,by], True, s]]
+
+ #LT now do the line
+ if sp1[1]==sp1[2] and sp2[0]==sp2[1] : #straightline
+ nlLT[-1]+=[[sp1[1],[nx1,ny1],False,i]]
+ else : #Bezier. First, recursively cut it up:
+ nn=bez_divide(sp1[1],sp1[2],sp2[0],sp2[1])
+ first=True #Flag entry to divided Bezier
+ for bLT in nn : #save as two line segments
+ for seg in range(3) :
+ if seg>0 or first :
+ nx1=bLT[seg][1]-bLT[seg+1][1]
+ ny1=bLT[seg+1][0]-bLT[seg][0]
+ l1=math.hypot(nx1,ny1)
+ if l1<engraving_tolerance :
continue
- for n1 in xrange(self.options.engraving_newton_iterations):
- t = find_cutter_center((x1,y1),(nx,ny), cspi[j][i-1], cspi[j][i], self.tools[layer][0], float(n1)/(self.options.engraving_newton_iterations-1))
- print_(t)
- if t[0] > engraving_tolerance and 0<=t[2]<=1 and abs(t[3])<engraving_tolerance:
- print_("!@#!@#!@#!@#!@",t)
- t3 = t[2]
- ax,ay,bx,by,cx,cy,dx,dy=bezmisc.bezierparameterize((cspi[j][i-1][1],cspi[j][i-1][2],cspi[j][i][0],cspi[j][i][1]))
- x2=ax*(t3*t3*t3)+bx*(t3*t3)+cx*t3+dx
- y2=ay*(t3*t3*t3)+by*(t3*t3)+cy*t3+dy
- if abs(x2-x1)<engraving_tolerance and abs(y2-y1)<engraving_tolerance:
- f1x = 3*ax*(t3*t3)+2*bx*t3+cx
- f1y = 3*ay*(t3*t3)+2*by*t3+cy
- f2x = 6*ax*t3+2*bx
- f2y = 6*ay*t3+2*by
- d = f1x*f2y-f1y*f2x
- # d = curvature
- if d!=0 :
- d = math.sqrt((f1x*f1x+f1y*f1y)**3)/d
- if d>0:
- r = min( d,r) if r!=None else d
- else :
- r = min(r,self.options.engraving_max_dist) if r!=None else self.options.engraving_max_dist
- else:
- r = min(t[0],r) if r!=None else t[0]
- for j in xrange(0,len(cspi)):
- for i in xrange(0,len(cspi[j])):
- x2,y2 = cspi[j][i][1]
- if (abs(x1-x2)>engraving_tolerance or abs(y1-y2)>engraving_tolerance ) and (x2*nx - x1*nx + y2*ny - y1*ny) != 0:
- t1 = .5 * ( (x1-x2)**2+(y1-y2)**2 ) / (x2*nx - x1*nx + y2*ny - y1*ny)
- if t1>0 : r = min(t1,r) if r!=None else t1
- if self.options.engraving_draw_calculation_paths==True:
- inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
- {"gcodetools": "Engraving calculation paths", 'style': "fill:#ff00ff; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(x1+nx*r), inkex.addNS('cy','sodipodi'): str(y1+ny*r), inkex.addNS('rx','sodipodi'): str(1), inkex.addNS('ry','sodipodi'): str(1), inkex.addNS('type','sodipodi'): 'arc'})
- inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
- {"gcodetools": "Engraving calculation paths", 'style': "fill:none; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(x1+nx*r), inkex.addNS('cy','sodipodi'): str(y1+ny*r),inkex.addNS('rx','sodipodi'): str(r), inkex.addNS('ry','sodipodi'): str(r), inkex.addNS('type','sodipodi'): 'arc'})
- r = min(r, self.options.engraving_max_dist)
- w = min(r, self.tools[layer][0]['diameter'])
- p += [ [x1+nx*w,y1+ny*w,r,w] ]
-
-
-
- if len(csp_points)>0 : csp_points[-1] += [p[0]]
- csp_points += [ p ]
- # Splitting path to pieces each of them not further from path more than engraving_max_dist
- engraving_path = [ [] ]
- for p_ in csp_points :
- for p in p_:
- if p[2]<self.options.engraving_max_dist : break
- if p[2]<self.options.engraving_max_dist: engraving_path[-1] += [p_]
- else :
- if engraving_path[-1] != [] : engraving_path += [ [] ]
- if engraving_path[-1] == [] : del engraving_path[-1]
-
+ nx1=nx1/l1 #normalise them
+ ny1=ny1/l1
+ nlLT[-1]+=[[bLT[seg],[nx1,ny1], False,i]]
+ first=False
+ if seg<2 : #get outgoing bisector
+ nx0=nx1
+ ny0=ny1
+ nx1=bLT[seg+1][1]-bLT[seg+2][1]
+ ny1=bLT[seg+2][0]-bLT[seg+1][0]
+ l1=math.hypot(nx1,ny1)
+ if l1<engraving_tolerance :
+ continue
+ nx1=nx1/l1 #normalise them
+ ny1=ny1/l1
+ #bisect
+ bx,by,s=bisect((nx0,ny0),(nx1,ny1))
+ nlLT[-1] += [[bLT[seg+1],[bx,by], True, 0.]]
+ #LT for each segment - ends here.
+ print_(("engraving_draw_calculation_paths=",self.options.engraving_draw_calculation_paths))
+ if self.options.engraving_draw_calculation_paths:
+ #Copy complete paths to 3D layer
+ #print_("cspl",cspl)
+ cspl+=[cspl[0]] #Close paths
+ cspr+=[cspr[0]] #Close paths
+ inkex.etree.SubElement( gcode_3Dleft , inkex.addNS('path','svg'),
+ { "d": cubicsuperpath.formatPath([cspl]),
+ 'style': "stroke:#808080; stroke-opacity:1; stroke-width:0.6; fill:none",
+ "gcodetools": "G1L outline"
+ })
+ inkex.etree.SubElement( gcode_3Dright , inkex.addNS('path','svg'),
+ { "d": cubicsuperpath.formatPath([cspr]),
+ 'style': "stroke:#808080; stroke-opacity:1; stroke-width:0.6; fill:none",
+ "gcodetools": "G1L outline"
+ })
+
+ for p in nlLT[-1]: #For last sub-path
+ if p[2]: inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
+ { "d": "M %f,%f L %f,%f" %(p[0][0],p[0][1],p[0][0]+p[1][0]*10,p[0][1]+p[1][1]*10),
+ 'style': "stroke:#f000af; stroke-opacity:0.46; stroke-width:0.1; fill:none",
+ "gcodetools": "Engraving normals"
+ })
+ else: inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
+ { "d": "M %f,%f L %f,%f" %(p[0][0],p[0][1],p[0][0]+p[1][0]*10,p[0][1]+p[1][1]*10),
+ 'style': "stroke:#0000ff; stroke-opacity:0.46; stroke-width:0.1; fill:none",
+ "gcodetools": "Engraving bisectors"
+ })
+
+
+ #LT6a build nlLT[j] for each subpath - ends here
+ #for nnn in nlLT :
+ #print_("nlLT",nnn) #LT debug stuff
+ # Calculate offset points
+ reflex=False
+ for j in xrange(len(nlLT)): #LT6b for each subpath
+ cspm=[] #Will be my output. List of csps.
+ wl=[] #Will be my w output list
+ w = r = 0 #LT initial, as first point is an angle
+ for i in xrange(len(nlLT[j])) : #LT for each node
+ #LT Note: Python enables wrapping of array indices
+ # backwards to -1, -2, but not forwards. Hence:
+ n0 = nlLT[j][i-2] #previous node
+ n1 = nlLT[j][i-1] #current node
+ n2 = nlLT[j][i] #next node
+ #if n1[2] == True and n1[3]==0 : # A straight angle
+ #continue
+ x1a,y1a = n1[0] #this point/start of this line
+ nx,ny = n1[1]
+ x1b,y1b = n2[0] #next point/end of this line
+ if n1[2] == True : # We're at a corner
+ bits=1
+ bit0=0
+ #lastr=r #Remember r from last line
+ lastw=w #Remember w from last line
+ w = max_dist
+ if n1[3]>0 : #acute. Limit radius
+ len1=math.hypot( (n0[0][0]-n1[0][0]),( n0[0][1]-n1[0][1]) )
+ if i<(len(nlLT[j])-1) :
+ len2=math.hypot( (nlLT[j][i+1][0][0]-n1[0][0]),(nlLT[j][i+1][0][1]-n1[0][1]) )
+ else:
+ len2=math.hypot( (nlLT[j][0][0][0]-n1[0][0]),(nlLT[j][0][0][1]-n1[0][1]) )
+ #set initial r value, not to be exceeded
+ w = math.sqrt(min(len1,len2))/n1[3]
+ else: #line. Cut it up if long.
+ if n0[3]>0 and not self.options.engraving_draw_calculation_paths :
+ bit0=r*n0[3] #after acute corner
+ else : bit0=0.0
+ length=math.hypot((x1b-x1a),(y1a-y1b))
+ bit0=(min(length,bit0))
+ bits=int((length-bit0)/bitlen)
+ #split excess evenly at both ends
+ bit0+=(length-bit0-bitlen*bits)/2
+ #print_("j,i,r,bit0,bits",j,i,w,bit0,bits)
+ for b in xrange(bits) : #divide line into bits
+ x1=x1a+ny*(b*bitlen+bit0)
+ y1=y1a-nx*(b*bitlen+bit0)
+ jjmin,iimin,w=get_biggest( (x1,y1), (nx,ny))
+ print_("i,j,jjmin,iimin,w",i,j,jjmin,iimin,w)
+ #w = min(r, toolr)
+ wmax=max(wmax,w)
+ if reflex : #just after a reflex corner
+ reflex = False
+ if w<lastw : #need to adjust it
+ draw_point((x1,y1),(n0[0][0]+n0[1][0]*w,n0[0][1]+n0[1][1]*w),w, (lastw-w)/2)
+ save_point((n0[0][0]+n0[1][0]*w,n0[0][1]+n0[1][1]*w),w,i,j,iimin,jjmin)
+ if n1[2] == True : # We're at a corner
+ if n1[3]>0 : #acute
+ save_point((x1+nx*w,y1+ny*w),w,i,j,iimin,jjmin)
+ draw_point((x1,y1),(x1,y1),0,0)
+ save_point((x1,y1),0,i,j,iimin,jjmin)
+ elif n1[3]<0 : #reflex
+ if w>lastw :
+ draw_point((x1,y1),(x1+nx*lastw,y1+ny*lastw),w, (w-lastw)/2)
+ wmax=max(wmax,w)
+ save_point((x1+nx*w,y1+ny*w),w,i,j,iimin,jjmin)
+ elif b>0 and n2[3]>0 and not self.options.engraving_draw_calculation_paths : #acute corner coming up
+ if jjmin==j and iimin==i+2 : break
+ draw_point((x1,y1),(x1+nx*w,y1+ny*w),w, bitlen)
+ save_point((x1+nx*w,y1+ny*w),w,i,j,iimin,jjmin)
+
+ #LT end of for each bit of this line
+ if n1[2] == True and n1[3]<0 : #reflex angle
+ reflex=True
+ lastw = w #remember this w
+ #LT next i
+ cspm+=[cspm[0]]
+ print_("cspm",cspm)
+ wl+=[wl[0]]
+ print_("wl",wl)
+ #Note: Original csp_points was a list, each element
+ #being 4 points, with the first being the same as the
+ #last of the previous set.
+ #Each point is a list of [cx,cy,r,w]
+ #I have flattened it to a flat list of points.
- for csp_points in engraving_path :
- # Create Path that goes through this points
- cspm = []
- w = []
- m = [[0.0, 0.0, 0.0, 1.0], [0.015625, 0.140625, 0.421875, 0.421875], [0.421875, 0.421875, 0.140625, 0.015625], [1.0, 0.0, 0.0, 0.0]]
- for p in csp_points:
- m = numpy.array(m)
- xi = numpy.array( [p[i][:2] for i in range(4)])
- sp1,sp2 = [[0.,0.],[0.,0.],[0.,0.]], [[0.,0.],[0.,0.],[0.,0.]]
- a,b,c,d = numpy.linalg.solve(m, xi).tolist()
- sp1[1], sp1[0] = d, d
- sp1[2] = c
- sp2[0] = b
- sp2[1], sp2[2] = a, a
- sp3,sp4,sp5 = csp_split(sp1, sp2, .25)
- l = cspseglength(sp3,sp4)
- sp1,sp2,sp4 = csp_split(sp1, sp2, .75)
- l1 = cspseglength(sp1,sp2)
- if l1!=0:
- sp1,sp2,sp3 = csp_splitatlength(sp1, sp2, l/l1)
- if len(cspm)>0 :
- cspm[-1][2] = sp1[2]
- cspm += [sp2[:], sp3[:], sp4[:]]
- w += [p[i][3] for i in range(1,4)]
- else :
- cspm += [sp1[:], sp2[:], sp3[:], sp4[:]]
- w += [p[i][3] for i in range(4)]
- if self.options.engraving_draw_calculation_paths==True:
- node = inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'), {
- "d": cubicsuperpath.formatPath([cspm]),
- 'style': styles["biarc_style_i"]['biarc1'],
- "gcodetools": "Engraving calculation paths",
- })
- for i in xrange(len(cspm)):
- inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
- {"gcodetools": "Engraving calculation paths", 'style': "fill:none; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(cspm[i][1][0]), inkex.addNS('cy','sodipodi'): str(cspm[i][1][1]),inkex.addNS('rx','sodipodi'): str(w[i]), inkex.addNS('ry','sodipodi'): str(w[i]), inkex.addNS('type','sodipodi'): 'arc'})
- cspe += [cspm]
- we += [w]
-
- if self.tools[layer][0]['shape'] != "":
- f = eval('lambda w: ' + self.tools[layer][0]['shape'].strip('"'))
- else:
- self.error(_("Tool '%s' has no shape!") % self.tools[layer][0]['name'],"engraving_tools_shape_error")
- f = lambda w: w
-
+ if self.options.engraving_draw_calculation_paths==True:
+ node = inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'), {
+ "d": cubicsuperpath.formatPath([cspm]),
+ 'style': styles["biarc_style_i"]['biarc1'],
+ "gcodetools": "Engraving calculation paths",
+ })
+ for i in xrange(len(cspm)):
+ inkex.etree.SubElement( engraving_group, inkex.addNS('path','svg'),
+ {"gcodetools": "Engraving calculation paths", 'style': "fill:none; fill-opacity:0.46; stroke:#000000; stroke-width:0.1;", inkex.addNS('cx','sodipodi'): str(cspm[i][1][0]), inkex.addNS('cy','sodipodi'): str(cspm[i][1][1]),inkex.addNS('rx','sodipodi'): str(wl[i]), inkex.addNS('ry','sodipodi'): str(wl[i]), inkex.addNS('type','sodipodi'): 'arc'})
+ cspe += [cspm]
+ wluu = [] #width list in user units: mm/inches
+ for w in wl :
+ wluu+=[ w / orientation_scale ]
+ print_("wl in pixels",wl)
+ print_("wl in user units",wluu)
+ #LT previously, we was in pixels so gave wrong depth
+ we += [wluu]
+ #LT6b For each subpath - ends here
+ #LT5 if it is a path - ends here
+ #print_("cspe",cspe)
+ #print_("we",we)
+ #LT4 for each selected object in this layer - ends here
+
if cspe!=[]:
- curve = self.parse_curve(cspe, layer, we, f)
+ curve = self.parse_curve(cspe, layer, we, toolshape) #convert to lines
self.draw_curve(curve, layer, engraving_group)
gcode += self.generate_gcode(curve, layer, self.options.Zsurface)
+ #LT3 for layers loop ends here
if gcode!='' :
+ self.header+="(Tool diameter should be at least "+str(2*wmax/orientation_scale)+unit+ ")\n"
+ self.header+="(Depth, as a function of radius w, must be "+ self.tools[layer][0]['shape']+ ")\n"
+ self.header+="(Rapid feeds use safe Z="+ str(self.options.Zsafe) + unit + ")\n"
+ self.header+="(Material surface at Z="+ str(self.options.Zsurface) + unit + ")\n"
self.export_gcode(gcode)
else : self.error(_("No need to engrave sharp angles."),"warning")
@@ -4079,47 +5806,75 @@ class Gcodetools(inkex.Effect):
###
################################################################################
def orientation(self, layer=None) :
- print_("entering orientations")
+
if layer == None :
layer = self.current_layer if self.current_layer is not None else self.document.getroot()
- if layer in self.orientation_points:
- self.error(_("Active layer already has orientation points! Remove them or select another layer!"),"active_layer_already_has_orientation_points")
- orientation_group = inkex.etree.SubElement(layer, inkex.addNS('g','svg'), {"gcodetools":"Gcodetools orientation group"})
- doc_height = inkex.unittouu(self.document.getroot().get('height'))
- if self.document.getroot().get('height') == "100%" :
- doc_height = 1052.3622047
- print_("Overruding height from 100 percents to %s" % doc_height)
- if self.options.unit == "G21 (All units in mm)" :
- points = [[0.,0.,self.options.Zsurface],[100.,0.,self.options.Zdepth],[0.,100.,0.]]
- orientation_scale = 3.5433070660
- print_("orientation_scale < 0 ===> switching to mm units=%0.10f"%orientation_scale )
- elif self.options.unit == "G20 (All units in inches)" :
- points = [[0.,0.,self.options.Zsurface],[5.,0.,self.options.Zdepth],[0.,5.,0.]]
- orientation_scale = 90
- print_("orientation_scale < 0 ===> switching to inches units=%0.10f"%orientation_scale )
- if self.options.orientation_points_count == 2 :
- points = points[:2]
- print_(("using orientation scale",orientation_scale,"i=",points))
- for i in points :
- si = [i[0]*orientation_scale, i[1]*orientation_scale]
- g = inkex.etree.SubElement(orientation_group, inkex.addNS('g','svg'), {'gcodetools': "Gcodetools orientation point (%s points)" % self.options.orientation_points_count})
+ transform = self.get_transforms(layer)
+ if transform != [] :
+ transform = self.reverse_transform(transform)
+ transform = simpletransform.formatTransform(transform)
+
+ if self.options.orientation_points_count == "graffiti" :
+ print_(self.graffiti_reference_points)
+ print_("Inserting graffiti points")
+ if layer in self.graffiti_reference_points: graffiti_reference_points_count = len(self.graffiti_reference_points[layer])
+ else: graffiti_reference_points_count = 0
+ axis = ["X","Y","Z","A"][graffiti_reference_points_count%4]
+ attr = {'gcodetools': "Gcodetools graffiti reference point"}
+ if transform != [] :
+ attr["transform"] = transform
+ g = inkex.etree.SubElement(layer, inkex.addNS('g','svg'), attr)
inkex.etree.SubElement( g, inkex.addNS('path','svg'),
{
- 'style': "stroke:none;fill:#000000;",
- 'd':'m %s,%s 2.9375,-6.343750000001 0.8125,1.90625 6.843748640396,-6.84374864039 0,0 0.6875,0.6875 -6.84375,6.84375 1.90625,0.812500000001 z z' % (si[0], -si[1]+doc_height),
- 'gcodetools': "Gcodetools orientation point arrow"
+ 'style': "stroke:none;fill:#00ff00;",
+ 'd':'m %s,%s 2.9375,-6.343750000001 0.8125,1.90625 6.843748640396,-6.84374864039 0,0 0.6875,0.6875 -6.84375,6.84375 1.90625,0.812500000001 z z' % (graffiti_reference_points_count*100, 0),
+ 'gcodetools': "Gcodetools graffiti reference point arrow"
})
- t = inkex.etree.SubElement( g, inkex.addNS('text','svg'),
- {
- 'style': "font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;",
- inkex.addNS("space","xml"):"preserve",
- 'x': str(si[0]+10),
- 'y': str(-si[1]-10+doc_height),
- 'gcodetools': "Gcodetools orientation point text"
- })
- t.text = "(%s; %s; %s)" % (i[0],i[1],i[2])
+
+ draw_text(axis,graffiti_reference_points_count*100+10,-10, group = g, gcodetools_tag = "Gcodetools graffiti reference point text")
+
+ elif self.options.orientation_points_count == "in-out reference point" :
+ draw_pointer(group = self.current_layer, x = self.view_center, figure="arrow", pointer_type = "In-out reference point", text = "In-out point")
+ else :
+ print_("Inserting orientation points")
+
+ if layer in self.orientation_points:
+ self.error(_("Active layer already has orientation points! Remove them or select another layer!"),"active_layer_already_has_orientation_points")
+
+ attr = {"gcodetools":"Gcodetools orientation group"}
+ if transform != [] :
+ attr["transform"] = transform
+
+ orientation_group = inkex.etree.SubElement(layer, inkex.addNS('g','svg'), attr)
+ doc_height = inkex.unittouu(self.document.getroot().get('height'))
+ if self.document.getroot().get('height') == "100%" :
+ doc_height = 1052.3622047
+ print_("Overruding height from 100 percents to %s" % doc_height)
+ if self.options.unit == "G21 (All units in mm)" :
+ points = [[0.,0.,self.options.Zsurface],[100.,0.,self.options.Zdepth],[0.,100.,0.]]
+ orientation_scale = 3.5433070660
+ print_("orientation_scale < 0 ===> switching to mm units=%0.10f"%orientation_scale )
+ elif self.options.unit == "G20 (All units in inches)" :
+ points = [[0.,0.,self.options.Zsurface],[5.,0.,self.options.Zdepth],[0.,5.,0.]]
+ orientation_scale = 90
+ print_("orientation_scale < 0 ===> switching to inches units=%0.10f"%orientation_scale )
+ if self.options.orientation_points_count == "2" :
+ points = points[:2]
+ print_(("using orientation scale",orientation_scale,"i=",points))
+ for i in points :
+ si = [i[0]*orientation_scale, i[1]*orientation_scale]
+ g = inkex.etree.SubElement(orientation_group, inkex.addNS('g','svg'), {'gcodetools': "Gcodetools orientation point (%s points)" % self.options.orientation_points_count})
+ inkex.etree.SubElement( g, inkex.addNS('path','svg'),
+ {
+ 'style': "stroke:none;fill:#000000;",
+ 'd':'m %s,%s 2.9375,-6.343750000001 0.8125,1.90625 6.843748640396,-6.84374864039 0,0 0.6875,0.6875 -6.84375,6.84375 1.90625,0.812500000001 z z' % (si[0], -si[1]+doc_height),
+ 'gcodetools': "Gcodetools orientation point arrow"
+ })
+
+ draw_text("(%s; %s; %s)" % (i[0],i[1],i[2]), (si[0]+10), (-si[1]-10+doc_height), group = g, gcodetools_tag = "Gcodetools orientation point text")
+
################################################################################
###
@@ -4189,20 +5944,33 @@ class Gcodetools(inkex.Effect):
"penetration feed":100,
"feed":400,
"gcode before path":"""G31 Z-100 F500 (find metal)
-G92 Z0 (zerro z)
+G92 Z0 (zero z)
G00 Z10 F500 (going up)
M03 (turn on plasma)
G04 P0.2 (pause)
G01 Z1 (going to cutting z)\n""",
"gcode after path":"M05 (turn off plasma)\n",
}
+ elif self.options.tools_library_type == "graffiti":
+ tool = {
+ "name": "Graffiti",
+ "id": "Graffiti 0001",
+ "diameter":10,
+ "penetration feed":100,
+ "feed":400,
+ "gcode before path":"""M03 S1(Turn spray on)\n """,
+ "gcode after path":"M05 (Turn spray off)\n ",
+ "tool change gcode":"(Add G00 here to change sprayer if needed)\n",
+
+ }
+
else :
tool = self.default_tool
tool_num = sum([len(self.tools[i]) for i in self.tools])
colors = ["00ff00","0000ff","ff0000","fefe00","00fefe", "fe00fe", "fe7e00", "7efe00", "00fe7e", "007efe", "7e00fe", "fe007e"]
- tools_group = inkex.etree.SubElement(layer, inkex.addNS('g','svg'), {'gcodetools': "Gcodetools tool defenition"})
+ tools_group = inkex.etree.SubElement(layer, inkex.addNS('g','svg'), {'gcodetools': "Gcodetools tool definition"})
bg = inkex.etree.SubElement( tools_group, inkex.addNS('path','svg'),
{'style': "fill:#%s;fill-opacity:0.5;stroke:#444444; stroke-width:1px;"%colors[tool_num%len(colors)], "gcodetools":"Gcodetools tool background"})
@@ -4214,35 +5982,13 @@ G01 Z1 (going to cutting z)\n""",
if key not in keys: keys += [key]
for key in keys :
g = inkex.etree.SubElement(tools_group, inkex.addNS('g','svg'), {'gcodetools': "Gcodetools tool parameter"})
-
- t = inkex.etree.SubElement( g, inkex.addNS('text','svg'),
- {
- 'style': ("font-size:10px;" if key!="name" else "font-size:20px;") + "font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;",
- inkex.addNS("space","xml"):"preserve",
- 'x': str(0),
- 'y': str(y),
- 'gcodetools': "Gcodetools tool defention field name"
- })
- t.text = str(key)
- v = str(tool[key]).split("\n")
- t = inkex.etree.SubElement( g, inkex.addNS('text','svg'),
- {
- 'style': ("font-size:10px;" if key!="name" else "font-size:20px;") + "font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#000000;fill-opacity:1;stroke:none;",
- 'x': str(150),
- inkex.addNS("space","xml"):"preserve",
- 'y': str(y),
- 'gcodetools': "Gcodetools tool defention field value"
- })
- for s in v :
- span = inkex.etree.SubElement( t, inkex.addNS('tspan','svg'),
- {
- 'x': str(150),
- 'y': str(+y),
- inkex.addNS("role","sodipodi"):"line",
- 'gcodetools': "Gcodetools tool defention field value"
- })
- y += 15 if key!='name' else 20
- span.text = s
+ draw_text(key, 0, y, group = g, gcodetools_tag = "Gcodetools tool definition field name", font_size = 10 if key!='name' else 20)
+ param = tool[key]
+ if type(param)==str and re.match("^\s*$",param) : param = "(None)"
+ draw_text(param, 150, y, group = g, gcodetools_tag = "Gcodetools tool definition field value", font_size = 10 if key!='name' else 20)
+ v = str(param).split("\n")
+ y += 15*len(v) if key!='name' else 20*len(v)
+
bg.set('d',"m -20,-20 l 400,0 0,%f -400,0 z " % (y+50))
tool = []
tools_group.set("transform", simpletransform.formatTransform([ [1,0,self.view_center[0]-150 ], [0,1,self.view_center[1]] ] ))
@@ -4262,15 +6008,9 @@ G01 Z1 (going to cutting z)\n""",
# Set group
group = inkex.etree.SubElement( self.selected_paths.keys()[0] if len(self.selected_paths.keys())>0 else self.layers[0], inkex.addNS('g','svg') )
trans_ = [[1,0.3,0],[0,0.5,0]]
- self.get_defs()
- # Add marker to defs if it doesnot exists
- if "CheckToolsAndOPMarker" not in self.defs :
- defs = inkex.etree.SubElement( self.document.getroot(), inkex.addNS("defs","svg"))
- marker = inkex.etree.SubElement( defs, inkex.addNS("marker","svg"), {"id":"CheckToolsAndOPMarker","orient":"auto","refX":"-8","refY":"-2.41063","style":"overflow:visible"})
- inkex.etree.SubElement( marker, inkex.addNS("path","svg"),
- { "d":"m -6.55552,-2.41063 0,0 L -13.11104,0 c 1.0473,-1.42323 1.04126,-3.37047 0,-4.82126",
- "style": "fill:#000044; fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;" }
- )
+
+ self.set_markers()
+
bounds = [float('inf'),float('inf'),float('-inf'),float('-inf')]
tools_bounds = {}
for layer in self.layers :
@@ -4330,7 +6070,7 @@ G01 Z1 (going to cutting z)\n""",
alias = {"X":"I", "Y":"J", "Z":"K", "x":"i", "y":"j", "z":"k"}
i_, k_ = alias[x], alias[z]
c = [ [subpath[0][1], "move", 0, 0, 0] ]
- #csp_draw(self.transform_csp([subpath],layer,True), color = "Orange", width = .1)
+ #draw_csp(self.transform_csp([subpath],layer,True), color = "Orange", width = .1)
for sp1,sp2 in zip(subpath,subpath[1:]) :
c += biarc(sp1,sp2,0,0)
for i in range(1,len(c)) : # Just in case check end point of each segment
@@ -4344,7 +6084,7 @@ G01 Z1 (going to cutting z)\n""",
gcode += ("G01 %s %f %s %f" % (x, s[4][0], z, s[4][1]) ) + feed + "\n"
elif s[1] == 'arc':
r = [(s[2][0]-s[0][0]), (s[2][1]-s[0][1])]
- if (r[0]**2 + r[1]**2)>self.options.min_arc_radius:
+ if (r[0]**2 + r[1]**2)>self.options.min_arc_radius**2:
r1, r2 = (P(s[0])-P(s[2])), (P(s[4])-P(s[2]))
if abs(r1.mag()-r2.mag()) < 0.001 :
gcode += ("G02" if s[3]*flip_angle<0 else "G03") + (" %s %f %s %f %s %f %s %f" % (x,s[4][0],z,s[4][1],i_,(s[2][0]-s[0][0]), k_, (s[2][1]-s[0][1]) ) ) + feed + "\n"
@@ -4381,7 +6121,6 @@ G01 Z1 (going to cutting z)\n""",
self.tool["passing feed"] = float(self.tool["passing feed"] if "passing feed" in self.tool else self.tool["feed"])
self.tool["feed"] = float(self.tool["feed"])
self.tool["fine feed"] = float(self.tool["fine feed"] if "fine feed" in self.tool else self.tool["feed"])
-
gcode += ( "(Change tool to %s)\n" % re.sub("\"'\(\)\\\\"," ",self.tool["name"]) ) + self.tool["tool change gcode"] + "\n"
for path in paths[layer]:
@@ -4392,21 +6131,24 @@ G01 Z1 (going to cutting z)\n""",
fine_cut = subpath[:]
if self.options.lathe_fine_cut_width>0 :
r = self.options.lathe_fine_cut_width
- # Close the path to make offset correct
- bound = csp_simple_bound([subpath])
- minx,miny,maxx,maxy = csp_true_bounds([subpath])
- offsetted_subpath = csp_subpath_line_to(subpath[:], [ [subpath[-1][1][0], miny[1]-r*10 ], [subpath[0][1][0], miny[1]-r*10 ], [subpath[0][1][0], subpath[0][1][1] ] ])
- left,right = subpath[-1][1][0], subpath[0][1][0]
- if left>right : left, right = right,left
- offsetted_subpath = csp_offset([offsetted_subpath], r if not csp_subpath_ccw(offsetted_subpath) else -r )
- offsetted_subpath = csp_clip_by_line(offsetted_subpath, [left,10], [left,0] )
- offsetted_subpath = csp_clip_by_line(offsetted_subpath, [right,0], [right,10] )
- offsetted_subpath = csp_clip_by_line(offsetted_subpath, [0, miny[1]-r], [10, miny[1]-r] )
- #csp_draw(self.transform_csp(offsetted_subpath,layer,True), color = "Green", width = 1)
- # Join offsetted_subpath together
- # Hope there wont be any cicles
- subpath = csp_join_subpaths(offsetted_subpath)[0]
-
+ if self.options.lathe_create_fine_cut_using == "Move path" :
+ subpath = [ [ [i2[0],i2[1]+r] for i2 in i1] for i1 in subpath]
+ else :
+ # Close the path to make offset correct
+ bound = csp_simple_bound([subpath])
+ minx,miny,maxx,maxy = csp_true_bounds([subpath])
+ offsetted_subpath = csp_subpath_line_to(subpath[:], [ [subpath[-1][1][0], miny[1]-r*10 ], [subpath[0][1][0], miny[1]-r*10 ], [subpath[0][1][0], subpath[0][1][1] ] ])
+ left,right = subpath[-1][1][0], subpath[0][1][0]
+ if left>right : left, right = right,left
+ offsetted_subpath = csp_offset([offsetted_subpath], r if not csp_subpath_ccw(offsetted_subpath) else -r )
+ offsetted_subpath = csp_clip_by_line(offsetted_subpath, [left,10], [left,0] )
+ offsetted_subpath = csp_clip_by_line(offsetted_subpath, [right,0], [right,10] )
+ offsetted_subpath = csp_clip_by_line(offsetted_subpath, [0, miny[1]-r], [10, miny[1]-r] )
+ #draw_csp(self.transform_csp(offsetted_subpath,layer,True), color = "Green", width = 1)
+ # Join offsetted_subpath together
+ # Hope there wont be any cicles
+ subpath = csp_join_subpaths(offsetted_subpath)[0]
+
# Create solid object from path and lathe_width
bound = csp_simple_bound([subpath])
top_start, top_end = [subpath[0][1][0], self.options.lathe_width+self.options.Zsafe+self.options.lathe_fine_cut_width], [subpath[-1][1][0], self.options.lathe_width+self.options.Zsafe+self.options.lathe_fine_cut_width]
@@ -4471,10 +6213,88 @@ G01 Z1 (going to cutting z)\n""",
gcode += ("G01 %s %f F %f \n" % (z, top_start[1], self.tool["passing feed"]) )
gcode += ("G01 %s %f %s %f F %f \n" % (x, top_start[0], z, top_start[1], self.tool["passing feed"]) )
-
-
self.export_gcode(gcode)
+
+################################################################################
+###
+### Lathe modify path
+### Modifies path to fit current cutter. As for now straight rect cutter.
+###
+################################################################################
+
+ def lathe_modify_path(self):
+ if self.selected_paths == {} and self.options.auto_select_paths:
+ paths=self.paths
+ self.error(_("No paths are selected! Trying to work on all available paths."),"warning")
+ else :
+ paths = self.selected_paths
+
+ for layer in self.layers :
+ if layer in paths :
+ width = self.options.lathe_rectangular_cutter_width
+ #self.set_tool(layer)
+ for path in paths[layer]:
+ csp = self.transform_csp(cubicsuperpath.parsePath(path.get("d")),layer)
+ new_csp = []
+ for subpath in csp:
+ orientation = subpath[-1][1][0]>subpath[0][1][0]
+ last_n = None
+ last_o = 0
+ new_subpath = []
+
+ # Split segment at x' and y' == 0
+ for sp1, sp2 in zip(subpath[:],subpath[1:]):
+ ax,ay,bx,by,cx,cy,dx,dy = csp_parameterize(sp1,sp2)
+ roots = cubic_solver_real(0, 3*ax, 2*bx, cx)
+ roots += cubic_solver_real(0, 3*ay, 2*by, cy)
+ new_subpath = csp_concat_subpaths(new_subpath, csp_seg_split(sp1,sp2,roots))
+ subpath = new_subpath
+ new_subpath = []
+ first_seg = True
+ for sp1, sp2 in zip(subpath[:],subpath[1:]):
+ n = csp_normalized_normal(sp1,sp2,0)
+ a = math.atan2(n[0],n[1])
+ if a == 0 or a == math.pi :
+ n = csp_normalized_normal(sp1,sp2,1)
+ a = math.atan2(n[0],n[1])
+ if a!=0 and a!=math.pi:
+ o = 0 if 0<a<=math.pi/2 or -math.pi<a<-math.pi/2 else 1
+ if not orientation: o = 1-o
+
+ # Add first horisontal straight line if needed
+ if not first_seg and new_subpath==[] : new_subpath = [ [[subpath[0][i][0] - width*o ,subpath[0][i][1]] for i in range(3)] ]
+
+ new_subpath = csp_concat_subpaths(
+ new_subpath,
+ [
+ [[sp1[i][0] - width*o ,sp1[i][1]] for i in range(3)],
+ [[sp2[i][0] - width*o ,sp2[i][1]] for i in range(3)]
+ ]
+ )
+ first_seg = False
+
+ # Add last horisontal straigth line if needed
+ if a==0 or a==math.pi :
+ new_subpath += [ [[subpath[-1][i][0] - width*o ,subpath[-1][i][1]] for i in range(3)] ]
+
+ new_csp += [new_subpath]
+ self.draw_csp(new_csp,layer)
+#
+# o = (1 if cross(n, [0,1])>0 else -1)*orientation
+# new_subpath += [ [sp1[i][0] - width*o,sp1[i][1]] for i in range(3) ]
+# n = csp_normalized_normal(sp1,sp2,1)
+# o = (1 if cross(n, [0,1])>0 else -1)*orientation
+# new_subpath += [ [sp2[i][0] - width*o,sp2[i][1]] for i in range(3) ]
+
+
+################################################################################
+###
+### Update function
+###
+### Gets file containing version information from the web and compaares it with.
+### current version.
+################################################################################
def update(self) :
try :
@@ -4494,6 +6314,309 @@ G01 Z1 (going to cutting z)\n""",
except :
self.error("Can not check the latest version. You can check it manualy at \nhttp://www.cnc-club.ru/gcodetools (English version). \nhttp://www.cnc-club.ru/gcodetools_ru (Russian version). \nCurrent version is Gcodetools %s"%gcodetools_current_version,"Warning")
+
+
+################################################################################
+### Graffiti function generates Gcode for graffiti drawer
+################################################################################
+ def graffiti(self) :
+ # Get reference points.
+
+ def get_gcode_coordinates(point,layer):
+ gcode = ''
+ pos = []
+ for ref_point in self.graffiti_reference_points[layer] :
+ c = math.sqrt((point[0]-ref_point[0][0])**2 + (point[1]-ref_point[0][1])**2)
+ gcode += " %s %f"%(ref_point[1], c)
+ pos += [c]
+ return pos, gcode
+
+
+ def graffiti_preview_draw_point(x1,y1,color,radius=.5):
+ self.graffiti_preview = self.graffiti_preview
+ r,g,b,a_ = color
+ for x in range(int(x1-1-math.ceil(radius)), int(x1+1+math.ceil(radius)+1)):
+ for y in range(int(y1-1-math.ceil(radius)), int(y1+1+math.ceil(radius)+1)):
+ if x>=0 and y>=0 and y<len(self.graffiti_preview) and x*4<len(self.graffiti_preview[0]) :
+ d = math.sqrt( (x1-x)**2 +(y1-y)**2 )
+ a = float(a_)*( max(0,(1-(d-radius))) if d>radius else 1 )/256
+ self.graffiti_preview[y][x*4] = int(r*a + (1-a)*self.graffiti_preview[y][x*4])
+ self.graffiti_preview[y][x*4+1] = int(g*a + (1-a)*self.graffiti_preview[y][x*4+1])
+ self.graffiti_preview[y][x*4+2] = int(g*b + (1-a)*self.graffiti_preview[y][x*4+2])
+ self.graffiti_preview[y][x*4+3] = min(255,int(self.graffiti_preview[y][x*4+3]+a*256))
+
+ def graffiti_preview_transform(x,y):
+ tr = self.graffiti_preview_transform
+ d = max(tr[2]-tr[0]+2,tr[3]-tr[1]+2)
+ return [(x-tr[0]+1)*self.options.graffiti_preview_size/d, self.options.graffiti_preview_size - (y-tr[1]+1)*self.options.graffiti_preview_size/d]
+
+
+ def draw_graffiti_segment(layer,start,end,feed,color=(0,255,0,40),emmit=1000):
+ # Emit = dots per second
+ l = math.sqrt(sum([(start[i]-end[i])**2 for i in range(len(start))]))
+ time_ = l/feed
+ c1,c2 = self.graffiti_reference_points[layer][0][0],self.graffiti_reference_points[layer][1][0]
+ d = math.sqrt( (c1[0]-c2[0])**2 + (c1[1]-c2[1])**2 )
+ if d == 0 : raise ValueError, "Error! Reference points should not be the same!"
+ for i in range(int(time_*emmit+1)) :
+ t = i/(time_*emmit)
+ r1,r2 = start[0]*(1-t) + end[0]*t, start[1]*(1-t) + end[1]*t
+ a = (r1**2-r2**2+d**2)/(2*d)
+ h = math.sqrt(r1**2 - a**2)
+ xa = c1[0] + a*(c2[0]-c1[0])/d
+ ya = c1[1] + a*(c2[1]-c1[1])/d
+
+ x1 = xa + h*(c2[1]-c1[1])/d
+ x2 = xa - h*(c2[1]-c1[1])/d
+ y1 = ya - h*(c2[0]-c1[0])/d
+ y2 = ya + h*(c2[0]-c1[0])/d
+
+ x = x1 if y1<y2 else x2
+ y = min(y1,y2)
+ x,y = graffiti_preview_transform(x,y)
+ graffiti_preview_draw_point(x,y,color)
+
+ def create_connector(p1,p2,t1,t2):
+ P1,P2 = P(p1), P(p2)
+ N1, N2 = P(rotate_ccw(t1)), P(rotate_ccw(t2))
+ r = self.options.graffiti_min_radius
+ C1,C2 = P1+N1*r, P2+N2*r
+ # Get closest possible centers of arcs, also we define that arcs are both ccw or both not.
+ dc, N1, N2, m = (
+ (
+ (((P2-N1*r) - (P1-N2*r)).l2(),-N1,-N2, 1)
+ if vectors_ccw(t1,t2) else
+ (((P2+N1*r) - (P1+N2*r)).l2(), N1, N2,-1)
+ )
+ if vectors_ccw((P1-C1).to_list(),t1) == vectors_ccw((P2-C2).to_list(),t2) else
+ (
+ (((P2+N1*r) - (P1-N2*r)).l2(), N1,-N2, 1)
+ if vectors_ccw(t1,t2) else
+ (((P2-N1*r) - (P1+N2*r)).l2(),-N1, N2, 1)
+ )
+ )
+ dc = math.sqrt(dc)
+ C1,C2 = P1+N1*r, P2+N2*r
+ Dc = C2-C1
+
+ if dc == 0 :
+ # can be joined by one arc
+ return csp_from_arc(p1, p2, C1.to_list(), r, t1)
+
+ cos, sin = Dc.x/dc, Dc.y/dc
+ #draw_csp(self.transform_csp([[ [[C1.x-r*sin,C1.y+r*cos]]*3,[[C2.x-r*sin,C2.y+r*cos]]*3 ]],layer,reverse=True), color = "#00ff00;" )
+ #draw_pointer(self.transform(C1.to_list(),layer,reverse=True))
+ #draw_pointer(self.transform(C2.to_list(),layer,reverse=True))
+
+ p1_end = [C1.x-r*sin*m,C1.y+r*cos*m]
+ p2_st = [C2.x-r*sin*m,C2.y+r*cos*m]
+ if point_to_point_d2(p1,p1_end)<0.0001 and point_to_point_d2(p2,p2_st)<0.0001 :
+ return ([[p1,p1,p1],[p2,p2,p2]])
+
+ arc1 = csp_from_arc(p1, p1_end, C1.to_list(), r, t1)
+ arc2 = csp_from_arc(p2_st, p2, C2.to_list(), r, [cos,sin])
+ return csp_concat_subpaths(arc1,arc2)
+
+ if not self.check_dir() : return
+ if self.selected_paths == {} and self.options.auto_select_paths:
+ paths=self.paths
+ self.error(_("No paths are selected! Trying to work on all available paths."),"warning")
+ else :
+ paths = self.selected_paths
+ self.tool = []
+ gcode = """(Header)
+(Generated by gcodetools from Inkscape.)
+(Using graffiti extension.)
+(Header end.)"""
+
+ minx,miny,maxx,maxy = float("inf"),float("inf"),float("-inf"),float("-inf")
+
+ # Get all reference points and path's bounds to make preview
+
+ for layer in self.layers :
+ if layer in paths :
+ # Set reference points
+ if layer not in self.graffiti_reference_points:
+ reference_points = None
+ for i in range(self.layers.index(layer),-1,-1):
+ if self.layers[i] in self.graffiti_reference_points :
+ reference_points = self.graffiti_reference_points[self.layers[i]]
+ self.graffiti_reference_points[layer] = self.graffiti_reference_points[self.layers[i]]
+ break
+ if reference_points == None :
+ self.error('There are no graffiti reference points for layer %s'%layer,"error")
+
+ # Transform reference points
+ for i in range(len(self.graffiti_reference_points[layer])):
+ self.graffiti_reference_points[layer][i][0] = self.transform(self.graffiti_reference_points[layer][i][0], layer)
+ point = self.graffiti_reference_points[layer][i]
+ gcode += "(Reference point %f;%f for %s axis)\n"%(point[0][0],point[0][1],point[1])
+
+ if self.options.graffiti_create_preview :
+ for point in self.graffiti_reference_points[layer]:
+ minx,miny,maxx,maxy = min(minx,point[0][0]), min(miny,point[0][1]), max(maxx,point[0][0]), max(maxy,point[0][1])
+ for path in paths[layer]:
+ csp = cubicsuperpath.parsePath(path.get("d"))
+ csp = self.apply_transforms(path, csp)
+ csp = self.transform_csp(csp, layer)
+ bounds = csp_simple_bound(csp)
+ minx,miny,maxx,maxy = min(minx,bounds[0]), min(miny,bounds[1]), max(maxx,bounds[2]), max(maxy,bounds[3])
+
+ if self.options.graffiti_create_preview :
+ self.graffiti_preview = list([ [255]*(4*self.options.graffiti_preview_size) for i in range(self.options.graffiti_preview_size)])
+ self.graffiti_preview_transform = [minx,miny,maxx,maxy]
+
+ for layer in self.layers :
+ if layer in paths :
+
+ r = re.match("\s*\(\s*([0-9\-,.]+)\s*;\s*([0-9\-,.]+)\s*\)\s*",self.options.graffiti_start_pos)
+ if r :
+ start_point = [float(r.group(1)),float(r.group(2))]
+ else :
+ start_point = [0.,0.]
+ last_sp1 = [[start_point[0],start_point[1]-10] for i in range(3)]
+ last_sp2 = [start_point for i in range(3)]
+
+ self.set_tool(layer)
+ self.tool = self.tools[layer][0]
+ # Change tool every layer. (Probably layer = color so it'll be
+ # better to change it even if the tool has not been changed)
+ gcode += ( "(Change tool to %s)\n" % re.sub("\"'\(\)\\\\"," ",self.tool["name"]) ) + self.tool["tool change gcode"] + "\n"
+
+ subpaths = []
+ for path in paths[layer]:
+ # Rebuild the paths to polyline.
+ csp = cubicsuperpath.parsePath(path.get("d"))
+ csp = self.apply_transforms(path, csp)
+ csp = self.transform_csp(csp, layer)
+ subpaths += csp
+ polylines = []
+ while len(subpaths)>0:
+ i = min( [( point_to_point_d2(last_sp2[1],subpaths[i][0][1]),i) for i in range(len(subpaths))] )[1]
+ subpath = subpaths[i][:]
+ del subpaths[i]
+ polylines += [
+ ['connector', create_connector(
+ last_sp2[1],
+ subpath[0][1],
+ csp_normalized_slope(last_sp1,last_sp2,1.),
+ csp_normalized_slope(subpath[0],subpath[1],0.),
+ )]
+ ]
+ polyline = []
+ spl = None
+
+ # remove zerro length segments
+ i = 0
+ while i<len(subpath)-1:
+ if (cspseglength(subpath[i],subpath[i+1])<0.00000001 ) :
+ subpath[i][2] = subpath[i+1][2]
+ del subpath[i+1]
+ else :
+ i += 1
+
+ for sp1, sp2 in zip(subpath,subpath[1:]) :
+ if spl != None and abs(cross( csp_normalized_slope(spl,sp1,1.),csp_normalized_slope(sp1,sp2,0.) )) > 0.1 : # TODO add coefficient into inx
+ # We've got sharp angle at sp1.
+ polyline += [sp1]
+ polylines += [['draw',polyline[:]]]
+ polylines += [
+ ['connector', create_connector(
+ sp1[1],
+ sp1[1],
+ csp_normalized_slope(spl,sp1,1.),
+ csp_normalized_slope(sp1,sp2,0.),
+ )]
+ ]
+ polyline = []
+ # max_segment_length
+ polyline += [ sp1 ]
+ print_(polyline)
+ print_(sp1)
+
+ spl = sp1
+ polyline += [ sp2 ]
+ polylines += [ ['draw',polyline[:]] ]
+
+ last_sp1, last_sp2 = sp1,sp2
+
+
+ # Add return to start_point
+ if polylines == [] : continue
+ polylines += [ ["connect1", [ [polylines[-1][1][-1][1] for i in range(3)],[start_point for i in range(3)] ] ] ]
+
+ # Make polilynes from polylines. They are still csp.
+ for i in range(len(polylines)) :
+ polyline = []
+ l = 0
+ print_("polylines",polylines)
+ print_(polylines[i])
+ for sp1,sp2 in zip(polylines[i][1],polylines[i][1][1:]) :
+ print_(sp1,sp2)
+ l = cspseglength(sp1,sp2)
+ if l>0.00000001 :
+ polyline += [sp1[1]]
+ parts = int(math.ceil(l/self.options.graffiti_max_seg_length))
+ for j in range(1,parts):
+ polyline += [csp_at_length(sp1,sp2,float(j)/parts) ]
+ if l>0.00000001 :
+ polyline += [sp2[1]]
+ print_(i)
+ polylines[i][1] = polyline
+
+ t = 0
+ last_state = None
+ for polyline_ in polylines:
+ polyline = polyline_[1]
+ # Draw linearization
+ if self.options.graffiti_create_linearization_preview :
+ t += 1
+ csp = [ [polyline[i],polyline[i],polyline[i]] for i in range(len(polyline))]
+ draw_csp(self.transform_csp([csp],layer,reverse=True), color = "#00cc00;" if polyline_[0]=='draw' else "#ff5555;")
+
+
+ # Export polyline to gcode
+ # we are making trnsform from XYZA coordinates to R1...Rn
+ # where R1...Rn are radius vectors from grafiti reference points
+ # to current (x,y) point. Also we need to assign custom feed rate
+ # for each segment. And we'll use only G01 gcode.
+ last_real_pos, g = get_gcode_coordinates(polyline[0],layer)
+ last_pos = polyline[0]
+ if polyline_[0] == "draw" and last_state!="draw":
+ gcode += self.tool['gcode before path']+"\n"
+ for point in polyline :
+ real_pos, g = get_gcode_coordinates(point,layer)
+ real_l = sum([(real_pos[i]-last_real_pos[i])**2 for i in range(len(last_real_pos))])
+ l = (last_pos[0]-point[0])**2 + (last_pos[1]-point[1])**2
+ if l!=0:
+ feed = self.tool['feed']*math.sqrt(real_l/l)
+ gcode += "G01 " + g + " F %f\n"%feed
+ if self.options.graffiti_create_preview :
+ draw_graffiti_segment(layer,real_pos,last_real_pos,feed,color=(0,0,255,200) if polyline_[0] == "draw" else (255,0,0,200),emmit=self.options.graffiti_preview_emmit)
+ last_real_pos = real_pos
+ last_pos = point[:]
+ if polyline_[0] == "draw" and last_state!="draw" :
+ gcode += self.tool['gcode after path']+"\n"
+ last_state = polyline_[0]
+ self.export_gcode(gcode, no_headers=True)
+ if self.options.graffiti_create_preview :
+ try :
+ # Draw reference points
+ for layer in self.graffiti_reference_points:
+ for point in self.graffiti_reference_points[layer] :
+ x, y = graffiti_preview_transform(point[0][0],point[0][1])
+ graffiti_preview_draw_point(x,y,(0,255,0,255),radius=5)
+
+ import png
+ writer = png.Writer(width=self.options.graffiti_preview_size, height=self.options.graffiti_preview_size, size=None, greyscale=False, alpha=True, bitdepth=8, palette=None, transparent=None, background=None, gamma=None, compression=None, interlace=False, bytes_per_sample=None, planes=None, colormap=None, maxval=None, chunk_limit=1048576)
+ f = open(self.options.directory+self.options.file+".png", 'wb')
+ writer.write(f,self.graffiti_preview)
+ f.close()
+
+ except :
+ self.error("Png module have not been found!","warning")
+
+
################################################################################
###
@@ -4503,6 +6626,7 @@ G01 Z1 (going to cutting z)\n""",
###
################################################################################
def effect(self) :
+ start_time = time.time()
global options
options = self.options
options.self = self
@@ -4523,12 +6647,19 @@ G01 Z1 (going to cutting z)\n""",
if self.options.active_tab == '"help"' :
self.help()
return
- elif self.options.active_tab not in ['"dxfpoints"','"path-to-gcode"', '"area"', '"area_artefacts"', '"engraving"', '"orientation"', '"tools_library"', '"lathe"', '"offset"', '"arrangement"', '"update"']:
- self.error(_("Select one of the active tabs - Path to Gcode, Area, Engraving, DXF points, Orientation, Offset, Lathe or Tools library."),"error")
+ elif self.options.active_tab == '"about"' :
+ self.help()
+ return
+
+ elif self.options.active_tab == '"test"' :
+ self.test()
+
+ elif self.options.active_tab not in ['"dxfpoints"','"path-to-gcode"', '"area_fill"', '"area"', '"area_artefacts"', '"engraving"', '"orientation"', '"tools_library"', '"lathe"', '"offset"', '"arrangement"', '"update"', '"graffiti"', '"lathe_modify_path"', '"plasma-prepare-path"']:
+ self.error(_("Select one of the action tabs - Path to Gcode, Area, Engraving, DXF points, Orientation, Offset, Lathe or Tools library.\n Current active tab id is %s" % self.options.active_tab),"error")
else:
# Get all Gcodetools data from the scene.
self.get_info()
- if self.options.active_tab in ['"dxfpoints"','"path-to-gcode"', '"area"', '"area_artefacts"', '"engraving"', '"lathe"']:
+ if self.options.active_tab in ['"dxfpoints"','"path-to-gcode"', '"area_fill"', '"area"', '"area_artefacts"', '"engraving"', '"lathe"', '"graffiti"', '"plasma-prepare-path"']:
if self.orientation_points == {} :
self.error(_("Orientation points have not been defined! A default set of orientation points has been automatically added."),"warning")
self.orientation( self.layers[min(1,len(self.layers)-1)] )
@@ -4540,6 +6671,8 @@ G01 Z1 (going to cutting z)\n""",
self.get_info()
if self.options.active_tab == '"path-to-gcode"':
self.path_to_gcode()
+ elif self.options.active_tab == '"area_fill"':
+ self.area_fill()
elif self.options.active_tab == '"area"':
self.area()
elif self.options.active_tab == '"area_artefacts"':
@@ -4550,6 +6683,8 @@ G01 Z1 (going to cutting z)\n""",
self.engraving()
elif self.options.active_tab == '"orientation"':
self.orientation()
+ elif self.options.active_tab == '"graffiti"':
+ self.graffiti()
elif self.options.active_tab == '"tools_library"':
if self.options.tools_library_type != "check":
self.tools_library()
@@ -4557,6 +6692,8 @@ G01 Z1 (going to cutting z)\n""",
self.check_tools_and_op()
elif self.options.active_tab == '"lathe"':
self.lathe()
+ elif self.options.active_tab == '"lathe_modify_path"':
+ self.lathe_modify_path()
elif self.options.active_tab == '"update"':
self.update()
elif self.options.active_tab == '"offset"':
@@ -4582,7 +6719,7 @@ G01 Z1 (going to cutting z)\n""",
offsets_count += 1
if offset_ != [] :
for iii in offset_ :
- csp_draw([iii], color="Green", width=1)
+ draw_csp([iii], color="Green", width=1)
#print_(offset_)
else :
print_("------------Reached empty offset at radius %s"% offset )
@@ -4597,7 +6734,17 @@ G01 Z1 (going to cutting z)\n""",
print_("Total offsets count %s"%offsets_count)
elif self.options.active_tab == '"arrangement"':
self.arrangement()
+
+ elif self.options.active_tab == '"plasma-prepare-path"':
+ self.plasma_prepare_path()
+
+
+ print_("------------------------------------------")
+ print_("Done in %f seconds"%(time.time()-start_time))
+ print_("End at %s."%time.strftime("%d.%m.%Y %H:%M:%S"))
+
+
#
-e = Gcodetools()
-e.affect()
+gcodetools = Gcodetools()
+gcodetools.affect()
diff --git a/share/extensions/gcodetools_about.inx b/share/extensions/gcodetools_about.inx
new file mode 100644
index 000000000..3dd983835
--- /dev/null
+++ b/share/extensions/gcodetools_about.inx
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
+ <name>About</name>
+ <id>ru.cnc-club.filter.gcodetools_about_no_options_no_preferences</id>
+ <dependency type="executable" location="extensions">gcodetools.py</dependency>
+ <dependency type="executable" location="extensions">inkex.py</dependency>
+ <param name='active-tab' type="notebook">
+
+ <page name='about' _gui-text='About'>
+ <_param name="help" type="description">Gcodetools was developed to make simple Gcode from Inkscape's paths. Gcode is a special format which is used in most of CNC machines. So Gcodetools allows you to use Inkscape as CAM program.
+
+It can be use with a lot of machone types:
+ Mills
+ Lathes
+ Laser and Palsma cutters and engravers
+ Mill engravers
+ Plotters
+ etc.
+
+To get more info visit developers page at http://www.cnc-club.ru/gcodetools</_param>
+ </page>
+
+ <page name='help' _gui-text='Help'>
+ <_param name="fullhelp" type="description">
+Gcodetools plug-in: converts paths to Gcode (using circular interpolation), makes offset paths and engraves sharp corners using cone cutters.
+This plug-in calculates Gcode for paths using circular interpolation or linear motion when needed.
+
+Tutorials, manuals and support can be found at
+English support forum:
+ http://www.cnc-club.ru/gcodetools
+
+and Russian support forum:
+ http://www.cnc-club.ru/gcodetoolsru
+
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
+
+Gcodetools ver. 1.7
+</_param>
+
+ </page>
+
+ </param>
+ <effect>
+ <effects-menu>
+ <submenu _name="Gcodetools"/>
+ </effects-menu>
+ <object-type>path</object-type>
+ </effect>
+ <script>
+ <command reldir="extensions" interpreter="python">gcodetools.py</command>
+ </script>
+</inkscape-extension>
diff --git a/share/extensions/gcodetools_all_in_one.inx b/share/extensions/gcodetools_all_in_one.inx
deleted file mode 100644
index 85d7cfbee..000000000
--- a/share/extensions/gcodetools_all_in_one.inx
+++ /dev/null
@@ -1,194 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>All in one</_name>
- <id>ru.cnc-club.filter.gcodetools_ptg_area_area_artefacts_engraving_dxfpoints_tools_library_orientation</id>
- <dependency type="executable" location="extensions">gcodetools.py</dependency>
- <dependency type="executable" location="extensions">inkex.py</dependency>
- <param name='active-tab' type="notebook">
-
- <page name='path-to-gcode' _gui-text='Path to Gcode'>
- <param name="biarc-tolerance" type='float' precision="5" _gui-text='Biarc interpolation tolerance:'>1</param>
- <param name="biarc-max-split-depth" type="int" _gui-text="Maximum splitting depth:">4</param>
- <_param name="help" type="description">
-Biarc interpolation tolerance is the maximum distance between path and its approximation.
-The segment will be split into two segments if the distance between path's segment and it's approximation exceeds biarc interpolation tolerance.
-</_param>
- </page>
-
- <page name='area' msgctxt="gcodetools extension" _gui-text='Area'>
- <param name="max-area-curves" type="int" min="0" max="1000" _gui-text="Maximum area cutting curves:">100</param>
- <param name="area-inkscape-radius" type="float" min="-1000" max="1000" _gui-text="Area width:">-10</param>
-
- <_param name="help" type="description">
-"Create area offset": creates several Inkscape path offsets to fill original path's area up to "Area radius" value.
-
-Outlines start from "1/2 D" up to "Area width" total width with "D" steps where D is taken from the nearest tool definition ("Tool diameter" value).
-Only one offset will be created if the "Area width" is equal to "1/2 D".
- </_param>
- </page>
-
- <page name='area_artefacts' _gui-text='Area artefacts'>
- <param name="area-find-artefacts-diameter" type="float" min="0.01" max="1000" _gui-text="Artefact diameter:">5.0</param>
- <param name="area-find-artefacts-action" type="optiongroup" _gui-text="Action:">
- <_option value="mark with an arrow">mark with an arrow</_option>
- <_option value="mark with style">mark with style</_option>
- <_option value="delete">delete</_option>
- </param>
- <_param name="help" type="description">
-Usage:
-1. Select all Area Offsets (gray outlines)
-2. Object/Ungroup (Shift+Ctrl+G)
-3. Press Apply
-
-Suspected small objects will be marked out by colored arrows.
- </_param>
- </page>
-
- <page name='engraving' _gui-text='Engraving'>
- <param name="engraving-sharp-angle-tollerance" type="float" precision="5" min="0" max="180" _gui-text="Sharp angle tolerance:">150</param>
- <param name="engraving-max-dist" type="float" precision="5" min="0" max="1000" _gui-text="Maximum distance for engraving:">10</param>
- <param name="engraving-newton-iterations" type="int" min="2" max="10" _gui-text="Number of sample points used to calculate distance:">4</param>
- <param name="engraving-draw-calculation-paths" type="boolean" _gui-text="Draw additional graphics to debug engraving path:">false</param>
-
- <_param name="help" type="description">
-This function creates path to engrave sharp angles.
-Cutter's shape function is defined by the tool. Some simple shapes:
-
-cone....(45 degrees)...........: w
-cone....(height/diameter=10/3).: 10/3 w
-sphere..("r" diameter).........: math.sqrt(max(0,r**2-w**2))
-ellipse.(R1=r and R2=r*4r).....: math.sqrt(max(0,r**2-w**2))*4</_param>
- </page>
-
- <page name='dxfpoints' _gui-text='DXF points'>
- <_param name="help" type="description">
-
-Convert selected objects to drill points (as dxf_import plugin does). Also you can save original shape. Only the start point of each curve will be used.
-
-Also you can manually select object, open XML editor (Shift+Ctrl+X) and add or remove XML tag 'dxfpoint' with any value.
- </_param>
- <param type='optiongroup' name='dxfpoints-action' _gui-text="Convert selection:">
-<_option value='save'>set as dxfpoint and save shape</_option>
-<_option value='replace'>set as dxfpoint and draw arrow</_option>
-<_option value='clear'>clear dxfpoint sign</_option>
- </param>
-
- </page>
-
- <page name='tools_library' _gui-text='Tools library'>
-
- <param type='optiongroup' name='tools-library-type' _gui-text="Tools type:">
-<_option value='default tool'>default</_option>
-<_option value='cylinder cutter'>cylinder</_option>
-<_option value='cone cutter'>cone</_option>
-<_option value='plasma cutter'>plasma</_option>
-<_option value='tangent knife'>tangent knife</_option>
-<_option value='lathe cutter'>lathe cutter</_option>
-
-<_option value='check'>Just check tools</_option>
-
- </param>
-
- <_param name="help" type="description">
-Selected tool type fills appropriate default values. You can change these values using the Text tool later on.
-
-The topmost (z order) tool in the active layer is used. If there is no tool inside the current layer it is taken from the upper layer.
-
-Press Apply to create new tool.
- </_param>
- </page>
-
- <page name='orientation' _gui-text='Orientation'>
-
- <param name="orientation-points-count" type="optiongroup" _gui-text="Orientation type:">
-<_option value="2">2-points mode
-(move and rotate,
-maintained aspect ratio X/Y)</_option>
-<_option value="3">3-points mode
-(move, rotate and mirror,
-different X/Y scale)</_option>
- </param>
- <param name="Zsurface" type="float" precision="5" min="-1000" max="1000" _gui-text="Z surface:">0</param>
- <param name="Zdepth" type="float" precision="5" min="-1000" max="1000" _gui-text="Z depth:">-1</param>
- <param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
- </param>
-
- <_param name="help" type="description">
-Orientation points are used to calculate transformation (offset,scale,mirror,rotation in XY plane) of the path.
-3-points mode only: do not put all three into one line (use 2-points mode instead).
-
-You can modify Z surface, Z depth values later using text tool (3rd coordinates).
-
-If there are no orientation points inside current layer they are taken from the upper layer.
-
-Do not ungroup orientation points! You can select them using double click to enter the group or by Ctrl+Click.
-
-Now press apply to create control points (independent set for each layer).
- </_param>
- </page>
-
- <page name='options' _gui-text='Options'>
- <param name="Zscale" type="float" precision="5" min="-100000" max="100000" _gui-text="Scale along Z axis:">1</param>
- <param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
- <param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
- <param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
- </page>
-
- <page name='preferences' _gui-text='Preferences'>
- <param name="filename" type="string" _gui-text="File:">output.ngc</param>
- <param name="add-numeric-suffix-to-filename" type="boolean" _gui-text="Add numeric suffix to filename">true</param>
-
- <param name="directory" type="string" _gui-text="Directory:">/home</param>
-
- <param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
- <param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
- </param>
- <param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
- </param>
- <param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
-
-
- <param name="create-log" type="boolean" _gui-text="Generate log file">false</param>
- <param name="log-filename" type="string" _gui-text="Full path to log file:"></param>
-
- </page>
-
- <page name='help' _gui-text='Help'>
- <_param name="fullhelp" type="description">
-Gcodetools plug-in: converts paths to Gcode (using circular interpolation), makes offset paths and engraves sharp corners using cone cutters.
-This plug-in calculates Gcode for paths using circular interpolation or linear motion when needed.
-
-Tutorials, manuals and support can be found at
-English support forum:
- http://www.cnc-club.ru/gcodetools
-
-and Russian support forum:
- http://www.cnc-club.ru/gcodetoolsru
-
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
-
-Gcodetools ver. 1.6.01
-</_param>
-
- </page>
-
- </param>
- <effect>
- <effects-menu>
- <submenu _name="Gcodetools"/>
- </effects-menu>
- <object-type>path</object-type>
- </effect>
- <script>
- <command reldir="extensions" interpreter="python">gcodetools.py</command>
- </script>
-
-</inkscape-extension>
diff --git a/share/extensions/gcodetools_area.inx b/share/extensions/gcodetools_area.inx
index 53ceeafaa..9f4a083d4 100644
--- a/share/extensions/gcodetools_area.inx
+++ b/share/extensions/gcodetools_area.inx
@@ -1,14 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Area</_name>
- <id>ru.cnc-club.filter.gcodetools_area_area_artefacts_ptg</id>
+ <name>Area</name>
+ <id>ru.cnc-club.filter.gcodetools_area_area_fill_area_artefacts_ptg</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
<param name='active-tab' type="notebook">
- <page name='area' msgctxt="gcodetools extension" _gui-text='Area'>
+ <page name='area' _gui-text='Area'>
<param name="max-area-curves" type="int" min="0" max="1000" _gui-text="Maximum area cutting curves:">100</param>
<param name="area-inkscape-radius" type="float" min="-1000" max="1000" _gui-text="Area width:">-10</param>
+ <param name="area-tool-overlap" type="float" min="0" max="1" _gui-text="Area tool overlap (0..0.9):">0</param>
<_param name="help" type="description">
"Create area offset": creates several Inkscape path offsets to fill original path's area up to "Area radius" value.
@@ -18,8 +20,18 @@ Only one offset will be created if the "Area width" is equal to "1/2 D".
</_param>
</page>
- <page name='area_artefacts' _gui-text='Area artefacts'>
- <param name="area-find-artefacts-diameter" type="float" min="0.01" max="1000" _gui-text="Artefact diameter:">5.0</param>
+ <page name='area_fill' _gui-text='Fill area'>
+ <param name="area-fill-angle" type="float" min="-360" max="360" _gui-text="Area fill anlge">0</param>
+ <param name="area-fill-shift" type="float" min="-1" max="1" _gui-text="Area fill shift">0</param>
+ <param name="area-fill-method" type="float" min="-1" max="1" _gui-text="Area fill shift">0</param>
+ <param name="area-fill-method" _gui-text="Filling method" type="optiongroup">
+ <_option value="zig-zag">Zig zag</_option>
+ <_option value="spiral">Spiral</_option>
+ </param>
+ </page>
+
+ <page name='area_artefacts' _gui-text='Area artifacts'>
+ <param name="area-find-artefacts-diameter" type="float" min="0.01" max="1000" _gui-text="Artifact diameter:">5.0</param>
<param name="area-find-artefacts-action" type="optiongroup" _gui-text="Action:">
<_option value="mark with an arrow">mark with an arrow</_option>
<_option value="mark with style">mark with style</_option>
@@ -38,9 +50,19 @@ Suspected small objects will be marked out by colored arrows.
<page name='path-to-gcode' _gui-text='Path to Gcode'>
<param name="biarc-tolerance" type='float' precision="5" _gui-text='Biarc interpolation tolerance:'>1</param>
<param name="biarc-max-split-depth" type="int" _gui-text="Maximum splitting depth:">4</param>
+ <param name="path-to-gcode-order" _gui-text="Cutting order" type="optiongroup" appearance="minimal">
+ <_option value="subpath by subpath">Subpath by subpath</_option>
+ <_option value="path by path">Path by path</_option>
+ <_option value="pass by pass">Pass by Pass</_option>
+ </param>
+
+ <param name="path-to-gcode-depth-function" type="string" _gui-text="Depth function:">d</param>
+ <param name="path-to-gcode-sort-paths" type="boolean" _gui-text="Sort paths to reduse rapid distance">True</param>
+
<_param name="help" type="description">
Biarc interpolation tolerance is the maximum distance between path and its approximation.
-The segment will be split into two segments if the distance between path's segment and it's approximation exceeds biarc interpolation tolerance.
+The segment will be split into two segments if the distance between path's segment and its approximation exceeds biarc interpolation tolerance.
+For depth function c=color intensity from 0.0 (white) to 1.0 (black), d is the depth defined by orientation points, s - surface defined by orientation points.
</_param>
</page>
@@ -49,6 +71,9 @@ The segment will be split into two segments if the distance between path's segme
<param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
<param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
<param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
+ <param name="comment-gcode" type="string" _gui-text="Comment Gcode:"></param>
+ <param name="comment-gcode-from-properties" type="boolean" _gui-text="Get additional comments from object's properties">False</param>
+
</page>
<page name='preferences' _gui-text='Preferences'>
@@ -59,14 +84,15 @@ The segment will be split into two segments if the distance between path's segme
<param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
</param>
<param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
@@ -88,9 +114,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -105,5 +131,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_check_for_updates.inx b/share/extensions/gcodetools_check_for_updates.inx
index 728f5d1e6..ef0313ecf 100644
--- a/share/extensions/gcodetools_check_for_updates.inx
+++ b/share/extensions/gcodetools_check_for_updates.inx
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Check for updates</_name>
+ <name>Check for updates</name>
<id>ru.cnc-club.filter.gcodetools_update_no_options_no_preferences</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
@@ -22,9 +23,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -39,5 +40,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_dxf_points.inx b/share/extensions/gcodetools_dxf_points.inx
index 7283853f9..cccd64497 100644
--- a/share/extensions/gcodetools_dxf_points.inx
+++ b/share/extensions/gcodetools_dxf_points.inx
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>DXF Points</_name>
+ <name>DXF Points</name>
<id>ru.cnc-club.filter.gcodetools_dxfpoints_no_options</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
@@ -29,14 +30,15 @@ Also you can manually select object, open XML editor (Shift+Ctrl+X) and add or r
<param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
</param>
<param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
@@ -58,9 +60,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -75,5 +77,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_engraving.inx b/share/extensions/gcodetools_engraving.inx
index 8645faa27..e278f64bc 100644
--- a/share/extensions/gcodetools_engraving.inx
+++ b/share/extensions/gcodetools_engraving.inx
@@ -1,25 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Engraving</_name>
+ <name>Engraving</name>
<id>ru.cnc-club.filter.gcodetools_engraving</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
<param name='active-tab' type="notebook">
<page name='engraving' _gui-text='Engraving'>
- <param name="engraving-sharp-angle-tollerance" type="float" precision="5" min="0" max="180" _gui-text="Sharp angle tolerance:">150</param>
- <param name="engraving-max-dist" type="float" precision="5" min="0" max="1000" _gui-text="Maximum distance for engraving:">10</param>
- <param name="engraving-newton-iterations" type="int" min="2" max="10" _gui-text="Number of sample points used to calculate distance:">4</param>
- <param name="engraving-draw-calculation-paths" type="boolean" _gui-text="Draw additional graphics to debug engraving path">false</param>
+ <param name="engraving-sharp-angle-tollerance" type="float" precision="5" min="150" max="180" _gui-text="Smooth convex corners between this value and 180 degrees:">175</param>
+ <param name="engraving-max-dist" type="float" precision="5" min="0" max="1000" _gui-text="Maximum distance for engraving (mm/inch):">10</param>
+ <param name="engraving-newton-iterations" type="int" min="2" max="10" _gui-text="Accuracy factor (2 low to 10 high):">4</param>
+ <param name="engraving-draw-calculation-paths" type="boolean" _gui-text="Draw additional graphics to see engraving path">false</param>
<_param name="help" type="description">
-This function creates path to engrave sharp angles.
-Cutter's shape function is defined by the tool. Some simple shapes:
+This function creates path to engrave letters or any shape with sharp angles.
+Cutter's depth as a function of radius is defined by the tool.
+Depth may be any Python expression. For instance:
-cone....(45 degrees)...........: w
-cone....(height/diameter=10/3).: 10/3 w
-sphere..("r" diameter).........: math.sqrt(max(0,r**2-w**2))
-ellipse.(R1=r and R2=r*4r).....: math.sqrt(max(0,r**2-w**2))*4</_param>
+cone....(45 degrees)......................: w
+cone....(height/diameter=10/3)..: 10*w/3
+sphere..(radius r)...........................: math.sqrt(max(0,r**2-w**2))
+ellipse.(minor axis r, major 4r).....: math.sqrt(max(0,r**2-w**2))*4</_param>
</page>
<page name='options' _gui-text='Options'>
@@ -27,6 +29,9 @@ ellipse.(R1=r and R2=r*4r).....: math.sqrt(max(0,r**2-w**2))*4</_param>
<param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
<param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
<param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
+ <param name="comment-gcode" type="string" _gui-text="Comment Gcode:"></param>
+ <param name="comment-gcode-from-properties" type="boolean" _gui-text="Get additional comments from object's properties">False</param>
+
</page>
<page name='preferences' _gui-text='Preferences'>
@@ -37,14 +42,15 @@ ellipse.(R1=r and R2=r*4r).....: math.sqrt(max(0,r**2-w**2))*4</_param>
<param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
</param>
<param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
@@ -66,9 +72,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -83,5 +89,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_graffiti.inx b/share/extensions/gcodetools_graffiti.inx
new file mode 100644
index 000000000..73235ee16
--- /dev/null
+++ b/share/extensions/gcodetools_graffiti.inx
@@ -0,0 +1,119 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
+ <name>Graffiti</name>
+ <id>ru.cnc-club.filter.gcodetools_graffiti_orientation</id>
+ <dependency type="executable" location="extensions">gcodetools.py</dependency>
+ <dependency type="executable" location="extensions">inkex.py</dependency>
+ <param name='active-tab' type="notebook">
+
+ <page name='graffiti' _gui-text='Graffiti'>
+ <param name="graffiti-max-seg-length" type="float" precision="5" min="0" max="1000" _gui-text="Maximum segment length:">10</param>
+ <param name="graffiti-min-radius" type="float" precision="5" min="0" max="1000" _gui-text="Minimal connector radius:">10</param>
+ <param name="graffiti-start-pos" type="string" _gui-text="Start position (x;y):">(0.0;0.0)</param>
+ <param name="graffiti-create-preview" type="boolean" _gui-text="Create preview">true</param>
+ <param name="graffiti-create-linearization-preview" type="boolean" _gui-text="Create linearization preview">true</param>
+ <param name="graffiti-preview-size" type="int" min="100" max="10000" _gui-text="Preview's size (px):">800</param>
+ <param name="graffiti-preview-emmit" type="int" min="100" max="10000" _gui-text="Preview's paint emmit (pts/s):">1000</param>
+ </page>
+
+ <page name='orientation' _gui-text='Orientation'>
+
+ <param name="orientation-points-count" type="optiongroup" _gui-text="Orientation type:">
+<_option value="2">2-points mode
+(move and rotate,
+maintained aspect ratio X/Y)</_option>
+<_option value="3">3-points mode
+(move, rotate and mirror,
+different X/Y scale)</_option>
+<_option value="graffiti">graffiti points</_option>
+<_option value="in-out reference point">in-out reference point</_option>
+
+ </param>
+ <param name="Zsurface" type="float" precision="5" min="-1000" max="1000" _gui-text="Z surface:">0</param>
+ <param name="Zdepth" type="float" precision="5" min="-1000" max="1000" _gui-text="Z depth:">-1</param>
+ <param name="unit" type="enum" _gui-text="Units (mm or in):">
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
+ </param>
+
+ <_param name="help" type="description">
+Orientation points are used to calculate transformation (offset,scale,mirror,rotation in XY plane) of the path.
+3-points mode only: do not put all three into one line (use 2-points mode instead).
+
+You can modify Z surface, Z depth values later using text tool (3rd coordinates).
+
+If there are no orientation points inside current layer they are taken from the upper layer.
+
+Do not ungroup orientation points! You can select them using double click to enter the group or by Ctrl+Click.
+
+Now press apply to create control points (independent set for each layer).
+ </_param>
+ </page>
+
+ <page name='options' _gui-text='Options'>
+ <param name="Zscale" type="float" precision="5" min="-100000" max="100000" _gui-text="Scale along Z axis:">1</param>
+ <param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
+ <param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
+ <param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
+ <param name="comment-gcode" type="string" _gui-text="Comment Gcode:"></param>
+ <param name="comment-gcode-from-properties" type="boolean" _gui-text="Get additional comments from object's properties">False</param>
+
+ </page>
+
+ <page name='preferences' _gui-text='Preferences'>
+ <param name="filename" type="string" _gui-text="File:">output.ngc</param>
+ <param name="add-numeric-suffix-to-filename" type="boolean" _gui-text="Add numeric suffix to filename">true</param>
+
+ <param name="directory" type="string" _gui-text="Directory:">/home</param>
+
+ <param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
+ <param name="unit" type="enum" _gui-text="Units (mm or in):">
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
+ </param>
+ <param name="postprocessor" type="enum" _gui-text="Post-processor:">
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
+ </param>
+ <param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
+
+
+ <param name="create-log" type="boolean" _gui-text="Generate log file">false</param>
+ <param name="log-filename" type="string" _gui-text="Full path to log file:"></param>
+
+ </page>
+
+ <page name='help' _gui-text='Help'>
+ <_param name="fullhelp" type="description">
+Gcodetools plug-in: converts paths to Gcode (using circular interpolation), makes offset paths and engraves sharp corners using cone cutters.
+This plug-in calculates Gcode for paths using circular interpolation or linear motion when needed.
+
+Tutorials, manuals and support can be found at
+English support forum:
+ http://www.cnc-club.ru/gcodetools
+
+and Russian support forum:
+ http://www.cnc-club.ru/gcodetoolsru
+
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
+
+Gcodetools ver. 1.7
+</_param>
+
+ </page>
+
+ </param>
+ <effect>
+ <effects-menu>
+ <submenu _name="Gcodetools"/>
+ </effects-menu>
+ <object-type>path</object-type>
+ </effect>
+ <script>
+ <command reldir="extensions" interpreter="python">gcodetools.py</command>
+ </script>
+</inkscape-extension>
diff --git a/share/extensions/gcodetools_lathe.inx b/share/extensions/gcodetools_lathe.inx
index 933073649..a45896f3e 100644
--- a/share/extensions/gcodetools_lathe.inx
+++ b/share/extensions/gcodetools_lathe.inx
@@ -1,7 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Lathe</_name>
- <id>ru.cnc-club.filter.gcodetools_lathe_ptg</id>
+ <name>Lathe</name>
+ <id>ru.cnc-club.filter.gcodetools_lathe_lathe_modify_path_ptg</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
<param name='active-tab' type="notebook">
@@ -11,21 +12,37 @@
<param name="lathe-fine-cut-width" type="float" precision="5" min="0" max="1000" _gui-text="Fine cut width:">1</param>
<param name="lathe-fine-cut-count" type="int" min="0" max="1000" _gui-text="Fine cut count:">1</param>
<param name="lathe-create-fine-cut-using" _gui-text="Create fine cut using:" type="optiongroup" appearance="minimal">
- <option value="Move path">Move path</option>
- <option value="Offset path">Offset path</option>
+ <_option value="Move path">Move path</_option>
+ <_option value="Offset path">Offset path</_option>
</param>
<param name="lathe-x-axis-remap" type="string" _gui-text="Lathe X axis remap:">X</param>
<param name="lathe-z-axis-remap" type="string" _gui-text="Lathe Z axis remap:">Z</param>
+ </page>
-
+ <page name='lathe_modify_path' _gui-text='Lathe modify path'>
+ <_param name="help" type="description">
+ This function modifies path so it will be able to be cut with the rectangular cutter.
+ </_param>
+ <param name="lathe-rectangular-cutter-width" type="float" precision="5" min="0" max="1000" _gui-text="Lathe width:">4</param>
</page>
+
<page name='path-to-gcode' _gui-text='Path to Gcode'>
<param name="biarc-tolerance" type='float' precision="5" _gui-text='Biarc interpolation tolerance:'>1</param>
<param name="biarc-max-split-depth" type="int" _gui-text="Maximum splitting depth:">4</param>
+ <param name="path-to-gcode-order" _gui-text="Cutting order" type="optiongroup" appearance="minimal">
+ <_option value="subpath by subpath">Subpath by subpath</_option>
+ <_option value="path by path">Path by path</_option>
+ <_option value="pass by pass">Pass by Pass</_option>
+ </param>
+
+ <param name="path-to-gcode-depth-function" type="string" _gui-text="Depth function:">d</param>
+ <param name="path-to-gcode-sort-paths" type="boolean" _gui-text="Sort paths to reduse rapid distance">True</param>
+
<_param name="help" type="description">
Biarc interpolation tolerance is the maximum distance between path and its approximation.
-The segment will be split into two segments if the distance between path's segment and it's approximation exceeds biarc interpolation tolerance.
+The segment will be split into two segments if the distance between path's segment and its approximation exceeds biarc interpolation tolerance.
+For depth function c=color intensity from 0.0 (white) to 1.0 (black), d is the depth defined by orientation points, s - surface defined by orientation points.
</_param>
</page>
@@ -34,24 +51,28 @@ The segment will be split into two segments if the distance between path's segme
<param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
<param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
<param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
+ <param name="comment-gcode" type="string" _gui-text="Comment Gcode:"></param>
+ <param name="comment-gcode-from-properties" type="boolean" _gui-text="Get additional comments from object's properties">False</param>
+
</page>
<page name='preferences' _gui-text='Preferences'>
- <param name="filename" type="string" _gui-text="File">output.ngc</param>
+ <param name="filename" type="string" _gui-text="File:">output.ngc</param>
<param name="add-numeric-suffix-to-filename" type="boolean" _gui-text="Add numeric suffix to filename">true</param>
<param name="directory" type="string" _gui-text="Directory:">/home</param>
<param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
</param>
<param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
@@ -73,9 +94,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -90,5 +111,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_orientation_points.inx b/share/extensions/gcodetools_orientation_points.inx
index 997b24d9b..3de8ba594 100644
--- a/share/extensions/gcodetools_orientation_points.inx
+++ b/share/extensions/gcodetools_orientation_points.inx
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Orientation points</_name>
+ <name>Orientation points</name>
<id>ru.cnc-club.filter.gcodetools_orientation_no_options_no_preferences</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
@@ -15,12 +16,15 @@ maintained aspect ratio X/Y)</_option>
<_option value="3">3-points mode
(move, rotate and mirror,
different X/Y scale)</_option>
+<_option value="graffiti">graffiti points</_option>
+<_option value="in-out reference point">in-out reference point</_option>
+
</param>
<param name="Zsurface" type="float" precision="5" min="-1000" max="1000" _gui-text="Z surface:">0</param>
<param name="Zdepth" type="float" precision="5" min="-1000" max="1000" _gui-text="Z depth:">-1</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<_param name="help" type="description">
@@ -49,9 +53,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -66,5 +70,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_path_to_gcode.inx b/share/extensions/gcodetools_path_to_gcode.inx
index 1be758370..16ac68ab8 100644
--- a/share/extensions/gcodetools_path_to_gcode.inx
+++ b/share/extensions/gcodetools_path_to_gcode.inx
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Path to Gcode</_name>
+ <name>Path to Gcode</name>
<id>ru.cnc-club.filter.gcodetools_ptg</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
@@ -9,9 +10,19 @@
<page name='path-to-gcode' _gui-text='Path to Gcode'>
<param name="biarc-tolerance" type='float' precision="5" _gui-text='Biarc interpolation tolerance:'>1</param>
<param name="biarc-max-split-depth" type="int" _gui-text="Maximum splitting depth:">4</param>
+ <param name="path-to-gcode-order" _gui-text="Cutting order" type="optiongroup" appearance="minimal">
+ <_option value="subpath by subpath">Subpath by subpath</_option>
+ <_option value="path by path">Path by path</_option>
+ <_option value="pass by pass">Pass by Pass</_option>
+ </param>
+
+ <param name="path-to-gcode-depth-function" type="string" _gui-text="Depth function:">d</param>
+ <param name="path-to-gcode-sort-paths" type="boolean" _gui-text="Sort paths to reduse rapid distance">True</param>
+
<_param name="help" type="description">
Biarc interpolation tolerance is the maximum distance between path and its approximation.
-The segment will be split into two segments if the distance between path's segment and it's approximation exceeds biarc interpolation tolerance.
+The segment will be split into two segments if the distance between path's segment and its approximation exceeds biarc interpolation tolerance.
+For depth function c=color intensity from 0.0 (white) to 1.0 (black), d is the depth defined by orientation points, s - surface defined by orientation points.
</_param>
</page>
@@ -20,6 +31,9 @@ The segment will be split into two segments if the distance between path's segme
<param name="Zoffset" type="float" precision="5" min="-100000" max="100000" _gui-text="Offset along Z axis:">0.0</param>
<param name="auto_select_paths" type="boolean" _gui-text="Select all paths if nothing is selected">true</param>
<param name="min-arc-radius" type="float" precision="5" min="-1000" max="1000" _gui-text="Minimum arc radius:">0.05</param>
+ <param name="comment-gcode" type="string" _gui-text="Comment Gcode:"></param>
+ <param name="comment-gcode-from-properties" type="boolean" _gui-text="Get additional comments from object's properties">False</param>
+
</page>
<page name='preferences' _gui-text='Preferences'>
@@ -30,14 +44,15 @@ The segment will be split into two segments if the distance between path's segme
<param name="Zsafe" type="float" precision="5" min="-1000" max="1000" _gui-text="Z safe height for G00 move over blank:">5</param>
<param name="unit" type="enum" _gui-text="Units (mm or in):">
- <item value="G21 (All units in mm)">mm</item>
- <item value="G20 (All units in inches)">in</item>
+ <_item value="G21 (All units in mm)">mm</_item>
+ <_item value="G20 (All units in inches)">in</_item>
</param>
<param name="postprocessor" type="enum" _gui-text="Post-processor:">
- <item value=" ">None</item>
- <item value="parameterize();">Parameterize Gcode</item>
- <item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</item>
- <item value="round(4);">Round all values to 4 digits</item>
+ <_item value=" ">None</_item>
+ <_item value="parameterize();">Parameterize Gcode</_item>
+ <_item value="flip(y);parameterize();">Flip y axis and parameterize Gcode</_item>
+ <_item value="round(4);">Round all values to 4 digits</_item>
+ <_item value='regex("G01 Z([0-9\.\-]+).*\(Penetrate\)", lambda match: "G00 Z%f (Fast pre-penetrate)\n%s" %(float(match.group(1))+5, match.group(0)));'>Fast pre-penetrate</_item>
</param>
<param name="postprocessor-custom" type="string" _gui-text="Additional post-processor:"></param>
@@ -59,9 +74,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -76,5 +91,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/gcodetools_prepare_path_for_plasma.inx b/share/extensions/gcodetools_prepare_path_for_plasma.inx
new file mode 100644
index 000000000..c3e46c8ac
--- /dev/null
+++ b/share/extensions/gcodetools_prepare_path_for_plasma.inx
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
+ <name>Prepare path for plasma</name>
+ <id>ru.cnc-club.filter.gcodetools_plasma-prepare-path_no_options_no_preferences</id>
+ <dependency type="executable" location="extensions">gcodetools.py</dependency>
+ <dependency type="executable" location="extensions">inkex.py</dependency>
+ <param name='active-tab' type="notebook">
+
+ <page name='plasma-prepare-path' _gui-text='Prepare path for plasma or laser cuters'>
+ <param name='in-out-path' type="boolean" _gui-text="Create in-out paths" >True</param>
+ <param name='in-out-path-len' type="float" precision="5" min="0" max="1000000" _gui-text='In-out path length:'>10</param>
+ <param name='in-out-path-point-max-dist' type="float" precision="5" min="0" max="1000000" _gui-text='In-out path max distance to reference point:'>10</param>
+ <param name="in-out-path-type" _gui-text="In-out path type:" type="optiongroup" appearance="minimal">
+ <_option value="Round">Round</_option>
+ <_option value="Perpendicular">Perpendicular</_option>
+ <_option value="Tangent">Tangent</_option>
+ </param>
+ <param name='in-out-path-radius' type="float" precision="5" min="0" max="1000000" _gui-text='In-out path radius for round path:'>10</param>
+ <param name='in-out-path-replace-original-path' type="boolean" _gui-text="Replace original path" >False</param>
+ <param name='in-out-path-do-not-add-reference-point' type="boolean" _gui-text="Do not add in-out reference points" >False</param>
+
+ <_param name="help" type="description">-------------------------------------------------</_param>
+ <param name='plasma-prepare-corners' type="boolean" _gui-text="Prepare corners" >True</param>
+ <param name='plasma-prepare-corners-distance' type="float" precision="5" min="0" max="1000000" _gui-text='Stepout distance for corners:'>10</param>
+ <param name='plasma-prepare-corners-tolerance' type="float" precision="5" min="0" max="180" _gui-text='Maximum angle for corner (0-180 deg):'>140</param>
+
+
+
+ </page>
+
+ <page name='help' _gui-text='Help'>
+ <_param name="fullhelp" type="description">
+Gcodetools plug-in: converts paths to Gcode (using circular interpolation), makes offset paths and engraves sharp corners using cone cutters.
+This plug-in calculates Gcode for paths using circular interpolation or linear motion when needed.
+
+Tutorials, manuals and support can be found at
+English support forum:
+ http://www.cnc-club.ru/gcodetools
+
+and Russian support forum:
+ http://www.cnc-club.ru/gcodetoolsru
+
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
+
+Gcodetools ver. 1.7
+</_param>
+
+ </page>
+
+ </param>
+ <effect>
+ <effects-menu>
+ <submenu _name="Gcodetools"/>
+ </effects-menu>
+ <object-type>path</object-type>
+ </effect>
+ <script>
+ <command reldir="extensions" interpreter="python">gcodetools.py</command>
+ </script>
+</inkscape-extension>
diff --git a/share/extensions/gcodetools_tools_library.inx b/share/extensions/gcodetools_tools_library.inx
index 4d15dc52c..aefd4b896 100644
--- a/share/extensions/gcodetools_tools_library.inx
+++ b/share/extensions/gcodetools_tools_library.inx
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
+
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
- <_name>Tools library</_name>
+ <name>Tools library</name>
<id>ru.cnc-club.filter.gcodetools_tools_library_no_options_no_preferences</id>
<dependency type="executable" location="extensions">gcodetools.py</dependency>
<dependency type="executable" location="extensions">inkex.py</dependency>
@@ -15,6 +16,8 @@
<_option value='plasma cutter'>plasma</_option>
<_option value='tangent knife'>tangent knife</_option>
<_option value='lathe cutter'>lathe cutter</_option>
+<_option value='graffiti'>graffiti</_option>
+
<_option value='check'>Just check tools</_option>
@@ -41,9 +44,9 @@ English support forum:
and Russian support forum:
http://www.cnc-club.ru/gcodetoolsru
-Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas.
+Credits: Nick Drobchenko, Vladimir Kalyaev, John Brooker, Henry Nicolas, Chris Lusby Taylor.
-Gcodetools ver. 1.6.01
+Gcodetools ver. 1.7
</_param>
</page>
@@ -58,5 +61,4 @@ Gcodetools ver. 1.6.01
<script>
<command reldir="extensions" interpreter="python">gcodetools.py</command>
</script>
-
</inkscape-extension>
diff --git a/share/extensions/xaml2svg/animation.xsl b/share/extensions/xaml2svg/animation.xsl
index 6e7578cd2..e51a430ba 100644
--- a/share/extensions/xaml2svg/animation.xsl
+++ b/share/extensions/xaml2svg/animation.xsl
@@ -1,141 +1,141 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:def="Definition"
-exclude-result-prefixes="def">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template name="template_animation">
- <xsl:if test="@From"><xsl:attribute name="from"><xsl:value-of select="@From" /></xsl:attribute></xsl:if>
- <xsl:if test="@To"><xsl:attribute name="to"><xsl:value-of select="@To" /></xsl:attribute></xsl:if>
- <xsl:if test="@Duration"><xsl:attribute name="dur"><xsl:value-of select="@Duration" /></xsl:attribute></xsl:if>
- <xsl:if test="@RepeatDuration"><xsl:attribute name="repeatDur"><xsl:value-of select="translate(@RepeatDuration, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" /></xsl:attribute></xsl:if>
- <xsl:if test="@RepeatCount"><xsl:attribute name="repeatCount"><xsl:value-of select="@RepeatCount" /></xsl:attribute></xsl:if>
- <xsl:if test="@AutoReverse">
- <xsl:attribute name="fill">
- <xsl:choose>
- <xsl:when test="@AutoReverse = 'True'">remove</xsl:when>
- <xsl:otherwise>freeze</xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- </xsl:if>
-</xsl:template>
-
-<xsl:template name="template_timeline_animations">
- <xsl:variable name="id" select="@ID" />
- <xsl:variable name="name" select="@Name" />
- <xsl:apply-templates select="//*[name(.) = 'SetterTimeline' and ($id = @TargetID or $name = @TargetName)]" />
-</xsl:template>
-
-<xsl:template name="template_animation_path">
- <xsl:param name="target" />
- <xsl:choose>
- <xsl:when test="$target = '(Line.X2)'">x2</xsl:when>
- <xsl:when test="$target = '(Rectangle.Opacity)'">opacity</xsl:when>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template match="*[name(.) = concat(name(..), '.Storyboards')]">
- <!--xsl:apply-templates /-->
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ParallelTimeLine']">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'SetterTimeline']">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ByteAnimationCollection' or name(.) = 'DecimalAnimationCollection' or name(.) = 'DoubleAnimationCollection' or name(.) = 'Int16AnimationCollection' or name(.) = 'Int32AnimationCollection' or name(.) = 'Int64AnimationCollection' or name(.) = 'LengthAnimationCollection' or name(.) = 'SingleAnimationCollection' or name(.) = 'SizeAnimationCollection' or name(.) = 'ThicknessAnimationCollection']">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ByteAnimation' or name(.) = 'DecimalAnimation' or name(.) = 'DoubleAnimation' or name(.) = 'Int16Animation' or name(.) = 'Int32Animation' or name(.) = 'Int64Animation' or name(.) = 'LengthAnimation' or name(.) = 'SingleAnimation' or name(.) = 'SizeAnimation' or name(.) = 'ThicknessAnimation']">
- <xsl:choose>
- <xsl:when test="../@Path">
- <animate>
- <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
- <xsl:call-template name="template_animation" />
- </animate>
- </xsl:when>
- <xsl:when test="name(..) = concat(name(.), 'Collection')">
- <animate>
- <xsl:attribute name="attributeName"><xsl:value-of select="translate(substring-after(name(../..), concat(name(../../..), '.')), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" /></xsl:attribute>
- <xsl:call-template name="template_animation" />
- </animate>
- </xsl:when>
- <xsl:when test="name(..) = concat(name(../..), '.AngleAnimations')">
- <animateTransform attributeName="transform" type="rotate">
- <xsl:call-template name="template_animation" />
- </animateTransform>
- </xsl:when>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template match="*[name(.) = concat(name(..), '.ColorAnimations')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = concat(name(..), '.AngleAnimations')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ColorAnimation']">
- <animateColor>
- <xsl:if test="../@Path">
- <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
- </xsl:if>
- <xsl:if test="name(..) = concat(name(../..), '.ColorAnimations')">
- <xsl:choose>
- <xsl:when test="name(../..) = 'SolidColorBrush'">
- <xsl:attribute name="attributeName">
- <xsl:value-of select="translate(substring-after(name(../../..), concat(name(../../../..), '.')), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" />
- </xsl:attribute>
- </xsl:when>
- </xsl:choose>
- </xsl:if>
- <xsl:call-template name="template_animation" />
- </animateColor>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'PointAnimation']">
- <animateMotion>
- <xsl:if test="../@Path">
- <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
- </xsl:if>
- <xsl:call-template name="template_animation" />
- </animateMotion>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'RectAnimation']">
-<!-- -->
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:def="Definition"
+exclude-result-prefixes="def">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template name="template_animation">
+ <xsl:if test="@From"><xsl:attribute name="from"><xsl:value-of select="@From" /></xsl:attribute></xsl:if>
+ <xsl:if test="@To"><xsl:attribute name="to"><xsl:value-of select="@To" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Duration"><xsl:attribute name="dur"><xsl:value-of select="@Duration" /></xsl:attribute></xsl:if>
+ <xsl:if test="@RepeatDuration"><xsl:attribute name="repeatDur"><xsl:value-of select="translate(@RepeatDuration, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" /></xsl:attribute></xsl:if>
+ <xsl:if test="@RepeatCount"><xsl:attribute name="repeatCount"><xsl:value-of select="@RepeatCount" /></xsl:attribute></xsl:if>
+ <xsl:if test="@AutoReverse">
+ <xsl:attribute name="fill">
+ <xsl:choose>
+ <xsl:when test="@AutoReverse = 'True'">remove</xsl:when>
+ <xsl:otherwise>freeze</xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template name="template_timeline_animations">
+ <xsl:variable name="id" select="@ID" />
+ <xsl:variable name="name" select="@Name" />
+ <xsl:apply-templates select="//*[name(.) = 'SetterTimeline' and ($id = @TargetID or $name = @TargetName)]" />
+</xsl:template>
+
+<xsl:template name="template_animation_path">
+ <xsl:param name="target" />
+ <xsl:choose>
+ <xsl:when test="$target = '(Line.X2)'">x2</xsl:when>
+ <xsl:when test="$target = '(Rectangle.Opacity)'">opacity</xsl:when>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template match="*[name(.) = concat(name(..), '.Storyboards')]">
+ <!--xsl:apply-templates /-->
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ParallelTimeLine']">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'SetterTimeline']">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ByteAnimationCollection' or name(.) = 'DecimalAnimationCollection' or name(.) = 'DoubleAnimationCollection' or name(.) = 'Int16AnimationCollection' or name(.) = 'Int32AnimationCollection' or name(.) = 'Int64AnimationCollection' or name(.) = 'LengthAnimationCollection' or name(.) = 'SingleAnimationCollection' or name(.) = 'SizeAnimationCollection' or name(.) = 'ThicknessAnimationCollection']">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ByteAnimation' or name(.) = 'DecimalAnimation' or name(.) = 'DoubleAnimation' or name(.) = 'Int16Animation' or name(.) = 'Int32Animation' or name(.) = 'Int64Animation' or name(.) = 'LengthAnimation' or name(.) = 'SingleAnimation' or name(.) = 'SizeAnimation' or name(.) = 'ThicknessAnimation']">
+ <xsl:choose>
+ <xsl:when test="../@Path">
+ <animate>
+ <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
+ <xsl:call-template name="template_animation" />
+ </animate>
+ </xsl:when>
+ <xsl:when test="name(..) = concat(name(.), 'Collection')">
+ <animate>
+ <xsl:attribute name="attributeName"><xsl:value-of select="translate(substring-after(name(../..), concat(name(../../..), '.')), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" /></xsl:attribute>
+ <xsl:call-template name="template_animation" />
+ </animate>
+ </xsl:when>
+ <xsl:when test="name(..) = concat(name(../..), '.AngleAnimations')">
+ <animateTransform attributeName="transform" type="rotate">
+ <xsl:call-template name="template_animation" />
+ </animateTransform>
+ </xsl:when>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template match="*[name(.) = concat(name(..), '.ColorAnimations')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = concat(name(..), '.AngleAnimations')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ColorAnimation']">
+ <animateColor>
+ <xsl:if test="../@Path">
+ <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
+ </xsl:if>
+ <xsl:if test="name(..) = concat(name(../..), '.ColorAnimations')">
+ <xsl:choose>
+ <xsl:when test="name(../..) = 'SolidColorBrush'">
+ <xsl:attribute name="attributeName">
+ <xsl:value-of select="translate(substring-after(name(../../..), concat(name(../../../..), '.')), 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')" />
+ </xsl:attribute>
+ </xsl:when>
+ </xsl:choose>
+ </xsl:if>
+ <xsl:call-template name="template_animation" />
+ </animateColor>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'PointAnimation']">
+ <animateMotion>
+ <xsl:if test="../@Path">
+ <xsl:attribute name="attributeName"><xsl:call-template name="template_animation_path"><xsl:with-param name="target" select="../@Path" /></xsl:call-template></xsl:attribute>
+ </xsl:if>
+ <xsl:call-template name="template_animation" />
+ </animateMotion>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'RectAnimation']">
+<!-- -->
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/brushes.xsl b/share/extensions/xaml2svg/brushes.xsl
index a5d20e12d..884d6db35 100644
--- a/share/extensions/xaml2svg/brushes.xsl
+++ b/share/extensions/xaml2svg/brushes.xsl
@@ -1,244 +1,244 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-exclude-result-prefixes="x">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template mode="forward" match="*[name(.) = 'LinearGradientBrush']">
- <linearGradient>
- <xsl:attribute name="id">
- <xsl:choose>
- <xsl:when test="@x:Key"><xsl:value-of select="@x:Key" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- <xsl:attribute name="gradientUnits">
- <xsl:choose>
- <xsl:when test="@MappingMode = 'RelativeToBoundingBox' or not(@StartPoint and @EndPoint)"><xsl:value-of select="'boundingBox'" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="'userSpaceOnUse'" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- <xsl:if test="@SpreadMethod">
- <xsl:attribute name="spreadMethod">
- <xsl:value-of select="translate(@SpreadMethod, 'PR', 'pr')" />
- </xsl:attribute>
- </xsl:if>
- <xsl:choose>
- <xsl:when test="@MappingMode = 'Absolute' and @StartPoint and @EndPoint">
- <xsl:attribute name="x1"><xsl:value-of select="substring-before(@StartPoint,',')" /></xsl:attribute>
- <xsl:attribute name="x1"><xsl:value-of select="substring-before(@StartPoint,',')" /></xsl:attribute>
- <xsl:attribute name="y1"><xsl:value-of select="substring-after(@StartPoint,',')" /></xsl:attribute>
- <xsl:attribute name="x2"><xsl:value-of select="substring-before(@EndPoint,',')" /></xsl:attribute>
- <xsl:attribute name="y2"><xsl:value-of select="substring-after(@EndPoint,',')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@StartPoint and @EndPoint">
- <xsl:attribute name="x1"><xsl:value-of select="concat(100 * number(substring-before(@StartPoint,',')), '%')" /></xsl:attribute>
- <xsl:attribute name="y1"><xsl:value-of select="concat(100 * number(substring-after(@StartPoint,',')), '%')" /></xsl:attribute>
- <xsl:attribute name="x2"><xsl:value-of select="concat(100 * number(substring-before(@EndPoint,',')), '%')" /></xsl:attribute>
- <xsl:attribute name="y2"><xsl:value-of select="concat(100 * number(substring-after(@EndPoint,',')), '%')" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="x1"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="y1"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="x2"><xsl:value-of select="'100%'" /></xsl:attribute>
- <xsl:attribute name="y2"><xsl:value-of select="'100%'" /></xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:call-template name="template_gradienttransform" />
- <xsl:apply-templates select="*[name(.) != 'Brush.Transform' and name(.) != concat(name(..), '.Transform') and name(.) != 'Brush.RelativeTransform' and name(.) != concat(name(..), '.RelativeTransform')]" />
- </linearGradient>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'RadialGradientBrush']">
- <radialGradient>
- <xsl:attribute name="id">
- <xsl:choose>
- <xsl:when test="@x:Key"><xsl:value-of select="@x:Key" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- <xsl:attribute name="gradientUnits">
- <xsl:choose>
- <xsl:when test="@MappingMode = 'RelativeToBoundingBox' or not(@StartPoint and @EndPoint)"><xsl:value-of select="'boundingBox'" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="'userSpaceOnUse'" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- <xsl:if test="@SpreadMethod">
- <xsl:attribute name="spreadMethod">
- <xsl:value-of select="translate(@SpreadMethod, 'PR', 'pr')" />
- </xsl:attribute>
- </xsl:if>
- <xsl:if test="@Center">
- <xsl:attribute name="cx"><xsl:value-of select="substring-before(@Center, ',')" /></xsl:attribute>
- <xsl:attribute name="cy"><xsl:value-of select="substring-after(@Center, ',')" /></xsl:attribute>
- </xsl:if>
- <xsl:if test="@GradientOrigin">
- <xsl:attribute name="fx"><xsl:value-of select="substring-before(@GradientOrigin, ',')" /></xsl:attribute>
- <xsl:attribute name="fy"><xsl:value-of select="substring-after(@GradientOrigin, ',')" /></xsl:attribute>
- </xsl:if>
- <!-- Xamlon uses Focus -->
- <xsl:if test="@Focus">
- <xsl:attribute name="fx"><xsl:value-of select="substring-before(@Focus, ',')" /></xsl:attribute>
- <xsl:attribute name="fy"><xsl:value-of select="substring-after(@Focus, ',')" /></xsl:attribute>
- </xsl:if>
- <xsl:attribute name="r"><xsl:value-of select="@RadiusX" /></xsl:attribute>
- <xsl:call-template name="template_gradienttransform" />
- <xsl:apply-templates select="*[name(.) != 'Brush.Transform' and name(.) != concat(name(..), '.Transform') and name(.) != 'Brush.RelativeTransform' and name(.) != concat(name(..), '.RelativeTransform')]" />
- </radialGradient>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'GradientStopCollection' or name(.) = 'GradientBrush.GradientStops' or name(.) = concat(name(..), '.GradientStops')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'GradientStop']">
- <stop>
- <xsl:if test="@Offset"><xsl:attribute name="offset"><xsl:value-of select="@Offset" /></xsl:attribute></xsl:if>
- <xsl:if test="@Color">
- <xsl:attribute name="stop-color"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stop-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
- </xsl:if>
- </stop>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'SolidColorBrush']">
- <xsl:call-template name="template_properties" />
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ImageBrush']">
- <defs>
- <pattern>
- <xsl:choose>
- <xsl:when test="@TileMode != 'none' and @Viewport and @ViewportUnits = 'Absolute'">
- <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="substring-before(@Viewport, ',')" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Viewport, ','), ',')" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@TileMode != 'none' and @Viewport">
- <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="concat(100 * number(substring-before(@Viewport, ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="concat(100 * number(substring-before(substring-after(@Viewport, ','), ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@Viewport and ../../@Width and ../../@Height">
- <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
- <xsl:attribute name="x">0</xsl:attribute>
- <xsl:attribute name="y">0</xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="../../@Width" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="../../@Height" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="patternUnits">boundingBox </xsl:attribute>
- <xsl:attribute name="x">0</xsl:attribute>
- <xsl:attribute name="y">0</xsl:attribute>
- <xsl:attribute name="width">100%</xsl:attribute>
- <xsl:attribute name="height">100%</xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:attribute name="id"><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:attribute>
- <image>
- <xsl:attribute name="xlink:href"><xsl:value-of select="@ImageSource" /></xsl:attribute>
- <xsl:choose>
- <xsl:when test="@Viewport and @ViewportUnits = 'Absolute'">
- <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@Viewport">
- <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="0" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
- <xsl:attribute name="x">0</xsl:attribute>
- <xsl:attribute name="y">0</xsl:attribute>
- <xsl:attribute name="width">100%</xsl:attribute>
- <xsl:attribute name="height">100%</xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:attribute name="style">opacity:1</xsl:attribute>
- <xsl:attribute name="image-rendering">optimizeSpeed</xsl:attribute>
- </image>
- </pattern>
- </defs>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'DrawingBrush']">
- <pattern>
- <xsl:choose>
- <xsl:when test="@TileMode != 'none' and @Viewport and @ViewportUnits = 'Absolute'">
- <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="substring-before(@Viewport, ',')" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Viewport, ','), ',')" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@TileMode != 'none' and @Viewport">
- <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
- <xsl:attribute name="x"><xsl:value-of select="concat(100 * number(substring-before(@Viewport, ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="concat(100 * number(substring-before(substring-after(@Viewport, ','), ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
- </xsl:when>
- <xsl:when test="@Viewport and ../../@Width and ../../@Height">
- <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
- <xsl:attribute name="x">0</xsl:attribute>
- <xsl:attribute name="y">0</xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="../../@Width" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="../../@Height" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
- <xsl:attribute name="x">0</xsl:attribute>
- <xsl:attribute name="y">0</xsl:attribute>
- <xsl:attribute name="width">100%</xsl:attribute>
- <xsl:attribute name="height">100%</xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:attribute name="id"><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:attribute>
- <xsl:apply-templates mode="forward" />
- </pattern>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'DrawingBrush.Drawing']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+exclude-result-prefixes="x">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template mode="forward" match="*[name(.) = 'LinearGradientBrush']">
+ <linearGradient>
+ <xsl:attribute name="id">
+ <xsl:choose>
+ <xsl:when test="@x:Key"><xsl:value-of select="@x:Key" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:attribute name="gradientUnits">
+ <xsl:choose>
+ <xsl:when test="@MappingMode = 'RelativeToBoundingBox' or not(@StartPoint and @EndPoint)"><xsl:value-of select="'boundingBox'" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="'userSpaceOnUse'" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:if test="@SpreadMethod">
+ <xsl:attribute name="spreadMethod">
+ <xsl:value-of select="translate(@SpreadMethod, 'PR', 'pr')" />
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:choose>
+ <xsl:when test="@MappingMode = 'Absolute' and @StartPoint and @EndPoint">
+ <xsl:attribute name="x1"><xsl:value-of select="substring-before(@StartPoint,',')" /></xsl:attribute>
+ <xsl:attribute name="x1"><xsl:value-of select="substring-before(@StartPoint,',')" /></xsl:attribute>
+ <xsl:attribute name="y1"><xsl:value-of select="substring-after(@StartPoint,',')" /></xsl:attribute>
+ <xsl:attribute name="x2"><xsl:value-of select="substring-before(@EndPoint,',')" /></xsl:attribute>
+ <xsl:attribute name="y2"><xsl:value-of select="substring-after(@EndPoint,',')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@StartPoint and @EndPoint">
+ <xsl:attribute name="x1"><xsl:value-of select="concat(100 * number(substring-before(@StartPoint,',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="y1"><xsl:value-of select="concat(100 * number(substring-after(@StartPoint,',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="x2"><xsl:value-of select="concat(100 * number(substring-before(@EndPoint,',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="y2"><xsl:value-of select="concat(100 * number(substring-after(@EndPoint,',')), '%')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute name="x1"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="y1"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="x2"><xsl:value-of select="'100%'" /></xsl:attribute>
+ <xsl:attribute name="y2"><xsl:value-of select="'100%'" /></xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:call-template name="template_gradienttransform" />
+ <xsl:apply-templates select="*[name(.) != 'Brush.Transform' and name(.) != concat(name(..), '.Transform') and name(.) != 'Brush.RelativeTransform' and name(.) != concat(name(..), '.RelativeTransform')]" />
+ </linearGradient>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'RadialGradientBrush']">
+ <radialGradient>
+ <xsl:attribute name="id">
+ <xsl:choose>
+ <xsl:when test="@x:Key"><xsl:value-of select="@x:Key" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:attribute name="gradientUnits">
+ <xsl:choose>
+ <xsl:when test="@MappingMode = 'RelativeToBoundingBox' or not(@StartPoint and @EndPoint)"><xsl:value-of select="'boundingBox'" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="'userSpaceOnUse'" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:if test="@SpreadMethod">
+ <xsl:attribute name="spreadMethod">
+ <xsl:value-of select="translate(@SpreadMethod, 'PR', 'pr')" />
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:if test="@Center">
+ <xsl:attribute name="cx"><xsl:value-of select="substring-before(@Center, ',')" /></xsl:attribute>
+ <xsl:attribute name="cy"><xsl:value-of select="substring-after(@Center, ',')" /></xsl:attribute>
+ </xsl:if>
+ <xsl:if test="@GradientOrigin">
+ <xsl:attribute name="fx"><xsl:value-of select="substring-before(@GradientOrigin, ',')" /></xsl:attribute>
+ <xsl:attribute name="fy"><xsl:value-of select="substring-after(@GradientOrigin, ',')" /></xsl:attribute>
+ </xsl:if>
+ <!-- Xamlon uses Focus -->
+ <xsl:if test="@Focus">
+ <xsl:attribute name="fx"><xsl:value-of select="substring-before(@Focus, ',')" /></xsl:attribute>
+ <xsl:attribute name="fy"><xsl:value-of select="substring-after(@Focus, ',')" /></xsl:attribute>
+ </xsl:if>
+ <xsl:attribute name="r"><xsl:value-of select="@RadiusX" /></xsl:attribute>
+ <xsl:call-template name="template_gradienttransform" />
+ <xsl:apply-templates select="*[name(.) != 'Brush.Transform' and name(.) != concat(name(..), '.Transform') and name(.) != 'Brush.RelativeTransform' and name(.) != concat(name(..), '.RelativeTransform')]" />
+ </radialGradient>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'GradientStopCollection' or name(.) = 'GradientBrush.GradientStops' or name(.) = concat(name(..), '.GradientStops')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'GradientStop']">
+ <stop>
+ <xsl:if test="@Offset"><xsl:attribute name="offset"><xsl:value-of select="@Offset" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Color">
+ <xsl:attribute name="stop-color"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stop-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
+ </xsl:if>
+ </stop>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'SolidColorBrush']">
+ <xsl:call-template name="template_properties" />
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ImageBrush']">
+ <defs>
+ <pattern>
+ <xsl:choose>
+ <xsl:when test="@TileMode != 'none' and @Viewport and @ViewportUnits = 'Absolute'">
+ <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="substring-before(@Viewport, ',')" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Viewport, ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@TileMode != 'none' and @Viewport">
+ <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="concat(100 * number(substring-before(@Viewport, ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="concat(100 * number(substring-before(substring-after(@Viewport, ','), ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@Viewport and ../../@Width and ../../@Height">
+ <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
+ <xsl:attribute name="x">0</xsl:attribute>
+ <xsl:attribute name="y">0</xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="../../@Width" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="../../@Height" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute name="patternUnits">boundingBox </xsl:attribute>
+ <xsl:attribute name="x">0</xsl:attribute>
+ <xsl:attribute name="y">0</xsl:attribute>
+ <xsl:attribute name="width">100%</xsl:attribute>
+ <xsl:attribute name="height">100%</xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:attribute name="id"><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:attribute>
+ <image>
+ <xsl:attribute name="xlink:href"><xsl:value-of select="@ImageSource" /></xsl:attribute>
+ <xsl:choose>
+ <xsl:when test="@Viewport and @ViewportUnits = 'Absolute'">
+ <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@Viewport">
+ <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="0" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
+ <xsl:attribute name="x">0</xsl:attribute>
+ <xsl:attribute name="y">0</xsl:attribute>
+ <xsl:attribute name="width">100%</xsl:attribute>
+ <xsl:attribute name="height">100%</xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:attribute name="style">opacity:1</xsl:attribute>
+ <xsl:attribute name="image-rendering">optimizeSpeed</xsl:attribute>
+ </image>
+ </pattern>
+ </defs>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'DrawingBrush']">
+ <pattern>
+ <xsl:choose>
+ <xsl:when test="@TileMode != 'none' and @Viewport and @ViewportUnits = 'Absolute'">
+ <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="substring-before(@Viewport, ',')" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Viewport, ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@TileMode != 'none' and @Viewport">
+ <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
+ <xsl:attribute name="x"><xsl:value-of select="concat(100 * number(substring-before(@Viewport, ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="concat(100 * number(substring-before(substring-after(@Viewport, ','), ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="concat(100 * number(substring-before(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="concat(100 * number(substring-after(substring-after(substring-after(@Viewport, ','), ','), ',')), '%')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:when test="@Viewport and ../../@Width and ../../@Height">
+ <xsl:attribute name="patternUnits">userSpaceOnUse</xsl:attribute>
+ <xsl:attribute name="x">0</xsl:attribute>
+ <xsl:attribute name="y">0</xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="../../@Width" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="../../@Height" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute name="patternUnits">boundingBox</xsl:attribute>
+ <xsl:attribute name="x">0</xsl:attribute>
+ <xsl:attribute name="y">0</xsl:attribute>
+ <xsl:attribute name="width">100%</xsl:attribute>
+ <xsl:attribute name="height">100%</xsl:attribute>
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:attribute name="id"><xsl:value-of select="concat('id_', generate-id(..))" /></xsl:attribute>
+ <xsl:apply-templates mode="forward" />
+ </pattern>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'DrawingBrush.Drawing']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/canvas.xsl b/share/extensions/xaml2svg/canvas.xsl
index 0438bde67..e67f0e225 100644
--- a/share/extensions/xaml2svg/canvas.xsl
+++ b/share/extensions/xaml2svg/canvas.xsl
@@ -1,80 +1,80 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template mode="forward" match="*[name(.) = 'Canvas' or name(.) = 'Window' or name(.) = 'StackPanel']">
- <svg>
- <xsl:choose>
- <!--
- <xsl:when test="@ID"><xsl:attribute name="id"><xsl:value-of select="@ID" /></xsl:attribute></xsl:when>
- -->
- <xsl:when test="@x:Key"><xsl:attribute name="id"><xsl:value-of select="@x:Key" /></xsl:attribute></xsl:when>
- <xsl:when test="@Name"><xsl:attribute name="id"><xsl:value-of select="@Name" /></xsl:attribute></xsl:when>
- </xsl:choose>
- <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
- <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
- <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
- <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
- <xsl:call-template name="template_properties" />
- <xsl:choose>
- <xsl:when test="@Transform or *[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]">
- <g>
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates select="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]" />
- <xsl:apply-templates mode="svg" />
- </g>
- </xsl:when>
- <xsl:otherwise><xsl:apply-templates mode="svg" /></xsl:otherwise>
- </xsl:choose>
- </svg>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Border']">
- <rect>
- <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
- <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
- <xsl:if test="@BorderThickness"><xsl:attribute name="stroke-width"><xsl:value-of select="@BorderThickness" /></xsl:attribute></xsl:if>
- <xsl:if test="@Background">
- <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Background" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Background" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
- </xsl:if>
- <xsl:if test="@BorderBrush">
- <xsl:attribute name="stroke"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@BorderBrush" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@BorderBrush" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stroke-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
- </xsl:if>
- <xsl:call-template name="template_properties" />
- </rect>
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template mode="forward" match="*[name(.) = 'Canvas' or name(.) = 'Window' or name(.) = 'StackPanel']">
+ <svg>
+ <xsl:choose>
+ <!--
+ <xsl:when test="@ID"><xsl:attribute name="id"><xsl:value-of select="@ID" /></xsl:attribute></xsl:when>
+ -->
+ <xsl:when test="@x:Key"><xsl:attribute name="id"><xsl:value-of select="@x:Key" /></xsl:attribute></xsl:when>
+ <xsl:when test="@Name"><xsl:attribute name="id"><xsl:value-of select="@Name" /></xsl:attribute></xsl:when>
+ </xsl:choose>
+ <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
+ <xsl:call-template name="template_properties" />
+ <xsl:choose>
+ <xsl:when test="@Transform or *[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]">
+ <g>
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates select="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]" />
+ <xsl:apply-templates mode="svg" />
+ </g>
+ </xsl:when>
+ <xsl:otherwise><xsl:apply-templates mode="svg" /></xsl:otherwise>
+ </xsl:choose>
+ </svg>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Border']">
+ <rect>
+ <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
+ <xsl:if test="@BorderThickness"><xsl:attribute name="stroke-width"><xsl:value-of select="@BorderThickness" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Background">
+ <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Background" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Background" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
+ </xsl:if>
+ <xsl:if test="@BorderBrush">
+ <xsl:attribute name="stroke"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@BorderBrush" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@BorderBrush" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stroke-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
+ </xsl:if>
+ <xsl:call-template name="template_properties" />
+ </rect>
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/geometry.xsl b/share/extensions/xaml2svg/geometry.xsl
index 4468ef4ff..c28e6a67c 100644
--- a/share/extensions/xaml2svg/geometry.xsl
+++ b/share/extensions/xaml2svg/geometry.xsl
@@ -1,272 +1,272 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:def="Definition"
-exclude-result-prefixes="def">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template mode="forward" match="*[name(.) = 'ClipGeometry']">
-<!-- -->
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'GlyphRunDrawing']">
-<!-- -->
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'ImageDrawing']">
- <image>
- <xsl:if test="@ImageSource"><xsl:attribute name="xlink:href"><xsl:value-of select="@ImageSource" /></xsl:attribute></xsl:if>
- <xsl:if test="@Rect">
- <xsl:attribute name="x"><xsl:value-of select="substring-before(@Rect, ',')" /></xsl:attribute>
- <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Rect, ','), ',')" /></xsl:attribute>
- <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Rect, ','), ','), ',')" /></xsl:attribute>
- <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Rect, ','), ','), ',')" /></xsl:attribute>
- </xsl:if>
- </image>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'DrawingGroup']">
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'EllipseGeometry']">
- <xsl:variable name="cx" select="substring-before(@Center, ',')" />
- <xsl:variable name="cy" select="substring-after(@Center, ',')" />
- <xsl:value-of select="concat('M ', $cx + @RadiusX, ',', $cy, ' ')" />
- <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx, ',', $cy + @RadiusY, ' ')" />
- <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx - @RadiusX, ',', $cy, ' ')" />
- <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx, ',', $cy - @RadiusY, ' ')" />
- <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx + @RadiusX, ',', $cy, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'LineGeometry']">
- <xsl:value-of select="concat('M ', @StartPoint, ' ')" />
- <xsl:value-of select="concat('L ', @EndPoint, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathGeometry']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathGeometry.Figures']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathFigureCollection']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathFigure']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathFigure.Segments']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PathSegmentCollection']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'StartSegment']">
- <xsl:value-of select="concat('M ', @Point, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'CloseSegment']">
- <xsl:value-of select="'z '" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'LineSegment']">
- <xsl:value-of select="concat('L ', @Point, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'ArcSegment']">
- <xsl:value-of select="concat('A ', substring-before(@Size, ','), ',', substring-after(@Size, ','), ' ', @XRotation, ' ', number(@LargeArc = 'True'), ' ', number(@Sweepflag = 'True'), ' ', @Point, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'BezierSegment']">
- <xsl:value-of select="concat('C ', @Point1, ' ', @Point2, ' ', @Point3, ' ')" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'QuadraticBezierSegment']">
- <xsl:value-of select="concat('Q ', @Point1, ' ', @Point2, ' ', @Point3, ' ')" />
-</xsl:template>
-
-<xsl:template name="PrintPolyBezierPoints">
- <xsl:param name="segments" />
- <xsl:param name="segmentsize" />
- <xsl:param name="cursor" />
- <xsl:text>C </xsl:text>
- <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
- <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
- <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
- <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
- <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments4, ','), ',')" />
- <xsl:variable name="segments5"><xsl:value-of select="substring-after($segments4, ',')" /></xsl:variable>
- <xsl:choose>
- <xsl:when test="contains($segments5, ' ')">
- <xsl:value-of select="concat(substring-before($segments5, ' '), ' ')" />
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$segments5" />
- </xsl:otherwise>
- </xsl:choose>
- <xsl:variable name="segments6"><xsl:value-of select="substring-after($segments5, ' ')" /></xsl:variable>
- <xsl:if test="contains($segments6, ' ')">
- <xsl:call-template name="PrintPolyBezierPoints">
- <xsl:with-param name="segments" select="$segments6" />
- </xsl:call-template>
- </xsl:if>
-</xsl:template>
-
-<xsl:template name="PrintPolyLinePoints">
- <xsl:param name="segments" />
- <xsl:text>L </xsl:text>
- <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
- <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
- <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
- <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
- <xsl:choose>
- <xsl:when test="contains($segments3, ' ')">
- <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$segments3" />
- </xsl:otherwise>
- </xsl:choose>
- <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
- <xsl:if test="contains($segments4, ' ')">
- <xsl:call-template name="PrintPolyLinePoints">
- <xsl:with-param name="segments" select="$segments4" />
- </xsl:call-template>
- </xsl:if>
-</xsl:template>
-
-<xsl:template name="PrintQuadraticBezierPoints">
- <xsl:param name="segments" />
- <xsl:text>Q </xsl:text>
- <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
- <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
- <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
- <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
- <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
- <xsl:choose>
- <xsl:when test="contains($segments3, ' ')">
- <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$segments3" />
- </xsl:otherwise>
- </xsl:choose>
- <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
- <xsl:if test="contains($segments4, ' ')">
- <xsl:call-template name="PrintQuadraticBezierPoints">
- <xsl:with-param name="segments" select="$segments4" />
- </xsl:call-template>
- </xsl:if>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PolyBezierSegment']">
- <xsl:call-template name="PrintPolyBezierPoints">
- <xsl:with-param name="segments" select="@Points" />
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PolyLineSegment']">
- <xsl:call-template name="PrintPolyLinePoints">
- <xsl:with-param name="segments" select="@Points" />
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'PolyQuadraticBezierSegment']">
- <xsl:call-template name="PrintQuadraticBezierPoints">
- <xsl:with-param name="segments" select="@Points" />
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'RectangleGeometry']">
- <xsl:variable name="rect" select="RectangleGeometry.Rect/Rect" />
- <xsl:choose>
- <xsl:when test="$rect">
- <xsl:value-of select="concat('M ', $rect/@X, ',', $rect/@Y, ' ')" />
- <xsl:value-of select="concat('H ', $rect/@X + $rect/@Width, ' V ', $rect/@Y + $rect/@Height, ' H ', $rect/@X,' V ', $rect/@Y, ' ')" />
- </xsl:when>
- <xsl:when test="@Rect">
- <xsl:variable name="x" select="substring-before(substring-before(@Rect, ' '), ',')" />
- <xsl:variable name="y" select="substring-after(substring-before(@Rect, ' '), ',')" />
- <xsl:variable name="width" select="substring-before(substring-after(@Rect, ' '), ',')" />
- <xsl:variable name="height" select="substring-after(substring-after(@Rect, ' '), ',')" />
- <xsl:value-of select="concat('M ', $x, ',', $y, ' ')" />
- <xsl:value-of select="concat('H ', $x + $width, ' V ', $y + $height, ' H ', $x,' V ', $y, ' ')" />
- </xsl:when>
- </xsl:choose>
-</xsl:template>
-
-<!--
-<xsl:template mode="forward" match="*[name(.) = 'GeometryCollection']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
--->
-
-<xsl:template mode="forward" match="*[name(.) = 'GeometryGroup']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing']">
- <path>
- <xsl:attribute name="d"><xsl:apply-templates select="*[name(.) = 'GeometryDrawing.Geometry']" mode="forward" /></xsl:attribute>
- <xsl:attribute name="fill"><xsl:value-of select="@Brush" /></xsl:attribute>
- <xsl:apply-templates mode="forward" select="*[name(.) = 'GeometryDrawing.Pen']" />
- </path>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing.Geometry']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing.Pen']">
- <xsl:variable name="pen" select="*[name(.) = 'Pen']" />
- <xsl:if test="$pen/@Brush"><xsl:attribute name="stroke"><xsl:value-of select="$pen/@Brush" /></xsl:attribute></xsl:if>
- <xsl:if test="$pen/@Thickness"><xsl:attribute name="stroke-width"><xsl:value-of select="$pen/@Thickness" /></xsl:attribute></xsl:if>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'CombinedGeometry' or name(.) = 'CombinedGeometry.Geometry1' or name(.) = 'CombinedGeometry.Geometry2']">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:def="Definition"
+exclude-result-prefixes="def">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template mode="forward" match="*[name(.) = 'ClipGeometry']">
+<!-- -->
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'GlyphRunDrawing']">
+<!-- -->
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'ImageDrawing']">
+ <image>
+ <xsl:if test="@ImageSource"><xsl:attribute name="xlink:href"><xsl:value-of select="@ImageSource" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Rect">
+ <xsl:attribute name="x"><xsl:value-of select="substring-before(@Rect, ',')" /></xsl:attribute>
+ <xsl:attribute name="y"><xsl:value-of select="substring-before(substring-after(@Rect, ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="width"><xsl:value-of select="substring-before(substring-after(substring-after(@Rect, ','), ','), ',')" /></xsl:attribute>
+ <xsl:attribute name="height"><xsl:value-of select="substring-after(substring-after(substring-after(@Rect, ','), ','), ',')" /></xsl:attribute>
+ </xsl:if>
+ </image>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'DrawingGroup']">
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'EllipseGeometry']">
+ <xsl:variable name="cx" select="substring-before(@Center, ',')" />
+ <xsl:variable name="cy" select="substring-after(@Center, ',')" />
+ <xsl:value-of select="concat('M ', $cx + @RadiusX, ',', $cy, ' ')" />
+ <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx, ',', $cy + @RadiusY, ' ')" />
+ <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx - @RadiusX, ',', $cy, ' ')" />
+ <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx, ',', $cy - @RadiusY, ' ')" />
+ <xsl:value-of select="concat('A ', @RadiusX, ',', @RadiusY, ' 0 0 1 ', $cx + @RadiusX, ',', $cy, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'LineGeometry']">
+ <xsl:value-of select="concat('M ', @StartPoint, ' ')" />
+ <xsl:value-of select="concat('L ', @EndPoint, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathGeometry']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathGeometry.Figures']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathFigureCollection']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathFigure']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathFigure.Segments']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PathSegmentCollection']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'StartSegment']">
+ <xsl:value-of select="concat('M ', @Point, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'CloseSegment']">
+ <xsl:value-of select="'z '" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'LineSegment']">
+ <xsl:value-of select="concat('L ', @Point, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'ArcSegment']">
+ <xsl:value-of select="concat('A ', substring-before(@Size, ','), ',', substring-after(@Size, ','), ' ', @XRotation, ' ', number(@LargeArc = 'True'), ' ', number(@Sweepflag = 'True'), ' ', @Point, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'BezierSegment']">
+ <xsl:value-of select="concat('C ', @Point1, ' ', @Point2, ' ', @Point3, ' ')" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'QuadraticBezierSegment']">
+ <xsl:value-of select="concat('Q ', @Point1, ' ', @Point2, ' ', @Point3, ' ')" />
+</xsl:template>
+
+<xsl:template name="PrintPolyBezierPoints">
+ <xsl:param name="segments" />
+ <xsl:param name="segmentsize" />
+ <xsl:param name="cursor" />
+ <xsl:text>C </xsl:text>
+ <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
+ <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
+ <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
+ <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
+ <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments4, ','), ',')" />
+ <xsl:variable name="segments5"><xsl:value-of select="substring-after($segments4, ',')" /></xsl:variable>
+ <xsl:choose>
+ <xsl:when test="contains($segments5, ' ')">
+ <xsl:value-of select="concat(substring-before($segments5, ' '), ' ')" />
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$segments5" />
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:variable name="segments6"><xsl:value-of select="substring-after($segments5, ' ')" /></xsl:variable>
+ <xsl:if test="contains($segments6, ' ')">
+ <xsl:call-template name="PrintPolyBezierPoints">
+ <xsl:with-param name="segments" select="$segments6" />
+ </xsl:call-template>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template name="PrintPolyLinePoints">
+ <xsl:param name="segments" />
+ <xsl:text>L </xsl:text>
+ <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
+ <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
+ <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
+ <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
+ <xsl:choose>
+ <xsl:when test="contains($segments3, ' ')">
+ <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$segments3" />
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
+ <xsl:if test="contains($segments4, ' ')">
+ <xsl:call-template name="PrintPolyLinePoints">
+ <xsl:with-param name="segments" select="$segments4" />
+ </xsl:call-template>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template name="PrintQuadraticBezierPoints">
+ <xsl:param name="segments" />
+ <xsl:text>Q </xsl:text>
+ <xsl:value-of select="concat(substring-before($segments, ','), ',')" />
+ <xsl:variable name="segments1"><xsl:value-of select="substring-after($segments, ',')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments1, ' '), ' ')" />
+ <xsl:variable name="segments2"><xsl:value-of select="substring-after($segments1, ' ')" /></xsl:variable>
+ <xsl:value-of select="concat(substring-before($segments2, ','), ',')" />
+ <xsl:variable name="segments3"><xsl:value-of select="substring-after($segments2, ',')" /></xsl:variable>
+ <xsl:choose>
+ <xsl:when test="contains($segments3, ' ')">
+ <xsl:value-of select="concat(substring-before($segments3, ' '), ' ')" />
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$segments3" />
+ </xsl:otherwise>
+ </xsl:choose>
+ <xsl:variable name="segments4"><xsl:value-of select="substring-after($segments3, ' ')" /></xsl:variable>
+ <xsl:if test="contains($segments4, ' ')">
+ <xsl:call-template name="PrintQuadraticBezierPoints">
+ <xsl:with-param name="segments" select="$segments4" />
+ </xsl:call-template>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PolyBezierSegment']">
+ <xsl:call-template name="PrintPolyBezierPoints">
+ <xsl:with-param name="segments" select="@Points" />
+ </xsl:call-template>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PolyLineSegment']">
+ <xsl:call-template name="PrintPolyLinePoints">
+ <xsl:with-param name="segments" select="@Points" />
+ </xsl:call-template>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'PolyQuadraticBezierSegment']">
+ <xsl:call-template name="PrintQuadraticBezierPoints">
+ <xsl:with-param name="segments" select="@Points" />
+ </xsl:call-template>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'RectangleGeometry']">
+ <xsl:variable name="rect" select="RectangleGeometry.Rect/Rect" />
+ <xsl:choose>
+ <xsl:when test="$rect">
+ <xsl:value-of select="concat('M ', $rect/@X, ',', $rect/@Y, ' ')" />
+ <xsl:value-of select="concat('H ', $rect/@X + $rect/@Width, ' V ', $rect/@Y + $rect/@Height, ' H ', $rect/@X,' V ', $rect/@Y, ' ')" />
+ </xsl:when>
+ <xsl:when test="@Rect">
+ <xsl:variable name="x" select="substring-before(substring-before(@Rect, ' '), ',')" />
+ <xsl:variable name="y" select="substring-after(substring-before(@Rect, ' '), ',')" />
+ <xsl:variable name="width" select="substring-before(substring-after(@Rect, ' '), ',')" />
+ <xsl:variable name="height" select="substring-after(substring-after(@Rect, ' '), ',')" />
+ <xsl:value-of select="concat('M ', $x, ',', $y, ' ')" />
+ <xsl:value-of select="concat('H ', $x + $width, ' V ', $y + $height, ' H ', $x,' V ', $y, ' ')" />
+ </xsl:when>
+ </xsl:choose>
+</xsl:template>
+
+<!--
+<xsl:template mode="forward" match="*[name(.) = 'GeometryCollection']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+-->
+
+<xsl:template mode="forward" match="*[name(.) = 'GeometryGroup']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing']">
+ <path>
+ <xsl:attribute name="d"><xsl:apply-templates select="*[name(.) = 'GeometryDrawing.Geometry']" mode="forward" /></xsl:attribute>
+ <xsl:attribute name="fill"><xsl:value-of select="@Brush" /></xsl:attribute>
+ <xsl:apply-templates mode="forward" select="*[name(.) = 'GeometryDrawing.Pen']" />
+ </path>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing.Geometry']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'GeometryDrawing.Pen']">
+ <xsl:variable name="pen" select="*[name(.) = 'Pen']" />
+ <xsl:if test="$pen/@Brush"><xsl:attribute name="stroke"><xsl:value-of select="$pen/@Brush" /></xsl:attribute></xsl:if>
+ <xsl:if test="$pen/@Thickness"><xsl:attribute name="stroke-width"><xsl:value-of select="$pen/@Thickness" /></xsl:attribute></xsl:if>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'CombinedGeometry' or name(.) = 'CombinedGeometry.Geometry1' or name(.) = 'CombinedGeometry.Geometry2']">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/properties.xsl b/share/extensions/xaml2svg/properties.xsl
index dcb6111bd..75d0aea26 100644
--- a/share/extensions/xaml2svg/properties.xsl
+++ b/share/extensions/xaml2svg/properties.xsl
@@ -1,286 +1,286 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
-
-Version history:
-
-20070907 Initial release
-20070912 TemplateBinding in template_color
-
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-xmlns:msxsl="urn:schemas-microsoft-com:xslt">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template mode="boundingbox" match="*">
-<xsl:if test="system-property('xsl:vendor') = 'Microsoft'">
- <xsl:choose>
- <xsl:when test="@Canvas.Left and @Canvas.Top and @Width and @Height">
- <boundingbox>
- <xsl:attribute name="x1">
- <xsl:value-of select="@Canvas.Left" />
- </xsl:attribute>
- <xsl:attribute name="x2">
- <xsl:value-of select="@Canvas.Left + @Width" />
- </xsl:attribute>
- <xsl:attribute name="y1">
- <xsl:value-of select="@Canvas.Top" />
- </xsl:attribute>
- <xsl:attribute name="y2">
- <xsl:value-of select="@Canvas.Top + @Height" />
- </xsl:attribute>
- </boundingbox>
- </xsl:when>
- <xsl:when test="count(*) &gt; 0">
- <xsl:variable name="boundingboxes"><xsl:apply-templates mode="boundingbox" select="*" />
- </xsl:variable>
- <boundingbox>
- <xsl:attribute name="x1">
- <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
- <xsl:sort data-type="number" select="@x1" order="ascending"/>
- <xsl:if test="position() = 1"><xsl:value-of select="@x1" /></xsl:if>
- </xsl:for-each>
- </xsl:attribute>
- <xsl:attribute name="x2">
- <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
- <xsl:sort data-type="number" select="@x2" order="descending"/>
- <xsl:if test="position() = 1"><xsl:value-of select="@x2" /></xsl:if>
- </xsl:for-each>
- </xsl:attribute>
- <xsl:attribute name="y1">
- <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
- <xsl:sort data-type="number" select="@y1" order="ascending"/>
- <xsl:if test="position() = 1"><xsl:value-of select="@y1" /></xsl:if>
- </xsl:for-each>
- </xsl:attribute>
- <xsl:attribute name="y2">
- <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
- <xsl:sort data-type="number" select="@y2" order="descending"/>
- <xsl:if test="position() = 1"><xsl:value-of select="@y2" /></xsl:if>
- </xsl:for-each>
- </xsl:attribute>
- </boundingbox>
- </xsl:when>
- </xsl:choose>
-</xsl:if>
-</xsl:template>
-
-<xsl:template mode="svg" match="*">
- <xsl:choose>
- <xsl:when test="false() and name(.) != 'Canvas' and name(.) != 'Image' and name(.) != 'Rect' and name(.) != 'Ellipse' and name(.) != 'Text' and name(.) != 'TextBlock' and (@Canvas.Left or @Canvas.Top)">
- <svg>
- <xsl:if test="@Canvas.Left and @Canvas.Top and @Width and @Height">
- <xsl:attribute name="viewBox">
- <xsl:value-of select="concat(@Canvas.Left, ' ')" />
- <xsl:value-of select="concat(@Canvas.Top, ' ')" />
- <xsl:value-of select="concat(@Width - @Canvas.Left, ' ')" />
- <xsl:value-of select="@Height - @Canvas.Top" />
- </xsl:attribute>
- </xsl:if>
- <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
- <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
- <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
- <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
- <xsl:apply-templates mode="g" select="." />
- </svg>
- </xsl:when>
- <xsl:otherwise><xsl:apply-templates mode="g" select="." /></xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template mode="g" match="*">
- <xsl:choose>
- <xsl:when test="*[(name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')) and not(*[name(.) = 'SolidColorBrush']) or (name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')) and not(*[name(.) = 'SolidColorBrush']) or name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask') or name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
- <g>
- <xsl:apply-templates mode="defs" select="." />
- <xsl:apply-templates mode="forward" select="." />
- </g>
- </xsl:when>
- <xsl:otherwise><xsl:apply-templates mode="forward" select="." /></xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template name="template_color">
- <xsl:param name="colorspec" />
- <xsl:choose>
- <xsl:when test="contains($colorspec, '#') and (string-length($colorspec) = 7 or string-length($colorspec) = 9)">
- <xsl:value-of select="concat('#', substring($colorspec, string-length($colorspec) - 5, 6))" />
- </xsl:when>
- <xsl:when test="contains($colorspec, '#') and (string-length($colorspec) = 4 or string-length($colorspec) = 5)">
- <xsl:value-of select="concat('#', substring($colorspec, string-length($colorspec) - 5, 3))" />
- </xsl:when>
- <xsl:when test="contains($colorspec, '{StaticResource ')"><xsl:value-of select="concat('url(#', substring-before(substring-after($colorspec, '{StaticResource '), '}'), ')')" /></xsl:when>
- <xsl:when test="contains($colorspec, '{TemplateBinding ')"><xsl:value-of select="concat('url(#', substring-before(substring-after($colorspec, '{TemplateBinding '), '}'), ')')" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="$colorspec" /></xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template name="template_opacity">
- <xsl:param name="colorspec" />
- <xsl:if test="contains($colorspec, '#') and (string-length($colorspec) = 4 or string-length($colorspec) = 9)">
- <xsl:variable name="opacityspec"><xsl:value-of select="translate(substring($colorspec, 2, 2), 'abcdefgh', 'ABCDEFGH')" /></xsl:variable>
- <xsl:choose>
- <xsl:when test="$opacityspec != 'FF'">
- <xsl:value-of select="format-number(number(string-length(substring-before('0123456789ABCDEF', substring($colorspec, 2, 1))) * 16 + string-length(substring-before('0123456789ABCDEF', substring($colorspec, 3, 1)))) div 255, '#0.00')" />
- </xsl:when>
- <xsl:otherwise><xsl:value-of select="''"/></xsl:otherwise>
- </xsl:choose>
- </xsl:if>
-</xsl:template>
-
-<xsl:template name="template_properties">
- <xsl:choose>
- <!--
- <xsl:when test="@ID"><xsl:attribute name="id"><xsl:value-of select="@ID" /></xsl:attribute></xsl:when>
- -->
- <xsl:when test="@x:Key"><xsl:attribute name="id"><xsl:value-of select="@x:Key" /></xsl:attribute></xsl:when>
- <xsl:when test="@Name"><xsl:attribute name="id"><xsl:value-of select="@Name" /></xsl:attribute></xsl:when>
- </xsl:choose>
- <xsl:choose>
- <xsl:when test="@Fill">
- <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Fill" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Fill" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0">
- <xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute>
- </xsl:if>
- </xsl:when>
- <xsl:when test="not(name(.) = 'Canvas') and not(@Foreground or *[name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')])"><xsl:attribute name="fill">none</xsl:attribute></xsl:when>
- </xsl:choose>
- <xsl:if test="@Stroke">
- <xsl:attribute name="stroke"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Stroke" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Stroke" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stroke-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
- </xsl:if>
- <xsl:if test="@StrokeThickness"><xsl:attribute name="stroke-width"><xsl:value-of select="@StrokeThickness" /></xsl:attribute></xsl:if>
- <xsl:if test="@StrokeMiterLimit"><xsl:attribute name="stroke-miterlimit"><xsl:value-of select="@StrokeMiterLimit" /></xsl:attribute></xsl:if>
- <xsl:if test="@StrokeDashArray"><xsl:attribute name="stroke-dasharray"><xsl:value-of select="@StrokeDashArray" /></xsl:attribute></xsl:if>
- <xsl:if test="@StrokeDashOffset"><xsl:attribute name="stroke-dashoffset"><xsl:value-of select="@StrokeDashOffset" /></xsl:attribute></xsl:if>
- <xsl:if test="@StrokeLineJoin"><xsl:attribute name="stroke-linejoin"><xsl:value-of select="@StrokeLineJoin" /></xsl:attribute></xsl:if>
- <xsl:if test="@StrokeEndLineCap"><xsl:attribute name="stroke-linecap"><xsl:value-of select="@StrokeEndLineCap" /></xsl:attribute></xsl:if>
- <xsl:if test="@Opacity"><xsl:attribute name="fill-opacity"><xsl:value-of select="@Opacity" /></xsl:attribute></xsl:if>
- <xsl:if test="@Color">
- <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:attribute>
- <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:variable>
- <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
- </xsl:if>
- <xsl:if test="@Clip">
- <xsl:choose>
- <xsl:when test="contains(@Clip, '{')"><xsl:attribute name="fill"><xsl:value-of select="concat('url(#', substring-before(substring-after(@Clip, '{'), '}'), ')')" /></xsl:attribute></xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="clip-path"><xsl:value-of select="concat('url(#clippath_', generate-id(.),')')" /></xsl:attribute>
- <defs>
- <clipPath>
- <xsl:attribute name="id"><xsl:value-of select="concat('clippath_', generate-id(.))" /></xsl:attribute>
- <path>
- <xsl:attribute name="d">
- <xsl:choose>
- <xsl:when test="contains(@Clip, 'F1')"><xsl:value-of select="substring-after(@Clip, 'F1')" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="@Clip" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute></path>
- </clipPath>
- </defs>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:if>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Resources')]">
- <defs><xsl:apply-templates mode="forward" /></defs>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Children')]">
- <xsl:apply-templates mode="forward" />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')]">
- <xsl:choose>
- <xsl:when test="not(*[name(.) = 'SolidColorBrush'])">
- <xsl:attribute name="fill"><xsl:value-of select="concat('url(#id_', generate-id(.), ')')" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise><xsl:apply-templates select="*[name(.) = 'SolidColorBrush']" /></xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template mode="defs" match="*[(name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')) and not(*[name(.) = 'SolidColorBrush'])]">
- <defs><xsl:apply-templates mode="forward" /></defs>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Shape.Opacity' or name(.) = concat(name(..), '.Opacity')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Height') or name(.) = concat(name(..), '.Width')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')]">
- <xsl:choose>
- <xsl:when test="not(*[name(.) = 'SolidColorBrush'])">
- <xsl:attribute name="stroke"><xsl:value-of select="concat('url(#id_', generate-id(.), ')')" /></xsl:attribute>
- </xsl:when>
- <xsl:otherwise><xsl:apply-templates select="*[name(.) = 'SolidColorBrush']" /></xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template mode="defs" match="*[(name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')) and not(*[name(.) = 'SolidColorBrush'])]">
- <defs><xsl:apply-templates mode="forward" /></defs>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
- <xsl:attribute name="clip-path"><xsl:value-of select="concat('url(#clippath_', generate-id(.),')')" /></xsl:attribute>
-</xsl:template>
-
-<xsl:template mode="defs" match="*[name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
- <defs>
- <clipPath>
- <xsl:attribute name="id"><xsl:value-of select="concat('clippath_', generate-id(.))" /></xsl:attribute>
- <path>
- <xsl:attribute name="d">
- <xsl:apply-templates mode="forward" />
- </xsl:attribute>
- </path>
- </clipPath>
- </defs>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask')]">
- <xsl:attribute name="mask"><xsl:value-of select="concat('url(#mask_', generate-id(.),')')" /></xsl:attribute>
-</xsl:template>
-
-<xsl:template mode="defs" match="*[name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask')]">
- <defs>
- <mask>
- <xsl:attribute name="id"><xsl:value-of select="concat('mask_', generate-id(.))" /></xsl:attribute>
- <xsl:apply-templates mode="svg" />
- </mask>
- </defs>
-</xsl:template>
-
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+
+Version history:
+
+20070907 Initial release
+20070912 TemplateBinding in template_color
+
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+xmlns:msxsl="urn:schemas-microsoft-com:xslt">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template mode="boundingbox" match="*">
+<xsl:if test="system-property('xsl:vendor') = 'Microsoft'">
+ <xsl:choose>
+ <xsl:when test="@Canvas.Left and @Canvas.Top and @Width and @Height">
+ <boundingbox>
+ <xsl:attribute name="x1">
+ <xsl:value-of select="@Canvas.Left" />
+ </xsl:attribute>
+ <xsl:attribute name="x2">
+ <xsl:value-of select="@Canvas.Left + @Width" />
+ </xsl:attribute>
+ <xsl:attribute name="y1">
+ <xsl:value-of select="@Canvas.Top" />
+ </xsl:attribute>
+ <xsl:attribute name="y2">
+ <xsl:value-of select="@Canvas.Top + @Height" />
+ </xsl:attribute>
+ </boundingbox>
+ </xsl:when>
+ <xsl:when test="count(*) &gt; 0">
+ <xsl:variable name="boundingboxes"><xsl:apply-templates mode="boundingbox" select="*" />
+ </xsl:variable>
+ <boundingbox>
+ <xsl:attribute name="x1">
+ <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
+ <xsl:sort data-type="number" select="@x1" order="ascending"/>
+ <xsl:if test="position() = 1"><xsl:value-of select="@x1" /></xsl:if>
+ </xsl:for-each>
+ </xsl:attribute>
+ <xsl:attribute name="x2">
+ <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
+ <xsl:sort data-type="number" select="@x2" order="descending"/>
+ <xsl:if test="position() = 1"><xsl:value-of select="@x2" /></xsl:if>
+ </xsl:for-each>
+ </xsl:attribute>
+ <xsl:attribute name="y1">
+ <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
+ <xsl:sort data-type="number" select="@y1" order="ascending"/>
+ <xsl:if test="position() = 1"><xsl:value-of select="@y1" /></xsl:if>
+ </xsl:for-each>
+ </xsl:attribute>
+ <xsl:attribute name="y2">
+ <xsl:for-each select="msxsl:node-set($boundingboxes)/boundingbox">
+ <xsl:sort data-type="number" select="@y2" order="descending"/>
+ <xsl:if test="position() = 1"><xsl:value-of select="@y2" /></xsl:if>
+ </xsl:for-each>
+ </xsl:attribute>
+ </boundingbox>
+ </xsl:when>
+ </xsl:choose>
+</xsl:if>
+</xsl:template>
+
+<xsl:template mode="svg" match="*">
+ <xsl:choose>
+ <xsl:when test="false() and name(.) != 'Canvas' and name(.) != 'Image' and name(.) != 'Rect' and name(.) != 'Ellipse' and name(.) != 'Text' and name(.) != 'TextBlock' and (@Canvas.Left or @Canvas.Top)">
+ <svg>
+ <xsl:if test="@Canvas.Left and @Canvas.Top and @Width and @Height">
+ <xsl:attribute name="viewBox">
+ <xsl:value-of select="concat(@Canvas.Left, ' ')" />
+ <xsl:value-of select="concat(@Canvas.Top, ' ')" />
+ <xsl:value-of select="concat(@Width - @Canvas.Left, ' ')" />
+ <xsl:value-of select="@Height - @Canvas.Top" />
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
+ <xsl:apply-templates mode="g" select="." />
+ </svg>
+ </xsl:when>
+ <xsl:otherwise><xsl:apply-templates mode="g" select="." /></xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template mode="g" match="*">
+ <xsl:choose>
+ <xsl:when test="*[(name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')) and not(*[name(.) = 'SolidColorBrush']) or (name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')) and not(*[name(.) = 'SolidColorBrush']) or name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask') or name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
+ <g>
+ <xsl:apply-templates mode="defs" select="." />
+ <xsl:apply-templates mode="forward" select="." />
+ </g>
+ </xsl:when>
+ <xsl:otherwise><xsl:apply-templates mode="forward" select="." /></xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template name="template_color">
+ <xsl:param name="colorspec" />
+ <xsl:choose>
+ <xsl:when test="contains($colorspec, '#') and (string-length($colorspec) = 7 or string-length($colorspec) = 9)">
+ <xsl:value-of select="concat('#', substring($colorspec, string-length($colorspec) - 5, 6))" />
+ </xsl:when>
+ <xsl:when test="contains($colorspec, '#') and (string-length($colorspec) = 4 or string-length($colorspec) = 5)">
+ <xsl:value-of select="concat('#', substring($colorspec, string-length($colorspec) - 5, 3))" />
+ </xsl:when>
+ <xsl:when test="contains($colorspec, '{StaticResource ')"><xsl:value-of select="concat('url(#', substring-before(substring-after($colorspec, '{StaticResource '), '}'), ')')" /></xsl:when>
+ <xsl:when test="contains($colorspec, '{TemplateBinding ')"><xsl:value-of select="concat('url(#', substring-before(substring-after($colorspec, '{TemplateBinding '), '}'), ')')" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="$colorspec" /></xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template name="template_opacity">
+ <xsl:param name="colorspec" />
+ <xsl:if test="contains($colorspec, '#') and (string-length($colorspec) = 4 or string-length($colorspec) = 9)">
+ <xsl:variable name="opacityspec"><xsl:value-of select="translate(substring($colorspec, 2, 2), 'abcdefgh', 'ABCDEFGH')" /></xsl:variable>
+ <xsl:choose>
+ <xsl:when test="$opacityspec != 'FF'">
+ <xsl:value-of select="format-number(number(string-length(substring-before('0123456789ABCDEF', substring($colorspec, 2, 1))) * 16 + string-length(substring-before('0123456789ABCDEF', substring($colorspec, 3, 1)))) div 255, '#0.00')" />
+ </xsl:when>
+ <xsl:otherwise><xsl:value-of select="''"/></xsl:otherwise>
+ </xsl:choose>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template name="template_properties">
+ <xsl:choose>
+ <!--
+ <xsl:when test="@ID"><xsl:attribute name="id"><xsl:value-of select="@ID" /></xsl:attribute></xsl:when>
+ -->
+ <xsl:when test="@x:Key"><xsl:attribute name="id"><xsl:value-of select="@x:Key" /></xsl:attribute></xsl:when>
+ <xsl:when test="@Name"><xsl:attribute name="id"><xsl:value-of select="@Name" /></xsl:attribute></xsl:when>
+ </xsl:choose>
+ <xsl:choose>
+ <xsl:when test="@Fill">
+ <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Fill" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Fill" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0">
+ <xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute>
+ </xsl:if>
+ </xsl:when>
+ <xsl:when test="not(name(.) = 'Canvas') and not(@Foreground or *[name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')])"><xsl:attribute name="fill">none</xsl:attribute></xsl:when>
+ </xsl:choose>
+ <xsl:if test="@Stroke">
+ <xsl:attribute name="stroke"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Stroke" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Stroke" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="stroke-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
+ </xsl:if>
+ <xsl:if test="@StrokeThickness"><xsl:attribute name="stroke-width"><xsl:value-of select="@StrokeThickness" /></xsl:attribute></xsl:if>
+ <xsl:if test="@StrokeMiterLimit"><xsl:attribute name="stroke-miterlimit"><xsl:value-of select="@StrokeMiterLimit" /></xsl:attribute></xsl:if>
+ <xsl:if test="@StrokeDashArray"><xsl:attribute name="stroke-dasharray"><xsl:value-of select="@StrokeDashArray" /></xsl:attribute></xsl:if>
+ <xsl:if test="@StrokeDashOffset"><xsl:attribute name="stroke-dashoffset"><xsl:value-of select="@StrokeDashOffset" /></xsl:attribute></xsl:if>
+ <xsl:if test="@StrokeLineJoin"><xsl:attribute name="stroke-linejoin"><xsl:value-of select="@StrokeLineJoin" /></xsl:attribute></xsl:if>
+ <xsl:if test="@StrokeEndLineCap"><xsl:attribute name="stroke-linecap"><xsl:value-of select="@StrokeEndLineCap" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Opacity"><xsl:attribute name="fill-opacity"><xsl:value-of select="@Opacity" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Color">
+ <xsl:attribute name="fill"><xsl:call-template name="template_color"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:attribute>
+ <xsl:variable name="test_opacity"><xsl:call-template name="template_opacity"><xsl:with-param name="colorspec" select="@Color" /></xsl:call-template></xsl:variable>
+ <xsl:if test="string-length($test_opacity) &gt; 0"><xsl:attribute name="fill-opacity"><xsl:value-of select="$test_opacity" /></xsl:attribute></xsl:if>
+ </xsl:if>
+ <xsl:if test="@Clip">
+ <xsl:choose>
+ <xsl:when test="contains(@Clip, '{')"><xsl:attribute name="fill"><xsl:value-of select="concat('url(#', substring-before(substring-after(@Clip, '{'), '}'), ')')" /></xsl:attribute></xsl:when>
+ <xsl:otherwise>
+ <xsl:attribute name="clip-path"><xsl:value-of select="concat('url(#clippath_', generate-id(.),')')" /></xsl:attribute>
+ <defs>
+ <clipPath>
+ <xsl:attribute name="id"><xsl:value-of select="concat('clippath_', generate-id(.))" /></xsl:attribute>
+ <path>
+ <xsl:attribute name="d">
+ <xsl:choose>
+ <xsl:when test="contains(@Clip, 'F1')"><xsl:value-of select="substring-after(@Clip, 'F1')" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="@Clip" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute></path>
+ </clipPath>
+ </defs>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Resources')]">
+ <defs><xsl:apply-templates mode="forward" /></defs>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Children')]">
+ <xsl:apply-templates mode="forward" />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')]">
+ <xsl:choose>
+ <xsl:when test="not(*[name(.) = 'SolidColorBrush'])">
+ <xsl:attribute name="fill"><xsl:value-of select="concat('url(#id_', generate-id(.), ')')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise><xsl:apply-templates select="*[name(.) = 'SolidColorBrush']" /></xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template mode="defs" match="*[(name(.) = 'Shape.Fill' or name(.) = concat(name(..), '.Fill')) and not(*[name(.) = 'SolidColorBrush'])]">
+ <defs><xsl:apply-templates mode="forward" /></defs>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Shape.Opacity' or name(.) = concat(name(..), '.Opacity')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = concat(name(..), '.Height') or name(.) = concat(name(..), '.Width')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')]">
+ <xsl:choose>
+ <xsl:when test="not(*[name(.) = 'SolidColorBrush'])">
+ <xsl:attribute name="stroke"><xsl:value-of select="concat('url(#id_', generate-id(.), ')')" /></xsl:attribute>
+ </xsl:when>
+ <xsl:otherwise><xsl:apply-templates select="*[name(.) = 'SolidColorBrush']" /></xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
+
+<xsl:template mode="defs" match="*[(name(.) = 'Shape.Stroke' or name(.) = concat(name(..), '.Stroke')) and not(*[name(.) = 'SolidColorBrush'])]">
+ <defs><xsl:apply-templates mode="forward" /></defs>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
+ <xsl:attribute name="clip-path"><xsl:value-of select="concat('url(#clippath_', generate-id(.),')')" /></xsl:attribute>
+</xsl:template>
+
+<xsl:template mode="defs" match="*[name(.) = 'UIElement.Clip' or name(.) = concat(name(..), '.Clip')]">
+ <defs>
+ <clipPath>
+ <xsl:attribute name="id"><xsl:value-of select="concat('clippath_', generate-id(.))" /></xsl:attribute>
+ <path>
+ <xsl:attribute name="d">
+ <xsl:apply-templates mode="forward" />
+ </xsl:attribute>
+ </path>
+ </clipPath>
+ </defs>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask')]">
+ <xsl:attribute name="mask"><xsl:value-of select="concat('url(#mask_', generate-id(.),')')" /></xsl:attribute>
+</xsl:template>
+
+<xsl:template mode="defs" match="*[name(.) = 'UIElement.OpacityMask' or name(.) = concat(name(..), '.OpacityMask')]">
+ <defs>
+ <mask>
+ <xsl:attribute name="id"><xsl:value-of select="concat('mask_', generate-id(.))" /></xsl:attribute>
+ <xsl:apply-templates mode="svg" />
+ </mask>
+ </defs>
+</xsl:template>
+
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/shapes.xsl b/share/extensions/xaml2svg/shapes.xsl
index db300154e..c28b027e1 100644
--- a/share/extensions/xaml2svg/shapes.xsl
+++ b/share/extensions/xaml2svg/shapes.xsl
@@ -1,171 +1,171 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
-
-Version history:
-
-20070907 Initial release
-20070912 starts-with(@Data, 'F0 ') to strip of F0 from path data
-20070912 nonzero and evenodd were outside xsl:attribute (reported by bulia byak and Ted Gould)
-
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:def="Definition"
-exclude-result-prefixes="def">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template mode="forward" match="*[name(.) = 'Path']">
- <path>
- <xsl:if test="@Data">
- <xsl:attribute name="d">
- <xsl:choose>
- <xsl:when test="starts-with(@Data, 'F0 ')"><xsl:value-of select="substring-after(@Data, 'F0 ')" /></xsl:when>
- <xsl:when test="starts-with(@Data, 'F1 ')"><xsl:value-of select="substring-after(@Data, 'F1 ')" /></xsl:when>
- <xsl:otherwise><xsl:value-of select="@Data" /></xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- </xsl:if>
- <xsl:choose>
- <xsl:when test="@FillRule = 'nonzero' or starts-with(@Data, 'F1 ')"><xsl:attribute name="fill-rule">nonzero</xsl:attribute></xsl:when>
- <xsl:when test="@FillRule = 'evenodd' or starts-with(@Data, 'F0 ')"><xsl:attribute name="fill-rule">evenodd</xsl:attribute></xsl:when>
- </xsl:choose>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
- </path>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Path.Data']">
- <xsl:attribute name="d">
- <xsl:apply-templates mode="forward" />
- </xsl:attribute>
- <xsl:if test="@FillRule">
- <xsl:attribute name="fill-rule">
- <xsl:choose>
- <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
- <xsl:otherwise>evenodd</xsl:otherwise>
- </xsl:choose>
- </xsl:attribute>
- </xsl:if>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Line']">
- <line>
- <xsl:if test="@X1"><xsl:attribute name="x1"><xsl:value-of select="@X1" /></xsl:attribute></xsl:if>
- <xsl:if test="@Y1"><xsl:attribute name="y1"><xsl:value-of select="@Y1" /></xsl:attribute></xsl:if>
- <xsl:if test="@X2"><xsl:attribute name="x2"><xsl:value-of select="@X2" /></xsl:attribute></xsl:if>
- <xsl:if test="@Y2"><xsl:attribute name="y2"><xsl:value-of select="@Y2" /></xsl:attribute></xsl:if>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
- </line>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Ellipse']">
- <ellipse>
- <xsl:if test="@Width">
- <xsl:attribute name="rx"><xsl:value-of select="@Width div 2" /></xsl:attribute>
- <xsl:if test="@Canvas.Left">
- <xsl:attribute name="cx"><xsl:value-of select="@Canvas.Left + @Width div 2" /></xsl:attribute>
- </xsl:if>
- </xsl:if>
- <xsl:if test="@Height">
- <xsl:attribute name="ry"><xsl:value-of select="@Height div 2" /></xsl:attribute>
- <xsl:if test="@Canvas.Top">
- <xsl:attribute name="cy"><xsl:value-of select="@Canvas.Top + @Height div 2" /></xsl:attribute>
- </xsl:if>
- </xsl:if>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
- </ellipse>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Rectangle']">
- <rect>
- <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
- <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
- <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
- <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
- <xsl:if test="@RadiusX"><xsl:attribute name="rx"><xsl:value-of select="@RadiusX" /></xsl:attribute></xsl:if>
- <xsl:if test="@RadiusY"><xsl:attribute name="ry"><xsl:value-of select="@RadiusY" /></xsl:attribute></xsl:if>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:call-template name="template_timeline_animations" />
- <xsl:apply-templates mode="forward" />
- </rect>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Polyline']">
- <polyline>
- <xsl:if test="@Points"><xsl:attribute name="points"><xsl:value-of select="@Points" /></xsl:attribute></xsl:if>
- <xsl:attribute name="fill-rule">
- <xsl:choose>
- <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
- <xsl:when test="@FillRule = 'evenodd'">evenodd</xsl:when>
- </xsl:choose>
- </xsl:attribute>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
- </polyline>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Polygon']">
- <polygon>
- <xsl:if test="@Points"><xsl:attribute name="points"><xsl:value-of select="@Points" /></xsl:attribute></xsl:if>
- <xsl:attribute name="fill-rule">
- <xsl:choose>
- <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
- <xsl:when test="@FillRule = 'evenodd'">evenodd</xsl:when>
- </xsl:choose>
- </xsl:attribute>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:apply-templates mode="forward" />
- </polygon>
-</xsl:template>
-
-<xsl:template mode="forward" match="*[name(.) = 'Glyphs']">
- <defs>
- <font-face>
- <xsl:attribute name="font-family"><xsl:value-of select="concat('TrueType ', generate-id(.))" /></xsl:attribute>
- <font-face-src><font-face-uri><xsl:attribute name="xlink:href"><xsl:value-of select="@FontUri" /></xsl:attribute></font-face-uri></font-face-src>
- </font-face>
- </defs>
- <text>
- <xsl:if test="@FontRenderingEmSize"><xsl:attribute name="font-size"><xsl:value-of select="@FontRenderingEmSize" /></xsl:attribute></xsl:if>
- <xsl:if test="@OriginX"><xsl:attribute name="x"><xsl:value-of select="@OriginX" /></xsl:attribute></xsl:if>
- <xsl:if test="@OriginY"><xsl:attribute name="y"><xsl:value-of select="@OriginY" /></xsl:attribute></xsl:if>
- <xsl:attribute name="font-family"><xsl:value-of select="concat('TrueType ', generate-id(.))" /></xsl:attribute>
- <xsl:call-template name="template_properties" />
- <xsl:call-template name="template_transform" />
- <xsl:if test="@UnicodeString"><xsl:value-of select="@UnicodeString" /></xsl:if>
- </text>
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+
+Version history:
+
+20070907 Initial release
+20070912 starts-with(@Data, 'F0 ') to strip of F0 from path data
+20070912 nonzero and evenodd were outside xsl:attribute (reported by bulia byak and Ted Gould)
+
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:def="Definition"
+exclude-result-prefixes="def">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template mode="forward" match="*[name(.) = 'Path']">
+ <path>
+ <xsl:if test="@Data">
+ <xsl:attribute name="d">
+ <xsl:choose>
+ <xsl:when test="starts-with(@Data, 'F0 ')"><xsl:value-of select="substring-after(@Data, 'F0 ')" /></xsl:when>
+ <xsl:when test="starts-with(@Data, 'F1 ')"><xsl:value-of select="substring-after(@Data, 'F1 ')" /></xsl:when>
+ <xsl:otherwise><xsl:value-of select="@Data" /></xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:choose>
+ <xsl:when test="@FillRule = 'nonzero' or starts-with(@Data, 'F1 ')"><xsl:attribute name="fill-rule">nonzero</xsl:attribute></xsl:when>
+ <xsl:when test="@FillRule = 'evenodd' or starts-with(@Data, 'F0 ')"><xsl:attribute name="fill-rule">evenodd</xsl:attribute></xsl:when>
+ </xsl:choose>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+ </path>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Path.Data']">
+ <xsl:attribute name="d">
+ <xsl:apply-templates mode="forward" />
+ </xsl:attribute>
+ <xsl:if test="@FillRule">
+ <xsl:attribute name="fill-rule">
+ <xsl:choose>
+ <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
+ <xsl:otherwise>evenodd</xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ </xsl:if>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Line']">
+ <line>
+ <xsl:if test="@X1"><xsl:attribute name="x1"><xsl:value-of select="@X1" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Y1"><xsl:attribute name="y1"><xsl:value-of select="@Y1" /></xsl:attribute></xsl:if>
+ <xsl:if test="@X2"><xsl:attribute name="x2"><xsl:value-of select="@X2" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Y2"><xsl:attribute name="y2"><xsl:value-of select="@Y2" /></xsl:attribute></xsl:if>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+ </line>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Ellipse']">
+ <ellipse>
+ <xsl:if test="@Width">
+ <xsl:attribute name="rx"><xsl:value-of select="@Width div 2" /></xsl:attribute>
+ <xsl:if test="@Canvas.Left">
+ <xsl:attribute name="cx"><xsl:value-of select="@Canvas.Left + @Width div 2" /></xsl:attribute>
+ </xsl:if>
+ </xsl:if>
+ <xsl:if test="@Height">
+ <xsl:attribute name="ry"><xsl:value-of select="@Height div 2" /></xsl:attribute>
+ <xsl:if test="@Canvas.Top">
+ <xsl:attribute name="cy"><xsl:value-of select="@Canvas.Top + @Height div 2" /></xsl:attribute>
+ </xsl:if>
+ </xsl:if>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+ </ellipse>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Rectangle']">
+ <rect>
+ <xsl:if test="@Canvas.Left"><xsl:attribute name="x"><xsl:value-of select="@Canvas.Left" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Canvas.Top"><xsl:attribute name="y"><xsl:value-of select="@Canvas.Top" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Width"><xsl:attribute name="width"><xsl:value-of select="@Width" /></xsl:attribute></xsl:if>
+ <xsl:if test="@Height"><xsl:attribute name="height"><xsl:value-of select="@Height" /></xsl:attribute></xsl:if>
+ <xsl:if test="@RadiusX"><xsl:attribute name="rx"><xsl:value-of select="@RadiusX" /></xsl:attribute></xsl:if>
+ <xsl:if test="@RadiusY"><xsl:attribute name="ry"><xsl:value-of select="@RadiusY" /></xsl:attribute></xsl:if>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:call-template name="template_timeline_animations" />
+ <xsl:apply-templates mode="forward" />
+ </rect>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Polyline']">
+ <polyline>
+ <xsl:if test="@Points"><xsl:attribute name="points"><xsl:value-of select="@Points" /></xsl:attribute></xsl:if>
+ <xsl:attribute name="fill-rule">
+ <xsl:choose>
+ <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
+ <xsl:when test="@FillRule = 'evenodd'">evenodd</xsl:when>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+ </polyline>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Polygon']">
+ <polygon>
+ <xsl:if test="@Points"><xsl:attribute name="points"><xsl:value-of select="@Points" /></xsl:attribute></xsl:if>
+ <xsl:attribute name="fill-rule">
+ <xsl:choose>
+ <xsl:when test="@FillRule = 'nonzero'">nonzero</xsl:when>
+ <xsl:when test="@FillRule = 'evenodd'">evenodd</xsl:when>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:apply-templates mode="forward" />
+ </polygon>
+</xsl:template>
+
+<xsl:template mode="forward" match="*[name(.) = 'Glyphs']">
+ <defs>
+ <font-face>
+ <xsl:attribute name="font-family"><xsl:value-of select="concat('TrueType ', generate-id(.))" /></xsl:attribute>
+ <font-face-src><font-face-uri><xsl:attribute name="xlink:href"><xsl:value-of select="@FontUri" /></xsl:attribute></font-face-uri></font-face-src>
+ </font-face>
+ </defs>
+ <text>
+ <xsl:if test="@FontRenderingEmSize"><xsl:attribute name="font-size"><xsl:value-of select="@FontRenderingEmSize" /></xsl:attribute></xsl:if>
+ <xsl:if test="@OriginX"><xsl:attribute name="x"><xsl:value-of select="@OriginX" /></xsl:attribute></xsl:if>
+ <xsl:if test="@OriginY"><xsl:attribute name="y"><xsl:value-of select="@OriginY" /></xsl:attribute></xsl:if>
+ <xsl:attribute name="font-family"><xsl:value-of select="concat('TrueType ', generate-id(.))" /></xsl:attribute>
+ <xsl:call-template name="template_properties" />
+ <xsl:call-template name="template_transform" />
+ <xsl:if test="@UnicodeString"><xsl:value-of select="@UnicodeString" /></xsl:if>
+ </text>
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/extensions/xaml2svg/transform.xsl b/share/extensions/xaml2svg/transform.xsl
index 66312dfcb..3d41cf408 100644
--- a/share/extensions/xaml2svg/transform.xsl
+++ b/share/extensions/xaml2svg/transform.xsl
@@ -1,120 +1,120 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-
-<xsl:stylesheet version="1.0"
-xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-xmlns:xlink="http://www.w3.org/1999/xlink"
-xmlns:svg="http://www.w3.org/2000/svg"
-xmlns:def="Definition"
-exclude-result-prefixes="def">
-<xsl:strip-space elements="*" />
-<xsl:output method="xml" encoding="ISO-8859-1"/>
-
-<xsl:template name="template_transform">
- <xsl:variable name="transform_value">
- <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
- <xsl:apply-templates select="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]/*" />
- </xsl:variable>
- <xsl:if test="string-length($transform_value) &gt; 0"><xsl:attribute name="transform"><xsl:value-of select="$transform_value" /></xsl:attribute></xsl:if>
-</xsl:template>
-
-<xsl:template name="template_gradienttransform">
- <xsl:variable name="transform_value">
- <xsl:if test="@Canvas.Left and @Canvas.Top"><xsl:value-of select="concat('translate(', @Canvas.Left, ',', @Canvas.Top, ')')" /></xsl:if>
- <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
- <xsl:apply-templates select="*[name(.) = 'Brush.Transform' or name(.) = concat(name(..), '.Transform')]" />
- <xsl:apply-templates select="*[name(.) = 'Brush.RelativeTransform' or name(.) = concat(name(..), '.RelativeTransform')]" />
- </xsl:variable>
- <xsl:if test="string-length($transform_value) &gt; 0"><xsl:attribute name="gradientTransform"><xsl:value-of select="$transform_value" /></xsl:attribute></xsl:if>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]">
- <!-- xsl:apply-templates /-->
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'Brush.Transform' or name(.) = concat(name(..), '.Transform')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'Brush.RelativeTransform' or name(.) = concat(name(..), '.RelativeTransform')]">
- <xsl:apply-templates />
-</xsl:template>
-
-<!--
-<xsl:template match="*[name(.) = 'TransformCollection' or name(.) = 'TransformGroup']">
- <xsl:apply-templates />
-</xsl:template>
--->
-<xsl:template match="*[name(.) = 'TransformGroup']">
- <xsl:apply-templates />
-</xsl:template>
-
-
-<!--
-<xsl:template mode="forward" match="*[name(.) = 'TransformDecorator']">
- <g>
- <xsl:attribute name="transform">
- <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
- <xsl:apply-templates select="*[name(.) = 'TransformDecorator.Transform']/*" />
- </xsl:attribute>
- <xsl:apply-templates select="*[name(.) = 'TransformDecorator.Transform']/*/*" />
- <xsl:apply-templates mode="forward" select="*[name(.) != 'TransformDecorator.Transform']" />
- </g>
-</xsl:template>
--->
-
-<xsl:template match="*[name(.) = 'TranslateTransform']">
- <xsl:if test="@X">
- <xsl:value-of select="concat('translate(', @X)" />
- <xsl:if test="@Y"><xsl:value-of select="concat(', ', @Y)" /></xsl:if>
- <xsl:value-of select="') '" />
- </xsl:if>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'ScaleTransform']">
- <xsl:if test="@ScaleX">
- <xsl:value-of select="concat('scale(', @ScaleX)" />
- <xsl:if test="@ScaleY"><xsl:value-of select="concat(', ', @ScaleY)" /></xsl:if>
- <xsl:value-of select="') '" />
- </xsl:if>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'RotateTransform']">
- <xsl:if test="@Angle">
- <xsl:value-of select="concat('rotate(', @Angle)" />
- <xsl:if test="@Center"><xsl:value-of select="concat(',', @Center)" /></xsl:if>
- <xsl:value-of select="') '" />
- </xsl:if>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'SkewTransform']">
- <xsl:if test="@AngleX"><xsl:value-of select="concat('skewX(', @AngleX,') ')" /></xsl:if>
- <xsl:if test="@AngleY"><xsl:value-of select="concat('skewY(', @AngleY,') ')" /></xsl:if>
-</xsl:template>
-
-<xsl:template match="*[name(.) = 'MatrixTransform']">
- <xsl:if test="@Matrix"><xsl:value-of select="concat('matrix(', @Matrix,') ')" /></xsl:if>
-</xsl:template>
-
-</xsl:stylesheet>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Copyright (c) 2005-2007 Toine de Greef (a.degreef@chello.nl)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+
+<xsl:stylesheet version="1.0"
+xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+xmlns:xlink="http://www.w3.org/1999/xlink"
+xmlns:svg="http://www.w3.org/2000/svg"
+xmlns:def="Definition"
+exclude-result-prefixes="def">
+<xsl:strip-space elements="*" />
+<xsl:output method="xml" encoding="ISO-8859-1"/>
+
+<xsl:template name="template_transform">
+ <xsl:variable name="transform_value">
+ <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
+ <xsl:apply-templates select="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]/*" />
+ </xsl:variable>
+ <xsl:if test="string-length($transform_value) &gt; 0"><xsl:attribute name="transform"><xsl:value-of select="$transform_value" /></xsl:attribute></xsl:if>
+</xsl:template>
+
+<xsl:template name="template_gradienttransform">
+ <xsl:variable name="transform_value">
+ <xsl:if test="@Canvas.Left and @Canvas.Top"><xsl:value-of select="concat('translate(', @Canvas.Left, ',', @Canvas.Top, ')')" /></xsl:if>
+ <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
+ <xsl:apply-templates select="*[name(.) = 'Brush.Transform' or name(.) = concat(name(..), '.Transform')]" />
+ <xsl:apply-templates select="*[name(.) = 'Brush.RelativeTransform' or name(.) = concat(name(..), '.RelativeTransform')]" />
+ </xsl:variable>
+ <xsl:if test="string-length($transform_value) &gt; 0"><xsl:attribute name="gradientTransform"><xsl:value-of select="$transform_value" /></xsl:attribute></xsl:if>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'UIElement.RenderTransform' or name(.) = 'Shape.RenderTransform' or name(.) = concat(name(..), '.RenderTransform')]">
+ <!-- xsl:apply-templates /-->
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'Brush.Transform' or name(.) = concat(name(..), '.Transform')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'Brush.RelativeTransform' or name(.) = concat(name(..), '.RelativeTransform')]">
+ <xsl:apply-templates />
+</xsl:template>
+
+<!--
+<xsl:template match="*[name(.) = 'TransformCollection' or name(.) = 'TransformGroup']">
+ <xsl:apply-templates />
+</xsl:template>
+-->
+<xsl:template match="*[name(.) = 'TransformGroup']">
+ <xsl:apply-templates />
+</xsl:template>
+
+
+<!--
+<xsl:template mode="forward" match="*[name(.) = 'TransformDecorator']">
+ <g>
+ <xsl:attribute name="transform">
+ <xsl:if test="@Transform"><xsl:value-of select="@Transform" /></xsl:if>
+ <xsl:apply-templates select="*[name(.) = 'TransformDecorator.Transform']/*" />
+ </xsl:attribute>
+ <xsl:apply-templates select="*[name(.) = 'TransformDecorator.Transform']/*/*" />
+ <xsl:apply-templates mode="forward" select="*[name(.) != 'TransformDecorator.Transform']" />
+ </g>
+</xsl:template>
+-->
+
+<xsl:template match="*[name(.) = 'TranslateTransform']">
+ <xsl:if test="@X">
+ <xsl:value-of select="concat('translate(', @X)" />
+ <xsl:if test="@Y"><xsl:value-of select="concat(', ', @Y)" /></xsl:if>
+ <xsl:value-of select="') '" />
+ </xsl:if>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'ScaleTransform']">
+ <xsl:if test="@ScaleX">
+ <xsl:value-of select="concat('scale(', @ScaleX)" />
+ <xsl:if test="@ScaleY"><xsl:value-of select="concat(', ', @ScaleY)" /></xsl:if>
+ <xsl:value-of select="') '" />
+ </xsl:if>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'RotateTransform']">
+ <xsl:if test="@Angle">
+ <xsl:value-of select="concat('rotate(', @Angle)" />
+ <xsl:if test="@Center"><xsl:value-of select="concat(',', @Center)" /></xsl:if>
+ <xsl:value-of select="') '" />
+ </xsl:if>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'SkewTransform']">
+ <xsl:if test="@AngleX"><xsl:value-of select="concat('skewX(', @AngleX,') ')" /></xsl:if>
+ <xsl:if test="@AngleY"><xsl:value-of select="concat('skewY(', @AngleY,') ')" /></xsl:if>
+</xsl:template>
+
+<xsl:template match="*[name(.) = 'MatrixTransform']">
+ <xsl:if test="@Matrix"><xsl:value-of select="concat('matrix(', @Matrix,') ')" /></xsl:if>
+</xsl:template>
+
+</xsl:stylesheet>
diff --git a/share/keys/corel-draw-x4.xml b/share/keys/corel-draw-x4.xml
index e5360c76f..b7259ea4b 100644
--- a/share/keys/corel-draw-x4.xml
+++ b/share/keys/corel-draw-x4.xml
@@ -13,7 +13,7 @@ See default.xml for more information.
<!-- Shaper -->
<bind key="F10" action="ToolNode" display="true"/>
-
+
<!-- Pen -->
<bind key="F12" action="ToolPen" display="true"/>
diff --git a/share/keys/macromedia-freehand-mx.xml b/share/keys/macromedia-freehand-mx.xml
index e2aee42c7..9297f4d2b 100644
--- a/share/keys/macromedia-freehand-mx.xml
+++ b/share/keys/macromedia-freehand-mx.xml
@@ -1,434 +1,434 @@
-<?xml version="1.0"?>
-<keys name="Macromedia Freehand">
-
-<!--
-This is an alternative set of keyboard shortcuts for Inkscape,
-in the style of Macromedia Freehand.
-This set is intended to help experienced Freehand users get
-started with Inkscape. It is not intended for long term use.
-
-Users are encouraged to learn how to use Inkscape which has more
-comprehensive keyboard shortcuts for all kind of features. Also
-users advised to get directly involved and provide feedback to
-developers on how best to improve the default settings for all users.
-
-Use the Preferences dialog to choose these shortcuts or
-if it doesn't exist yet be sure to check the request tracker and
-encourage the developers to add the option to the user interface.
-In the meantime to manually enable these keyboard shortcuts replace the file
-inkscape/share/keys/default.xml with this file.
--->
-
-<!--
-Macromedia Freehand MX toplevel menus:
-File, Edit, View, Modify, Text, Xtras, Window, Help.
--->
-
-<!-- Tools -->
-
- <!-- Selector (Inkscape). Pointer (Freehand). -->
- <bind key="F10" modifiers="Shift" action="ToolSelector" />
- <!-- Holding down the Control (Ctrl) key also toggles back to the Pointer -->
-
- <!-- Node (Inkscape). Subselect (Freehand). No key shortcut. -->
- <bind key="" modifiers="" action="ToolNode" display="false"/>
-
- <bind key="F1" modifiers="Shift" action="ToolRect" display="true"/>
-
- <!-- Freehand has seperate tools for Ellipse and Arc unlike Inkscape. -->
- <bind key="F3" modifiers="Shift" action="ToolArc" display="true"/>
-
- <!-- Star (Inkscape). Polygon (Freehand) inlcudes star options. -->
- <bind key="F8" modifiers="Shift" action="ToolStar" />
-
- <!-- Freehand does not use a keybinding for the Spiral tool.
- Freehand uses F9 for the Reflect Tool. Including anyway for now. -->
- <bind key="F9" action="ToolSpiral" display="true"/>
-
- <bind key="F5" modifiers="Shift" action="ToolPencil" display="true"/>
-
- <bind key="F6" modifiers="Shift" action="ToolPen" display="true"/>
- <!-- Freehand does not use a keybinding for the Calligraphic Pen tool.
- The Calligraphic Pen is hidden under the Pencil tool -->
-
- <bind key="F9" modifiers="Ctrl,Shift" action="ToolText" display="true"/>
-
- <!-- Freehand does not include equivalent tool. Fireworks oddly enough
- has a more advanced gradient tool similar to Inkscape. -->
- <bind key="g" action="ToolGradient" />
- <bind key="G" action="ToolGradient" />
-
- <!-- Freehand includes a Connector tool but no keybinding for it. -->
- <bind key="" modifiers="" action="ToolConnector" display="true"/>
-
- <!-- Freehand includes an Eyedropper tool but no keybinding for it. -->
- <bind key="" action="ToolDropper" display="true"/>
-
-<!-- File -->
-
- <bind key="n" modifiers="Ctrl" action="FileNew" display="true"/>
- <bind key="N" modifiers="Ctrl" action="FileNew" />
-
- <bind key="o" modifiers="Ctrl" action="FileOpen" display="true"/>
- <bind key="O" modifiers="Ctrl" action="FileOpen" />
-
- <bind key="w" modifiers="Ctrl" action="FileClose" display="true"/>
- <bind key="W" modifiers="Ctrl" action="FileClose" display="true"/>
-
- <bind key="" modifiers="" action="FileRevert" />
-
- <bind key="s" modifiers="Ctrl" action="FileSave" display="true"/>
- <bind key="S" modifiers="Ctrl" action="FileSave" />
-
- <bind key="s" modifiers="Ctrl,Shift" action="FileSaveAs" display="true"/>
- <bind key="S" modifiers="Ctrl,Shift" action="FileSaveAs" />
-
- <bind key="p" modifiers="Ctrl" action="FilePrint" display="true"/>
- <bind key="P" modifiers="Ctrl" action="FilePrint" />
-
- <bind key="r" modifiers="Ctrl" action="FileImport" display="true"/>
- <bind key="R" modifiers="Ctrl" action="FileImport" />
-
- <bind key="r" modifiers="Ctrl,Shift" action="FileExport" display="true"/>
- <bind key="R" modifiers="Ctrl,Shift" action="FileExport" />
-
- <bind key="q" modifiers="Ctrl" action="FileQuit" display="true"/>
- <bind key="Q" modifiers="Ctrl" action="FileQuit" display="true"/>
- <!-- Alt+F4 included, do not assume the Window Manager provides it. -->
- <bind key="F4" modifiers="Alt" action="FileQuit" display="true"/>
-
-<!-- Zoom (Inkscape). View, Magnification (Freehand). -->
-
- <!-- Not included in Freehand but including here anyway for sanity.
- Fireworks does use Ctrl+= for Zoom In and Ctrl+- for Zoom Out. -->
- <bind key="plus" action="ZoomIn" display="true"/>
- <bind key="plus" modifiers="Shift" action="ZoomIn" />
- <bind key="equal" action="ZoomIn" />
- <bind key="KP_Add" action="ZoomIn" />
-
- <bind key="minus" action="ZoomOut" display="true"/>
- <bind key="KP_Subtract" action="ZoomOut" />
-
- <!-- Fit Selection Ctrl+Alt+0 -->
- <bind key="0" modifiers="Ctrl,Alt" action="ZoomSelection" display="true"/>
- <!-- Fit to Page Ctrl+Shift+W -->
- <bind key="w" modifiers="Ctrl,Shift" action="ZoomPage" display="true"/>
- <bind key="W" modifiers="Ctrl,Shift" action="ZoomPage" display="true"/>
- <bind key="" action="ZoomPageWidth" />
- <!-- Fit All Ctrl+0 -->
- <bind key="0" modifiers="Ctrl" action="ZoomDrawing" display="true"/>
-
- <!-- Magnification 50% Ctrl+5-->
- <bind key="5" modifiers="Ctrl" action="Zoom1:2" display="true"/>
- <!-- Magnification 100% Ctrl+1 -->
- <bind key="1" modifiers="Ctrl" action="Zoom1:0" display="true"/>
- <!-- Magnification 200% Ctrl+2 -->
- <!-- Magnification 400% Ctrl+4 -->
- <!-- Magnification 800% Ctrl+8 -->
-
-<!-- View -->
-
- <!-- Freehand has no direct equivalent. F11 used by Library palette. -->
- <bind key="" action="FullScreen" display="true"/>
-
- <!-- Freehand has a menu item "Toolbars Ctrl+Alt+T" to hide all Toolbars -->
- <bind key="t" modifiers="Ctrl,Alt" action="ToggleToolbox" display="true"/>
- <bind key="T" modifiers="Ctrl,Alt" action="ToggleToolbox" />
-
- <!-- Freehand "View, Panels F4" also Ctrl+Shift+H
- Fireworks uses "Window, Hide Panels F4" to hide both Panels and Toolbox -->
- <bind key="F4" action="DialogsToggle" display="true"/>
- <bind key="h" modifiers="Ctrl,Shift" action="DialogsToggle" />
- <bind key="H" modifiers="Ctrl,Shift" action="DialogsToggle" />
-
- <!-- No menu items in Freehand but these do cycle through Windows as expected -->
- <bind key="Tab" modifiers="Ctrl" action="NextWindow" />
- <bind key="ISO_Left_Tab" modifiers="Ctrl,Shift" action="NextWindow" />
- <bind key="Tab" modifiers="Ctrl,Shift" action="PrevWindow" />
- <bind key="ISO_Left_Tab" modifiers="Ctrl" action="PrevWindow" />
-
- <!-- Rulers off by default. Looks better and cleaner that way, less busy. -->
- <bind key="r" modifiers="Ctrl,Alt" action="ToggleRulers" display="true"/>
- <bind key="R" modifiers="Ctrl,Alt" action="ToggleRulers" />
-
- <!-- No keybinding or option to toggle Scrollbars. Ctrl+B used for Bold text. -->
- <bind action="ToggleScrollbars" />
-
- <!-- TODO: Freehand "View, Guides, Show Ctrl+;" -->
- <bind key="" modifiers="Ctrl" action="ToggleGuides" display="true"/>
-
- <!-- View, Grid, Show Ctrl+Alt+G. -->
- <bind key="g" modifiers="Ctrl,Alt" action="ToggleGrid" />
- <bind key="G" modifiers="Ctrl,Alt" action="ToggleGrid" />
- <!-- TODO: View, Grid, Snap to Grid Ctrl+Alt+Shift+G. -->
-
- <!-- New View in Inkscape is equivalent to New Window in Freehand. -->
- <bind key="n" modifiers="Shift,Alt" action="ViewNew"/>
- <bind key="N" modifiers="Shift,Alt" action="ViewNew"/>
-
- <bind action="ViewNewPreview"/>
- <bind action="ViewIconPreview"/>
-
- <bind action="ViewModeNormal"/>
- <!-- Wireframe View (Inkscape). Keyline View Ctrl+K (Freehand). -->
- <bind key="K" modifiers="Ctrl" action="ViewModeOutline"/>
-
- <!-- Freehand also has a Fast Mode Ctrl+Shift+K
- which can be used in combination with Keyline. -->
-
-<!-- Edit -->
-
- <bind key="z" modifiers="Ctrl" action="EditUndo" display="true"/>
- <bind key="Z" modifiers="Ctrl" action="EditUndo" />
-
- <bind key="z" modifiers="Ctrl,Shift" action="EditRedo" />
- <bind key="Z" modifiers="Ctrl,Shift" action="EditRedo" />
- <bind key="y" modifiers="Ctrl" action="EditRedo" />
- <bind key="Y" modifiers="Ctrl" action="EditRedo" display="true" />
-
- <bind key="x" modifiers="Ctrl" action="EditCut" display="true"/>
- <bind key="X" modifiers="Ctrl" action="EditCut" />
-
- <bind key="c" modifiers="Ctrl" action="EditCopy" display="true"/>
- <bind key="C" modifiers="Ctrl" action="EditCopy" />
-
- <bind key="v" modifiers="Ctrl" action="EditPaste" display="true"/>
- <bind key="V" modifiers="Ctrl" action="EditPaste" />
-
- <!-- TODO -->
- <!-- Special: Paste Attributes Ctrl+Alt+Shift+V -->
- <!-- Cut Contents Ctrl+shift+X -->
- <!-- Paste Contents Ctrl+shift+V -->
-
- <bind key="Delete" action="EditDelete" display="true"/>
- <bind key="KP_Delete" action="EditDelete" />
- <bind key="BackSpace" action="EditDelete" />
-
- <bind key="d" modifiers="Ctrl,Alt" action="EditDuplicate" display="true"/>
- <bind key="D" modifiers="Ctrl,Alt" action="EditDuplicate" />
-
- <bind key="d" modifiers="Ctrl,Shift" action="EditClone" display="true"/>
- <bind key="D" modifiers="Ctrl,Shift" action="EditClone" />
-
- <bind key="a" modifiers="Ctrl" action="EditSelectAll" display="true"/>
- <bind key="A" modifiers="Ctrl" action="EditSelectAll" />
-
- <!-- Freehand "Edit, Select None Ctrl+D" -->
- <bind key="d" modifiers="Ctrl" action="EditDeselect" display="true"/>
- <bind key="D" modifiers="Ctrl" action="EditDeselect" />
-
- <!-- Freehand "Edit, Select All in Document None Ctrl+Shift+A" -->
- <bind key="a" modifiers="Ctrl,Shift" action="EditSelectAllInAllLayers" display="true"/>
- <bind key="A" modifiers="Ctrl,Shift" action="EditSelectAllInAllLayers" />
-
- <bind action="EditInvert" />
- <bind action="EditInvertInAllLayers" />
- <bind action="EditClearAll" />
-
-<!-- Objects/selection -->
-
- <bind key="h" action="ObjectFlipHorizontally" display="true"/>
- <bind key="H" action="ObjectFlipHorizontally" />
-
- <bind key="v" action="ObjectFlipVertically" display="true"/>
- <bind key="V" action="ObjectFlipVertically" />
-
- <bind key="Home" action="SelectionToFront" display="true"/>
- <bind key="KP_Home" action="SelectionToFront" />
-
- <bind key="End" action="SelectionToBack" display="true"/>
- <bind key="KP_End" action="SelectionToBack" />
-
- <bind key="Page_Up" action="SelectionRaise" display="true"/>
- <bind key="KP_Page_Up" action="SelectionRaise" />
-
- <bind key="Page_Down" action="SelectionLower" display="true"/>
- <bind key="KP_Page_Down" action="SelectionLower" />
-
- <bind key="g" modifiers="Ctrl" action="SelectionGroup" display="true"/>
- <bind key="G" modifiers="Ctrl" action="SelectionGroup" />
- <bind key="g" modifiers="Ctrl,Shift" action="SelectionUnGroup" display="true"/>
- <bind key="G" modifiers="Ctrl,Shift" action="SelectionUnGroup" />
-
- <bind key="b" modifiers="Alt" action="SelectionCreateBitmap" display="true"/>
- <bind key="B" modifiers="Alt" action="SelectionCreateBitmap" />
-
- <bind key="b" modifiers="Alt,Shift" action="SelectionTrace" display="true"/>
- <bind key="B" modifiers="Alt,Shift" action="SelectionTrace" />
-
- <bind key="i" modifiers="Alt" action="ObjectsToPattern" display="true"/>
- <bind key="I" modifiers="Alt" action="ObjectsToPattern" />
-
- <bind key="i" modifiers="Alt,Shift" action="ObjectsFromPattern" display="true"/>
- <bind key="I" modifiers="Alt,Shift" action="ObjectsFromPattern" />
-
- <bind action="ObjectSetMask" />
- <bind action="ObjectUnSetMask" />
-
- <bind action="ObjectSetClipPath" />
- <bind action="ObjectUnSetClipPath" />
-
- <!-- FIXME: currently these bypass the verbs, so the verbs are not bound to ctrl+[] as they should be -->
- <bind action="ObjectRotate90" />
- <bind action="ObjectRotate90CCW" />
-
- <bind action="ObjectRemoveTransform" />
-
-<!-- Path -->
-
- <bind key="c" modifiers="Ctrl,Shift" action="ObjectToPath" display="true"/>
- <bind key="C" modifiers="Ctrl,Shift" action="ObjectToPath" />
-
- <bind key="c" modifiers="Ctrl,Alt" action="StrokeToPath" display="true"/>
- <bind key="C" modifiers="Ctrl,Alt" action="StrokeToPath" />
-
- <bind key="k" modifiers="Ctrl" action="SelectionCombine" display="true"/>
- <bind key="K" modifiers="Ctrl" action="SelectionCombine" />
-
- <bind key="k" modifiers="Ctrl,Shift" action="SelectionBreakApart" display="true"/>
- <bind key="K" modifiers="Ctrl,Shift" action="SelectionBreakApart" />
-
- <bind key="plus" modifiers="Ctrl" action="SelectionUnion" display="true"/>
- <bind key="KP_Add" modifiers="Ctrl" action="SelectionUnion" />
- <bind key="plus" modifiers="Ctrl,Shift" action="SelectionUnion" />
-
- <bind key="asterisk" modifiers="Ctrl" action="SelectionIntersect" display="true"/>
- <bind key="KP_Multiply" modifiers="Ctrl" action="SelectionIntersect" />
- <bind key="asterisk" modifiers="Ctrl,Shift" action="SelectionIntersect" />
-
- <bind key="minus" modifiers="Ctrl" action="SelectionDiff" display="true"/>
- <bind key="underscore" modifiers="Ctrl" action="SelectionDiff" />
- <bind key="underscore" modifiers="Ctrl,Shift" action="SelectionDiff" />
- <bind key="KP_Subtract" modifiers="Ctrl" action="SelectionDiff" />
- <bind key="minus" modifiers="Ctrl,Shift" action="SelectionDiff" />
-
- <bind key="asciicircum" modifiers="Ctrl" action="SelectionSymDiff" display="true"/> <!-- ^ -->
- <bind key="asciicircum" modifiers="Ctrl,Shift" action="SelectionSymDiff" />
-
- <bind key="slash" modifiers="Ctrl,Alt" action="SelectionCutPath" display="true"/>
- <bind key="slash" modifiers="Ctrl,Alt,Shift" action="SelectionCutPath" />
-
- <bind key="slash" modifiers="Ctrl" action="SelectionDivide" display="true"/>
- <bind key="slash" modifiers="Ctrl,Shift" action="SelectionDivide" />
-
- <bind key="parenright" modifiers="Ctrl" action="SelectionOffset" display="true"/>
- <bind key="parenright" modifiers="Ctrl,Shift" action="SelectionOffset" />
- <bind key="0" modifiers="Ctrl,Shift" action="SelectionOffset" />
-
- <bind key="parenright" modifiers="Alt" action="SelectionOffsetScreen" display="true"/>
- <bind key="0" modifiers="Alt" action="SelectionOffsetScreen" />
-
- <bind key="parenright" modifiers="Alt,Shift" action="SelectionOffsetScreen10" display="true"/>
- <bind key="0" modifiers="Alt,Shift" action="SelectionOffsetScreen10" />
-
- <bind key="parenleft" modifiers="Ctrl" action="SelectionInset" display="true"/>
- <bind key="parenleft" modifiers="Ctrl,Shift" action="SelectionInset" />
- <bind key="9" modifiers="Ctrl,Shift" action="SelectionInset" />
-
- <bind key="parenleft" modifiers="Alt" action="SelectionInsetScreen" display="true"/>
- <bind key="9" modifiers="Alt" action="SelectionInsetScreen" />
-
- <bind key="parenleft" modifiers="Alt,Shift" action="SelectionInsetScreen10" display="true"/>
- <bind key="9" modifiers="Alt,Shift" action="SelectionInsetScreen10" />
-
- <bind key="j" modifiers="Ctrl" action="SelectionDynOffset" display="true"/>
- <bind key="J" modifiers="Ctrl" action="SelectionDynOffset" />
-
- <bind key="j" modifiers="Ctrl,Alt" action="SelectionLinkedOffset" display="true"/>
- <bind key="J" modifiers="Ctrl,Alt" action="SelectionLinkedOffset" />
-
- <bind key="l" modifiers="Ctrl" action="SelectionSimplify" display="true"/>
- <bind key="L" modifiers="Ctrl" action="SelectionSimplify" />
-
- <bind action="SelectionReverse" />
-
-<!-- Text -->
-
- <!-- Text, Font, Size, Smaller key="comma" modifiers="Ctrl,Shift" -->
- <!-- Text, Font, Size, Larger key="period" modifiers="Ctrl,Shift" -->
-
- <bind key="w" modifiers="Alt" action="ObjectFlowText" display="true"/>
- <bind key="W" modifiers="Alt" action="ObjectFlowText" />
-
- <bind key="w" modifiers="Alt,Shift" action="ObjectUnFlowText" display="true"/>
- <bind key="W" modifiers="Alt,Shift" action="ObjectUnFlowText" />
-
- <bind action="SelectionTextToPath" />
- <bind action="SelectionTextFromPath" />
-
- <bind action="ObjectFlowtextToText" />
- <bind action="SelectionTextRemoveKerns" />
-
-<!-- Layers -->
-
- <!-- Freehand provides only a limited a Layers palette,
- no menus, no keybindings. -->
- <bind action="LayerNew" />
- <bind action="LayerRename" />
- <bind action="LayerNext" />
- <bind action="LayerPrev" />
- <bind action="LayerDelete" />
- <bind action="LayerRaise" />
- <bind action="LayerLower" />
- <bind action="LayerToTop" />
- <bind action="LayerToBottom" />
- <bind action="LayerMoveToNext" />
- <bind action="LayerMoveToPrev" />
-
-<!-- Dialogs. Freehand has a Window menu listing the various palettes/panels. -->
-
- <!-- Nothing even remotely equivalent -->
- <bind action="DialogXMLEditor" />
- <!-- Equivalent exists but no key binding -->
- <bind action="DialogDocumentProperties" />
-
- <bind key="a" modifiers="Ctrl,Alt" action="DialogAlignDistribute" display="true"/>
- <bind key="A" modifiers="Ctrl,Alt" action="DialogAlignDistribute" />
-
- <!-- No equivalent. Various dialogs.
- Inkscape will probably move this to Tool options bar anyway. -->
- <bind action="DialogText" />
-
- <bind key="u" modifiers="Ctrl" action="DialogPreferences" display="true"/>
- <bind key="U" modifiers="Ctrl" action="DialogPreferences" />
-
- <!-- Object Panel is the closest equivalent in Freehand -->
- <bind key="F3" modifiers="Ctrl" action="DialogFillStroke" display="true"/>
- <bind action="DialogObjectProperties" />
-
- <!-- Freehand has a seperate find and replace for Text and Graphics -->
- <!-- Edit, Find And Replace, Graphics Ctrl+F -->
- <bind key="f" modifiers="Ctrl" action="DialogFind" display="true"/>
- <bind key="F" modifiers="Ctrl" action="DialogFind" />
- <!-- Edit, Find And Replace, Text Ctrl+Shift+F -->
- <bind key="f" modifiers="Ctrl,Shift" action="DialogFind" />
- <bind key="F" modifiers="Ctrl,Shift" action="DialogFind" />
-
- <bind key="m" modifiers="Ctrl" action="DialogTransform" display="true"/>
- <bind key="M" modifiers="Ctrl" action="DialogTransform" />
-
- <!-- Swatches in Freehand is a sub-tab of the Assets Panel. -->
- <bind key="F9" modifiers="Ctrl" action="DialogSwatches" display="true"/>
-
- <bind action="DialogMetadata" />
- <bind action="DialogClonetiler" />
- <bind action="DialogGridArrange" />
- <bind action="DialogScript" />
- <bind action="DialogDebug" />
- <bind action="DialogInput" />
-
- <!-- DialogsToggle (Hide Panels), see above in the View menu section -->
-
-<!-- Help -->
-
- <!-- This is a useful help section section to link to but it might be
- better to later link to an introductory beginners guide. -->
- <bind key="F1" action="HelpKeys" display="true"/>
-
-<!-- Effects (Inkscape). Xtras (Freehand) -->
-
- <!-- Freehand repeats the last Effect without any prompting. -->
- <bind key="equal" modifiers="Ctrl,Shift" action="EffectLast" display="true"/>
- <bind action="EffectLastPref" />
-
-</keys>
+<?xml version="1.0"?>
+<keys name="Macromedia Freehand">
+
+<!--
+This is an alternative set of keyboard shortcuts for Inkscape,
+in the style of Macromedia Freehand.
+This set is intended to help experienced Freehand users get
+started with Inkscape. It is not intended for long term use.
+
+Users are encouraged to learn how to use Inkscape which has more
+comprehensive keyboard shortcuts for all kind of features. Also
+users advised to get directly involved and provide feedback to
+developers on how best to improve the default settings for all users.
+
+Use the Preferences dialog to choose these shortcuts or
+if it doesn't exist yet be sure to check the request tracker and
+encourage the developers to add the option to the user interface.
+In the meantime to manually enable these keyboard shortcuts replace the file
+inkscape/share/keys/default.xml with this file.
+-->
+
+<!--
+Macromedia Freehand MX toplevel menus:
+File, Edit, View, Modify, Text, Xtras, Window, Help.
+-->
+
+<!-- Tools -->
+
+ <!-- Selector (Inkscape). Pointer (Freehand). -->
+ <bind key="F10" modifiers="Shift" action="ToolSelector" />
+ <!-- Holding down the Control (Ctrl) key also toggles back to the Pointer -->
+
+ <!-- Node (Inkscape). Subselect (Freehand). No key shortcut. -->
+ <bind key="" modifiers="" action="ToolNode" display="false"/>
+
+ <bind key="F1" modifiers="Shift" action="ToolRect" display="true"/>
+
+ <!-- Freehand has seperate tools for Ellipse and Arc unlike Inkscape. -->
+ <bind key="F3" modifiers="Shift" action="ToolArc" display="true"/>
+
+ <!-- Star (Inkscape). Polygon (Freehand) inlcudes star options. -->
+ <bind key="F8" modifiers="Shift" action="ToolStar" />
+
+ <!-- Freehand does not use a keybinding for the Spiral tool.
+ Freehand uses F9 for the Reflect Tool. Including anyway for now. -->
+ <bind key="F9" action="ToolSpiral" display="true"/>
+
+ <bind key="F5" modifiers="Shift" action="ToolPencil" display="true"/>
+
+ <bind key="F6" modifiers="Shift" action="ToolPen" display="true"/>
+ <!-- Freehand does not use a keybinding for the Calligraphic Pen tool.
+ The Calligraphic Pen is hidden under the Pencil tool -->
+
+ <bind key="F9" modifiers="Ctrl,Shift" action="ToolText" display="true"/>
+
+ <!-- Freehand does not include equivalent tool. Fireworks oddly enough
+ has a more advanced gradient tool similar to Inkscape. -->
+ <bind key="g" action="ToolGradient" />
+ <bind key="G" action="ToolGradient" />
+
+ <!-- Freehand includes a Connector tool but no keybinding for it. -->
+ <bind key="" modifiers="" action="ToolConnector" display="true"/>
+
+ <!-- Freehand includes an Eyedropper tool but no keybinding for it. -->
+ <bind key="" action="ToolDropper" display="true"/>
+
+<!-- File -->
+
+ <bind key="n" modifiers="Ctrl" action="FileNew" display="true"/>
+ <bind key="N" modifiers="Ctrl" action="FileNew" />
+
+ <bind key="o" modifiers="Ctrl" action="FileOpen" display="true"/>
+ <bind key="O" modifiers="Ctrl" action="FileOpen" />
+
+ <bind key="w" modifiers="Ctrl" action="FileClose" display="true"/>
+ <bind key="W" modifiers="Ctrl" action="FileClose" display="true"/>
+
+ <bind key="" modifiers="" action="FileRevert" />
+
+ <bind key="s" modifiers="Ctrl" action="FileSave" display="true"/>
+ <bind key="S" modifiers="Ctrl" action="FileSave" />
+
+ <bind key="s" modifiers="Ctrl,Shift" action="FileSaveAs" display="true"/>
+ <bind key="S" modifiers="Ctrl,Shift" action="FileSaveAs" />
+
+ <bind key="p" modifiers="Ctrl" action="FilePrint" display="true"/>
+ <bind key="P" modifiers="Ctrl" action="FilePrint" />
+
+ <bind key="r" modifiers="Ctrl" action="FileImport" display="true"/>
+ <bind key="R" modifiers="Ctrl" action="FileImport" />
+
+ <bind key="r" modifiers="Ctrl,Shift" action="FileExport" display="true"/>
+ <bind key="R" modifiers="Ctrl,Shift" action="FileExport" />
+
+ <bind key="q" modifiers="Ctrl" action="FileQuit" display="true"/>
+ <bind key="Q" modifiers="Ctrl" action="FileQuit" display="true"/>
+ <!-- Alt+F4 included, do not assume the Window Manager provides it. -->
+ <bind key="F4" modifiers="Alt" action="FileQuit" display="true"/>
+
+<!-- Zoom (Inkscape). View, Magnification (Freehand). -->
+
+ <!-- Not included in Freehand but including here anyway for sanity.
+ Fireworks does use Ctrl+= for Zoom In and Ctrl+- for Zoom Out. -->
+ <bind key="plus" action="ZoomIn" display="true"/>
+ <bind key="plus" modifiers="Shift" action="ZoomIn" />
+ <bind key="equal" action="ZoomIn" />
+ <bind key="KP_Add" action="ZoomIn" />
+
+ <bind key="minus" action="ZoomOut" display="true"/>
+ <bind key="KP_Subtract" action="ZoomOut" />
+
+ <!-- Fit Selection Ctrl+Alt+0 -->
+ <bind key="0" modifiers="Ctrl,Alt" action="ZoomSelection" display="true"/>
+ <!-- Fit to Page Ctrl+Shift+W -->
+ <bind key="w" modifiers="Ctrl,Shift" action="ZoomPage" display="true"/>
+ <bind key="W" modifiers="Ctrl,Shift" action="ZoomPage" display="true"/>
+ <bind key="" action="ZoomPageWidth" />
+ <!-- Fit All Ctrl+0 -->
+ <bind key="0" modifiers="Ctrl" action="ZoomDrawing" display="true"/>
+
+ <!-- Magnification 50% Ctrl+5-->
+ <bind key="5" modifiers="Ctrl" action="Zoom1:2" display="true"/>
+ <!-- Magnification 100% Ctrl+1 -->
+ <bind key="1" modifiers="Ctrl" action="Zoom1:0" display="true"/>
+ <!-- Magnification 200% Ctrl+2 -->
+ <!-- Magnification 400% Ctrl+4 -->
+ <!-- Magnification 800% Ctrl+8 -->
+
+<!-- View -->
+
+ <!-- Freehand has no direct equivalent. F11 used by Library palette. -->
+ <bind key="" action="FullScreen" display="true"/>
+
+ <!-- Freehand has a menu item "Toolbars Ctrl+Alt+T" to hide all Toolbars -->
+ <bind key="t" modifiers="Ctrl,Alt" action="ToggleToolbox" display="true"/>
+ <bind key="T" modifiers="Ctrl,Alt" action="ToggleToolbox" />
+
+ <!-- Freehand "View, Panels F4" also Ctrl+Shift+H
+ Fireworks uses "Window, Hide Panels F4" to hide both Panels and Toolbox -->
+ <bind key="F4" action="DialogsToggle" display="true"/>
+ <bind key="h" modifiers="Ctrl,Shift" action="DialogsToggle" />
+ <bind key="H" modifiers="Ctrl,Shift" action="DialogsToggle" />
+
+ <!-- No menu items in Freehand but these do cycle through Windows as expected -->
+ <bind key="Tab" modifiers="Ctrl" action="NextWindow" />
+ <bind key="ISO_Left_Tab" modifiers="Ctrl,Shift" action="NextWindow" />
+ <bind key="Tab" modifiers="Ctrl,Shift" action="PrevWindow" />
+ <bind key="ISO_Left_Tab" modifiers="Ctrl" action="PrevWindow" />
+
+ <!-- Rulers off by default. Looks better and cleaner that way, less busy. -->
+ <bind key="r" modifiers="Ctrl,Alt" action="ToggleRulers" display="true"/>
+ <bind key="R" modifiers="Ctrl,Alt" action="ToggleRulers" />
+
+ <!-- No keybinding or option to toggle Scrollbars. Ctrl+B used for Bold text. -->
+ <bind action="ToggleScrollbars" />
+
+ <!-- TODO: Freehand "View, Guides, Show Ctrl+;" -->
+ <bind key="" modifiers="Ctrl" action="ToggleGuides" display="true"/>
+
+ <!-- View, Grid, Show Ctrl+Alt+G. -->
+ <bind key="g" modifiers="Ctrl,Alt" action="ToggleGrid" />
+ <bind key="G" modifiers="Ctrl,Alt" action="ToggleGrid" />
+ <!-- TODO: View, Grid, Snap to Grid Ctrl+Alt+Shift+G. -->
+
+ <!-- New View in Inkscape is equivalent to New Window in Freehand. -->
+ <bind key="n" modifiers="Shift,Alt" action="ViewNew"/>
+ <bind key="N" modifiers="Shift,Alt" action="ViewNew"/>
+
+ <bind action="ViewNewPreview"/>
+ <bind action="ViewIconPreview"/>
+
+ <bind action="ViewModeNormal"/>
+ <!-- Wireframe View (Inkscape). Keyline View Ctrl+K (Freehand). -->
+ <bind key="K" modifiers="Ctrl" action="ViewModeOutline"/>
+
+ <!-- Freehand also has a Fast Mode Ctrl+Shift+K
+ which can be used in combination with Keyline. -->
+
+<!-- Edit -->
+
+ <bind key="z" modifiers="Ctrl" action="EditUndo" display="true"/>
+ <bind key="Z" modifiers="Ctrl" action="EditUndo" />
+
+ <bind key="z" modifiers="Ctrl,Shift" action="EditRedo" />
+ <bind key="Z" modifiers="Ctrl,Shift" action="EditRedo" />
+ <bind key="y" modifiers="Ctrl" action="EditRedo" />
+ <bind key="Y" modifiers="Ctrl" action="EditRedo" display="true" />
+
+ <bind key="x" modifiers="Ctrl" action="EditCut" display="true"/>
+ <bind key="X" modifiers="Ctrl" action="EditCut" />
+
+ <bind key="c" modifiers="Ctrl" action="EditCopy" display="true"/>
+ <bind key="C" modifiers="Ctrl" action="EditCopy" />
+
+ <bind key="v" modifiers="Ctrl" action="EditPaste" display="true"/>
+ <bind key="V" modifiers="Ctrl" action="EditPaste" />
+
+ <!-- TODO -->
+ <!-- Special: Paste Attributes Ctrl+Alt+Shift+V -->
+ <!-- Cut Contents Ctrl+shift+X -->
+ <!-- Paste Contents Ctrl+shift+V -->
+
+ <bind key="Delete" action="EditDelete" display="true"/>
+ <bind key="KP_Delete" action="EditDelete" />
+ <bind key="BackSpace" action="EditDelete" />
+
+ <bind key="d" modifiers="Ctrl,Alt" action="EditDuplicate" display="true"/>
+ <bind key="D" modifiers="Ctrl,Alt" action="EditDuplicate" />
+
+ <bind key="d" modifiers="Ctrl,Shift" action="EditClone" display="true"/>
+ <bind key="D" modifiers="Ctrl,Shift" action="EditClone" />
+
+ <bind key="a" modifiers="Ctrl" action="EditSelectAll" display="true"/>
+ <bind key="A" modifiers="Ctrl" action="EditSelectAll" />
+
+ <!-- Freehand "Edit, Select None Ctrl+D" -->
+ <bind key="d" modifiers="Ctrl" action="EditDeselect" display="true"/>
+ <bind key="D" modifiers="Ctrl" action="EditDeselect" />
+
+ <!-- Freehand "Edit, Select All in Document None Ctrl+Shift+A" -->
+ <bind key="a" modifiers="Ctrl,Shift" action="EditSelectAllInAllLayers" display="true"/>
+ <bind key="A" modifiers="Ctrl,Shift" action="EditSelectAllInAllLayers" />
+
+ <bind action="EditInvert" />
+ <bind action="EditInvertInAllLayers" />
+ <bind action="EditClearAll" />
+
+<!-- Objects/selection -->
+
+ <bind key="h" action="ObjectFlipHorizontally" display="true"/>
+ <bind key="H" action="ObjectFlipHorizontally" />
+
+ <bind key="v" action="ObjectFlipVertically" display="true"/>
+ <bind key="V" action="ObjectFlipVertically" />
+
+ <bind key="Home" action="SelectionToFront" display="true"/>
+ <bind key="KP_Home" action="SelectionToFront" />
+
+ <bind key="End" action="SelectionToBack" display="true"/>
+ <bind key="KP_End" action="SelectionToBack" />
+
+ <bind key="Page_Up" action="SelectionRaise" display="true"/>
+ <bind key="KP_Page_Up" action="SelectionRaise" />
+
+ <bind key="Page_Down" action="SelectionLower" display="true"/>
+ <bind key="KP_Page_Down" action="SelectionLower" />
+
+ <bind key="g" modifiers="Ctrl" action="SelectionGroup" display="true"/>
+ <bind key="G" modifiers="Ctrl" action="SelectionGroup" />
+ <bind key="g" modifiers="Ctrl,Shift" action="SelectionUnGroup" display="true"/>
+ <bind key="G" modifiers="Ctrl,Shift" action="SelectionUnGroup" />
+
+ <bind key="b" modifiers="Alt" action="SelectionCreateBitmap" display="true"/>
+ <bind key="B" modifiers="Alt" action="SelectionCreateBitmap" />
+
+ <bind key="b" modifiers="Alt,Shift" action="SelectionTrace" display="true"/>
+ <bind key="B" modifiers="Alt,Shift" action="SelectionTrace" />
+
+ <bind key="i" modifiers="Alt" action="ObjectsToPattern" display="true"/>
+ <bind key="I" modifiers="Alt" action="ObjectsToPattern" />
+
+ <bind key="i" modifiers="Alt,Shift" action="ObjectsFromPattern" display="true"/>
+ <bind key="I" modifiers="Alt,Shift" action="ObjectsFromPattern" />
+
+ <bind action="ObjectSetMask" />
+ <bind action="ObjectUnSetMask" />
+
+ <bind action="ObjectSetClipPath" />
+ <bind action="ObjectUnSetClipPath" />
+
+ <!-- FIXME: currently these bypass the verbs, so the verbs are not bound to ctrl+[] as they should be -->
+ <bind action="ObjectRotate90" />
+ <bind action="ObjectRotate90CCW" />
+
+ <bind action="ObjectRemoveTransform" />
+
+<!-- Path -->
+
+ <bind key="c" modifiers="Ctrl,Shift" action="ObjectToPath" display="true"/>
+ <bind key="C" modifiers="Ctrl,Shift" action="ObjectToPath" />
+
+ <bind key="c" modifiers="Ctrl,Alt" action="StrokeToPath" display="true"/>
+ <bind key="C" modifiers="Ctrl,Alt" action="StrokeToPath" />
+
+ <bind key="k" modifiers="Ctrl" action="SelectionCombine" display="true"/>
+ <bind key="K" modifiers="Ctrl" action="SelectionCombine" />
+
+ <bind key="k" modifiers="Ctrl,Shift" action="SelectionBreakApart" display="true"/>
+ <bind key="K" modifiers="Ctrl,Shift" action="SelectionBreakApart" />
+
+ <bind key="plus" modifiers="Ctrl" action="SelectionUnion" display="true"/>
+ <bind key="KP_Add" modifiers="Ctrl" action="SelectionUnion" />
+ <bind key="plus" modifiers="Ctrl,Shift" action="SelectionUnion" />
+
+ <bind key="asterisk" modifiers="Ctrl" action="SelectionIntersect" display="true"/>
+ <bind key="KP_Multiply" modifiers="Ctrl" action="SelectionIntersect" />
+ <bind key="asterisk" modifiers="Ctrl,Shift" action="SelectionIntersect" />
+
+ <bind key="minus" modifiers="Ctrl" action="SelectionDiff" display="true"/>
+ <bind key="underscore" modifiers="Ctrl" action="SelectionDiff" />
+ <bind key="underscore" modifiers="Ctrl,Shift" action="SelectionDiff" />
+ <bind key="KP_Subtract" modifiers="Ctrl" action="SelectionDiff" />
+ <bind key="minus" modifiers="Ctrl,Shift" action="SelectionDiff" />
+
+ <bind key="asciicircum" modifiers="Ctrl" action="SelectionSymDiff" display="true"/> <!-- ^ -->
+ <bind key="asciicircum" modifiers="Ctrl,Shift" action="SelectionSymDiff" />
+
+ <bind key="slash" modifiers="Ctrl,Alt" action="SelectionCutPath" display="true"/>
+ <bind key="slash" modifiers="Ctrl,Alt,Shift" action="SelectionCutPath" />
+
+ <bind key="slash" modifiers="Ctrl" action="SelectionDivide" display="true"/>
+ <bind key="slash" modifiers="Ctrl,Shift" action="SelectionDivide" />
+
+ <bind key="parenright" modifiers="Ctrl" action="SelectionOffset" display="true"/>
+ <bind key="parenright" modifiers="Ctrl,Shift" action="SelectionOffset" />
+ <bind key="0" modifiers="Ctrl,Shift" action="SelectionOffset" />
+
+ <bind key="parenright" modifiers="Alt" action="SelectionOffsetScreen" display="true"/>
+ <bind key="0" modifiers="Alt" action="SelectionOffsetScreen" />
+
+ <bind key="parenright" modifiers="Alt,Shift" action="SelectionOffsetScreen10" display="true"/>
+ <bind key="0" modifiers="Alt,Shift" action="SelectionOffsetScreen10" />
+
+ <bind key="parenleft" modifiers="Ctrl" action="SelectionInset" display="true"/>
+ <bind key="parenleft" modifiers="Ctrl,Shift" action="SelectionInset" />
+ <bind key="9" modifiers="Ctrl,Shift" action="SelectionInset" />
+
+ <bind key="parenleft" modifiers="Alt" action="SelectionInsetScreen" display="true"/>
+ <bind key="9" modifiers="Alt" action="SelectionInsetScreen" />
+
+ <bind key="parenleft" modifiers="Alt,Shift" action="SelectionInsetScreen10" display="true"/>
+ <bind key="9" modifiers="Alt,Shift" action="SelectionInsetScreen10" />
+
+ <bind key="j" modifiers="Ctrl" action="SelectionDynOffset" display="true"/>
+ <bind key="J" modifiers="Ctrl" action="SelectionDynOffset" />
+
+ <bind key="j" modifiers="Ctrl,Alt" action="SelectionLinkedOffset" display="true"/>
+ <bind key="J" modifiers="Ctrl,Alt" action="SelectionLinkedOffset" />
+
+ <bind key="l" modifiers="Ctrl" action="SelectionSimplify" display="true"/>
+ <bind key="L" modifiers="Ctrl" action="SelectionSimplify" />
+
+ <bind action="SelectionReverse" />
+
+<!-- Text -->
+
+ <!-- Text, Font, Size, Smaller key="comma" modifiers="Ctrl,Shift" -->
+ <!-- Text, Font, Size, Larger key="period" modifiers="Ctrl,Shift" -->
+
+ <bind key="w" modifiers="Alt" action="ObjectFlowText" display="true"/>
+ <bind key="W" modifiers="Alt" action="ObjectFlowText" />
+
+ <bind key="w" modifiers="Alt,Shift" action="ObjectUnFlowText" display="true"/>
+ <bind key="W" modifiers="Alt,Shift" action="ObjectUnFlowText" />
+
+ <bind action="SelectionTextToPath" />
+ <bind action="SelectionTextFromPath" />
+
+ <bind action="ObjectFlowtextToText" />
+ <bind action="SelectionTextRemoveKerns" />
+
+<!-- Layers -->
+
+ <!-- Freehand provides only a limited a Layers palette,
+ no menus, no keybindings. -->
+ <bind action="LayerNew" />
+ <bind action="LayerRename" />
+ <bind action="LayerNext" />
+ <bind action="LayerPrev" />
+ <bind action="LayerDelete" />
+ <bind action="LayerRaise" />
+ <bind action="LayerLower" />
+ <bind action="LayerToTop" />
+ <bind action="LayerToBottom" />
+ <bind action="LayerMoveToNext" />
+ <bind action="LayerMoveToPrev" />
+
+<!-- Dialogs. Freehand has a Window menu listing the various palettes/panels. -->
+
+ <!-- Nothing even remotely equivalent -->
+ <bind action="DialogXMLEditor" />
+ <!-- Equivalent exists but no key binding -->
+ <bind action="DialogDocumentProperties" />
+
+ <bind key="a" modifiers="Ctrl,Alt" action="DialogAlignDistribute" display="true"/>
+ <bind key="A" modifiers="Ctrl,Alt" action="DialogAlignDistribute" />
+
+ <!-- No equivalent. Various dialogs.
+ Inkscape will probably move this to Tool options bar anyway. -->
+ <bind action="DialogText" />
+
+ <bind key="u" modifiers="Ctrl" action="DialogPreferences" display="true"/>
+ <bind key="U" modifiers="Ctrl" action="DialogPreferences" />
+
+ <!-- Object Panel is the closest equivalent in Freehand -->
+ <bind key="F3" modifiers="Ctrl" action="DialogFillStroke" display="true"/>
+ <bind action="DialogObjectProperties" />
+
+ <!-- Freehand has a seperate find and replace for Text and Graphics -->
+ <!-- Edit, Find And Replace, Graphics Ctrl+F -->
+ <bind key="f" modifiers="Ctrl" action="DialogFind" display="true"/>
+ <bind key="F" modifiers="Ctrl" action="DialogFind" />
+ <!-- Edit, Find And Replace, Text Ctrl+Shift+F -->
+ <bind key="f" modifiers="Ctrl,Shift" action="DialogFind" />
+ <bind key="F" modifiers="Ctrl,Shift" action="DialogFind" />
+
+ <bind key="m" modifiers="Ctrl" action="DialogTransform" display="true"/>
+ <bind key="M" modifiers="Ctrl" action="DialogTransform" />
+
+ <!-- Swatches in Freehand is a sub-tab of the Assets Panel. -->
+ <bind key="F9" modifiers="Ctrl" action="DialogSwatches" display="true"/>
+
+ <bind action="DialogMetadata" />
+ <bind action="DialogClonetiler" />
+ <bind action="DialogGridArrange" />
+ <bind action="DialogScript" />
+ <bind action="DialogDebug" />
+ <bind action="DialogInput" />
+
+ <!-- DialogsToggle (Hide Panels), see above in the View menu section -->
+
+<!-- Help -->
+
+ <!-- This is a useful help section section to link to but it might be
+ better to later link to an introductory beginners guide. -->
+ <bind key="F1" action="HelpKeys" display="true"/>
+
+<!-- Effects (Inkscape). Xtras (Freehand) -->
+
+ <!-- Freehand repeats the last Effect without any prompting. -->
+ <bind key="equal" modifiers="Ctrl,Shift" action="EffectLast" display="true"/>
+ <bind action="EffectLastPref" />
+
+</keys>
diff --git a/src/2geom/!PLEASE DON'T MAKE CHANGES IN THESE FILES.README b/src/2geom/!PLEASE DON'T MAKE CHANGES IN THESE FILES.README
index fdb2212ae..9e4585078 100644
--- a/src/2geom/!PLEASE DON'T MAKE CHANGES IN THESE FILES.README
+++ b/src/2geom/!PLEASE DON'T MAKE CHANGES IN THESE FILES.README
@@ -1,8 +1,8 @@
-All code files in this directory are *direct* copies of the files in 2geom's svn.
-If you want to change the code, please change it in 2geom, then copy the files here.
-Otherwise, I will probably miss that you changed something in Inkscape's copy, and
-destroy your changes by copying 2geom's files over it during the next time I update
-Inkscape's copy of 2geom.
- - Johan Engelen
-
+All code files in this directory are *direct* copies of the files in 2geom's svn.
+If you want to change the code, please change it in 2geom, then copy the files here.
+Otherwise, I will probably miss that you changed something in Inkscape's copy, and
+destroy your changes by copying 2geom's files over it during the next time I update
+Inkscape's copy of 2geom.
+ - Johan Engelen
+
2geom's SVN = https://lib2geom.svn.sourceforge.net/svnroot/lib2geom/lib2geom/trunk \ No newline at end of file
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 2e83a1604..580d65b0c 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -1,598 +1,598 @@
-
-# -----------------------------------------------------------------------------
-# Define the main source
-# -----------------------------------------------------------------------------
-
-set(main_SRC
- main.cpp
-)
-
-set(sp_SRC
- sp-anchor.cpp
- # sp-animation.cpp
- sp-clippath.cpp
- sp-conn-end-pair.cpp
- sp-conn-end.cpp
- sp-cursor.cpp
- sp-defs.cpp
- sp-desc.cpp
- sp-ellipse.cpp
- sp-filter-primitive.cpp
- sp-filter-reference.cpp
- sp-filter.cpp
- sp-flowdiv.cpp
- sp-flowregion.cpp
- sp-flowtext.cpp
- sp-font-face.cpp
- sp-font.cpp
- sp-glyph-kerning.cpp
- sp-glyph.cpp
- sp-gradient-reference.cpp
- sp-gradient.cpp
- sp-guide.cpp
- sp-image.cpp
- sp-item-group.cpp
- sp-item-notify-moveto.cpp
- sp-item-rm-unsatisfied-cns.cpp
- sp-item-transform.cpp
- sp-item-update-cns.cpp
- sp-item.cpp
- sp-line.cpp
- sp-lpe-item.cpp
- sp-mask.cpp
- sp-metadata.cpp
- sp-metrics.cpp
- sp-missing-glyph.cpp
- sp-namedview.cpp
- sp-object-group.cpp
- sp-object-repr.cpp
- sp-object.cpp
- sp-offset.cpp
- sp-paint-server.cpp
- sp-path.cpp
- sp-pattern.cpp
- sp-polygon.cpp
- sp-polyline.cpp
- sp-rect.cpp
- sp-root.cpp
- sp-script.cpp
- sp-shape.cpp
- # sp-skeleton.cpp
- sp-spiral.cpp
- sp-star.cpp
- sp-stop.cpp
- sp-string.cpp
- sp-style-elem.cpp
- sp-switch.cpp
- sp-symbol.cpp
- sp-text.cpp
- sp-title.cpp
- sp-tref-reference.cpp
- sp-tref.cpp
- sp-tspan.cpp
- sp-use-reference.cpp
- sp-use.cpp
- spiral-context.cpp
- splivarot.cpp
-
-
- # -------
- # Headers
- sp-anchor.h
- sp-animation.h
- sp-clippath.h
- sp-conn-end-pair.h
- sp-conn-end.h
- sp-cursor.h
- sp-defs.h
- sp-desc.h
- sp-ellipse.h
- sp-filter-primitive.h
- sp-filter-reference.h
- sp-filter-units.h
- sp-filter.h
- sp-flowdiv.h
- sp-flowregion.h
- sp-flowtext.h
- sp-font-face.h
- sp-font.h
- sp-glyph-kerning.h
- sp-glyph.h
- sp-gradient-fns.h
- sp-gradient-reference.h
- sp-gradient-spread.h
- sp-gradient-test.h
- sp-gradient-units.h
- sp-gradient-vector.h
- sp-gradient.h
- sp-guide-attachment.h
- sp-guide-constraint.h
- sp-guide.h
- sp-image.h
- sp-item-group.h
- sp-item-notify-moveto.h
- sp-item-rm-unsatisfied-cns.h
- sp-item-transform.h
- sp-item-update-cns.h
- sp-item.h
- sp-line.h
- sp-linear-gradient-fns.h
- sp-linear-gradient.h
- sp-lpe-item.h
- sp-marker-loc.h
- sp-mask.h
- sp-metadata.h
- sp-metric.h
- sp-metrics.h
- sp-missing-glyph.h
- sp-namedview.h
- sp-object-group.h
- sp-object-repr.h
- sp-object.h
- sp-offset.h
- sp-paint-server-reference.h
- sp-paint-server.h
- sp-path.h
- sp-pattern.h
- sp-polygon.h
- sp-polyline.h
- sp-radial-gradient-fns.h
- sp-radial-gradient.h
- sp-rect.h
- sp-root.h
- sp-script.h
- sp-shape.h
- # sp-skeleton.h
- sp-spiral.h
- sp-star.h
- sp-stop.h
- sp-string.h
- sp-style-elem-test.h
- sp-style-elem.h
- sp-switch.h
- sp-symbol.h
- sp-text.h
- sp-textpath.h
- sp-title.h
- sp-tref-reference.h
- sp-tref.h
- sp-tspan.h
- sp-use-reference.h
- sp-use.h
-)
-
-set(inkscape_SRC
- arc-context.cpp
- attributes.cpp
- axis-manip.cpp
- box3d-context.cpp
- box3d-side.cpp
- box3d.cpp
- color-profile.cpp
- color.cpp
- common-context.cpp
- composite-undo-stack-observer.cpp
- conditions.cpp
- conn-avoid-ref.cpp
- connection-points.cpp
- connector-context.cpp
- console-output-undo-observer.cpp
- context-fns.cpp
- desktop-events.cpp
- desktop-handles.cpp
- desktop-style.cpp
- desktop.cpp
- device-manager.cpp
- dir-util.cpp
- document-subset.cpp
- document-undo.cpp
- document.cpp
- doxygen-main.cpp
- draw-anchor.cpp
- draw-context.cpp
- dropper-context.cpp
- dyna-draw-context.cpp
- ege-adjustment-action.cpp
- ege-color-prof-tracker.cpp
- ege-output-action.cpp
- ege-select-one-action.cpp
- eraser-context.cpp
- event-context.cpp
- event-log.cpp
- extract-uri.cpp
- file.cpp
- filter-chemistry.cpp
- filter-enums.cpp
- fixes.cpp
- flood-context.cpp
- gc-anchored.cpp
- gc-finalized.cpp
- gc.cpp
- gradient-chemistry.cpp
- gradient-context.cpp
- gradient-drag.cpp
- graphlayout.cpp
- guide-snapper.cpp
- help.cpp
- id-clash.cpp
- ige-mac-menu.c
- ink-action.cpp
- ink-comboboxentry-action.cpp
- inkscape.cpp
- inkscape.rc
- interface.cpp
- knot-holder-entity.cpp
- knot.cpp
- knotholder.cpp
- layer-fns.cpp
- layer-manager.cpp
- line-geometry.cpp
- line-snapper.cpp
- lpe-tool-context.cpp
- main-cmdlineact.cpp
- marker.cpp
- measure-context.cpp
- media.cpp
- message-context.cpp
- message-stack.cpp
- mod360.cpp
- object-edit.cpp
- object-hierarchy.cpp
- object-snapper.cpp
- path-chemistry.cpp
- pen-context.cpp
- pencil-context.cpp
- persp3d-reference.cpp
- persp3d.cpp
- perspective-line.cpp
- preferences.cpp
- prefix.cpp
- print.cpp
- profile-manager.cpp
- proj_pt.cpp
- rdf.cpp
- rect-context.cpp
- removeoverlap.cpp
- resource-manager.cpp
- rubberband.cpp
- satisfied-guide-cns.cpp
- selcue.cpp
- select-context.cpp
- selection-chemistry.cpp
- selection-describer.cpp
- selection.cpp
- seltrans-handles.cpp
- seltrans.cpp
- shape-editor.cpp
- shortcuts.cpp
- snap-preferences.cpp
- snap.cpp
- snapped-curve.cpp
- snapped-line.cpp
- snapped-point.cpp
- snapper.cpp
- spray-context.cpp
- star-context.cpp
- style.cpp
- svg-view-widget.cpp
- svg-view.cpp
- text-chemistry.cpp
- text-context.cpp
- text-editing.cpp
- tools-switch.cpp
- transf_mat_3x4.cpp
- tweak-context.cpp
- unclump.cpp
- unicoderange.cpp
- uri-references.cpp
- uri.cpp
- vanishing-point.cpp
- verbs.cpp
- version.cpp
- zoom-context.cpp
-
-
- # -------
- # Headers
- MultiPrinter.h
- PylogFormatter.h
- TRPIFormatter.h
- approx-equal.h
- arc-context.h
- attributes-test.h
- attributes.h
- axis-manip.h
- bad-uri-exception.h
- box3d-context.h
- box3d-side.h
- box3d.h
- color-profile-fns.h
- color-profile-test.h
- color-profile.h
- color-rgba.h
- color.h
- common-context.h
- composite-undo-stack-observer.h
- conditions.h
- conn-avoid-ref.h
- connection-points.h
- connection-pool.h
- connector-context.h
- console-output-undo-observer.h
- context-fns.h
- decimal-round.h
- desktop-events.h
- desktop-handles.h
- desktop-style.h
- desktop.h
- device-manager.h
- dir-util-test.h
- dir-util.h
- document-private.h
- document-subset.h
- document-undo.h
- document.h
- draw-anchor.h
- draw-context.h
- dropper-context.h
- dyna-draw-context.h
- ege-adjustment-action.h
- ege-color-prof-tracker.h
- ege-output-action.h
- ege-select-one-action.h
- enums.h
- eraser-context.h
- event-context.h
- event-log.h
- event.h
- extract-uri-test.h
- extract-uri.h
- file.h
- fill-or-stroke.h
- filter-chemistry.h
- filter-enums.h
- flood-context.h
- forward.h
- gc-alloc.h
- gc-allocator.h
- gc-anchored.h
- gc-core.h
- gc-finalized.h
- gc-managed.h
- gc-soft-ptr.h
- gradient-chemistry.h
- gradient-context.h
- gradient-drag.h
- graphlayout.h
- guide-snapper.h
- help.h
- helper-fns.h
- icon-size.h
- id-clash.h
- ige-mac-menu.h
- ink-action.h
- ink-comboboxentry-action.h
- inkscape-private.h
- inkscape-version.h
- inkscape.h
- interface.h
- isinf.h
- isnormal.h
- knot-enums.h
- knot-holder-entity.h
- knot.h
- knotholder.h
- layer-fns.h
- layer-manager.h
- line-geometry.h
- line-snapper.h
- lpe-tool-context.h
- macros.h
- main-cmdlineact.h
- marker-test.h
- marker.h
- measure-context.h
- media.h
- memeq.h
- menus-skeleton.h
- message-context.h
- message-stack.h
- message.h
- mod360-test.h
- mod360.h
- modifier-fns.h
- number-opt-number.h
- object-edit.h
- object-hierarchy.h
- object-snapper.h
- path-chemistry.h
- path-prefix.h
- pen-context.h
- pencil-context.h
- persp3d-reference.h
- persp3d.h
- perspective-line.h
- preferences-skeleton.h
- preferences-test.h
- preferences.h
- prefix.h
- print.h
- profile-manager.h
- proj_pt.h
- rdf.h
- rect-context.h
- registrytool.h
- remove-last.h
- removeoverlap.h
- require-config.h
- resource-manager.h
- round-test.h
- round.h
- rubberband.h
- satisfied-guide-cns.h
- selcue.h
- select-context.h
- selection-chemistry.h
- selection-describer.h
- selection.h
- seltrans-handles.h
- seltrans.h
- shape-editor.h
- shortcuts.h
- snap-candidate.h
- snap-enums.h
- snap-preferences.h
- snap.h
- snapped-curve.h
- snapped-line.h
- snapped-point.h
- snapper.h
- spiral-context.h
- splivarot.h
- spray-context.h
- star-context.h
- streq.h
- strneq.h
- style-test.h
- style.h
- svg-profile.h
- svg-view-widget.h
- svg-view.h
- syseq.h
- test-helpers.h
- text-chemistry.h
- text-context.h
- text-editing.h
- text-tag-attributes.h
- tools-switch.h
- transf_mat_3x4.h
- tweak-context.h
- unclump.h
- undo-stack-observer.h
- unicoderange.h
- unit-constants.h
- uri-references.h
- uri.h
- vanishing-point.h
- verbs-test.h
- verbs.h
- version.h
- zoom-context.h
-)
-
-if(WIN32)
- list(APPEND inkscape_SRC
- registrytool.cpp
- #deptool.cpp
- winmain.cpp
- )
-endif()
-
-
-# -----------------------------------------------------------------------------
-# Generate version file
-# -----------------------------------------------------------------------------
-
-# a custom target that is always built
-add_custom_target(
- inkscape_version ALL
- DEPENDS ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp)
-
-# creates inkscape-version.cpp using cmake script
-add_custom_command(
- OUTPUT ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
- COMMAND ${CMAKE_COMMAND}
- -DINKSCAPE_SOURCE_DIR=${CMAKE_SOURCE_DIR}
- -DINKSCAPE_BINARY_DIR=${CMAKE_BINARY_DIR}
- -P ${CMAKE_SOURCE_DIR}/CMakeScripts/inkscape-version.cmake)
-
-# buildinfo.h is a generated file
-set_source_files_properties(
- ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
- PROPERTIES GENERATED TRUE)
-
-list(APPEND inkscape_SRC
- ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
-)
-
-
-# -----------------------------------------------------------------------------
-# Load in subdirectories
-# -----------------------------------------------------------------------------
-
-# All folders for internal inkscape
-# these call add_inkscape_source
-add_subdirectory(bind)
-add_subdirectory(debug)
-add_subdirectory(dialogs)
-add_subdirectory(display)
-add_subdirectory(dom)
-add_subdirectory(extension)
-add_subdirectory(filters)
-add_subdirectory(helper)
-add_subdirectory(io)
-add_subdirectory(live_effects)
-add_subdirectory(svg)
-add_subdirectory(trace)
-add_subdirectory(ui)
-add_subdirectory(util)
-add_subdirectory(widgets)
-add_subdirectory(xml)
-add_subdirectory(2geom)
-
-
-# Directories containing lists files that describe building internal libraries
-add_subdirectory(libavoid)
-add_subdirectory(libcola)
-add_subdirectory(libcroco)
-add_subdirectory(libgdl)
-add_subdirectory(libvpsc)
-add_subdirectory(livarot)
-add_subdirectory(libnr)
-add_subdirectory(libnrtype)
-
-
-get_property(inkscape_global_SRC GLOBAL PROPERTY inkscape_global_SRC)
-
-set(inkscape_SRC
- ${inkscape_global_SRC}
- ${inkscape_SRC}
-)
-
-# -----------------------------------------------------------------------------
-# Setup the executable
-# -----------------------------------------------------------------------------
-add_inkscape_lib(sp_LIB "${sp_SRC}")
-add_inkscape_lib(inkscape_LIB "${inkscape_SRC}")
-
-# make executable for INKSCAPE
-add_executable(inkscape ${main_SRC})
-
-add_dependencies(inkscape inkscape_version)
-
-target_link_libraries(inkscape
- # order from automake
- sp_LIB
- inkscape_LIB
- sp_LIB # annoying, we need both!
-
- nr_LIB
- nrtype_LIB
-
- dom_LIB
- croco_LIB
- avoid_LIB
- gdl_LIB
- cola_LIB
- vpsc_LIB
- livarot_LIB
- 2geom_LIB
-
- ${INKSCAPE_LIBS}
-)
-
-# TODO
-# make executable for INKVIEW
-#add_executable(inkview inkview.cpp)
-# ...
-
+
+# -----------------------------------------------------------------------------
+# Define the main source
+# -----------------------------------------------------------------------------
+
+set(main_SRC
+ main.cpp
+)
+
+set(sp_SRC
+ sp-anchor.cpp
+ # sp-animation.cpp
+ sp-clippath.cpp
+ sp-conn-end-pair.cpp
+ sp-conn-end.cpp
+ sp-cursor.cpp
+ sp-defs.cpp
+ sp-desc.cpp
+ sp-ellipse.cpp
+ sp-filter-primitive.cpp
+ sp-filter-reference.cpp
+ sp-filter.cpp
+ sp-flowdiv.cpp
+ sp-flowregion.cpp
+ sp-flowtext.cpp
+ sp-font-face.cpp
+ sp-font.cpp
+ sp-glyph-kerning.cpp
+ sp-glyph.cpp
+ sp-gradient-reference.cpp
+ sp-gradient.cpp
+ sp-guide.cpp
+ sp-image.cpp
+ sp-item-group.cpp
+ sp-item-notify-moveto.cpp
+ sp-item-rm-unsatisfied-cns.cpp
+ sp-item-transform.cpp
+ sp-item-update-cns.cpp
+ sp-item.cpp
+ sp-line.cpp
+ sp-lpe-item.cpp
+ sp-mask.cpp
+ sp-metadata.cpp
+ sp-metrics.cpp
+ sp-missing-glyph.cpp
+ sp-namedview.cpp
+ sp-object-group.cpp
+ sp-object-repr.cpp
+ sp-object.cpp
+ sp-offset.cpp
+ sp-paint-server.cpp
+ sp-path.cpp
+ sp-pattern.cpp
+ sp-polygon.cpp
+ sp-polyline.cpp
+ sp-rect.cpp
+ sp-root.cpp
+ sp-script.cpp
+ sp-shape.cpp
+ # sp-skeleton.cpp
+ sp-spiral.cpp
+ sp-star.cpp
+ sp-stop.cpp
+ sp-string.cpp
+ sp-style-elem.cpp
+ sp-switch.cpp
+ sp-symbol.cpp
+ sp-text.cpp
+ sp-title.cpp
+ sp-tref-reference.cpp
+ sp-tref.cpp
+ sp-tspan.cpp
+ sp-use-reference.cpp
+ sp-use.cpp
+ spiral-context.cpp
+ splivarot.cpp
+
+
+ # -------
+ # Headers
+ sp-anchor.h
+ sp-animation.h
+ sp-clippath.h
+ sp-conn-end-pair.h
+ sp-conn-end.h
+ sp-cursor.h
+ sp-defs.h
+ sp-desc.h
+ sp-ellipse.h
+ sp-filter-primitive.h
+ sp-filter-reference.h
+ sp-filter-units.h
+ sp-filter.h
+ sp-flowdiv.h
+ sp-flowregion.h
+ sp-flowtext.h
+ sp-font-face.h
+ sp-font.h
+ sp-glyph-kerning.h
+ sp-glyph.h
+ sp-gradient-fns.h
+ sp-gradient-reference.h
+ sp-gradient-spread.h
+ sp-gradient-test.h
+ sp-gradient-units.h
+ sp-gradient-vector.h
+ sp-gradient.h
+ sp-guide-attachment.h
+ sp-guide-constraint.h
+ sp-guide.h
+ sp-image.h
+ sp-item-group.h
+ sp-item-notify-moveto.h
+ sp-item-rm-unsatisfied-cns.h
+ sp-item-transform.h
+ sp-item-update-cns.h
+ sp-item.h
+ sp-line.h
+ sp-linear-gradient-fns.h
+ sp-linear-gradient.h
+ sp-lpe-item.h
+ sp-marker-loc.h
+ sp-mask.h
+ sp-metadata.h
+ sp-metric.h
+ sp-metrics.h
+ sp-missing-glyph.h
+ sp-namedview.h
+ sp-object-group.h
+ sp-object-repr.h
+ sp-object.h
+ sp-offset.h
+ sp-paint-server-reference.h
+ sp-paint-server.h
+ sp-path.h
+ sp-pattern.h
+ sp-polygon.h
+ sp-polyline.h
+ sp-radial-gradient-fns.h
+ sp-radial-gradient.h
+ sp-rect.h
+ sp-root.h
+ sp-script.h
+ sp-shape.h
+ # sp-skeleton.h
+ sp-spiral.h
+ sp-star.h
+ sp-stop.h
+ sp-string.h
+ sp-style-elem-test.h
+ sp-style-elem.h
+ sp-switch.h
+ sp-symbol.h
+ sp-text.h
+ sp-textpath.h
+ sp-title.h
+ sp-tref-reference.h
+ sp-tref.h
+ sp-tspan.h
+ sp-use-reference.h
+ sp-use.h
+)
+
+set(inkscape_SRC
+ arc-context.cpp
+ attributes.cpp
+ axis-manip.cpp
+ box3d-context.cpp
+ box3d-side.cpp
+ box3d.cpp
+ color-profile.cpp
+ color.cpp
+ common-context.cpp
+ composite-undo-stack-observer.cpp
+ conditions.cpp
+ conn-avoid-ref.cpp
+ connection-points.cpp
+ connector-context.cpp
+ console-output-undo-observer.cpp
+ context-fns.cpp
+ desktop-events.cpp
+ desktop-handles.cpp
+ desktop-style.cpp
+ desktop.cpp
+ device-manager.cpp
+ dir-util.cpp
+ document-subset.cpp
+ document-undo.cpp
+ document.cpp
+ doxygen-main.cpp
+ draw-anchor.cpp
+ draw-context.cpp
+ dropper-context.cpp
+ dyna-draw-context.cpp
+ ege-adjustment-action.cpp
+ ege-color-prof-tracker.cpp
+ ege-output-action.cpp
+ ege-select-one-action.cpp
+ eraser-context.cpp
+ event-context.cpp
+ event-log.cpp
+ extract-uri.cpp
+ file.cpp
+ filter-chemistry.cpp
+ filter-enums.cpp
+ fixes.cpp
+ flood-context.cpp
+ gc-anchored.cpp
+ gc-finalized.cpp
+ gc.cpp
+ gradient-chemistry.cpp
+ gradient-context.cpp
+ gradient-drag.cpp
+ graphlayout.cpp
+ guide-snapper.cpp
+ help.cpp
+ id-clash.cpp
+ ige-mac-menu.c
+ ink-action.cpp
+ ink-comboboxentry-action.cpp
+ inkscape.cpp
+ inkscape.rc
+ interface.cpp
+ knot-holder-entity.cpp
+ knot.cpp
+ knotholder.cpp
+ layer-fns.cpp
+ layer-manager.cpp
+ line-geometry.cpp
+ line-snapper.cpp
+ lpe-tool-context.cpp
+ main-cmdlineact.cpp
+ marker.cpp
+ measure-context.cpp
+ media.cpp
+ message-context.cpp
+ message-stack.cpp
+ mod360.cpp
+ object-edit.cpp
+ object-hierarchy.cpp
+ object-snapper.cpp
+ path-chemistry.cpp
+ pen-context.cpp
+ pencil-context.cpp
+ persp3d-reference.cpp
+ persp3d.cpp
+ perspective-line.cpp
+ preferences.cpp
+ prefix.cpp
+ print.cpp
+ profile-manager.cpp
+ proj_pt.cpp
+ rdf.cpp
+ rect-context.cpp
+ removeoverlap.cpp
+ resource-manager.cpp
+ rubberband.cpp
+ satisfied-guide-cns.cpp
+ selcue.cpp
+ select-context.cpp
+ selection-chemistry.cpp
+ selection-describer.cpp
+ selection.cpp
+ seltrans-handles.cpp
+ seltrans.cpp
+ shape-editor.cpp
+ shortcuts.cpp
+ snap-preferences.cpp
+ snap.cpp
+ snapped-curve.cpp
+ snapped-line.cpp
+ snapped-point.cpp
+ snapper.cpp
+ spray-context.cpp
+ star-context.cpp
+ style.cpp
+ svg-view-widget.cpp
+ svg-view.cpp
+ text-chemistry.cpp
+ text-context.cpp
+ text-editing.cpp
+ tools-switch.cpp
+ transf_mat_3x4.cpp
+ tweak-context.cpp
+ unclump.cpp
+ unicoderange.cpp
+ uri-references.cpp
+ uri.cpp
+ vanishing-point.cpp
+ verbs.cpp
+ version.cpp
+ zoom-context.cpp
+
+
+ # -------
+ # Headers
+ MultiPrinter.h
+ PylogFormatter.h
+ TRPIFormatter.h
+ approx-equal.h
+ arc-context.h
+ attributes-test.h
+ attributes.h
+ axis-manip.h
+ bad-uri-exception.h
+ box3d-context.h
+ box3d-side.h
+ box3d.h
+ color-profile-fns.h
+ color-profile-test.h
+ color-profile.h
+ color-rgba.h
+ color.h
+ common-context.h
+ composite-undo-stack-observer.h
+ conditions.h
+ conn-avoid-ref.h
+ connection-points.h
+ connection-pool.h
+ connector-context.h
+ console-output-undo-observer.h
+ context-fns.h
+ decimal-round.h
+ desktop-events.h
+ desktop-handles.h
+ desktop-style.h
+ desktop.h
+ device-manager.h
+ dir-util-test.h
+ dir-util.h
+ document-private.h
+ document-subset.h
+ document-undo.h
+ document.h
+ draw-anchor.h
+ draw-context.h
+ dropper-context.h
+ dyna-draw-context.h
+ ege-adjustment-action.h
+ ege-color-prof-tracker.h
+ ege-output-action.h
+ ege-select-one-action.h
+ enums.h
+ eraser-context.h
+ event-context.h
+ event-log.h
+ event.h
+ extract-uri-test.h
+ extract-uri.h
+ file.h
+ fill-or-stroke.h
+ filter-chemistry.h
+ filter-enums.h
+ flood-context.h
+ forward.h
+ gc-alloc.h
+ gc-allocator.h
+ gc-anchored.h
+ gc-core.h
+ gc-finalized.h
+ gc-managed.h
+ gc-soft-ptr.h
+ gradient-chemistry.h
+ gradient-context.h
+ gradient-drag.h
+ graphlayout.h
+ guide-snapper.h
+ help.h
+ helper-fns.h
+ icon-size.h
+ id-clash.h
+ ige-mac-menu.h
+ ink-action.h
+ ink-comboboxentry-action.h
+ inkscape-private.h
+ inkscape-version.h
+ inkscape.h
+ interface.h
+ isinf.h
+ isnormal.h
+ knot-enums.h
+ knot-holder-entity.h
+ knot.h
+ knotholder.h
+ layer-fns.h
+ layer-manager.h
+ line-geometry.h
+ line-snapper.h
+ lpe-tool-context.h
+ macros.h
+ main-cmdlineact.h
+ marker-test.h
+ marker.h
+ measure-context.h
+ media.h
+ memeq.h
+ menus-skeleton.h
+ message-context.h
+ message-stack.h
+ message.h
+ mod360-test.h
+ mod360.h
+ modifier-fns.h
+ number-opt-number.h
+ object-edit.h
+ object-hierarchy.h
+ object-snapper.h
+ path-chemistry.h
+ path-prefix.h
+ pen-context.h
+ pencil-context.h
+ persp3d-reference.h
+ persp3d.h
+ perspective-line.h
+ preferences-skeleton.h
+ preferences-test.h
+ preferences.h
+ prefix.h
+ print.h
+ profile-manager.h
+ proj_pt.h
+ rdf.h
+ rect-context.h
+ registrytool.h
+ remove-last.h
+ removeoverlap.h
+ require-config.h
+ resource-manager.h
+ round-test.h
+ round.h
+ rubberband.h
+ satisfied-guide-cns.h
+ selcue.h
+ select-context.h
+ selection-chemistry.h
+ selection-describer.h
+ selection.h
+ seltrans-handles.h
+ seltrans.h
+ shape-editor.h
+ shortcuts.h
+ snap-candidate.h
+ snap-enums.h
+ snap-preferences.h
+ snap.h
+ snapped-curve.h
+ snapped-line.h
+ snapped-point.h
+ snapper.h
+ spiral-context.h
+ splivarot.h
+ spray-context.h
+ star-context.h
+ streq.h
+ strneq.h
+ style-test.h
+ style.h
+ svg-profile.h
+ svg-view-widget.h
+ svg-view.h
+ syseq.h
+ test-helpers.h
+ text-chemistry.h
+ text-context.h
+ text-editing.h
+ text-tag-attributes.h
+ tools-switch.h
+ transf_mat_3x4.h
+ tweak-context.h
+ unclump.h
+ undo-stack-observer.h
+ unicoderange.h
+ unit-constants.h
+ uri-references.h
+ uri.h
+ vanishing-point.h
+ verbs-test.h
+ verbs.h
+ version.h
+ zoom-context.h
+)
+
+if(WIN32)
+ list(APPEND inkscape_SRC
+ registrytool.cpp
+ #deptool.cpp
+ winmain.cpp
+ )
+endif()
+
+
+# -----------------------------------------------------------------------------
+# Generate version file
+# -----------------------------------------------------------------------------
+
+# a custom target that is always built
+add_custom_target(
+ inkscape_version ALL
+ DEPENDS ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp)
+
+# creates inkscape-version.cpp using cmake script
+add_custom_command(
+ OUTPUT ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
+ COMMAND ${CMAKE_COMMAND}
+ -DINKSCAPE_SOURCE_DIR=${CMAKE_SOURCE_DIR}
+ -DINKSCAPE_BINARY_DIR=${CMAKE_BINARY_DIR}
+ -P ${CMAKE_SOURCE_DIR}/CMakeScripts/inkscape-version.cmake)
+
+# buildinfo.h is a generated file
+set_source_files_properties(
+ ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
+ PROPERTIES GENERATED TRUE)
+
+list(APPEND inkscape_SRC
+ ${CMAKE_BINARY_DIR}/src/inkscape-version.cpp
+)
+
+
+# -----------------------------------------------------------------------------
+# Load in subdirectories
+# -----------------------------------------------------------------------------
+
+# All folders for internal inkscape
+# these call add_inkscape_source
+add_subdirectory(bind)
+add_subdirectory(debug)
+add_subdirectory(dialogs)
+add_subdirectory(display)
+add_subdirectory(dom)
+add_subdirectory(extension)
+add_subdirectory(filters)
+add_subdirectory(helper)
+add_subdirectory(io)
+add_subdirectory(live_effects)
+add_subdirectory(svg)
+add_subdirectory(trace)
+add_subdirectory(ui)
+add_subdirectory(util)
+add_subdirectory(widgets)
+add_subdirectory(xml)
+add_subdirectory(2geom)
+
+
+# Directories containing lists files that describe building internal libraries
+add_subdirectory(libavoid)
+add_subdirectory(libcola)
+add_subdirectory(libcroco)
+add_subdirectory(libgdl)
+add_subdirectory(libvpsc)
+add_subdirectory(livarot)
+add_subdirectory(libnr)
+add_subdirectory(libnrtype)
+
+
+get_property(inkscape_global_SRC GLOBAL PROPERTY inkscape_global_SRC)
+
+set(inkscape_SRC
+ ${inkscape_global_SRC}
+ ${inkscape_SRC}
+)
+
+# -----------------------------------------------------------------------------
+# Setup the executable
+# -----------------------------------------------------------------------------
+add_inkscape_lib(sp_LIB "${sp_SRC}")
+add_inkscape_lib(inkscape_LIB "${inkscape_SRC}")
+
+# make executable for INKSCAPE
+add_executable(inkscape ${main_SRC})
+
+add_dependencies(inkscape inkscape_version)
+
+target_link_libraries(inkscape
+ # order from automake
+ sp_LIB
+ inkscape_LIB
+ sp_LIB # annoying, we need both!
+
+ nr_LIB
+ nrtype_LIB
+
+ dom_LIB
+ croco_LIB
+ avoid_LIB
+ gdl_LIB
+ cola_LIB
+ vpsc_LIB
+ livarot_LIB
+ 2geom_LIB
+
+ ${INKSCAPE_LIBS}
+)
+
+# TODO
+# make executable for INKVIEW
+#add_executable(inkview inkview.cpp)
+# ...
+
diff --git a/src/dom/mingwenv.bat b/src/dom/mingwenv.bat
index 996566e7b..48e8bf096 100644
--- a/src/dom/mingwenv.bat
+++ b/src/dom/mingwenv.bat
@@ -1,2 +1,2 @@
-set PATH=c:\mingw\bin;%PATH%
-set RM=del
+set PATH=c:\mingw\bin;%PATH%
+set RM=del
diff --git a/src/inkscape-manifest.xml b/src/inkscape-manifest.xml
index fd2f19e43..f9ca4617f 100644
--- a/src/inkscape-manifest.xml
+++ b/src/inkscape-manifest.xml
@@ -1,10 +1,10 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
-<dependency>
-<dependentAssembly>
-<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls"
- version="6.0.0.0" processorArchitecture="X86"
- publicKeyToken="6595b64144ccf1df" language="*"/>
-</dependentAssembly>
-</dependency>
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+<dependency>
+<dependentAssembly>
+<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls"
+ version="6.0.0.0" processorArchitecture="X86"
+ publicKeyToken="6595b64144ccf1df" language="*"/>
+</dependentAssembly>
+</dependency>
</assembly> \ No newline at end of file
diff --git a/src/inkview-manifest.xml b/src/inkview-manifest.xml
index fd2f19e43..f9ca4617f 100644
--- a/src/inkview-manifest.xml
+++ b/src/inkview-manifest.xml
@@ -1,10 +1,10 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
-<dependency>
-<dependentAssembly>
-<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls"
- version="6.0.0.0" processorArchitecture="X86"
- publicKeyToken="6595b64144ccf1df" language="*"/>
-</dependentAssembly>
-</dependency>
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+<dependency>
+<dependentAssembly>
+<assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls"
+ version="6.0.0.0" processorArchitecture="X86"
+ publicKeyToken="6595b64144ccf1df" language="*"/>
+</dependentAssembly>
+</dependency>
</assembly> \ No newline at end of file
diff --git a/src/inkview.rc b/src/inkview.rc
index b2d3da7bc..83bb89ba4 100644
--- a/src/inkview.rc
+++ b/src/inkview.rc
@@ -1,29 +1,29 @@
-
-APPLICATION_ICON ICON DISCARDABLE "../inkscape.ico"
-1 24 DISCARDABLE "./inkview-manifest.xml"
-
-1 VERSIONINFO
- FILEVERSION 0,48,0,9
- PRODUCTVERSION 0,48,0,9
-BEGIN
- BLOCK "StringFileInfo"
- BEGIN
- BLOCK "040901b5"
- BEGIN
- VALUE "Comments", "Published under the GNU GPL"
- VALUE "CompanyName", "inkscape.org"
- VALUE "FileDescription", "Inkview"
- VALUE "FileVersion", "0.48+devel"
- VALUE "InternalName", "Inkview"
- VALUE "LegalCopyright", "© 2010 Inkscape"
- VALUE "ProductName", "Inkview"
- VALUE "ProductVersion", "0.48+devel"
- END
- END
- BLOCK "VarFileInfo"
- BEGIN
- VALUE "Translation", 1033, 437
- END
-END
-
-1000 BITMAP "./show-preview.bmp"
+
+APPLICATION_ICON ICON DISCARDABLE "../inkscape.ico"
+1 24 DISCARDABLE "./inkview-manifest.xml"
+
+1 VERSIONINFO
+ FILEVERSION 0,48,0,9
+ PRODUCTVERSION 0,48,0,9
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "040901b5"
+ BEGIN
+ VALUE "Comments", "Published under the GNU GPL"
+ VALUE "CompanyName", "inkscape.org"
+ VALUE "FileDescription", "Inkview"
+ VALUE "FileVersion", "0.48+devel"
+ VALUE "InternalName", "Inkview"
+ VALUE "LegalCopyright", "© 2010 Inkscape"
+ VALUE "ProductName", "Inkview"
+ VALUE "ProductVersion", "0.48+devel"
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 1033, 437
+ END
+END
+
+1000 BITMAP "./show-preview.bmp"
diff --git a/src/libvpsc/CMakeLists.txt b/src/libvpsc/CMakeLists.txt
index 8db059b5d..4099900b5 100644
--- a/src/libvpsc/CMakeLists.txt
+++ b/src/libvpsc/CMakeLists.txt
@@ -1,29 +1,29 @@
-
-set(libvpsc_SRC
- block.cpp
- blocks.cpp
- constraint.cpp
- csolve_VPSC.cpp
- generate-constraints.cpp
- remove_rectangle_overlap.cpp
- solve_VPSC.cpp
- variable.cpp
- pairingheap/PairingHeap.cpp
-
-
- # -------
- # Headers
- block.h
- blocks.h
- constraint.h
- csolve_VPSC.h
- generate-constraints.h
- pairingheap/PairingHeap.h
- pairingheap/dsexceptions.h
- placement_SolveVPSC.h
- remove_rectangle_overlap.h
- solve_VPSC.h
- variable.h
-)
-
-add_inkscape_lib(vpsc_LIB "${libvpsc_SRC}")
+
+set(libvpsc_SRC
+ block.cpp
+ blocks.cpp
+ constraint.cpp
+ csolve_VPSC.cpp
+ generate-constraints.cpp
+ remove_rectangle_overlap.cpp
+ solve_VPSC.cpp
+ variable.cpp
+ pairingheap/PairingHeap.cpp
+
+
+ # -------
+ # Headers
+ block.h
+ blocks.h
+ constraint.h
+ csolve_VPSC.h
+ generate-constraints.h
+ pairingheap/PairingHeap.h
+ pairingheap/dsexceptions.h
+ placement_SolveVPSC.h
+ remove_rectangle_overlap.h
+ solve_VPSC.h
+ variable.h
+)
+
+add_inkscape_lib(vpsc_LIB "${libvpsc_SRC}")