Merged upstream and Mac OS X build fixes.
This commit is contained in:
commit
32e962e8ee
|
@ -1,4 +1,4 @@
|
|||
include/boost
|
||||
boost_root
|
||||
.downloads-by-cmake
|
||||
common/netlist_keywords.*
|
||||
common/netlist_lexer.h
|
||||
|
|
|
@ -2,7 +2,6 @@ add_definitions(-DPCBNEW)
|
|||
|
||||
include_directories(BEFORE ${INC_BEFORE})
|
||||
include_directories(
|
||||
${Boost_INCLUDE_DIR}
|
||||
../pcbnew
|
||||
../polygon
|
||||
${INC_AFTER}
|
||||
|
|
442
CMakeLists.txt
442
CMakeLists.txt
|
@ -1,10 +1,10 @@
|
|||
project(kicad)
|
||||
project( kicad )
|
||||
|
||||
cmake_minimum_required(VERSION 2.8.4 FATAL_ERROR)
|
||||
cmake_minimum_required( VERSION 2.8.4 FATAL_ERROR )
|
||||
# because of http://public.kitware.com/Bug/view.php?id=10395
|
||||
|
||||
# Path to local CMake modules.
|
||||
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeModules)
|
||||
set( CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeModules )
|
||||
|
||||
#
|
||||
# KiCad build options should be added below.
|
||||
|
@ -14,40 +14,33 @@ set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeModules)
|
|||
# reports.
|
||||
#
|
||||
|
||||
option(USE_PCBNEW_NANOMETRES
|
||||
"Use nanometers for Pcbnew internal units instead of deci-mils (default ON)." ON)
|
||||
|
||||
# Russian GOST patch
|
||||
option(wxUSE_UNICODE "enable/disable building unicode (default OFF)")
|
||||
option(KICAD_GOST "enable/disable building using GOST notation for multiple gates per package (default OFF)")
|
||||
option( wxUSE_UNICODE "enable/disable building unicode ( default OFF)" )
|
||||
option( KICAD_GOST "enable/disable building using GOST notation for multiple gates per package ( default OFF)" )
|
||||
|
||||
#for those who bored with uppercase
|
||||
option(KICAD_KEEPCASE "turn-off automatic component name conversion to uppercase if selected")
|
||||
option( KICAD_KEEPCASE "turn-off automatic component name conversion to uppercase if selected" )
|
||||
|
||||
option(USE_WX_GRAPHICS_CONTEXT
|
||||
"Use wxGraphicsContext for rendering (default OFF). Warning, this is experimental")
|
||||
option( USE_WX_GRAPHICS_CONTEXT
|
||||
"Use wxGraphicsContext for rendering ( default OFF). Warning, this is experimental" )
|
||||
|
||||
option(USE_WX_OVERLAY
|
||||
"Use wxOverlay: Always ON for MAC (default OFF). Warning, this is experimental")
|
||||
option( USE_WX_OVERLAY
|
||||
"Use wxOverlay: Always ON for MAC ( default OFF). Warning, this is experimental" )
|
||||
|
||||
#One of these 2 option *must* be set to ON:
|
||||
option(KICAD_STABLE_VERSION
|
||||
option( KICAD_STABLE_VERSION
|
||||
"set this option to ON to build the stable version of KICAD. mainly used to set version ID (default OFF)"
|
||||
)
|
||||
|
||||
option(KICAD_TESTING_VERSION
|
||||
"set this option to ON to build the testing version of KICAD. mainly used to set version ID (default OFF)"
|
||||
)
|
||||
|
||||
option(KICAD_SCRIPTING
|
||||
option( KICAD_SCRIPTING
|
||||
"set this option ON to build the scripting support inside kicad binaries"
|
||||
)
|
||||
|
||||
option(KICAD_SCRIPTING_MODULES
|
||||
option( KICAD_SCRIPTING_MODULES
|
||||
"set this option ON to build kicad modules that can be used from scripting languages"
|
||||
)
|
||||
|
||||
option(KICAD_SCRIPTING_WXPYTHON
|
||||
option( KICAD_SCRIPTING_WXPYTHON
|
||||
"set this option ON to build wxpython implementation for wx interface building in python and py.shell"
|
||||
)
|
||||
|
||||
|
@ -58,20 +51,16 @@ option(KICAD_SCRIPTING_WXPYTHON
|
|||
# python binary file should be is exec path.
|
||||
|
||||
|
||||
option(USE_FP_LIB_TABLE "Use the new footprint library table implementation. (default OFF)")
|
||||
option( USE_FP_LIB_TABLE "Use the new footprint library table implementation. ( default OFF)" )
|
||||
|
||||
#option( BUILD_GITHUB_PLUGIN "Build the GITHUB_PLUGIN for pcbnew." OFF )
|
||||
|
||||
|
||||
#Set version option (stable or testing)
|
||||
|
||||
if(KICAD_STABLE_VERSION AND KICAD_TESTING_VERSION )
|
||||
message(FATAL_ERROR "Only one KiCad build version option KICAD_TESTING_VERSION or KICAD_STABLE_VERSION can be set to ON")
|
||||
elseif(NOT KICAD_STABLE_VERSION AND NOT KICAD_TESTING_VERSION)
|
||||
message(FATAL_ERROR "Either KiCad build version option KICAD_TESTING_VERSION or KICAD_STABLE_VERSION must be set to ON")
|
||||
elseif(KICAD_STABLE_VERSION)
|
||||
add_definitions(-DKICAD_STABLE_VERSION)
|
||||
message( "Build stable version of KiCad")
|
||||
else()
|
||||
add_definitions(-DKICAD_TESTING_VERSION)
|
||||
message("Build testing (unstable) version of KiCad")
|
||||
if( KICAD_STABLE_VERSION)
|
||||
add_definitions( -DKICAD_STABLE_VERSION )
|
||||
message( STATUS "Building stable version of KiCad" )
|
||||
endif()
|
||||
|
||||
# All CMake downloads go here. Suggested is up in the source tree, not in the build dir where they
|
||||
|
@ -86,14 +75,14 @@ set( DOWNLOAD_DIR ${PROJECT_SOURCE_DIR}/.downloads-by-cmake
|
|||
# Set flags for GCC.
|
||||
#================================================
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX)
|
||||
if( CMAKE_COMPILER_IS_GNUCXX )
|
||||
|
||||
set(KICAD_GCC_RELEASE_BUILD_FLAGS "-O2")
|
||||
set(KICAD_GCC_RELEASE_DEBUG_FLAGS "")
|
||||
set( KICAD_GCC_RELEASE_BUILD_FLAGS "-O2" )
|
||||
set( KICAD_GCC_RELEASE_DEBUG_FLAGS "" )
|
||||
|
||||
execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion
|
||||
execute_process( COMMAND ${CMAKE_C_COMPILER} -dumpversion
|
||||
OUTPUT_VARIABLE GCC_VERSION
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE )
|
||||
|
||||
# Added -Wno-narrowing on 10/7/12 to prevent a huge number of warnings when
|
||||
# compiling with GCC 4.7. This appears to be caused by and int to unsigned
|
||||
|
@ -102,38 +91,38 @@ if(CMAKE_COMPILER_IS_GNUCXX)
|
|||
# see if the problem has been resolved. Wayne.
|
||||
#
|
||||
# Also note the optimization level is -O1 instead of the usual -O2 level
|
||||
# because boost::polygon has a function (inflate polygon) broken by
|
||||
# because boost::polygon has a function ( inflate polygon) broken by
|
||||
# the -O2 level with GCC 4.7 (works fine with with GCC 4.6).
|
||||
# This lower optimization level does not have a significant change on the speed.
|
||||
#
|
||||
# As newer versions of GCC and/or Boost are released, this code needs reviewed to
|
||||
# determine if the problems above have been fixed either in Boost or GCC.
|
||||
if(GCC_VERSION VERSION_GREATER 4.7 OR GCC_VERSION VERSION_EQUAL 4.7)
|
||||
set(KICAD_GCC_RELEASE_BUILD_FLAGS "-Wno-narrowing -O1")
|
||||
set(KICAD_GCC_DEBUG_BUILD_FLAGS "-Wno-narrowing")
|
||||
if( GCC_VERSION VERSION_GREATER 4.7 OR GCC_VERSION VERSION_EQUAL 4.7 )
|
||||
set( KICAD_GCC_RELEASE_BUILD_FLAGS "-Wno-narrowing -O1" )
|
||||
set( KICAD_GCC_DEBUG_BUILD_FLAGS "-Wno-narrowing" )
|
||||
endif()
|
||||
|
||||
if(CMAKE_BUILD_TYPE STREQUAL Debug)
|
||||
message(STATUS
|
||||
"Setting GCC version ${GCC_VERSION} build flags \"${KICAD_GCC_DEBUG_BUILD_FLAGS}\"")
|
||||
if( CMAKE_BUILD_TYPE STREQUAL Debug )
|
||||
message( STATUS
|
||||
"Setting GCC version ${GCC_VERSION} build flags \"${KICAD_GCC_DEBUG_BUILD_FLAGS}\"" )
|
||||
else()
|
||||
message(STATUS
|
||||
"Setting GCC version ${GCC_VERSION} build flags \"${KICAD_GCC_RELEASE_BUILD_FLAGS}\"")
|
||||
message( STATUS
|
||||
"Setting GCC version ${GCC_VERSION} build flags \"${KICAD_GCC_RELEASE_BUILD_FLAGS}\"" )
|
||||
endif()
|
||||
|
||||
if(MINGW)
|
||||
if( MINGW )
|
||||
# According to some sources, under Windows -fPIC option is not needed:
|
||||
# http://mingw.5.n7.nabble.com/Option-fPIC-not-supported-td18480.html
|
||||
|
||||
# Set default flags for Release build.
|
||||
set(CMAKE_C_FLAGS_RELEASE "-Wall ${KICAD_GCC_RELEASE_BUILD_FLAGS} -DNDEBUG")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "-Wall ${KICAD_GCC_RELEASE_BUILD_FLAGS} -DNDEBUG")
|
||||
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "-s -static-libgcc -static-libstdc++")
|
||||
set( CMAKE_C_FLAGS_RELEASE "-Wall ${KICAD_GCC_RELEASE_BUILD_FLAGS} -DNDEBUG" )
|
||||
set( CMAKE_CXX_FLAGS_RELEASE "-Wall ${KICAD_GCC_RELEASE_BUILD_FLAGS} -DNDEBUG" )
|
||||
set( CMAKE_EXE_LINKER_FLAGS_RELEASE "-s -static-libgcc -static-libstdc++" )
|
||||
|
||||
# Set default flags for Debug build.
|
||||
set(CMAKE_C_FLAGS_DEBUG "-Wall ${KICAD_GCC_DEBUG_BUILD_FLAGS} -g3 -ggdb3 -DDEBUG")
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "-Wall ${KICAD_GCC_DEBUG_BUILD_FLAGS} -g3 -ggdb3 -DDEBUG")
|
||||
set(CMAKE_MODULE_LINKER_FLAGS "-static-libgcc -static-libstdc++") # SWIG macros on Windows
|
||||
set( CMAKE_C_FLAGS_DEBUG "-Wall ${KICAD_GCC_DEBUG_BUILD_FLAGS} -g3 -ggdb3 -DDEBUG" )
|
||||
set( CMAKE_CXX_FLAGS_DEBUG "-Wall ${KICAD_GCC_DEBUG_BUILD_FLAGS} -g3 -ggdb3 -DDEBUG" )
|
||||
set( CMAKE_MODULE_LINKER_FLAGS "-static-libgcc -static-libstdc++") # SWIG macros on Windows
|
||||
|
||||
else()
|
||||
# We build DLL/DSOs from static libraries, so create position independent code
|
||||
|
@ -143,17 +132,17 @@ if(CMAKE_COMPILER_IS_GNUCXX)
|
|||
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC" )
|
||||
|
||||
# Thou shalt not link vaporware and tell us it's a valid DSO:
|
||||
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined")
|
||||
set(CMAKE_MODULE_LINKER_FLAGS "-Wl,--no-undefined") # needed by SWIG macros on linux
|
||||
set( CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined" )
|
||||
set( CMAKE_MODULE_LINKER_FLAGS "-Wl,--no-undefined" ) # needed by SWIG macros on linux
|
||||
|
||||
# Set default flags for Release build.
|
||||
set(CMAKE_C_FLAGS_RELEASE "${KICAD_GCC_RELEASE_BUILD_FLAGS} -Wall -DNDEBUG")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${KICAD_GCC_RELEASE_BUILD_FLAGS} -Wall -DNDEBUG")
|
||||
set(CMAKE_EXE_LINKER_FLAGS_RELEASE "-s")
|
||||
set( CMAKE_C_FLAGS_RELEASE "${KICAD_GCC_RELEASE_BUILD_FLAGS} -Wall -DNDEBUG" )
|
||||
set( CMAKE_CXX_FLAGS_RELEASE "${KICAD_GCC_RELEASE_BUILD_FLAGS} -Wall -DNDEBUG" )
|
||||
set( CMAKE_EXE_LINKER_FLAGS_RELEASE "-s" )
|
||||
|
||||
# Set default flags for Debug build.
|
||||
set(CMAKE_C_FLAGS_DEBUG "${KICAD_GCC_DEBUG_BUILD_FLAGS} -Wall -g3 -ggdb3 -DDEBUG")
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${KICAD_GCC_DEBUG_BUILD_FLAGS} -Wall -g3 -ggdb3 -DDEBUG")
|
||||
set( CMAKE_C_FLAGS_DEBUG "${KICAD_GCC_DEBUG_BUILD_FLAGS} -Wall -g3 -ggdb3 -DDEBUG" )
|
||||
set( CMAKE_CXX_FLAGS_DEBUG "${KICAD_GCC_DEBUG_BUILD_FLAGS} -Wall -g3 -ggdb3 -DDEBUG" )
|
||||
endif()
|
||||
|
||||
# quiet GCC 4.8.1 while in boost
|
||||
|
@ -161,100 +150,100 @@ if(CMAKE_COMPILER_IS_GNUCXX)
|
|||
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-local-typedefs" )
|
||||
endif()
|
||||
|
||||
endif(CMAKE_COMPILER_IS_GNUCXX)
|
||||
endif( CMAKE_COMPILER_IS_GNUCXX )
|
||||
|
||||
if(wxUSE_UNICODE)
|
||||
add_definitions(-DwxUSE_UNICODE)
|
||||
if( wxUSE_UNICODE )
|
||||
add_definitions( -DwxUSE_UNICODE )
|
||||
endif()
|
||||
|
||||
if(KICAD_GOST)
|
||||
add_definitions(-DKICAD_GOST)
|
||||
if( KICAD_GOST )
|
||||
add_definitions( -DKICAD_GOST )
|
||||
endif()
|
||||
|
||||
if(KICAD_KEEPCASE)
|
||||
add_definitions(-DKICAD_KEEPCASE)
|
||||
if( KICAD_KEEPCASE )
|
||||
add_definitions( -DKICAD_KEEPCASE )
|
||||
endif()
|
||||
|
||||
if(USE_WX_OVERLAY OR APPLE)
|
||||
add_definitions(-DUSE_WX_OVERLAY)
|
||||
if( USE_WX_OVERLAY OR APPLE )
|
||||
add_definitions( -DUSE_WX_OVERLAY )
|
||||
endif()
|
||||
|
||||
if(KICAD_SCRIPTING)
|
||||
add_definitions(-DKICAD_SCRIPTING)
|
||||
if( KICAD_SCRIPTING )
|
||||
add_definitions( -DKICAD_SCRIPTING )
|
||||
endif()
|
||||
|
||||
if(KICAD_SCRIPTING_MODULES)
|
||||
add_definitions(-DKICAD_SCRIPTING_MODULES)
|
||||
if( KICAD_SCRIPTING_MODULES )
|
||||
add_definitions( -DKICAD_SCRIPTING_MODULES )
|
||||
endif()
|
||||
|
||||
if(KICAD_SCRIPTING_WXPYTHON)
|
||||
add_definitions(-DKICAD_SCRIPTING_WXPYTHON)
|
||||
if( KICAD_SCRIPTING_WXPYTHON )
|
||||
add_definitions( -DKICAD_SCRIPTING_WXPYTHON )
|
||||
endif()
|
||||
|
||||
if(USE_WX_GRAPHICS_CONTEXT)
|
||||
add_definitions(-DUSE_WX_GRAPHICS_CONTEXT)
|
||||
if( USE_WX_GRAPHICS_CONTEXT )
|
||||
add_definitions( -DUSE_WX_GRAPHICS_CONTEXT )
|
||||
endif()
|
||||
|
||||
# Allow user to override the default settings for adding images to menu items. By default
|
||||
# images in menu items are enabled on all platforms except OSX. This can be over ridden by
|
||||
# defining -DUSE_IMAGES_IN_MENUS=ON/OFF to force the preferred behavior.
|
||||
if(NOT DEFINED USE_IMAGES_IN_MENUS)
|
||||
if(NOT APPLE)
|
||||
set(USE_IMAGES_IN_MENUS ON)
|
||||
if( NOT DEFINED USE_IMAGES_IN_MENUS )
|
||||
if( NOT APPLE )
|
||||
set( USE_IMAGES_IN_MENUS ON )
|
||||
endif()
|
||||
else()
|
||||
if(USE_IMAGES_IN_MENUS)
|
||||
set(USE_IMAGES_IN_MENUS ON)
|
||||
if( USE_IMAGES_IN_MENUS )
|
||||
set( USE_IMAGES_IN_MENUS ON )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Locations for install targets.
|
||||
set(KICAD_BIN bin
|
||||
CACHE PATH "Location of KiCad binaries.")
|
||||
set( KICAD_BIN bin
|
||||
CACHE PATH "Location of KiCad binaries." )
|
||||
|
||||
if(UNIX)
|
||||
if( UNIX )
|
||||
# Everything without leading / is relative to CMAKE_INSTALL_PREFIX.
|
||||
set(KICAD_PLUGINS lib/kicad/plugins
|
||||
CACHE PATH "Location of KiCad plugins.")
|
||||
set(KICAD_DATA share/kicad
|
||||
CACHE PATH "Location of KiCad data files.")
|
||||
set(KICAD_DOCS share/doc/kicad
|
||||
CACHE PATH "Location of KiCad documentation files.")
|
||||
set( KICAD_PLUGINS lib/kicad/plugins
|
||||
CACHE PATH "Location of KiCad plugins." )
|
||||
set( KICAD_DATA share/kicad
|
||||
CACHE PATH "Location of KiCad data files." )
|
||||
set( KICAD_DOCS share/doc/kicad
|
||||
CACHE PATH "Location of KiCad documentation files." )
|
||||
endif()
|
||||
|
||||
if(MINGW)
|
||||
if( MINGW )
|
||||
# Like all variables, CMAKE_INSTALL_PREFIX can be over-ridden on the command line.
|
||||
set(CMAKE_INSTALL_PREFIX c:/kicad
|
||||
CACHE PATH "")
|
||||
set( CMAKE_INSTALL_PREFIX c:/kicad
|
||||
CACHE PATH "" )
|
||||
# Everything without leading / is relative to CMAKE_INSTALL_PREFIX.
|
||||
set(KICAD_PLUGINS ${KICAD_BIN}/plugins
|
||||
CACHE PATH "Location of KiCad plugins.")
|
||||
set(KICAD_DATA share
|
||||
CACHE PATH "Location of KiCad data files.")
|
||||
set(KICAD_DOCS doc
|
||||
CACHE PATH "Location of KiCad documentation files.")
|
||||
set( KICAD_PLUGINS ${KICAD_BIN}/plugins
|
||||
CACHE PATH "Location of KiCad plugins." )
|
||||
set( KICAD_DATA share
|
||||
CACHE PATH "Location of KiCad data files." )
|
||||
set( KICAD_DOCS doc
|
||||
CACHE PATH "Location of KiCad documentation files." )
|
||||
endif()
|
||||
|
||||
set(KICAD_DEMOS ${KICAD_DATA}/demos
|
||||
CACHE PATH "Location of KiCad demo files.")
|
||||
set(KICAD_TEMPLATE ${KICAD_DATA}/template
|
||||
CACHE PATH "Location of KiCad template files.")
|
||||
set( KICAD_DEMOS ${KICAD_DATA}/demos
|
||||
CACHE PATH "Location of KiCad demo files." )
|
||||
set( KICAD_TEMPLATE ${KICAD_DATA}/template
|
||||
CACHE PATH "Location of KiCad template files." )
|
||||
|
||||
mark_as_advanced(KICAD_BIN
|
||||
mark_as_advanced( KICAD_BIN
|
||||
KICAD_PLUGINS
|
||||
KICAD_DATA
|
||||
KICAD_DOCS
|
||||
KICAD_DEMOS
|
||||
KICAD_TEMPLATE)
|
||||
KICAD_TEMPLATE )
|
||||
|
||||
include(Functions)
|
||||
include( Functions )
|
||||
|
||||
include( ExternalProject )
|
||||
|
||||
#================================================
|
||||
# Find libraries that are needed to build KiCad.
|
||||
#================================================
|
||||
include(CheckFindPackageResult)
|
||||
include( CheckFindPackageResult )
|
||||
|
||||
# Turn on wxWidgets compatibility mode for some classes
|
||||
add_definitions(-DWX_COMPATIBILITY)
|
||||
|
@ -262,8 +251,8 @@ add_definitions(-DWX_COMPATIBILITY)
|
|||
#######################
|
||||
# Find OpenGL library #
|
||||
#######################
|
||||
find_package(OpenGL QUIET)
|
||||
check_find_package_result(OPENGL_FOUND "OpenGL")
|
||||
find_package( OpenGL QUIET )
|
||||
check_find_package_result( OPENGL_FOUND "OpenGL" )
|
||||
|
||||
#####################
|
||||
# Find GLEW library #
|
||||
|
@ -277,9 +266,8 @@ check_find_package_result(GLEW_FOUND "GLEW")
|
|||
find_package(Cairo 1.8.1 QUIET)
|
||||
check_find_package_result(CAIRO_FOUND "Cairo")
|
||||
|
||||
##########################
|
||||
# Download Boost library #
|
||||
##########################
|
||||
# Download boost and possibly build parts of it
|
||||
#################################################
|
||||
include( download_boost )
|
||||
|
||||
|
||||
|
@ -291,115 +279,129 @@ include( download_boost )
|
|||
# http://www.wxwidgets.org/manuals/2.8/wx_librarieslist.html
|
||||
|
||||
# On Apple only wxwidgets 2.9 or higher doesn't need to find aui part of base
|
||||
if(APPLE)
|
||||
find_package(wxWidgets COMPONENTS gl adv html core net base xml QUIET)
|
||||
else(APPLE)
|
||||
find_package(wxWidgets COMPONENTS gl aui adv html core net base xml QUIET)
|
||||
endif(APPLE)
|
||||
check_find_package_result(wxWidgets_FOUND "wxWidgets")
|
||||
if( APPLE )
|
||||
find_package( wxWidgets COMPONENTS gl adv html core net base xml QUIET )
|
||||
else( APPLE )
|
||||
find_package( wxWidgets COMPONENTS gl aui adv html core net base xml QUIET )
|
||||
endif( APPLE )
|
||||
check_find_package_result( wxWidgets_FOUND "wxWidgets" )
|
||||
|
||||
|
||||
# Include wxWidgets macros.
|
||||
include(${wxWidgets_USE_FILE})
|
||||
include( ${wxWidgets_USE_FILE} )
|
||||
|
||||
# Include MinGW resource compiler.
|
||||
include(MinGWResourceCompiler)
|
||||
include( MinGWResourceCompiler )
|
||||
|
||||
# Generate build system specific header file.
|
||||
include(PerformFeatureChecks)
|
||||
include( PerformFeatureChecks )
|
||||
perform_feature_checks()
|
||||
|
||||
# Find GDI+ on windows if wxGraphicsContext is available.
|
||||
if(MINGW AND USE_WX_GRAPHICS_CONTEXT)
|
||||
find_package(GdiPlus)
|
||||
check_find_package_result(GDI_PLUS_FOUND "GDI+")
|
||||
if( MINGW AND USE_WX_GRAPHICS_CONTEXT )
|
||||
find_package( GdiPlus )
|
||||
check_find_package_result( GDI_PLUS_FOUND "GDI+" )
|
||||
endif()
|
||||
|
||||
# Find Python and other scripting resources
|
||||
if(KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
set(PythonInterp_FIND_VERSION)
|
||||
find_package(PythonInterp)
|
||||
check_find_package_result(PYTHONINTERP_FOUND "Python Interpreter")
|
||||
|
||||
# Get the correct Python site package install path from the Python interpreter found by
|
||||
# FindPythonInterp unless the user specifically defined a custom path.
|
||||
if(NOT PYTHON_SITE_PACKAGE_PATH)
|
||||
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "import distutils.sysconfig;print\"%s\"%distutils.sysconfig.get_python_lib()"
|
||||
OUTPUT_VARIABLE PYTHON_SITE_PACKAGE_PATH
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
|
||||
if(NOT PYTHON_SITE_PACKAGE_PATH)
|
||||
message(FATAL_ERROR "Error occurred while attemping to find the Python site library path.")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(PYTHON_DEST "${PYTHON_SITE_PACKAGE_PATH}" CACHE PATH "Python module install path.")
|
||||
mark_as_advanced(PYTHON_DEST)
|
||||
message( STATUS "Python module install path: ${PYTHON_DEST}")
|
||||
find_package(PythonLibs)
|
||||
include_directories(${PYTHON_INCLUDE_DIRS}
|
||||
./scripting)
|
||||
endif(KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
|
||||
|
||||
|
||||
# Automagically create version header file.
|
||||
include(CreateBzrVersionHeader)
|
||||
create_bzr_version_header()
|
||||
|
||||
if(EXISTS ${CMAKE_SOURCE_DIR}/include/config.h)
|
||||
# This file may exist (created by an alternate process to the svn test above),
|
||||
# e.g. could be created by a checkout script that produces a source tar file.
|
||||
# This directive means the about box will have the svn date & revision in it,
|
||||
# but the hard coded release date (program version) will be preserved.
|
||||
add_definitions(-DHAVE_SVN_REVISION)
|
||||
endif()
|
||||
|
||||
# For include_directories(BEFORE ...), which _reverses_
|
||||
# the order during insertion, so put first wanted last, which is
|
||||
# ${CMAKE_SOURCE_DIR/include. Use '.' for current source dir since
|
||||
# we don't want expansion here and now, and don't need expansion of
|
||||
# ${CMAKE_CURRENT_SOURCE_DIR}, '.' will work for any source directory.
|
||||
set(INC_BEFORE
|
||||
# Assist with header file searching optimization:
|
||||
# INC_BEFORE and INC_AFTER are two lists which go at the front and back of the
|
||||
# header file search lists, respectively.
|
||||
# INC_BEFORE is for use with "include_directories( BEFORE ...)", which _reverses_
|
||||
# the order during insertion. (So put first wanted last, which is
|
||||
# ${CMAKE_SOURCE_DIR/include.) Use '.' for current source dir since
|
||||
# we don't want expansion here and now, which would happen if using ${CMAKE_CURRENT_SOURCE_DIR}.
|
||||
# Instead we use '.' which is applicable to any source directory below here as a result of
|
||||
# this lack of expansion.
|
||||
set( INC_BEFORE
|
||||
.
|
||||
${CMAKE_SOURCE_DIR}/include
|
||||
)
|
||||
|
||||
set(INC_AFTER
|
||||
set( INC_AFTER
|
||||
${Boost_INCLUDE_DIR}
|
||||
#include <config.h>
|
||||
${CMAKE_BINARY_DIR}
|
||||
)
|
||||
|
||||
|
||||
# Find Python and other scripting resources
|
||||
if( KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES )
|
||||
set( PythonInterp_FIND_VERSION )
|
||||
find_package( PythonInterp )
|
||||
check_find_package_result( PYTHONINTERP_FOUND "Python Interpreter" )
|
||||
|
||||
# Get the correct Python site package install path from the Python interpreter found by
|
||||
# FindPythonInterp unless the user specifically defined a custom path.
|
||||
if( NOT PYTHON_SITE_PACKAGE_PATH )
|
||||
execute_process( COMMAND ${PYTHON_EXECUTABLE} -c "import distutils.sysconfig;print\"%s\"%distutils.sysconfig.get_python_lib()"
|
||||
OUTPUT_VARIABLE PYTHON_SITE_PACKAGE_PATH
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
|
||||
if( NOT PYTHON_SITE_PACKAGE_PATH )
|
||||
message( FATAL_ERROR "Error occurred while attemping to find the Python site library path." )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set( PYTHON_DEST "${PYTHON_SITE_PACKAGE_PATH}" CACHE PATH "Python module install path." )
|
||||
mark_as_advanced( PYTHON_DEST )
|
||||
message( STATUS "Python module install path: ${PYTHON_DEST}" )
|
||||
|
||||
find_package( PythonLibs )
|
||||
|
||||
#message( STATUS "PYTHON_INCLUDE_DIRS:${PYTHON_INCLUDE_DIRS}" )
|
||||
|
||||
# Infrequently needed headers go at end of search paths, append to INC_AFTER which
|
||||
# although is used for all components, should be a harmless hit for something like eeschema
|
||||
# so long as unused search paths are at the end like this.
|
||||
set( INC_AFTER ${INC_AFTER} ${PYTHON_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR}/scripting )
|
||||
|
||||
#message( STATUS "/ INC_AFTER:${INC_AFTER}" )
|
||||
|
||||
endif()
|
||||
|
||||
|
||||
# Automagically create version header file.
|
||||
include( CreateBzrVersionHeader )
|
||||
create_bzr_version_header()
|
||||
|
||||
if( EXISTS ${CMAKE_SOURCE_DIR}/include/config.h )
|
||||
# This file may exist ( created by an alternate process to the svn test above),
|
||||
# e.g. could be created by a checkout script that produces a source tar file.
|
||||
# This directive means the about box will have the svn date & revision in it,
|
||||
# but the hard coded release date ( program version) will be preserved.
|
||||
add_definitions( -DHAVE_SVN_REVISION )
|
||||
endif()
|
||||
|
||||
|
||||
#================================================
|
||||
# Let CMake look in these directories for nested
|
||||
# 'CMakeLists.txt' files to process
|
||||
#================================================
|
||||
|
||||
############################
|
||||
# Binaries (CMake targets) #
|
||||
# Binaries ( CMake targets ) #
|
||||
############################
|
||||
|
||||
add_subdirectory(bitmaps_png)
|
||||
add_subdirectory(common)
|
||||
add_subdirectory(3d-viewer)
|
||||
add_subdirectory(cvpcb)
|
||||
add_subdirectory(eeschema)
|
||||
add_subdirectory(gerbview)
|
||||
add_subdirectory(kicad)
|
||||
add_subdirectory(pcbnew)
|
||||
add_subdirectory(pcbnew/pcad2kicadpcb_plugin)
|
||||
add_subdirectory(polygon)
|
||||
add_subdirectory(pagelayout_editor)
|
||||
add_subdirectory(potrace)
|
||||
add_subdirectory(bitmap2component)
|
||||
add_subdirectory(pcb_calculator)
|
||||
add_subdirectory(tools)
|
||||
#add_subdirectory(new)
|
||||
add_subdirectory( bitmaps_png )
|
||||
add_subdirectory( common )
|
||||
add_subdirectory( 3d-viewer )
|
||||
add_subdirectory( cvpcb )
|
||||
add_subdirectory( eeschema )
|
||||
add_subdirectory( gerbview )
|
||||
add_subdirectory( kicad )
|
||||
add_subdirectory( pcbnew )
|
||||
add_subdirectory( polygon )
|
||||
add_subdirectory( pagelayout_editor )
|
||||
add_subdirectory( potrace )
|
||||
add_subdirectory( bitmap2component )
|
||||
add_subdirectory( pcb_calculator )
|
||||
add_subdirectory( tools )
|
||||
#add_subdirectory( new )
|
||||
|
||||
|
||||
# Make all libs and executables depend on ExternalProject_Add( boost ),
|
||||
# except perhaps bitmap lib
|
||||
# except perhaps bitmap lib. This allows a multi-threaded build to succeed.
|
||||
add_dependencies( pcbnew boost )
|
||||
add_dependencies( eeschema boost )
|
||||
add_dependencies( cvpcb boost )
|
||||
|
@ -415,14 +417,14 @@ add_dependencies( pl_editor boost )
|
|||
#############
|
||||
# Resources #
|
||||
#############
|
||||
add_subdirectory(demos)
|
||||
add_subdirectory(template)
|
||||
add_subdirectory( demos )
|
||||
add_subdirectory( template )
|
||||
|
||||
#================================================
|
||||
# Doxygen Output
|
||||
#================================================
|
||||
find_package(Doxygen)
|
||||
if(DOXYGEN_FOUND)
|
||||
find_package( Doxygen )
|
||||
if( DOXYGEN_FOUND )
|
||||
add_custom_target( doxygen-docs
|
||||
${CMAKE_COMMAND} -E remove_directory Documentation/doxygen
|
||||
COMMAND ${DOXYGEN_EXECUTABLE}
|
||||
|
@ -441,67 +443,67 @@ endif()
|
|||
configure_file(
|
||||
"${CMAKE_MODULE_PATH}/cmake_uninstall.cmake.in"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
|
||||
IMMEDIATE @ONLY)
|
||||
IMMEDIATE @ONLY )
|
||||
|
||||
add_custom_target(uninstall
|
||||
"${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake")
|
||||
add_custom_target( uninstall
|
||||
"${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" )
|
||||
|
||||
|
||||
#================================================
|
||||
# Installation parameters
|
||||
#================================================
|
||||
install(FILES INSTALL.txt
|
||||
install( FILES INSTALL.txt
|
||||
DESTINATION ${KICAD_DOCS}
|
||||
COMPONENT resources)
|
||||
COMPONENT resources )
|
||||
|
||||
install(FILES resources/freeroute.jnlp
|
||||
install( FILES resources/freeroute.jnlp
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT resources)
|
||||
COMPONENT resources )
|
||||
|
||||
###
|
||||
# Install scripts
|
||||
###
|
||||
if(UNIX)
|
||||
install(DIRECTORY scripts
|
||||
if( UNIX )
|
||||
install( DIRECTORY scripts
|
||||
DESTINATION ${KICAD_DOCS}
|
||||
COMPONENT resources
|
||||
PATTERN ".svn" EXCLUDE)
|
||||
PATTERN ".svn" EXCLUDE )
|
||||
endif()
|
||||
|
||||
###
|
||||
# FreeDesktop .desktop and MIME resources
|
||||
###
|
||||
if(UNIX)
|
||||
if( UNIX )
|
||||
# Set paths
|
||||
set(UNIX_MIME_DIR resources/linux/mime)
|
||||
set(UNIX_MIMELNK_FILES ${UNIX_MIME_DIR}/mimelnk)
|
||||
set(UNIX_MIME_FILES ${UNIX_MIME_DIR}/mime)
|
||||
set(UNIX_ICONS_FILES ${UNIX_MIME_DIR}/icons)
|
||||
set(UNIX_APPLICATIONS_FILES ${UNIX_MIME_DIR}/applications)
|
||||
set( UNIX_MIME_DIR resources/linux/mime )
|
||||
set( UNIX_MIMELNK_FILES ${UNIX_MIME_DIR}/mimelnk )
|
||||
set( UNIX_MIME_FILES ${UNIX_MIME_DIR}/mime )
|
||||
set( UNIX_ICONS_FILES ${UNIX_MIME_DIR}/icons )
|
||||
set( UNIX_APPLICATIONS_FILES ${UNIX_MIME_DIR}/applications )
|
||||
|
||||
# Install Mimelnk directory
|
||||
install(DIRECTORY ${UNIX_MIMELNK_FILES}
|
||||
install( DIRECTORY ${UNIX_MIMELNK_FILES}
|
||||
DESTINATION ${CMAKE_INSTALL_PREFIX}/share
|
||||
COMPONENT resources
|
||||
PATTERN ".svn" EXCLUDE)
|
||||
PATTERN ".svn" EXCLUDE )
|
||||
|
||||
# Install Mime directory
|
||||
install(DIRECTORY ${UNIX_ICONS_FILES}
|
||||
install( DIRECTORY ${UNIX_ICONS_FILES}
|
||||
DESTINATION ${CMAKE_INSTALL_PREFIX}/share
|
||||
COMPONENT resources
|
||||
PATTERN ".svn" EXCLUDE)
|
||||
PATTERN ".svn" EXCLUDE )
|
||||
|
||||
# Install Icons
|
||||
install(DIRECTORY ${UNIX_MIME_FILES}
|
||||
install( DIRECTORY ${UNIX_MIME_FILES}
|
||||
DESTINATION ${CMAKE_INSTALL_PREFIX}/share
|
||||
COMPONENT resources
|
||||
PATTERN ".svn" EXCLUDE)
|
||||
PATTERN ".svn" EXCLUDE )
|
||||
|
||||
# Install Applications directory (.desktop files)
|
||||
install(DIRECTORY ${UNIX_APPLICATIONS_FILES}
|
||||
install( DIRECTORY ${UNIX_APPLICATIONS_FILES}
|
||||
DESTINATION ${CMAKE_INSTALL_PREFIX}/share
|
||||
COMPONENT resources
|
||||
PATTERN ".svn" EXCLUDE)
|
||||
PATTERN ".svn" EXCLUDE )
|
||||
endif()
|
||||
|
||||
include(CTest)
|
||||
include( CTest )
|
||||
|
|
|
@ -75,17 +75,14 @@
|
|||
|
||||
#cmakedefine USE_IMAGES_IN_MENUS 1
|
||||
|
||||
/// Definitions to enable the s-expression file formats and nanometer units.
|
||||
#cmakedefine USE_PCBNEW_NANOMETRES
|
||||
|
||||
/// The legacy file format revision of the *.brd file created by this build
|
||||
#if defined(USE_PCBNEW_NANOMETRES)
|
||||
#define LEGACY_BOARD_FILE_VERSION 2
|
||||
#else
|
||||
#define LEGACY_BOARD_FILE_VERSION 1
|
||||
#endif
|
||||
#define LEGACY_BOARD_FILE_VERSION 2
|
||||
|
||||
/// Definition to compile with Pcbnew footprint library table implementation.
|
||||
#cmakedefine USE_FP_LIB_TABLE
|
||||
|
||||
/// When defined, build the GITHUB_PLUGIN for pcbnew.
|
||||
#cmakedefine BUILD_GITHUB_PLUGIN
|
||||
|
||||
|
||||
#endif // CONFIG_H_
|
||||
|
|
|
@ -22,11 +22,43 @@
|
|||
|
||||
|
||||
|
||||
# Download and patch boost headers to a particular version.
|
||||
# Assumes include( ExternalProject ) was done inline previous to this file.
|
||||
# Download a particular boost version, and patch it [and build it if BUILD_GITHUB_PLUGIN].
|
||||
# Assumes include( ExternalProject ) was done inline previous to this file
|
||||
# and that set( DOWNLOAD_DIR ... ) was set in a higher context.
|
||||
|
||||
|
||||
#-----<configure>----------------------------------------------------------------
|
||||
|
||||
if( false )
|
||||
set( BOOST_RELEASE 1.53.0 )
|
||||
set( BOOST_MD5 a00d22605d5dbcfb4c9936a9b35bc4c2 ) # re-calc this on every RELEASE change
|
||||
else()
|
||||
set( BOOST_RELEASE 1.54.0 )
|
||||
set( BOOST_MD5 15cb8c0803064faef0c4ddf5bc5ca279 ) # re-calc this on every RELEASE change
|
||||
endif()
|
||||
|
||||
# The boost headers [and static libs if built] go here, at the top of KiCad
|
||||
# source tree in boost_root.
|
||||
set( BOOST_ROOT "${PROJECT_SOURCE_DIR}/boost_root" )
|
||||
|
||||
|
||||
if( BUILD_GITHUB_PLUGIN )
|
||||
# Space separated list which indicates the subset of boost libraries to compile.
|
||||
set( BOOST_LIBS_BUILT
|
||||
#filesystem
|
||||
system
|
||||
#regex
|
||||
#program_options
|
||||
#date_time
|
||||
#thread
|
||||
#exception
|
||||
unit_test_framework
|
||||
)
|
||||
endif()
|
||||
|
||||
#-----</configure>---------------------------------------------------------------
|
||||
|
||||
|
||||
set( BOOST_RELEASE 1.53.0 )
|
||||
set( BOOST_MD5 a00d22605d5dbcfb4c9936a9b35bc4c2 ) # re-calc this on every RELEASE change
|
||||
|
||||
string( REGEX REPLACE "\\." "_" BOOST_VERS "${BOOST_RELEASE}" )
|
||||
set( PREFIX ${DOWNLOAD_DIR}/boost_${BOOST_VERS} )
|
||||
|
@ -36,26 +68,101 @@ set( PREFIX ${DOWNLOAD_DIR}/boost_${BOOST_VERS} )
|
|||
# download, the patch is applied. This lets you regenerate a new patch at any time
|
||||
# easily, simply by editing the working tree in <SOURCE_DIR> and doing "bzr diff" in there.
|
||||
|
||||
# include only the headers in the repo.
|
||||
# repo = "${headers}/../.bzr" = "<SOURCE_DIR>/.bzr"
|
||||
set( headers ${PREFIX}/src/boost/boost )
|
||||
# path to the boost headers in the repo.
|
||||
# repo = "${headers_src}/../.bzr" = "<SOURCE_DIR>/.bzr"
|
||||
set( headers_src "${PREFIX}/src/boost/boost" )
|
||||
|
||||
|
||||
ExternalProject_Add( boost
|
||||
PREFIX ${PREFIX}
|
||||
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
||||
URL http://downloads.sourceforge.net/project/boost/boost/${BOOST_RELEASE}/boost_${BOOST_VERS}.tar.bz2
|
||||
URL_MD5 ${BOOST_MD5}
|
||||
# don't look at this:
|
||||
function( set_boost_lib_names libs output )
|
||||
foreach( lib ${libs} )
|
||||
set( fullpath_lib, "${BOOST_ROOT}/lib/libboost_${lib}.a" )
|
||||
message( STATUS "fullpath_lib:${fullpath_lib}" )
|
||||
set( output ${output} ${fullpath_lib} )
|
||||
endforeach()
|
||||
endfunction()
|
||||
|
||||
# The patch command executes with the working directory set to <SOURCE_DIR>
|
||||
PATCH_COMMAND bzr patch -p0 ${PROJECT_SOURCE_DIR}/patches/boost.patch
|
||||
|
||||
CONFIGURE_COMMAND ""
|
||||
if( BUILD_GITHUB_PLUGIN )
|
||||
|
||||
# remove then re-copy into the include/boost directory during next two steps:
|
||||
BUILD_COMMAND ${CMAKE_COMMAND} -E remove_directory ${PROJECT_SOURCE_DIR}/include/boost
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy_directory ${headers} ${PROJECT_SOURCE_DIR}/include/boost
|
||||
)
|
||||
# (BTW "test" yields "unit_test_framework" when passed to bootstrap.{sh,bat} ).
|
||||
message( STATUS "BOOST_LIBS_BUILT:${BOOST_LIBS_BUILT}" )
|
||||
string( REPLACE "unit_test_framework" "test" libs_csv "${BOOST_LIBS_BUILT}" )
|
||||
message( STATUS "REPLACE libs_csv:${libs_csv}" )
|
||||
|
||||
string( REGEX REPLACE "\\;" "," libs_csv "${libs_csv}" )
|
||||
message( STATUS "libs_csv:${libs_csv}" )
|
||||
|
||||
if( MINGW )
|
||||
set( bootstrap "bootstart.bat mingw" )
|
||||
else()
|
||||
set( bootstrap bootstrap.sh )
|
||||
endif()
|
||||
|
||||
ExternalProject_Add( boost
|
||||
PREFIX "${PREFIX}"
|
||||
DOWNLOAD_DIR "${DOWNLOAD_DIR}"
|
||||
URL http://downloads.sourceforge.net/project/boost/boost/${BOOST_RELEASE}/boost_${BOOST_VERS}.tar.bz2
|
||||
URL_MD5 ${BOOST_MD5}
|
||||
|
||||
# The patch command executes with the working directory set to <SOURCE_DIR>
|
||||
PATCH_COMMAND bzr patch -p0 "${PROJECT_SOURCE_DIR}/patches/boost.patch"
|
||||
|
||||
# [Mis-]use this step to erase all the boost headers and libraries before
|
||||
# replacing them below.
|
||||
UPDATE_COMMAND ${CMAKE_COMMAND} -E remove_directory "${BOOST_ROOT}"
|
||||
|
||||
BINARY_DIR "${PREFIX}/src/boost/"
|
||||
CONFIGURE_COMMAND ${bootstrap}
|
||||
--with-libraries=${libs_csv}
|
||||
|
||||
BUILD_COMMAND b2
|
||||
variant=release
|
||||
threading=multi
|
||||
toolset=gcc
|
||||
link=static
|
||||
--prefix=${BOOST_ROOT}
|
||||
install
|
||||
|
||||
INSTALL_COMMAND ""
|
||||
)
|
||||
|
||||
file( GLOB boost_libs "${BOOST_ROOT}/lib/*" )
|
||||
#message( STATUS BOOST_ROOT:${BOOST_ROOT} boost_libs:${boost_libs} )
|
||||
set( Boost_LIBRARIES ${boost_libs} CACHE FILEPATH "Boost libraries directory" )
|
||||
set( Boost_INCLUDE_DIR "${BOOST_ROOT}/include" CACHE FILEPATH "Boost include directory" )
|
||||
|
||||
|
||||
else( BUILD_GITHUB_PLUGIN )
|
||||
|
||||
|
||||
ExternalProject_Add( boost
|
||||
PREFIX "${PREFIX}"
|
||||
DOWNLOAD_DIR "${DOWNLOAD_DIR}"
|
||||
URL http://downloads.sourceforge.net/project/boost/boost/${BOOST_RELEASE}/boost_${BOOST_VERS}.tar.bz2
|
||||
URL_MD5 ${BOOST_MD5}
|
||||
|
||||
# The patch command executes with the working directory set to <SOURCE_DIR>
|
||||
PATCH_COMMAND bzr patch -p0 "${PROJECT_SOURCE_DIR}/patches/boost.patch"
|
||||
|
||||
# Dick 18-Aug-2013:
|
||||
# [mis-]use this UPDATE_COMMAND opportunity to remove the old place of boost headers.
|
||||
# Can eventually remove this step after headers are moved from <kicad_src>/include/boost
|
||||
# to <kicad_src>/boost_root/include/boost over the next several months.
|
||||
UPDATE_COMMAND ${CMAKE_COMMAND} -E remove_directory "${PROJECT_SOURCE_DIR}/include/boost"
|
||||
|
||||
CONFIGURE_COMMAND ""
|
||||
|
||||
# remove then re-copy into the include/boost directory during next two steps:
|
||||
BUILD_COMMAND ${CMAKE_COMMAND} -E remove_directory ${BOOST_ROOT}
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy_directory "${headers_src}" "${BOOST_ROOT}/include/boost"
|
||||
)
|
||||
|
||||
# Until my find_package() support is done for my boost.
|
||||
set( Boost_INCLUDE_DIR "${BOOST_ROOT}/include" CACHE FILEPATH "Boost include directory" )
|
||||
|
||||
|
||||
endif( BUILD_GITHUB_PLUGIN )
|
||||
|
||||
|
||||
ExternalProject_Add_Step( boost bzr_commit_boost
|
||||
|
@ -66,8 +173,8 @@ ExternalProject_Add_Step( boost bzr_commit_boost
|
|||
|
||||
|
||||
ExternalProject_Add_Step( boost bzr_add_boost
|
||||
# add only the headers to the scratch repo, repo = "../.bzr" from ${headers}
|
||||
COMMAND bzr add -q ${headers}
|
||||
# add only the headers to the scratch repo, repo = "../.bzr" from ${headers_src}
|
||||
COMMAND bzr add -q ${headers_src}
|
||||
COMMENT "adding pristine boost files to 'boost scratch repo'"
|
||||
DEPENDERS bzr_commit_boost
|
||||
)
|
||||
|
@ -79,3 +186,4 @@ ExternalProject_Add_Step( boost bzr_init_boost
|
|||
DEPENDERS bzr_add_boost
|
||||
DEPENDEES download
|
||||
)
|
||||
|
||||
|
|
|
@ -111,10 +111,6 @@ This option is used to enable or disable building KiCad with images in menu
|
|||
items. If this is not defined when CMake is used to create the build files,
|
||||
images will be included in menu items on all platforms except OSX.
|
||||
|
||||
USE_PCBNEW_NANOMETRES (ON/OFF)
|
||||
This option is used to enable or disable the nano-meter internal units for
|
||||
Pcbnew. The default is ON.
|
||||
|
||||
KICAD_GOST (ON/OFF)
|
||||
-------------------
|
||||
This option is used to enable or disable the GOST notation for multiple gates
|
||||
|
|
|
@ -25,10 +25,10 @@ Contribute to KiCad (under Linux)
|
|||
6) Compile:
|
||||
cd kicad_john
|
||||
mkdir build; cd build
|
||||
cmake ../ -DKICAD_TESTING_VERSION=ON -DCMAKE_BUILD_TYPE=Debug
|
||||
cmake ../ -DCMAKE_BUILD_TYPE=Debug
|
||||
to build a debug version
|
||||
or
|
||||
cmake ../ -DKICAD_TESTING_VERSION=ON -DCMAKE_BUILD_TYPE=Release
|
||||
cmake ../ -DCMAKE_BUILD_TYPE=Release
|
||||
to build a release version
|
||||
make
|
||||
|
||||
|
|
|
@ -3,7 +3,6 @@ include_directories(BEFORE ${INC_BEFORE})
|
|||
include_directories(
|
||||
./dialogs
|
||||
./dialog_about
|
||||
${Boost_INCLUDE_DIR}
|
||||
${CAIRO_INCLUDE_DIR}
|
||||
${GLEW_INCLUDE_DIR}
|
||||
../3d-viewer
|
||||
|
|
|
@ -502,13 +502,6 @@ void EDA_BASE_FRAME::CopyVersionInfoToClipboard( wxCommandEvent& event )
|
|||
tmp << wxT( "Boost version: " ) << ( BOOST_VERSION / 100000 ) << wxT( "." )
|
||||
<< ( BOOST_VERSION / 100 % 1000 ) << wxT( "." ) << ( BOOST_VERSION % 100 ) << wxT( "\n" );
|
||||
|
||||
tmp << wxT( "Options: USE_PCBNEW_NANOMETRES=" );
|
||||
#ifdef USE_PCBNEW_NANOMETRES
|
||||
tmp << wxT( "ON\n" );
|
||||
#else
|
||||
tmp << wxT( "OFF\n" );
|
||||
#endif
|
||||
|
||||
tmp << wxT( " USE_WX_GRAPHICS_CONTEXT=" );
|
||||
#ifdef USE_WX_GRAPHICS_CONTEXT
|
||||
tmp << wxT( "ON\n" );
|
||||
|
|
|
@ -10,15 +10,10 @@
|
|||
#endif
|
||||
|
||||
|
||||
#if defined KICAD_TESTING_VERSION
|
||||
# define VERSION_STABILITY "testing"
|
||||
#elif defined KICAD_STABLE_VERSION
|
||||
#if defined KICAD_STABLE_VERSION
|
||||
# define VERSION_STABILITY "stable"
|
||||
#else
|
||||
# define VERSION_STABILITY "unknown"
|
||||
# warning "unknown version stability"
|
||||
# warning "please: when running CMAKE, add -DKICAD_TESTING_VERSION=ON"
|
||||
# warning "or -DKICAD_STABLE_VERSION=ON option"
|
||||
# define VERSION_STABILITY "product"
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
@ -27,8 +22,11 @@
|
|||
*/
|
||||
wxString GetBuildVersion()
|
||||
{
|
||||
static wxString msg;
|
||||
msg.Printf( wxT("%s-%s"),
|
||||
wxT( KICAD_BUILD_VERSION ), wxT( VERSION_STABILITY ));
|
||||
wxString msg = wxString::Format(
|
||||
wxT( "%s-%s" ),
|
||||
wxT( KICAD_BUILD_VERSION ),
|
||||
wxT( VERSION_STABILITY )
|
||||
);
|
||||
|
||||
return msg;
|
||||
}
|
||||
|
|
|
@ -59,7 +59,7 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
|
|||
info.SetAppName( wxT( ".: " ) + wxGetApp().GetTitle() + wxT( " :." ) );
|
||||
|
||||
/* Copyright information */
|
||||
info.SetCopyright( wxT( "(C) 1992-2012 KiCad Developers Team" ) );
|
||||
info.SetCopyright( wxT( "(C) 1992-2013 KiCad Developers Team" ) );
|
||||
|
||||
/* KiCad build version */
|
||||
wxString version;
|
||||
|
@ -203,98 +203,109 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
|
|||
* which should be represented by the same icon.
|
||||
*/
|
||||
|
||||
/* The developers */
|
||||
info.AddDeveloper( new Contributor( wxT( "Jean-Pierre Charras" ),
|
||||
wxT( "jp.charras@wanadoo.fr" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Dick Hollenbeck" ), wxT( "dick@softplc.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Frank Bennett" ), wxT( "bennett78@lpbroadband.net" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Hauptmech" ), wxT( "hauptmech@gmail.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Jerry Jacobs" ),
|
||||
wxT( "xor.gate.engineering@gmail.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Jonas Diemer" ), wxT( "diemer@gmx.de" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "KBool Library" ),
|
||||
wxT( "http://boolean.klaasholwerda.nl/bool.html" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Lorenzo Marcantonio" ), wxT( "lomarcan@tin.it" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Marco Serantoni" ),
|
||||
wxT( "marco.serantoni@gmail.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Marco Mattila" ), wxT( "marcom99@gmail.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Miguel Angel Ajo Pelayo" ),
|
||||
wxT( "miguelangel@nbee.es" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Rafael Sokolowski" ),
|
||||
wxT( "rafael.sokolowski@web.de" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Rok Markovic" ), wxT( "rok@kanardia.eu" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Tim Hanson" ), wxT( "sideskate@gmail.com" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Vesa Solonen" ), wxT( "vesa.solonen@hut.fi" ) ) );
|
||||
info.AddDeveloper( new Contributor( wxT( "Wayne Stambaugh" ),
|
||||
wxT( "stambaughw@verizon.net" ) ) );
|
||||
// The developers
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Jean-Pierre Charras" ), wxT( "jp.charras@wanadoo.fr" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Dick Hollenbeck" ), wxT( "dick@softplc.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Wayne Stambaugh" ), wxT( "stambaughw@verizon.net" ) ) );
|
||||
|
||||
/* The document writers */
|
||||
info.AddDocWriter( new Contributor( wxT( "Jean-Pierre Charras" ),
|
||||
wxT( "jp.charras@wanadoo.fr" ) ) );
|
||||
info.AddDocWriter( new Contributor( wxT( "Igor Plyatov" ),
|
||||
wxT( "plyatov@gmail.com" ) ) );
|
||||
info.AddDocWriter( new Contributor( wxT( "Fabrizio Tappero" ),
|
||||
wxT( "fabrizio.tappero@gmail.com" ) ) );
|
||||
// alphabetically by last name after main 3 above:
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Frank Bennett" ), wxT( "bennett78@lpbroadband.net" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Jonas Diemer" ), wxT( "diemer@gmx.de" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Tim Hanson" ), wxT( "sideskate@gmail.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Hauptmech" ), wxT( "hauptmech@gmail.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Jerry Jacobs" ), wxT( "xor.gate.engineering@gmail.com" ) ) );
|
||||
|
||||
/*
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "KBool Library" ), wxT( "http://boolean.klaasholwerda.nl/bool.html" ) ) );
|
||||
*/
|
||||
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Lorenzo Marcantonio" ), wxT( "lomarcan@tin.it" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Rok Markovic" ), wxT( "rok@kanardia.eu" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Marco Mattila" ), wxT( "marcom99@gmail.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Miguel Angel Ajo Pelayo" ),wxT( "miguelangel@nbee.es" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Marco Serantoni" ), wxT( "marco.serantoni@gmail.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Brian Sidebotham" ), wxT( "brian.sidebotham@gmail.com" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Rafael Sokolowski" ), wxT( "rafael.sokolowski@web.de" ) ) );
|
||||
info.AddDeveloper(
|
||||
new Contributor( wxT( "Vesa Solonen" ), wxT( "vesa.solonen@hut.fi" ) ) );
|
||||
|
||||
// The document writers
|
||||
info.AddDocWriter(
|
||||
new Contributor( wxT( "Jean-Pierre Charras" ), wxT( "jp.charras@wanadoo.fr" ) ) );
|
||||
info.AddDocWriter(
|
||||
new Contributor( wxT( "Igor Plyatov" ), wxT( "plyatov@gmail.com" ) ) );
|
||||
info.AddDocWriter(
|
||||
new Contributor( wxT( "Fabrizio Tappero" ), wxT( "fabrizio.tappero@gmail.com" ) ) );
|
||||
|
||||
/* The translators
|
||||
* As category the language to which the translation was done is used
|
||||
* and as icon the national flag of the corresponding country.
|
||||
*/
|
||||
info.AddTranslator( new Contributor( wxT( "Martin Kratoška" ), wxT( "martin@ok1rr.com" ),
|
||||
wxT( "Czech (CZ)" ), KiBitmapNew( lang_cs_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Jerry Jacobs" ),
|
||||
wxT( "xor.gate.engineering@gmail.com" ), wxT( "Dutch (NL)" ),
|
||||
KiBitmapNew( lang_nl_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Vesa Solonen" ), wxT( "vesa.solonen@hut.fi" ),
|
||||
wxT( "Finnish (FI)" ), KiBitmapNew( lang_fi_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Jean-Pierre Charras" ),
|
||||
wxT( "jp.charras@wanadoo.fr" ),
|
||||
wxT( "French (FR)" ), KiBitmapNew( lang_fr_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Mateusz Skowroński" ), wxT( "skowri@gmail.com" ),
|
||||
wxT( "Polish (PL)" ), KiBitmapNew( lang_pl_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Renie Marquet" ), wxT( "reniemarquet@uol.com.br" ),
|
||||
wxT( "Portuguese (PT)" ), KiBitmapNew( lang_pt_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Igor Plyatov" ), wxT( "plyatov@gmail.com" ),
|
||||
wxT( "Russian (RU)" ), KiBitmapNew( lang_ru_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Andrey Fedorushkov" ), wxT( "andrf@mail.ru" ),
|
||||
wxT( "Russian (RU)" ), KiBitmapNew( lang_ru_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Pedro Martin del Valle" ), wxT( "pkicad@yahoo.es" ),
|
||||
wxT( "Spanish (ES)" ), KiBitmapNew( lang_es_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Iñigo Zuluaga" ), wxT( "inigo_zuluaga@yahoo.es" ),
|
||||
wxT( "Spanish (ES)" ), KiBitmapNew( lang_es_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Rafael Sokolowski" ),
|
||||
wxT( "rafael.sokolowski@web.de" ), wxT( "German (DE)" ),
|
||||
KiBitmapNew( lang_de_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Kenta Yonekura" ),
|
||||
wxT( "midpika@hotmail.com" ), wxT( "Japanese (JA)" ),
|
||||
KiBitmapNew( lang_jp_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Manolis Stefanis, Athanasios Vlastos and Milonas Kostas" ),
|
||||
wxT( "milonas.ko@gmail.com" ), wxT( "Greek (el_GR)" ),
|
||||
KiBitmapNew( lang_gr_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Massimo Cioce" ),
|
||||
wxT( "ciocemax@alice.it" ), wxT( "Italian (IT)" ),
|
||||
KiBitmapNew( lang_it_xpm ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Evgeniy Ivanov" ),
|
||||
wxT( "evgeniy_p_ivanov@yahoo.ca" ), wxT( "Bulgarian (BG)" ),
|
||||
KiBitmapNew( lang_bg_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Martin Kratoška" ), wxT( "martin@ok1rr.com" ), wxT( "Czech (CZ)" ), KiBitmapNew( lang_cs_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Jerry Jacobs" ), wxT( "xor.gate.engineering@gmail.com" ),wxT( "Dutch (NL)" ), KiBitmapNew( lang_nl_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Vesa Solonen" ), wxT( "vesa.solonen@hut.fi" ), wxT( "Finnish (FI)" ), KiBitmapNew( lang_fi_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Jean-Pierre Charras" ), wxT( "jp.charras@wanadoo.fr" ), wxT( "French (FR)" ), KiBitmapNew( lang_fr_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Mateusz Skowroński" ), wxT( "skowri@gmail.com" ), wxT( "Polish (PL)" ), KiBitmapNew( lang_pl_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Renie Marquet" ), wxT( "reniemarquet@uol.com.br" ), wxT( "Portuguese (PT)" ), KiBitmapNew( lang_pt_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Igor Plyatov" ), wxT( "plyatov@gmail.com" ), wxT( "Russian (RU)" ), KiBitmapNew( lang_ru_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Andrey Fedorushkov" ), wxT( "andrf@mail.ru" ), wxT( "Russian (RU)" ), KiBitmapNew( lang_ru_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Pedro Martin del Valle" ), wxT( "pkicad@yahoo.es" ), wxT( "Spanish (ES)" ), KiBitmapNew( lang_es_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Iñigo Zuluaga" ), wxT( "inigo_zuluaga@yahoo.es" ), wxT( "Spanish (ES)" ), KiBitmapNew( lang_es_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Rafael Sokolowski" ), wxT( "rafael.sokolowski@web.de" ), wxT( "German (DE)" ), KiBitmapNew( lang_de_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Kenta Yonekura" ), wxT( "midpika@hotmail.com" ), wxT( "Japanese (JA)" ), KiBitmapNew( lang_jp_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Manolis Stefanis, Athanasios Vlastos and Milonas Kostas" ),
|
||||
wxT( "milonas.ko@gmail.com" ), wxT( "Greek (el_GR)" ), KiBitmapNew( lang_gr_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Massimo Cioce" ), wxT( "ciocemax@alice.it" ), wxT( "Italian (IT)" ), KiBitmapNew( lang_it_xpm ) ) );
|
||||
info.AddTranslator(
|
||||
new Contributor( wxT( "Evgeniy Ivanov" ), wxT( "evgeniy_p_ivanov@yahoo.ca" ), wxT( "Bulgarian (BG)" ),KiBitmapNew( lang_bg_xpm ) ) );
|
||||
|
||||
// TODO: are these all russian translators,
|
||||
// placed them here now,
|
||||
// or else align them below other language maintainer with mail adress
|
||||
info.AddTranslator( new Contributor( wxT( "Remy Halvick" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "David Briscoe" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Dominique Laigle" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Paul Burke" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Remy Halvick" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "David Briscoe" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Dominique Laigle" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
info.AddTranslator( new Contributor( wxT( "Paul Burke" ), wxEmptyString, wxT( "Others" ) ) );
|
||||
|
||||
/* Programm credits for icons */
|
||||
info.AddArtist( new Contributor( wxT( "Iñigo Zuluagaz" ), wxT( "inigo_zuluaga@yahoo.es" ),
|
||||
wxT( "Icons by" ), KiBitmapNew( edit_module_xpm ) ) );
|
||||
info.AddArtist( new Contributor( wxT( "Fabrizio Tappero" ), wxT( "fabrizio.tappero@gmail.com" ),
|
||||
wxT( "New icons by" ), KiBitmapNew( edit_module_xpm ) ) );
|
||||
info.AddArtist( new Contributor( wxT( "Renie Marquet" ), wxT( "reniemarquet@uol.com.br" ),
|
||||
wxT( "3D modules by" ), KiBitmapNew( three_d_xpm ) ) );
|
||||
info.AddArtist( new Contributor( wxT( "Christophe Boschat" ), wxT( "nox454@hotmail.fr" ),
|
||||
wxT( "3D modules by" ), KiBitmapNew( three_d_xpm ) ) );
|
||||
// Programm credits for icons
|
||||
info.AddArtist(
|
||||
new Contributor( wxT( "Iñigo Zuluagaz" ), wxT( "inigo_zuluaga@yahoo.es" ), wxT( "Icons by" ), KiBitmapNew( edit_module_xpm ) ) );
|
||||
info.AddArtist(
|
||||
new Contributor( wxT( "Fabrizio Tappero" ), wxT( "fabrizio.tappero@gmail.com" ), wxT( "New icons by" ), KiBitmapNew( edit_module_xpm ) ) );
|
||||
info.AddArtist(
|
||||
new Contributor( wxT( "Renie Marquet" ), wxT( "reniemarquet@uol.com.br" ), wxT( "3D modules by" ), KiBitmapNew( three_d_xpm ) ) );
|
||||
info.AddArtist(
|
||||
new Contributor( wxT( "Christophe Boschat" ), wxT( "nox454@hotmail.fr" ), wxT( "3D modules by" ), KiBitmapNew( three_d_xpm ) ) );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<wxFormBuilder_Project>
|
||||
<FileVersion major="1" minor="10" />
|
||||
<FileVersion major="1" minor="11" />
|
||||
<object class="Project" expanded="1">
|
||||
<property name="class_decoration"></property>
|
||||
<property name="class_decoration" />
|
||||
<property name="code_generation">C++</property>
|
||||
<property name="disconnect_events">1</property>
|
||||
<property name="disconnect_mode">source_name</property>
|
||||
|
@ -14,73 +14,73 @@
|
|||
<property name="help_provider">none</property>
|
||||
<property name="internationalize">1</property>
|
||||
<property name="name">MyProject</property>
|
||||
<property name="namespace"></property>
|
||||
<property name="namespace" />
|
||||
<property name="path">.</property>
|
||||
<property name="precompiled_header"></property>
|
||||
<property name="precompiled_header" />
|
||||
<property name="relative_path">1</property>
|
||||
<property name="skip_python_events">1</property>
|
||||
<property name="use_enum">1</property>
|
||||
<property name="use_microsoft_bom">0</property>
|
||||
<object class="Dialog" expanded="1">
|
||||
<property name="bg"></property>
|
||||
<property name="center"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="center" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="event_handler">impl_virtual</property>
|
||||
<property name="extra_style"></property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="extra_style" />
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size">-1,-1</property>
|
||||
<property name="name">dialog_about_base</property>
|
||||
<property name="pos"></property>
|
||||
<property name="pos" />
|
||||
<property name="size">750,450</property>
|
||||
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER|wxSTAY_ON_TOP</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="subclass" />
|
||||
<property name="title">About...</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnActivate"></event>
|
||||
<event name="OnActivateApp"></event>
|
||||
<event name="OnChar"></event>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<event name="OnActivate" />
|
||||
<event name="OnActivateApp" />
|
||||
<event name="OnChar" />
|
||||
<event name="OnClose">OnClose</event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnHibernate"></event>
|
||||
<event name="OnIconize"></event>
|
||||
<event name="OnIdle"></event>
|
||||
<event name="OnInitDialog"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnHibernate" />
|
||||
<event name="OnIconize" />
|
||||
<event name="OnIdle" />
|
||||
<event name="OnInitDialog" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
<object class="wxBoxSizer" expanded="0">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="minimum_size" />
|
||||
<property name="name">bSizer1</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="permission">none</property>
|
||||
|
@ -89,7 +89,7 @@
|
|||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxBoxSizer" expanded="0">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="minimum_size" />
|
||||
<property name="name">bSizer3</property>
|
||||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="permission">none</property>
|
||||
|
@ -108,53 +108,53 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxALL</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxStaticBitmap" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="bitmap"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="bitmap" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_bitmapApp</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -162,7 +162,7 @@
|
|||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">10</property>
|
||||
<object class="wxBoxSizer" expanded="0">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="minimum_size" />
|
||||
<property name="name">b_apptitleSizer</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="permission">none</property>
|
||||
|
@ -171,55 +171,55 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="fg" />
|
||||
<property name="font">,90,92,14,70,0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">App Title</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_staticTextAppTitle</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxALIGN_CENTRE</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -227,55 +227,55 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Copyright Info</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_staticTextCopyright</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxALIGN_CENTRE</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -283,55 +283,55 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxLEFT|wxRIGHT|wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Build Version Info</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_staticTextBuildVersion</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxALIGN_CENTRE</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -339,55 +339,55 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxBOTTOM|wxLEFT|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Lib Version Info</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_staticTextLibVersion</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxALIGN_CENTRE</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
|
@ -409,53 +409,53 @@
|
|||
<property name="flag">wxEXPAND | wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticLine" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_staticline1</property>
|
||||
<property name="permission">none</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxLI_HORIZONTAL</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -463,63 +463,63 @@
|
|||
<property name="flag">wxEXPAND | wxALL</property>
|
||||
<property name="proportion">2</property>
|
||||
<object class="wxAuiNotebook" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size">750,350</property>
|
||||
<property name="name">m_auiNotebook</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style">wxAUI_NB_SCROLL_BUTTONS|wxAUI_NB_TAB_FIXED_WIDTH</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="subclass" />
|
||||
<property name="tab_ctrl_height">-1</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="uniform_bitmap_size"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="tooltip" />
|
||||
<property name="uniform_bitmap_size" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnAuiNotebookAllowDND"></event>
|
||||
<event name="OnAuiNotebookBeginDrag"></event>
|
||||
<event name="OnAuiNotebookButton"></event>
|
||||
<event name="OnAuiNotebookDragMotion"></event>
|
||||
<event name="OnAuiNotebookEndDrag"></event>
|
||||
<event name="OnAuiNotebookPageChanged"></event>
|
||||
<event name="OnAuiNotebookPageChanging"></event>
|
||||
<event name="OnAuiNotebookPageClose"></event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<event name="OnAuiNotebookAllowDND" />
|
||||
<event name="OnAuiNotebookBeginDrag" />
|
||||
<event name="OnAuiNotebookButton" />
|
||||
<event name="OnAuiNotebookDragMotion" />
|
||||
<event name="OnAuiNotebookEndDrag" />
|
||||
<event name="OnAuiNotebookPageChanged" />
|
||||
<event name="OnAuiNotebookPageChanging" />
|
||||
<event name="OnAuiNotebookPageClose" />
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
|
@ -527,56 +527,56 @@
|
|||
<property name="flag">wxALIGN_CENTER|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxButton" expanded="0">
|
||||
<property name="bg"></property>
|
||||
<property name="context_help"></property>
|
||||
<property name="bg" />
|
||||
<property name="context_help" />
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="fg" />
|
||||
<property name="font" />
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_CANCEL</property>
|
||||
<property name="label">OK</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="maximum_size" />
|
||||
<property name="minimum_size" />
|
||||
<property name="name">m_buttonOK</property>
|
||||
<property name="permission">private</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="pos" />
|
||||
<property name="size" />
|
||||
<property name="style" />
|
||||
<property name="subclass" />
|
||||
<property name="tooltip" />
|
||||
<property name="validator_data_type" />
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="validator_variable" />
|
||||
<property name="window_extra_style" />
|
||||
<property name="window_name" />
|
||||
<property name="window_style" />
|
||||
<event name="OnButtonClick">OnOkClick</event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
<event name="OnChar" />
|
||||
<event name="OnEnterWindow" />
|
||||
<event name="OnEraseBackground" />
|
||||
<event name="OnKeyDown" />
|
||||
<event name="OnKeyUp" />
|
||||
<event name="OnKillFocus" />
|
||||
<event name="OnLeaveWindow" />
|
||||
<event name="OnLeftDClick" />
|
||||
<event name="OnLeftDown" />
|
||||
<event name="OnLeftUp" />
|
||||
<event name="OnMiddleDClick" />
|
||||
<event name="OnMiddleDown" />
|
||||
<event name="OnMiddleUp" />
|
||||
<event name="OnMotion" />
|
||||
<event name="OnMouseEvents" />
|
||||
<event name="OnMouseWheel" />
|
||||
<event name="OnPaint" />
|
||||
<event name="OnRightDClick" />
|
||||
<event name="OnRightDown" />
|
||||
<event name="OnRightUp" />
|
||||
<event name="OnSetFocus" />
|
||||
<event name="OnSize" />
|
||||
<event name="OnUpdateUI" />
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
#include <wxstruct.h>
|
||||
#include <worksheet_shape_builder.h>
|
||||
#include <class_base_screen.h>
|
||||
#include <wildcards_and_files_ext.h>
|
||||
|
||||
#include <wx/valgen.h>
|
||||
#include <wx/tokenzr.h>
|
||||
|
@ -125,8 +126,7 @@ void DIALOG_PAGES_SETTINGS::initDialog()
|
|||
}
|
||||
|
||||
// initialize the page layout descr filename
|
||||
m_plDescrFileName = BASE_SCREEN::m_PageLayoutDescrFileName;
|
||||
m_filePicker->SetPath( m_plDescrFileName );
|
||||
SetWksFileName( BASE_SCREEN::m_PageLayoutDescrFileName );
|
||||
|
||||
|
||||
#ifdef EESCHEMA
|
||||
|
@ -401,13 +401,13 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings()
|
|||
{
|
||||
bool retSuccess = false;
|
||||
|
||||
m_plDescrFileName = m_filePicker->GetPath();
|
||||
wxString fileName = GetWksFileName();
|
||||
|
||||
if( m_plDescrFileName != BASE_SCREEN::m_PageLayoutDescrFileName )
|
||||
if( fileName != BASE_SCREEN::m_PageLayoutDescrFileName )
|
||||
{
|
||||
if( !m_plDescrFileName.IsEmpty() )
|
||||
if( !fileName.IsEmpty() )
|
||||
{
|
||||
wxString fullFileName = WORKSHEET_LAYOUT::MakeFullFileName( m_plDescrFileName );
|
||||
wxString fullFileName = WORKSHEET_LAYOUT::MakeFullFileName( fileName );
|
||||
if( !wxFileExists( fullFileName ) )
|
||||
{
|
||||
wxString msg;
|
||||
|
@ -418,26 +418,9 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings()
|
|||
}
|
||||
}
|
||||
|
||||
// Try to remove the path, if the path is the current working dir,
|
||||
// or the dir of kicad.pro (template)
|
||||
wxString shortFileName = WORKSHEET_LAYOUT::MakeShortFileName( m_plDescrFileName );
|
||||
wxFileName fn = shortFileName;
|
||||
|
||||
// For Win/Linux/macOS compatibility, a relative path is a good idea
|
||||
if( fn.IsAbsolute() )
|
||||
{
|
||||
fn.MakeRelativeTo( wxGetCwd() );
|
||||
wxString msg;
|
||||
msg.Printf( _( "The page layout descr filename has changed\n"
|
||||
"Do you want to use the relative path:\n%s"),
|
||||
fn.GetFullPath().GetData() );
|
||||
if( IsOK( this, msg ) )
|
||||
shortFileName = fn.GetFullPath();
|
||||
}
|
||||
|
||||
BASE_SCREEN::m_PageLayoutDescrFileName = shortFileName;
|
||||
BASE_SCREEN::m_PageLayoutDescrFileName = fileName;
|
||||
WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance();
|
||||
pglayout.SetPageLayout( shortFileName );
|
||||
pglayout.SetPageLayout( fileName );
|
||||
m_localPrjConfigChanged = true;
|
||||
}
|
||||
|
||||
|
@ -793,7 +776,35 @@ void DIALOG_PAGES_SETTINGS::GetCustomSizeMilsFromDialog()
|
|||
}
|
||||
|
||||
// Called on .kicad_wks file description selection change
|
||||
void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxFileDirPickerEvent& event )
|
||||
void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxCommandEvent& event )
|
||||
{
|
||||
// Currently: Nothing to do.
|
||||
// Display a file picker dialog
|
||||
wxFileDialog fileDialog( this, _( "Select Page Layout Descr File" ),
|
||||
wxGetCwd(), GetWksFileName(),
|
||||
PageLayoutDescrFileWildcard,
|
||||
wxFD_DEFAULT_STYLE | wxFD_FILE_MUST_EXIST );
|
||||
|
||||
if( fileDialog.ShowModal() != wxID_OK )
|
||||
return;
|
||||
|
||||
wxString fileName = fileDialog.GetPath();
|
||||
|
||||
// Try to remove the path, if the path is the current working dir,
|
||||
// or the dir of kicad.pro (template)
|
||||
wxString shortFileName = WORKSHEET_LAYOUT::MakeShortFileName( fileName );
|
||||
wxFileName fn = shortFileName;
|
||||
|
||||
// For Win/Linux/macOS compatibility, a relative path is a good idea
|
||||
if( fn.IsAbsolute() && fileName != GetWksFileName() )
|
||||
{
|
||||
fn.MakeRelativeTo( wxGetCwd() );
|
||||
wxString msg;
|
||||
msg.Printf( _( "The page layout descr filename has changed\n"
|
||||
"Do you want to use the relative path:\n%s"),
|
||||
fn.GetFullPath().GetData() );
|
||||
if( IsOK( this, msg ) )
|
||||
shortFileName = fn.GetFullPath();
|
||||
}
|
||||
|
||||
SetWksFileName( shortFileName );
|
||||
}
|
||||
|
|
|
@ -45,9 +45,6 @@ private:
|
|||
PAGE_INFO m_pageInfo; /// Temporary page info.
|
||||
bool m_customFmt; /// true if the page selection is custom
|
||||
TITLE_BLOCK m_tb; /// Temporary title block (basic inscriptions).
|
||||
wxString m_plDescrFileName; /// Temporary BASE_SCREEN::m_PageLayoutDescrFileName copy
|
||||
|
||||
|
||||
|
||||
public:
|
||||
DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent );
|
||||
|
@ -55,24 +52,23 @@ public:
|
|||
|
||||
const wxString GetWksFileName()
|
||||
{
|
||||
return m_filePicker->GetPath();
|
||||
return m_textCtrlFilePicker->GetValue();
|
||||
}
|
||||
|
||||
void SetWksFileName(const wxString& aFilename )
|
||||
{
|
||||
m_filePicker->SetPath( aFilename );
|
||||
m_textCtrlFilePicker->SetValue( aFilename );
|
||||
}
|
||||
|
||||
void EnableWksFileNamePicker( bool aEnable )
|
||||
{
|
||||
m_filePicker->Enable( aEnable );
|
||||
m_textCtrlFilePicker->Enable( aEnable );
|
||||
m_buttonBrowse->Enable( aEnable );
|
||||
}
|
||||
|
||||
private:
|
||||
void initDialog(); // Initialisation of member variables
|
||||
|
||||
// void OnCloseWindow( wxCloseEvent& event );
|
||||
|
||||
// event handler for wxID_OK
|
||||
void OnOkClick( wxCommandEvent& event );
|
||||
|
||||
|
@ -99,7 +95,7 @@ private:
|
|||
void OnDateApplyClick( wxCommandEvent& event );
|
||||
|
||||
// .kicad_wks file description selection
|
||||
void OnWksFileSelection( wxFileDirPickerEvent& event );
|
||||
void OnWksFileSelection( wxCommandEvent& event );
|
||||
|
||||
// Save in the current title block the new page settings
|
||||
// return true if changes are made, or false if not
|
||||
|
|
|
@ -350,8 +350,11 @@ DIALOG_PAGES_SETTINGS_BASE::DIALOG_PAGES_SETTINGS_BASE( wxWindow* parent, wxWind
|
|||
wxBoxSizer* bSizerfileSelection;
|
||||
bSizerfileSelection = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_filePicker = new wxFilePickerCtrl( this, wxID_ANY, wxEmptyString, _("Select a file"), wxT("*.kicad_wks"), wxDefaultPosition, wxDefaultSize, wxFLP_OPEN|wxFLP_USE_TEXTCTRL );
|
||||
bSizerfileSelection->Add( m_filePicker, 1, wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
m_textCtrlFilePicker = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
bSizerfileSelection->Add( m_textCtrlFilePicker, 1, wxBOTTOM|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_buttonBrowse = new wxButton( this, wxID_ANY, _("Browse"), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT );
|
||||
bSizerfileSelection->Add( m_buttonBrowse, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
|
||||
bSizerFilename->Add( bSizerfileSelection, 1, wxEXPAND, 5 );
|
||||
|
@ -393,7 +396,7 @@ DIALOG_PAGES_SETTINGS_BASE::DIALOG_PAGES_SETTINGS_BASE( wxWindow* parent, wxWind
|
|||
m_TextComment2->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment2TextUpdated ), NULL, this );
|
||||
m_TextComment3->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment3TextUpdated ), NULL, this );
|
||||
m_TextComment4->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment4TextUpdated ), NULL, this );
|
||||
m_filePicker->Connect( wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnWksFileSelection ), NULL, this );
|
||||
m_buttonBrowse->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnWksFileSelection ), NULL, this );
|
||||
m_sdbSizer1Cancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnCancelClick ), NULL, this );
|
||||
m_sdbSizer1OK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnOkClick ), NULL, this );
|
||||
}
|
||||
|
@ -415,7 +418,7 @@ DIALOG_PAGES_SETTINGS_BASE::~DIALOG_PAGES_SETTINGS_BASE()
|
|||
m_TextComment2->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment2TextUpdated ), NULL, this );
|
||||
m_TextComment3->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment3TextUpdated ), NULL, this );
|
||||
m_TextComment4->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnComment4TextUpdated ), NULL, this );
|
||||
m_filePicker->Disconnect( wxEVT_COMMAND_FILEPICKER_CHANGED, wxFileDirPickerEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnWksFileSelection ), NULL, this );
|
||||
m_buttonBrowse->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnWksFileSelection ), NULL, this );
|
||||
m_sdbSizer1Cancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnCancelClick ), NULL, this );
|
||||
m_sdbSizer1OK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_PAGES_SETTINGS_BASE::OnOkClick ), NULL, this );
|
||||
|
||||
|
|
|
@ -4235,9 +4235,9 @@
|
|||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxFilePickerCtrl" expanded="1">
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
|
@ -4268,12 +4268,12 @@
|
|||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="message">Select a file</property>
|
||||
<property name="maxlength"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_filePicker</property>
|
||||
<property name="name">m_textCtrlFilePicker</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
|
@ -4283,7 +4283,7 @@
|
|||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxFLP_OPEN|wxFLP_USE_TEXTCTRL</property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
|
@ -4292,14 +4292,104 @@
|
|||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="value"></property>
|
||||
<property name="wildcard">*.kicad_wks</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnFileChanged">OnWksFileSelection</event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnText"></event>
|
||||
<event name="OnTextEnter"></event>
|
||||
<event name="OnTextMaxLen"></event>
|
||||
<event name="OnTextURL"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxButton" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default">0</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Browse</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_buttonBrowse</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxBU_EXACTFIT</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnButtonClick">OnWksFileSelection</event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
|
|
|
@ -33,7 +33,6 @@ class DIALOG_SHIM;
|
|||
#include <wx/datectrl.h>
|
||||
#include <wx/dateevt.h>
|
||||
#include <wx/checkbox.h>
|
||||
#include <wx/filepicker.h>
|
||||
#include <wx/dialog.h>
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
@ -113,7 +112,8 @@ class DIALOG_PAGES_SETTINGS_BASE : public DIALOG_SHIM
|
|||
wxTextCtrl* m_TextComment4;
|
||||
wxCheckBox* m_Comment4Export;
|
||||
wxStaticText* m_staticTextfilename;
|
||||
wxFilePickerCtrl* m_filePicker;
|
||||
wxTextCtrl* m_textCtrlFilePicker;
|
||||
wxButton* m_buttonBrowse;
|
||||
wxStdDialogButtonSizer* m_sdbSizer1;
|
||||
wxButton* m_sdbSizer1OK;
|
||||
wxButton* m_sdbSizer1Cancel;
|
||||
|
@ -133,7 +133,7 @@ class DIALOG_PAGES_SETTINGS_BASE : public DIALOG_SHIM
|
|||
virtual void OnComment2TextUpdated( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnComment3TextUpdated( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnComment4TextUpdated( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnWksFileSelection( wxFileDirPickerEvent& event ) { event.Skip(); }
|
||||
virtual void OnWksFileSelection( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnOkClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
|
|
@ -786,7 +786,6 @@ void EDA_DRAW_FRAME::AdjustScrollBars( const wxPoint& aCenterPositionIU )
|
|||
DBOX clientRectIU( wxPoint( xIU, yIU ), wxSize( clientSizeIU.x, clientSizeIU.y ) );
|
||||
wxPoint centerPositionIU;
|
||||
|
||||
#if 1 || defined( USE_PCBNEW_NANOMETRES )
|
||||
// put "int" limits on the clientRect
|
||||
if( clientRectIU.GetLeft() < VIRT_MIN )
|
||||
clientRectIU.MoveLeftTo( VIRT_MIN );
|
||||
|
@ -796,7 +795,6 @@ void EDA_DRAW_FRAME::AdjustScrollBars( const wxPoint& aCenterPositionIU )
|
|||
clientRectIU.MoveRightTo( VIRT_MAX );
|
||||
if( clientRectIU.GetBottom() > VIRT_MAX )
|
||||
clientRectIU.MoveBottomTo( VIRT_MAX );
|
||||
#endif
|
||||
|
||||
centerPositionIU.x = KiROUND( clientRectIU.GetX() + clientRectIU.GetWidth() / 2 );
|
||||
centerPositionIU.y = KiROUND( clientRectIU.GetY() + clientRectIU.GetHeight() / 2 );
|
||||
|
@ -869,11 +867,9 @@ void EDA_DRAW_FRAME::AdjustScrollBars( const wxPoint& aCenterPositionIU )
|
|||
}
|
||||
}
|
||||
|
||||
#if 1 || defined( USE_PCBNEW_NANOMETRES )
|
||||
// put "int" limits on the virtualSizeIU
|
||||
virtualSizeIU.x = std::min( virtualSizeIU.x, MAX_AXIS );
|
||||
virtualSizeIU.y = std::min( virtualSizeIU.y, MAX_AXIS );
|
||||
#endif
|
||||
|
||||
if( screen->m_Center )
|
||||
{
|
||||
|
|
|
@ -146,9 +146,11 @@ EDA_DRAW_PANEL::~EDA_DRAW_PANEL()
|
|||
wxGetApp().GetSettings()->Write( ENBL_AUTO_PAN_KEY, m_enableAutoPan );
|
||||
}
|
||||
|
||||
|
||||
EDA_DRAW_FRAME* EDA_DRAW_PANEL::GetParent()
|
||||
{
|
||||
return ( EDA_DRAW_FRAME* ) wxWindow::GetParent();
|
||||
wxWindow* mom = wxScrolledWindow::GetParent();
|
||||
return (EDA_DRAW_FRAME*) mom;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -462,6 +462,43 @@ void WORKSHEET_DATAITEM_TEXT::IncrementLabel( int aIncr )
|
|||
m_FullText << (wxChar) ( aIncr + lbchar );
|
||||
}
|
||||
|
||||
// Replace the '\''n' sequence by EOL
|
||||
// and the sequence '\''\' by only one '\' in m_FullText
|
||||
// if m_FullTextis a multiline text (i;e.contains '\n') return true
|
||||
bool WORKSHEET_DATAITEM_TEXT::ReplaceAntiSlashSequence()
|
||||
{
|
||||
bool multiline = false;
|
||||
|
||||
for( unsigned ii = 0; ii < m_FullText.Len(); ii++ )
|
||||
{
|
||||
if( m_FullText[ii] == '\n' )
|
||||
multiline = true;
|
||||
|
||||
else if( m_FullText[ii] == '\\' )
|
||||
{
|
||||
if( ++ii >= m_FullText.Len() )
|
||||
break;
|
||||
|
||||
if( m_FullText[ii] == '\\' )
|
||||
{
|
||||
// a double \\ sequence is replaced by a single \ char
|
||||
m_FullText.Remove(ii, 1);
|
||||
ii--;
|
||||
}
|
||||
else if( m_FullText[ii] == 'n' )
|
||||
{
|
||||
// Replace the "\n" sequence by a EOL char
|
||||
multiline = true;
|
||||
m_FullText[ii] = '\n';
|
||||
m_FullText.Remove(ii-1, 1);
|
||||
ii--;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return multiline;
|
||||
}
|
||||
|
||||
void WORKSHEET_DATAITEM_TEXT::SetConstrainedTextSize()
|
||||
{
|
||||
m_ConstrainedTextSize = m_TextSize;
|
||||
|
@ -501,3 +538,4 @@ void WORKSHEET_DATAITEM_TEXT::SetConstrainedTextSize()
|
|||
m_ConstrainedTextSize.y *= m_BoundingBoxSize.y / size.y;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -152,8 +152,7 @@ void WS_DRAW_ITEM_LIST::BuildWorkSheetGraphicList(
|
|||
else
|
||||
{
|
||||
wsText->m_FullText = BuildFullText( wsText->m_TextBase );
|
||||
if( wsText->m_FullText.Replace( wxT("\\n" ), wxT("\n") ) > 0 )
|
||||
multilines = true;
|
||||
multilines = wsText->ReplaceAntiSlashSequence();
|
||||
}
|
||||
|
||||
if( wsText->m_FullText.IsEmpty() )
|
||||
|
|
|
@ -28,7 +28,6 @@
|
|||
#include <macros.h>
|
||||
#include <reporter.h>
|
||||
|
||||
|
||||
REPORTER& REPORTER::Report( const char* aText )
|
||||
{
|
||||
Report( FROM_UTF8( aText ) );
|
||||
|
|
|
@ -136,8 +136,8 @@ wxString WS_DRAW_ITEM_LIST::BuildFullText( const wxString& aTextbase )
|
|||
msg << aTextbase[ii];
|
||||
continue;
|
||||
}
|
||||
ii++;
|
||||
if( ii >= aTextbase.Len() )
|
||||
|
||||
if( ++ii >= aTextbase.Len() )
|
||||
break;
|
||||
|
||||
wxChar format = aTextbase[ii];
|
||||
|
@ -174,7 +174,7 @@ wxString WS_DRAW_ITEM_LIST::BuildFullText( const wxString& aTextbase )
|
|||
|
||||
case 'F':
|
||||
{
|
||||
wxFileName fn( *m_fileName );
|
||||
wxFileName fn( m_fileName );
|
||||
msg += fn.GetFullName();
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
add_definitions(-DCVPCB)
|
||||
add_definitions( -DCVPCB )
|
||||
|
||||
###
|
||||
# Includes
|
||||
###
|
||||
|
||||
include_directories(BEFORE ${INC_BEFORE})
|
||||
include_directories( BEFORE ${INC_BEFORE} )
|
||||
include_directories(
|
||||
./dialogs
|
||||
${Boost_INCLUDE_DIR}
|
||||
../3d-viewer
|
||||
../pcbnew
|
||||
../polygon
|
||||
|
@ -18,14 +17,14 @@ include_directories(
|
|||
###
|
||||
# Sources
|
||||
###
|
||||
set(CVPCB_DIALOGS
|
||||
set( CVPCB_DIALOGS
|
||||
dialogs/dialog_cvpcb_config.cpp
|
||||
dialogs/dialog_cvpcb_config_fbp.cpp
|
||||
dialogs/dialog_display_options.cpp
|
||||
dialogs/dialog_display_options_base.cpp
|
||||
)
|
||||
|
||||
set(CVPCB_SRCS
|
||||
set( CVPCB_SRCS
|
||||
../common/base_units.cpp
|
||||
../pcbnew/board_items_to_polygon_shape_transform.cpp
|
||||
../pcbnew/class_drc_item.cpp
|
||||
|
@ -46,32 +45,35 @@ set(CVPCB_SRCS
|
|||
###
|
||||
# Windows resource file
|
||||
###
|
||||
if(WIN32)
|
||||
if(MINGW)
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# CVPCB_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler(cvpcb)
|
||||
else(MINGW)
|
||||
set(CVPCB_RESOURCES cvpcb.rc)
|
||||
endif(MINGW)
|
||||
endif(WIN32)
|
||||
mingw_resource_compiler( cvpcb )
|
||||
else()
|
||||
set( CVPCB_RESOURCES cvpcb.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
###
|
||||
# Apple resource files
|
||||
###
|
||||
if(APPLE)
|
||||
set(CVPCB_RESOURCES cvpcb.icns cvpcb_doc.icns)
|
||||
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/cvpcb.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
||||
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/cvpcb_doc.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
||||
set(MACOSX_BUNDLE_ICON_FILE cvpcb.icns)
|
||||
set(MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.cvpcb)
|
||||
endif(APPLE)
|
||||
if( APPLE )
|
||||
set( CVPCB_RESOURCES cvpcb.icns cvpcb_doc.icns )
|
||||
|
||||
set_source_files_properties( "${CMAKE_CURRENT_SOURCE_DIR}/cvpcb.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources )
|
||||
|
||||
set_source_files_properties( "${CMAKE_CURRENT_SOURCE_DIR}/cvpcb_doc.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources )
|
||||
|
||||
set( MACOSX_BUNDLE_ICON_FILE cvpcb.icns )
|
||||
set( MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.cvpcb )
|
||||
endif()
|
||||
|
||||
###
|
||||
# Create the cvpcb executable
|
||||
###
|
||||
add_executable(cvpcb WIN32 MACOSX_BUNDLE
|
||||
add_executable( cvpcb WIN32 MACOSX_BUNDLE
|
||||
${CVPCB_SRCS}
|
||||
${CVPCB_DIALOGS}
|
||||
${CVPCB_RESOURCES}
|
||||
|
@ -80,14 +82,14 @@ add_executable(cvpcb WIN32 MACOSX_BUNDLE
|
|||
###
|
||||
# Set properties for APPLE on cvpcb target
|
||||
###
|
||||
if(APPLE)
|
||||
set_target_properties(cvpcb PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
||||
endif(APPLE)
|
||||
if( APPLE )
|
||||
set_target_properties( cvpcb PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist )
|
||||
endif()
|
||||
|
||||
###
|
||||
# Link executable target cvpcb with correct libraries
|
||||
###
|
||||
target_link_libraries(cvpcb
|
||||
target_link_libraries( cvpcb
|
||||
3d-viewer
|
||||
pcbcommon
|
||||
pcad2kicadpcb
|
||||
|
@ -117,6 +119,7 @@ endif(WIN32 AND MSYS)
|
|||
###
|
||||
# Add cvpcb as install target
|
||||
###
|
||||
install(TARGETS cvpcb
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary)
|
||||
install( TARGETS cvpcb
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary
|
||||
)
|
||||
|
|
|
@ -1,11 +1,13 @@
|
|||
EESchema-LIBRARY Version 2.3 Date: 18/12/2011 10:04:44
|
||||
EESchema-LIBRARY Version 2.3
|
||||
#encoding utf-8
|
||||
#
|
||||
# 4003APG120
|
||||
#
|
||||
DEF 4003APG120 U 0 40 Y Y 1 F N
|
||||
F0 "U" 0 100 70 H V C CNN
|
||||
F1 "4003APG120" 0 -100 70 H V C CNN
|
||||
F0 "U" 400 2800 70 H V C CNN
|
||||
F1 "4003APG120" 0 -2850 70 H V C CNN
|
||||
F2 "PGA120" 0 -2950 40 H V C CNN
|
||||
F3 "" 400 2800 60 H V C CNN
|
||||
ALIAS 4003PG120
|
||||
DRAW
|
||||
S -800 -2700 800 2700 0 1 0 N
|
||||
|
@ -134,6 +136,8 @@ ENDDEF
|
|||
DEF 628128 U 0 40 Y Y 1 F N
|
||||
F0 "U" 50 0 70 H V C CNN
|
||||
F1 "628128" 300 -1200 70 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
X VCC 32 0 1100 0 D 60 60 0 0 W N
|
||||
X GND 16 0 -1100 0 U 60 60 0 0 W N
|
||||
|
@ -175,6 +179,8 @@ ENDDEF
|
|||
DEF 74LS245 U 0 10 Y Y 1 F N
|
||||
F0 "U" 100 575 60 H V L BNN
|
||||
F1 "74LS245" 50 -575 60 H V L TNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
ALIAS 74HC245
|
||||
DRAW
|
||||
X GND 10 0 -550 0 U 60 60 0 0 W N
|
||||
|
@ -208,6 +214,8 @@ ENDDEF
|
|||
DEF 74LS541 U 0 30 Y Y 1 F N
|
||||
F0 "U" 0 575 60 H V C BNN
|
||||
F1 "74LS541" 0 -575 60 H V C TNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
X GND 10 -200 -550 0 U 60 60 0 0 W N
|
||||
X VCC 20 -200 550 0 D 60 60 0 0 W N
|
||||
|
@ -243,6 +251,8 @@ ENDDEF
|
|||
DEF 74LS688 U 0 40 Y Y 1 F N
|
||||
F0 "U" 0 950 60 H V C CNN
|
||||
F1 "74LS688" 0 -950 60 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
X GND 10 -300 -900 0 R 60 60 0 0 W N
|
||||
X VCC 20 -300 900 0 R 60 60 0 0 W N
|
||||
|
@ -273,6 +283,8 @@ ENDDEF
|
|||
DEF BUSPC BUS 0 40 Y Y 1 F N
|
||||
F0 "BUS" 0 100 70 H V C CNN
|
||||
F1 "BUSPC" 0 -100 70 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
S -600 -1600 600 1600 0 1 0 N
|
||||
X GND 1 -900 1500 300 R 60 60 1 1 P
|
||||
|
@ -343,16 +355,18 @@ ENDDEF
|
|||
# C
|
||||
#
|
||||
DEF C C 0 10 N Y 1 F N
|
||||
F0 "C" 50 100 50 H V L CNN
|
||||
F1 "C" 50 -100 50 H V L CNN
|
||||
F0 "C" 0 100 40 H V L CNN
|
||||
F1 "C" 6 -85 40 H V L CNN
|
||||
F2 "" 38 -150 30 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
$FPLIST
|
||||
SM*
|
||||
C?
|
||||
C1-1
|
||||
$ENDFPLIST
|
||||
DRAW
|
||||
P 2 0 1 20 -100 -30 100 -30 N
|
||||
P 2 0 1 20 -100 30 100 30 N
|
||||
P 2 0 1 20 -80 -30 80 -30 N
|
||||
P 2 0 1 20 -80 30 80 30 N
|
||||
X ~ 1 0 200 170 D 40 40 1 1 P
|
||||
X ~ 2 0 -200 170 U 40 40 1 1 P
|
||||
ENDDRAW
|
||||
|
@ -363,6 +377,8 @@ ENDDEF
|
|||
DEF CONN_8X2 P 0 40 Y Y 1 F N
|
||||
F0 "P" 0 450 60 H V C CNN
|
||||
F1 "CONN_8X2" 0 0 50 V V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
S -100 400 100 -400 0 1 0 N
|
||||
X ~ 1 -400 350 300 R 60 60 1 1 P I
|
||||
|
@ -387,15 +403,17 @@ ENDDEF
|
|||
# CP
|
||||
#
|
||||
DEF CP C 0 10 N N 1 F N
|
||||
F0 "C" 50 100 50 H V L CNN
|
||||
F1 "CP" 50 -100 50 H V L CNN
|
||||
F0 "C" 50 100 40 H V L CNN
|
||||
F1 "CP" 50 -100 40 H V L CNN
|
||||
F2 "" 100 -150 30 H V C CNN
|
||||
F3 "" 0 0 300 H V C CNN
|
||||
ALIAS CAPAPOL
|
||||
$FPLIST
|
||||
CP*
|
||||
SM*
|
||||
$ENDFPLIST
|
||||
DRAW
|
||||
P 4 0 1 8 -100 50 -100 -50 100 -50 100 50 N
|
||||
P 4 0 1 8 -80 50 -80 -50 80 -50 80 50 N
|
||||
P 4 0 1 0 -50 50 -50 -20 50 -20 50 50 F
|
||||
X ~ 1 0 200 150 D 40 40 1 1 P
|
||||
X ~ 2 0 -200 150 U 40 40 1 1 P
|
||||
|
@ -407,6 +425,8 @@ ENDDEF
|
|||
DEF CRYSTAL X 0 40 N N 1 F N
|
||||
F0 "X" 0 150 60 H V C CNN
|
||||
F1 "CRYSTAL" 0 -150 60 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
P 2 0 1 16 -100 100 -100 -100 N
|
||||
P 2 0 1 16 100 100 100 -100 N
|
||||
|
@ -421,6 +441,8 @@ ENDDEF
|
|||
DEF DB25 J 0 40 Y N 1 F N
|
||||
F0 "J" 50 1350 70 H V C CNN
|
||||
F1 "DB25" -50 -1350 70 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
$FPLIST
|
||||
DB25*
|
||||
$ENDFPLIST
|
||||
|
@ -516,6 +538,8 @@ ENDDEF
|
|||
DEF EP600 U 0 40 Y Y 1 F N
|
||||
F0 "U" 0 100 70 H V C CNN
|
||||
F1 "EP600" 0 -500 70 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
S -500 -850 500 850 0 1 0 N
|
||||
X CLK1 1 -800 750 300 R 60 60 1 1 I C
|
||||
|
@ -550,6 +574,8 @@ ENDDEF
|
|||
DEF ~GND #PWR 0 0 Y Y 1 F P
|
||||
F0 "#PWR" 0 0 30 H I C CNN
|
||||
F1 "GND" 0 -70 30 H I C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
P 4 0 1 0 -50 0 0 -50 50 0 -50 0 N
|
||||
X GND 1 0 0 0 U 30 30 1 1 W N
|
||||
|
@ -561,6 +587,8 @@ ENDDEF
|
|||
DEF LED D 0 40 Y N 1 F N
|
||||
F0 "D" 0 100 50 H V C CNN
|
||||
F1 "LED" 0 -100 50 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
$FPLIST
|
||||
LED-3MM
|
||||
LED-5MM
|
||||
|
@ -585,6 +613,8 @@ ENDDEF
|
|||
DEF PWR_FLAG #FLG 0 0 N N 1 F P
|
||||
F0 "#FLG" 0 95 30 H I C CNN
|
||||
F1 "PWR_FLAG" 0 180 30 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
X pwr 1 0 0 0 U 20 20 0 0 w
|
||||
P 6 0 1 0 0 0 0 50 -75 100 0 150 75 100 0 50 N
|
||||
|
@ -594,8 +624,10 @@ ENDDEF
|
|||
# R
|
||||
#
|
||||
DEF R R 0 0 N Y 1 F N
|
||||
F0 "R" 80 0 50 V V C CNN
|
||||
F1 "R" 0 0 50 V V C CNN
|
||||
F0 "R" 80 0 40 V V C CNN
|
||||
F1 "R" 7 1 40 V V C CNN
|
||||
F2 "" -70 0 30 V V C CNN
|
||||
F3 "" 0 0 30 H V C CNN
|
||||
$FPLIST
|
||||
R?
|
||||
SM0603
|
||||
|
@ -615,6 +647,8 @@ ENDDEF
|
|||
DEF RR9 RR 0 40 Y N 1 F N
|
||||
F0 "RR" 50 600 70 H V C CNN
|
||||
F1 "RR9" 30 0 70 V V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
P 6 0 1 0 -50 -450 -50 550 50 550 100 500 100 -450 -50 -450 N
|
||||
X COM 1 -350 500 300 R 60 60 1 1 P I
|
||||
|
@ -635,6 +669,8 @@ ENDDEF
|
|||
DEF VCC #PWR 0 0 Y Y 1 F P
|
||||
F0 "#PWR" 0 100 30 H I C CNN
|
||||
F1 "VCC" 0 100 30 H V C CNN
|
||||
F2 "" 0 0 60 H V C CNN
|
||||
F3 "" 0 0 60 H V C CNN
|
||||
DRAW
|
||||
X VCC 1 0 0 0 U 20 20 0 0 W N
|
||||
C 0 50 20 0 1 0 N
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
Cmp-Mod V01 Created by CvPCB (2011-03-30 BZR 2935)-testing date = 02/04/2011 13:22:13
|
||||
Cmp-Mod V01 Created by CvPcb (2013-08-20 BZR 4294)-product date = 21/08/2013 18:12:43
|
||||
|
||||
BeginCmp
|
||||
TimeStamp = /322D3011;
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -1,4 +1,4 @@
|
|||
update=02/04/2011 15:02:30
|
||||
update=07/08/2013 15:44:03
|
||||
version=1
|
||||
last_client=pcbnew
|
||||
[common]
|
||||
|
@ -14,31 +14,11 @@ NetIExt=net
|
|||
EquName1=devcms
|
||||
[eeschema]
|
||||
version=1
|
||||
PageLayoutDescrFile=pagelayout_logo.kicad_wks
|
||||
SubpartIdSeparator=0
|
||||
SubpartFirstId=65
|
||||
LibDir=
|
||||
NetFmt=1
|
||||
HPGLSpd=20
|
||||
HPGLDm=15
|
||||
HPGLNum=1
|
||||
offX_A4=0
|
||||
offY_A4=0
|
||||
offX_A3=0
|
||||
offY_A3=0
|
||||
offX_A2=0
|
||||
offY_A2=0
|
||||
offX_A1=0
|
||||
offY_A1=0
|
||||
offX_A0=0
|
||||
offY_A0=0
|
||||
offX_A=0
|
||||
offY_A=0
|
||||
offX_B=0
|
||||
offY_B=0
|
||||
offX_C=0
|
||||
offY_C=0
|
||||
offX_D=0
|
||||
offY_D=0
|
||||
offX_E=0
|
||||
offY_E=0
|
||||
NetFmtName=
|
||||
RptD_X=0
|
||||
RptD_Y=100
|
||||
RptLab=1
|
||||
|
@ -58,21 +38,24 @@ LibName11=special
|
|||
LibName12=image
|
||||
[pcbnew]
|
||||
version=1
|
||||
PadDrlX=354
|
||||
PadDimH=550
|
||||
PadDimV=550
|
||||
BoardThickness=630
|
||||
TxtPcbV=800
|
||||
TxtPcbH=600
|
||||
TxtModV=600
|
||||
TxtModH=600
|
||||
TxtModW=120
|
||||
VEgarde=100
|
||||
DrawLar=150
|
||||
EdgeLar=50
|
||||
TxtLar=170
|
||||
MSegLar=150
|
||||
PageLayoutDescrFile=pagelayout_logo.kicad_wks
|
||||
LastNetListRead=interf_u.net
|
||||
UseCmpFile=1
|
||||
PadDrill=0.89916
|
||||
PadDrillOvalY=0.89916
|
||||
PadSizeH=1.397
|
||||
PadSizeV=1.397
|
||||
PcbTextSizeV=2.032
|
||||
PcbTextSizeH=1.524
|
||||
PcbTextThickness=0.4318
|
||||
ModuleTextSizeV=1.524
|
||||
ModuleTextSizeH=1.524
|
||||
ModuleTextSizeThickness=0.3048
|
||||
SolderMaskClearance=0.254
|
||||
SolderMaskMinWidth=0
|
||||
DrawSegmentWidth=0.381
|
||||
BoardOutlineThickness=0.127
|
||||
ModuleOutlineThickness=0.381
|
||||
[pcbnew/libraries]
|
||||
LibDir=
|
||||
LibName1=connect
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
EESchema Schematic File Version 2 date 18/12/2011 10:04:44
|
||||
EESchema Schematic File Version 2
|
||||
LIBS:power
|
||||
LIBS:device
|
||||
LIBS:conn
|
||||
|
@ -12,9 +12,9 @@ LIBS:xilinx
|
|||
LIBS:special
|
||||
LIBS:image
|
||||
LIBS:interf_u-cache
|
||||
EELAYER 25 0
|
||||
EELAYER 24 0
|
||||
EELAYER END
|
||||
$Descr A3 16535 11700
|
||||
$Descr A3 16535 11693
|
||||
encoding utf-8
|
||||
Sheet 1 1
|
||||
Title "INTERFACE UNIVERSEL"
|
||||
|
@ -27,7 +27,7 @@ Comment3 "Comment 3"
|
|||
Comment4 "Comment 4"
|
||||
$EndDescr
|
||||
$Bitmap
|
||||
Pos 11200 10550
|
||||
Pos 9350 10600
|
||||
Scale 1,000000
|
||||
Data
|
||||
89 50 4E 47 0D 0A 1A 0A 00 00 00 0D 49 48 44 52 00 00 00 E5 00 00 01 0E 08 02 00 00 00 F9 5F 47
|
||||
|
@ -1181,7 +1181,7 @@ BF FD 96 77 9E 38 7E F1 EC E1 55 E2 AF 2F E0 1B 5F F9 FC FE BD 4F B9 56 EB C9 C9
|
|||
29 65 D5 9A 89 35 EB 37 F6 E3 02 4F 95 57 89 BF 1E 63 D9 CA D5 CB 7E 65 BC F3 FF E1 D5 7A 1F CE
|
||||
A2 94 8E 79 E6 79 49 E6 FD 75 9E B9 C4 BC BF CE 33 97 98 F7 D7 79 E6 12 F3 FE 3A CF 5C E2 E7 E2
|
||||
03 93 93 93 FD BA 8E 79 E6 39 19 8E FB EB DC 15 0B E6 F9 D5 61 7E 3F 30 CF 5C 62 DE 5F E7 99 4B
|
||||
FC 1F 94 BD 62 D3 EE A5 8B 6B 00 00 00 00 49 45 4E 44 AE 42 60 82 3F $EndBitmap
|
||||
FC 1F 94 BD 62 D3 EE A5 8B 6B 00 00 00 00 49 45 4E 44 AE 42 60 82 10
|
||||
EndData
|
||||
$EndBitmap
|
||||
Wire Bus Line
|
||||
|
@ -1794,6 +1794,8 @@ U 1 1 4A087146
|
|||
P 5250 1950
|
||||
F 0 "U3" H 5250 2525 60 0000 C BNN
|
||||
F 1 "74LS541" H 5250 1375 60 0000 C TNN
|
||||
F 2 "DIP-20__300" H 5250 1250 60 0000 C CNN
|
||||
F 3 "" H 5250 1950 60 0001 C CNN
|
||||
1 5250 1950
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1805,6 +1807,8 @@ U 1 1 43020357
|
|||
P 14350 4800
|
||||
F 0 "#PWR01" H 14350 4800 30 0001 C CNN
|
||||
F 1 "GND" H 14350 4730 30 0001 C CNN
|
||||
F 2 "" H 14350 4800 60 0001 C CNN
|
||||
F 3 "" H 14350 4800 60 0001 C CNN
|
||||
1 14350 4800
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1814,6 +1818,8 @@ U 1 1 43020354
|
|||
P 13550 4800
|
||||
F 0 "#PWR02" H 13550 4800 30 0001 C CNN
|
||||
F 1 "GND" H 13550 4730 30 0001 C CNN
|
||||
F 2 "" H 13550 4800 60 0001 C CNN
|
||||
F 3 "" H 13550 4800 60 0001 C CNN
|
||||
1 13550 4800
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1823,6 +1829,8 @@ U 1 1 43020343
|
|||
P 4550 2550
|
||||
F 0 "#PWR03" H 4550 2550 30 0001 C CNN
|
||||
F 1 "GND" H 4550 2480 30 0001 C CNN
|
||||
F 2 "" H 4550 2550 60 0001 C CNN
|
||||
F 3 "" H 4550 2550 60 0001 C CNN
|
||||
1 4550 2550
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1832,6 +1840,8 @@ U 1 1 4302032E
|
|||
P 1200 7700
|
||||
F 0 "#PWR04" H 1200 7700 30 0001 C CNN
|
||||
F 1 "GND" H 1200 7630 30 0001 C CNN
|
||||
F 2 "" H 1200 7700 60 0001 C CNN
|
||||
F 3 "" H 1200 7700 60 0001 C CNN
|
||||
1 1200 7700
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1841,6 +1851,8 @@ U 1 1 43020328
|
|||
P 2600 9350
|
||||
F 0 "#PWR05" H 2600 9350 30 0001 C CNN
|
||||
F 1 "GND" H 2600 9280 30 0001 C CNN
|
||||
F 2 "" H 2600 9350 60 0001 C CNN
|
||||
F 3 "" H 2600 9350 60 0001 C CNN
|
||||
1 2600 9350
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1850,6 +1862,8 @@ U 1 1 38CEA284
|
|||
P 3250 9300
|
||||
F 0 "#FLG06" H 3250 9570 30 0001 C CNN
|
||||
F 1 "PWR_FLAG" H 3250 9530 30 0000 C CNN
|
||||
F 2 "" H 3250 9300 60 0001 C CNN
|
||||
F 3 "" H 3250 9300 60 0001 C CNN
|
||||
1 3250 9300
|
||||
-1 0 0 1
|
||||
$EndComp
|
||||
|
@ -1859,6 +1873,8 @@ U 1 1 38C8E81F
|
|||
P 3250 8900
|
||||
F 0 "#PWR07" H 3250 9170 30 0001 C CNN
|
||||
F 1 "PWR_FLAG" H 3250 9130 30 0000 C CNN
|
||||
F 2 "" H 3250 8900 60 0001 C CNN
|
||||
F 3 "" H 3250 8900 60 0001 C CNN
|
||||
1 3250 8900
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1868,6 +1884,8 @@ U 1 1 38C8E014
|
|||
P 8450 2550
|
||||
F 0 "#PWR08" H 8450 2650 30 0001 C CNN
|
||||
F 1 "VCC" H 8450 2650 30 0000 C CNN
|
||||
F 2 "" H 8450 2550 60 0001 C CNN
|
||||
F 3 "" H 8450 2550 60 0001 C CNN
|
||||
1 8450 2550
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1877,6 +1895,8 @@ U 1 1 4A33B1CF
|
|||
P 1350 4250
|
||||
F 0 "#PWR09" H 1350 4450 40 0001 C CNN
|
||||
F 1 "VCC" H 1350 4400 40 0000 C CNN
|
||||
F 2 "" H 1350 4250 60 0001 C CNN
|
||||
F 3 "" H 1350 4250 60 0001 C CNN
|
||||
1 1350 4250
|
||||
0 -1 -1 0
|
||||
$EndComp
|
||||
|
@ -1886,6 +1906,8 @@ U 1 1 4A33B1D0
|
|||
P 1350 1650
|
||||
F 0 "#PWR010" H 1350 1850 40 0001 C CNN
|
||||
F 1 "VCC" H 1350 1800 40 0000 C CNN
|
||||
F 2 "" H 1350 1650 60 0001 C CNN
|
||||
F 3 "" H 1350 1650 60 0001 C CNN
|
||||
1 1350 1650
|
||||
0 -1 -1 0
|
||||
$EndComp
|
||||
|
@ -1895,6 +1917,8 @@ U 1 1 4A33B1D1
|
|||
P 10050 3000
|
||||
F 0 "#PWR011" H 10050 3100 30 0001 C CNN
|
||||
F 1 "VCC" H 10050 3100 30 0000 C CNN
|
||||
F 2 "" H 10050 3000 60 0001 C CNN
|
||||
F 3 "" H 10050 3000 60 0001 C CNN
|
||||
1 10050 3000
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1904,6 +1928,8 @@ U 1 1 4A33B1D2
|
|||
P 6100 9900
|
||||
F 0 "#PWR012" H 6100 10000 30 0001 C CNN
|
||||
F 1 "VCC" H 6100 10000 30 0000 C CNN
|
||||
F 2 "" H 6100 9900 60 0001 C CNN
|
||||
F 3 "" H 6100 9900 60 0001 C CNN
|
||||
1 6100 9900
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1913,6 +1939,8 @@ U 1 1 38C8DFD2
|
|||
P 2600 8850
|
||||
F 0 "#PWR013" H 2600 8950 30 0001 C CNN
|
||||
F 1 "VCC" H 2600 8950 30 0000 C CNN
|
||||
F 2 "" H 2600 8850 60 0001 C CNN
|
||||
F 3 "" H 2600 8850 60 0001 C CNN
|
||||
1 2600 8850
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -1994,6 +2022,8 @@ U 1 1 3268ED7F
|
|||
P 6850 2550
|
||||
F 0 "#GND014" H 6850 2550 30 0001 C CNN
|
||||
F 1 "GND" H 6850 2480 30 0001 C CNN
|
||||
F 2 "" H 6850 2550 60 0001 C CNN
|
||||
F 3 "" H 6850 2550 60 0001 C CNN
|
||||
1 6850 2550
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2019,7 +2049,8 @@ U 1 1 32568D1E
|
|||
P 1700 7250
|
||||
F 0 "JP1" H 1700 7750 70 0000 C CNN
|
||||
F 1 "CONN_8X2" V 1700 7250 70 0000 C CNN
|
||||
F 2 "pin_array_8x2" H 1700 7800 60 0000 C CNN
|
||||
F 2 "pin_array_8x2" H 1700 7850 60 0000 C CNN
|
||||
F 3 "" H 1700 7250 60 0001 C CNN
|
||||
1 1700 7250
|
||||
1 0 0 1
|
||||
$EndComp
|
||||
|
@ -2032,6 +2063,8 @@ U 1 1 32567A22
|
|||
P 3250 7950
|
||||
F 0 "#015" H 3250 8150 40 0001 C CNN
|
||||
F 1 "VCC" H 3250 8100 40 0000 C CNN
|
||||
F 2 "" H 3250 7950 60 0001 C CNN
|
||||
F 3 "" H 3250 7950 60 0001 C CNN
|
||||
1 3250 7950
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2042,6 +2075,7 @@ P 2750 8300
|
|||
F 0 "RR1" V 2800 8300 70 0000 C CNN
|
||||
F 1 "9x1K" V 2770 8630 70 0000 C CNN
|
||||
F 2 "r_pack9" V 2900 8350 60 0000 C CNN
|
||||
F 3 "" H 2750 8300 60 0001 C CNN
|
||||
1 2750 8300
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2083,6 +2117,8 @@ U 1 1 325676D0
|
|||
P 14650 6100
|
||||
F 0 "#016" H 14650 6100 30 0001 C CNN
|
||||
F 1 "GND" H 14650 6030 30 0001 C CNN
|
||||
F 2 "" H 14650 6100 60 0001 C CNN
|
||||
F 3 "" H 14650 6100 60 0001 C CNN
|
||||
1 14650 6100
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2095,6 +2131,7 @@ P 15200 7200
|
|||
F 0 "P1" H 15250 8550 70 0000 C CNN
|
||||
F 1 "DB25FEMELLE" H 15150 5850 70 0000 C CNN
|
||||
F 2 "DB25FC" H 15150 5750 60 0000 C CNN
|
||||
F 3 "" H 15200 7200 60 0001 C CNN
|
||||
1 15200 7200
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2297,6 +2334,7 @@ P 6350 9900
|
|||
F 0 "R3" V 6430 9900 50 0000 C CNN
|
||||
F 1 "10K" V 6350 9900 50 0000 C CNN
|
||||
F 2 "R3" V 6250 9900 60 0000 C CNN
|
||||
F 3 "" H 6350 9900 60 0001 C CNN
|
||||
1 6350 9900
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2346,7 +2384,8 @@ U 1 1 3240023F
|
|||
P 7700 9050
|
||||
F 0 "U5" H 7750 10200 70 0000 C CNN
|
||||
F 1 "628128" H 7700 7900 70 0000 C CNN
|
||||
F 2 "32dip600" H 7700 7800 60 0000 C CNN
|
||||
F 2 "DIP-32__600" H 7700 7800 60 0000 C CNN
|
||||
F 3 "" H 7700 9050 60 0001 C CNN
|
||||
1 7700 9050
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2378,6 +2417,8 @@ U 1 1 32332C72
|
|||
P 8450 1050
|
||||
F 0 "#017" H 8450 1150 30 0001 C CNN
|
||||
F 1 "VCC" H 8450 1150 30 0000 C CNN
|
||||
F 2 "" H 8450 1050 60 0001 C CNN
|
||||
F 3 "" H 8450 1050 60 0001 C CNN
|
||||
1 8450 1050
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2389,6 +2430,8 @@ U 1 1 32331877
|
|||
P 6850 1050
|
||||
F 0 "#018" H 6850 1050 30 0001 C CNN
|
||||
F 1 "GND" H 6850 980 30 0001 C CNN
|
||||
F 2 "" H 6850 1050 60 0001 C CNN
|
||||
F 3 "" H 6850 1050 60 0001 C CNN
|
||||
1 6850 1050
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2466,6 +2509,8 @@ U 1 1 32308380
|
|||
P 14650 1750
|
||||
F 0 "#019" H 14650 1750 30 0001 C CNN
|
||||
F 1 "GND" H 14650 1680 30 0001 C CNN
|
||||
F 2 "" H 14650 1750 60 0001 C CNN
|
||||
F 3 "" H 14650 1750 60 0001 C CNN
|
||||
1 14650 1750
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2475,6 +2520,8 @@ U 1 1 3230837A
|
|||
P 14250 2200
|
||||
F 0 "#020" H 14250 2200 30 0001 C CNN
|
||||
F 1 "GND" H 14250 2130 30 0001 C CNN
|
||||
F 2 "" H 14250 2200 60 0001 C CNN
|
||||
F 3 "" H 14250 2200 60 0001 C CNN
|
||||
1 14250 2200
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2558,6 +2605,8 @@ U 1 1 32307FB9
|
|||
P 1350 4450
|
||||
F 0 "#021" H 1350 4450 40 0001 C CNN
|
||||
F 1 "GND" H 1350 4380 40 0000 C CNN
|
||||
F 2 "" H 1350 4450 60 0001 C CNN
|
||||
F 3 "" H 1350 4450 60 0001 C CNN
|
||||
1 1350 4450
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2567,6 +2616,8 @@ U 1 1 32307FA7
|
|||
P 1350 1450
|
||||
F 0 "#022" H 1350 1450 40 0001 C CNN
|
||||
F 1 "GND" H 1350 1380 40 0000 C CNN
|
||||
F 2 "" H 1350 1450 60 0001 C CNN
|
||||
F 3 "" H 1350 1450 60 0001 C CNN
|
||||
1 1350 1450
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2577,6 +2628,7 @@ P 14350 4600
|
|||
F 0 "C3" V 14450 4750 50 0000 C CNN
|
||||
F 1 "47pF" V 14450 4450 50 0000 C CNN
|
||||
F 2 "C1" H 14550 4600 60 0000 C CNN
|
||||
F 3 "" H 14350 4600 60 0001 C CNN
|
||||
1 14350 4600
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2587,6 +2639,7 @@ P 13550 4600
|
|||
F 0 "C2" V 13650 4750 50 0000 C CNN
|
||||
F 1 "47pF" V 13650 4450 50 0000 C CNN
|
||||
F 2 "C1" H 13350 4600 60 0000 C CNN
|
||||
F 3 "" H 13550 4600 60 0001 C CNN
|
||||
1 13550 4600
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2597,6 +2650,7 @@ P 13950 4150
|
|||
F 0 "X1" H 13950 4350 70 0000 C CNN
|
||||
F 1 "8MHz" H 13950 3950 70 0000 C CNN
|
||||
F 2 "HC-18UH" H 13950 3850 60 0000 C CNN
|
||||
F 3 "" H 13950 4150 60 0001 C CNN
|
||||
1 13950 4150
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2607,6 +2661,7 @@ P 14900 3700
|
|||
F 0 "R2" V 14980 3700 50 0000 C CNN
|
||||
F 1 "1K" V 14900 3700 50 0000 C CNN
|
||||
F 2 "R3" V 14800 3700 60 0000 C CNN
|
||||
F 3 "" H 14900 3700 60 0001 C CNN
|
||||
1 14900 3700
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2617,6 +2672,7 @@ P 13950 3700
|
|||
F 0 "R1" V 14030 3700 50 0000 C CNN
|
||||
F 1 "100K" V 13950 3700 50 0000 C CNN
|
||||
F 2 "R3" V 13850 3700 60 0000 C CNN
|
||||
F 3 "" H 13950 3700 60 0001 C CNN
|
||||
1 13950 3700
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2627,6 +2683,7 @@ P 4450 9100
|
|||
F 0 "C1" H 4500 9200 50 0000 L CNN
|
||||
F 1 "47uF" H 4500 9000 50 0000 L CNN
|
||||
F 2 "CP6" H 4650 9100 60 0000 C CNN
|
||||
F 3 "" H 4450 9100 60 0001 C CNN
|
||||
1 4450 9100
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2637,6 +2694,7 @@ P 3800 9100
|
|||
F 0 "C4" H 3850 9200 50 0000 L CNN
|
||||
F 1 "47uF" H 3850 9000 50 0000 L CNN
|
||||
F 2 "CP6" H 4000 9100 60 0000 C CNN
|
||||
F 3 "" H 3800 9100 60 0001 C CNN
|
||||
1 3800 9100
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2647,6 +2705,7 @@ P 3250 9100
|
|||
F 0 "C5" H 3300 9200 50 0000 L CNN
|
||||
F 1 "47uF" H 3300 9000 50 0000 L CNN
|
||||
F 2 "CP6" H 3450 9100 60 0000 C CNN
|
||||
F 3 "" H 3250 9100 60 0001 C CNN
|
||||
1 3250 9100
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2657,6 +2716,7 @@ P 2600 9100
|
|||
F 0 "C6" H 2650 9200 50 0000 L CNN
|
||||
F 1 "47uF" H 2650 9000 50 0000 L CNN
|
||||
F 2 "CP6" H 2800 9100 60 0000 C CNN
|
||||
F 3 "" H 2600 9100 60 0001 C CNN
|
||||
1 2600 9100
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2682,7 +2742,8 @@ U 1 1 322D35B4
|
|||
P 4600 6900
|
||||
F 0 "U2" H 4600 7850 60 0000 C CNN
|
||||
F 1 "74LS688" H 4600 5950 60 0000 C CIB
|
||||
F 2 "20dip300" H 4600 5850 60 0000 C CNB
|
||||
F 2 "DIP-20__300" H 4600 5850 60 0000 C CNB
|
||||
F 3 "" H 4600 6900 60 0001 C CNN
|
||||
1 4600 6900
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2693,6 +2754,7 @@ P 11200 5700
|
|||
F 0 "U9" H 11200 8450 70 0000 C CNN
|
||||
F 1 "4003APG120" H 11200 2950 70 0000 C CNN
|
||||
F 2 "PGA120" H 11200 2850 60 0000 C CNN
|
||||
F 3 "" H 11200 5700 60 0001 C CNN
|
||||
F 4 "50$" H 11200 5700 60 0001 C CNN "price"
|
||||
F 5 "test" H 11200 5700 60 0001 C CNN "Field5"
|
||||
1 11200 5700
|
||||
|
@ -2705,6 +2767,7 @@ P 14250 2000
|
|||
F 0 "D2" H 14250 2100 50 0000 C CNN
|
||||
F 1 "LED" H 14250 1900 50 0000 C CNN
|
||||
F 2 "LEDV" V 14250 2250 60 0000 C CNN
|
||||
F 3 "" H 14250 2000 60 0001 C CNN
|
||||
1 14250 2000
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2715,6 +2778,7 @@ P 14650 1550
|
|||
F 0 "D1" H 14650 1650 50 0000 C CNN
|
||||
F 1 "LED" H 14650 1450 50 0000 C CNN
|
||||
F 2 "LEDV" V 14650 1800 60 0000 C CNN
|
||||
F 3 "" H 14650 1550 60 0001 C CNN
|
||||
1 14650 1550
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2725,6 +2789,7 @@ P 13700 1500
|
|||
F 0 "R5" V 13780 1500 50 0000 C CNN
|
||||
F 1 "330" V 13700 1500 50 0000 C CNN
|
||||
F 2 "R3" V 13730 1680 30 0000 C CNN
|
||||
F 3 "" H 13700 1500 60 0001 C CNN
|
||||
1 13700 1500
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2735,6 +2800,7 @@ P 13700 1050
|
|||
F 0 "R4" V 13780 1050 50 0000 C CNN
|
||||
F 1 "330" V 13700 1050 50 0000 C CNN
|
||||
F 2 "R3" V 13850 1050 60 0000 C CNN
|
||||
F 3 "" H 13700 1050 60 0001 C CNN
|
||||
1 13700 1050
|
||||
0 1 1 0
|
||||
$EndComp
|
||||
|
@ -2743,8 +2809,9 @@ L EP600 U8
|
|||
U 1 1 322D321C
|
||||
P 7650 1800
|
||||
F 0 "U8" H 7650 1900 70 0000 C CNN
|
||||
F 1 "EP600" H 7650 1300 70 0000 C CNN
|
||||
F 2 "24dip300" H 7700 1000 60 0000 C CNN
|
||||
F 1 "EP600" H 7650 850 70 0000 C CNN
|
||||
F 2 "DIP-24__300" H 7700 750 60 0000 C CNN
|
||||
F 3 "" H 7650 1800 60 0001 C CNN
|
||||
1 7650 1800
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2754,7 +2821,8 @@ U 1 1 322D31F4
|
|||
P 5200 3600
|
||||
F 0 "U1" H 5300 4175 60 0000 L BNN
|
||||
F 1 "74LS245" H 5250 3025 60 0000 L TNN
|
||||
F 2 "20dip300" H 5350 3100 60 0000 C CNN
|
||||
F 2 "DIP-20__300" H 5400 2900 60 0000 C CNN
|
||||
F 3 "" H 5200 3600 60 0001 C CNN
|
||||
1 5200 3600
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
@ -2762,9 +2830,10 @@ $Comp
|
|||
L BUSPC BUS1
|
||||
U 1 1 322D3011
|
||||
P 2250 2950
|
||||
F 0 "BUS1" H 2250 3050 70 0000 C CNN
|
||||
F 1 "BUSPC" H 2250 2850 70 0000 C CNN
|
||||
F 2 "BUS_PC" H 2250 1250 60 0000 C CNN
|
||||
F 0 "BUS1" H 2200 4600 70 0000 C CNN
|
||||
F 1 "BUSPC" H 2200 1250 70 0000 C CNN
|
||||
F 2 "BUS_PC" H 2202 1160 60 0000 C CNN
|
||||
F 3 "" H 2250 2950 60 0001 C CNN
|
||||
1 2250 2950
|
||||
1 0 0 -1
|
||||
$EndComp
|
||||
|
|
|
@ -0,0 +1,191 @@
|
|||
( page_layout
|
||||
( setup (textsize 1.5 1.5) (linewidth 0.15) (textlinewidth 0.15) )
|
||||
( rect (comment "rect around the title block") (linewidth 0.15) (start 110 34) (end 2 2) )
|
||||
( rect (start 0 0 ltcorner) (end 0 0 rbcorner) (repeat 2) (incrx 2) (incry 2) )
|
||||
( line (start 50 2 ltcorner) (end 50 0 ltcorner) (repeat 30) (incrx 50) )
|
||||
( tbtext "1" (pos 25 1 ltcorner) (font (size 1.3 1.3))(repeat 100) (incrx 50) )
|
||||
( line (start 50 2 lbcorner) (end 50 0 lbcorner) (repeat 30) (incrx 50) )
|
||||
( tbtext "1" (pos 25 1 lbcorner) (font (size 1.3 1.3)) (repeat 100) (incrx 50) )
|
||||
( line (start 0 50 ltcorner) (end 2 50 ltcorner) (repeat 30) (incry 50) )
|
||||
( tbtext "A" (pos 1 25 ltcorner) (font (size 1.3 1.3))
|
||||
(justify center)(repeat 100) (incry 50) )
|
||||
( line (start 0 50 rtcorner) (end 2 50 rtcorner) (repeat 30) (incry 50) )
|
||||
( tbtext "A" (pos 1 25 rtcorner) (font (size 1.3 1.3))
|
||||
(justify center) (repeat 100) (incry 50) )
|
||||
( tbtext "Date: %D" (pos 87 6.9) )
|
||||
( line (start 110 5.5) end 2 5.5) )
|
||||
( tbtext "%K" (pos 109 4.1) (comment "Kicad version" ) )
|
||||
( line (start 110 8.5) end 2 8.5) )
|
||||
( tbtext "Rev: %R" (pos 24 6.9)(font bold)(justify left) )
|
||||
( tbtext "Size: %Z" (comment "Paper format name")(pos 109 6.9) )
|
||||
( tbtext "Id: %S/%N" (comment "Sheet id")(pos 24 4.1) )
|
||||
( line (start 110 12.5) end 2 12.5) )
|
||||
( tbtext "Title: %T" (pos 109 10.7)(font bold (size 2 2)) )
|
||||
( tbtext "File: %F" (pos 109 14.3) )
|
||||
( line (start 110 18.5) end 2 18.5) )
|
||||
( tbtext "Sheet: %P" (pos 109 17) )
|
||||
( tbtext "%Y" (comment "Company name") (pos 109 20)(font bold) )
|
||||
( tbtext "%C0" (comment "Comment 0") (pos 109 23) )
|
||||
( tbtext "%C1" (comment "Comment 1") (pos 109 26) )
|
||||
( tbtext "%C2" (comment "Comment 2") (pos 109 29) )
|
||||
( tbtext "%C3" (comment "Comment 3") (pos 109 32) )
|
||||
( line (start 90 8.5) (end 90 5.5) )
|
||||
( line (start 26 8.5) (end 26 2) )
|
||||
|
||||
( rect (comment "rect around the logo") (linewidth 0.15) (start 157 34) (end 110 2) )
|
||||
(polygon (pos 134 18 rbcorner) (rotate 20) (linewidth 0.00254)
|
||||
(pts (xy 20.574 8.382) (xy 19.9009 8.382) (xy 19.9009 6.26364) (xy 19.7485 5.98932)
|
||||
(xy 19.71802 5.92328) (xy 19.69262 5.83946) (xy 19.66976 5.72262) (xy 19.65198 5.56006)
|
||||
(xy 19.63674 5.33908) (xy 19.6215 5.04952) (xy 19.61134 4.67614) (xy 19.60372 4.20624)
|
||||
(xy 19.5961 3.62712) (xy 19.58848 2.92862) (xy 19.5834 2.09296) (xy 19.57832 1.11252)
|
||||
(xy 19.57578 0.27432) (xy 19.55038 -5.16636) (xy 18.15592 -5.16636) (xy 17.69364 -5.16382)
|
||||
(xy 17.29232 -5.15874) (xy 16.98752 -5.15112) (xy 16.80464 -5.14096) (xy 16.764 -5.13334)
|
||||
(xy 16.79194 -5.0419) (xy 16.8656 -4.85648) (xy 16.891 -4.79806) (xy 16.93672 -4.64312)
|
||||
(xy 16.97228 -4.42468) (xy 16.99514 -4.11734) (xy 17.01038 -3.69824) (xy 17.01546 -3.14198)
|
||||
(xy 17.018 -2.82702) (xy 17.01546 -2.25806) (xy 17.01292 -1.83896) (xy 17.0053 -1.5494)
|
||||
(xy 16.99006 -1.36652) (xy 16.9672 -1.27508) (xy 16.93164 -1.25222) (xy 16.88592 -1.28016)
|
||||
(xy 16.8656 -1.29794) (xy 16.47444 -1.5494) (xy 15.96644 -1.71704) (xy 15.3797 -1.7907)
|
||||
(xy 15.2527 -1.79324) (xy 14.53134 -1.71958) (xy 13.89634 -1.50622) (xy 13.35278 -1.14808)
|
||||
(xy 12.9032 -0.65024) (xy 12.5476 -0.0127) (xy 12.28598 0.762) (xy 12.22756 1.016)
|
||||
(xy 12.1539 1.50368) (xy 12.11326 2.07264) (xy 12.10564 2.667) (xy 12.13104 3.23342)
|
||||
(xy 12.18692 3.71348) (xy 12.2301 3.91668) (xy 12.49934 4.66344) (xy 12.88288 5.2959)
|
||||
(xy 13.36802 5.8039) (xy 13.94968 6.17982) (xy 14.39164 6.35508) (xy 14.76248 6.41858)
|
||||
(xy 15.21968 6.4262) (xy 15.69466 6.38302) (xy 16.11376 6.29158) (xy 16.20266 6.2611)
|
||||
(xy 16.49984 6.1341) (xy 16.76146 5.99694) (xy 16.87576 5.92074) (xy 17.06118 5.7912)
|
||||
(xy 17.15262 5.78104) (xy 17.1831 5.9055) (xy 17.18564 6.00964) (xy 17.18564 6.26364)
|
||||
(xy 18.542 6.26364) (xy 19.9009 6.26364) (xy 19.9009 8.382) (xy 11.51636 8.382)
|
||||
(xy 11.51636 6.26364) (xy 11.3665 6.03504) (xy 11.32586 5.9563) (xy 11.2903 5.84962)
|
||||
(xy 11.26236 5.69468) (xy 11.24204 5.4737) (xy 11.22172 5.17144) (xy 11.20648 4.76504)
|
||||
(xy 11.19124 4.2418) (xy 11.17854 3.57886) (xy 11.16838 3.00736) (xy 11.1506 2.16408)
|
||||
(xy 11.13282 1.47066) (xy 11.10996 0.90932) (xy 11.07694 0.45974) (xy 11.03122 0.10414)
|
||||
(xy 10.97026 -0.1778) (xy 10.89152 -0.40386) (xy 10.78738 -0.59436) (xy 10.6553 -0.76962)
|
||||
(xy 10.49274 -0.94234) (xy 10.40892 -1.0287) (xy 9.93394 -1.38684) (xy 9.34212 -1.63576)
|
||||
(xy 8.64616 -1.77546) (xy 7.85622 -1.80086) (xy 6.99262 -1.7145) (xy 6.31952 -1.57988)
|
||||
(xy 5.92836 -1.48844) (xy 5.58038 -1.41478) (xy 5.31622 -1.36906) (xy 5.19938 -1.35636)
|
||||
(xy 5.0419 -1.32588) (xy 4.99364 -1.27254) (xy 5.02666 -1.1557) (xy 5.10794 -0.92964)
|
||||
(xy 5.22224 -0.635) (xy 5.35432 -0.31496) (xy 5.48132 -0.01524) (xy 5.588 0.22098)
|
||||
(xy 5.65658 0.35052) (xy 5.6642 0.36068) (xy 5.76834 0.36322) (xy 5.98424 0.31496)
|
||||
(xy 6.26872 0.22098) (xy 6.3119 0.2032) (xy 6.83768 0.04572) (xy 7.3406 -0.03048)
|
||||
(xy 7.79018 -0.0254) (xy 8.14324 0.0635) (xy 8.2677 0.13462) (xy 8.49376 0.40132)
|
||||
(xy 8.60044 0.68326) (xy 8.69188 1.05664) (xy 7.66826 1.10744) (xy 6.97738 1.16078)
|
||||
(xy 6.41096 1.24968) (xy 5.92836 1.3843) (xy 5.49148 1.5748) (xy 5.24764 1.70942)
|
||||
(xy 4.77012 2.08534) (xy 4.4196 2.54762) (xy 4.19608 3.0734) (xy 4.09448 3.63474)
|
||||
(xy 4.11988 4.20878) (xy 4.26974 4.76758) (xy 4.54406 5.28828) (xy 4.9403 5.74294)
|
||||
(xy 5.31876 6.02742) (xy 5.85978 6.2738) (xy 6.47954 6.40588) (xy 7.12724 6.42112)
|
||||
(xy 7.74954 6.30936) (xy 7.75208 6.30936) (xy 8.06958 6.18744) (xy 8.37438 6.02742)
|
||||
(xy 8.46582 5.96646) (xy 8.763 5.74802) (xy 8.7884 6.00456) (xy 8.8138 6.26364)
|
||||
(xy 10.16508 6.26364) (xy 11.51636 6.26364) (xy 11.51636 8.382) (xy 4.13766 8.382)
|
||||
(xy 4.13766 5.44068) (xy 4.10972 5.36702) (xy 4.0132 5.1816) (xy 3.86334 4.91744)
|
||||
(xy 3.68046 4.6101) (xy 3.48742 4.29006) (xy 3.29946 3.99034) (xy 3.1369 3.74142)
|
||||
(xy 3.10896 3.70078) (xy 2.9464 3.46456) (xy 2.65684 3.7211) (xy 2.20726 4.05892)
|
||||
(xy 1.76276 4.26212) (xy 1.27254 4.34848) (xy 1.05664 4.3561) (xy 0.70104 4.34594)
|
||||
(xy 0.43942 4.29768) (xy 0.19558 4.19862) (xy 0.05842 4.11988) (xy -0.38862 3.76682)
|
||||
(xy -0.75946 3.28168) (xy -1.03378 2.7051) (xy -1.07188 2.58572) (xy -1.143 2.30378)
|
||||
(xy -1.19126 1.98374) (xy -1.21666 1.58496) (xy -1.22936 1.0668) (xy -1.22936 0.889)
|
||||
(xy -1.22428 0.381) (xy -1.21158 0) (xy -1.17856 -0.30226) (xy -1.12776 -0.56896)
|
||||
(xy -1.04902 -0.84328) (xy -1.02108 -0.92964) (xy -0.75438 -1.53416) (xy -0.3937 -2.01676)
|
||||
(xy 0.04318 -2.36474) (xy 0.54864 -2.57048) (xy 0.99822 -2.62636) (xy 1.54686 -2.55524)
|
||||
(xy 2.05486 -2.35712) (xy 2.35712 -2.15138) (xy 2.5527 -1.98882) (xy 2.68986 -1.88468)
|
||||
(xy 2.7305 -1.86436) (xy 2.794 -1.9304) (xy 2.92608 -2.10312) (xy 3.10388 -2.35458)
|
||||
(xy 3.30962 -2.65176) (xy 3.51536 -2.96164) (xy 3.70586 -3.25374) (xy 3.85318 -3.4925)
|
||||
(xy 3.94208 -3.64998) (xy 3.95732 -3.69316) (xy 3.86588 -3.74396) (xy 3.66268 -3.85064)
|
||||
(xy 3.3782 -3.99288) (xy 3.22326 -4.06654) (xy 2.54508 -4.36118) (xy 1.92532 -4.5466)
|
||||
(xy 1.31318 -4.64058) (xy 0.87122 -4.65836) (xy 0.02286 -4.59232) (xy -0.7493 -4.38912)
|
||||
(xy -1.46558 -4.0386) (xy -2.15392 -3.5306) (xy -2.38252 -3.32232) (xy -2.9464 -2.70764)
|
||||
(xy -3.37312 -2.04978) (xy -3.6957 -1.30302) (xy -3.82524 -0.87376) (xy -3.94208 -0.26924)
|
||||
(xy -4.00304 0.43434) (xy -4.00812 1.17348) (xy -3.95986 1.88976) (xy -3.85572 2.52222)
|
||||
(xy -3.82524 2.64922) (xy -3.51028 3.53314) (xy -3.07848 4.32562) (xy -2.53746 5.0165)
|
||||
(xy -1.905 5.588) (xy -1.19126 6.02488) (xy -0.44958 6.30682) (xy 0.01016 6.39064)
|
||||
(xy 0.57404 6.4262) (xy 1.17856 6.41604) (xy 1.76276 6.3627) (xy 2.26822 6.26364)
|
||||
(xy 2.286 6.25856) (xy 2.72288 6.11124) (xy 3.23088 5.90296) (xy 3.73888 5.66166)
|
||||
(xy 4.13766 5.44068) (xy 4.13766 8.382) (xy 0 8.382) (xy -4.74218 8.382)
|
||||
(xy -4.74218 1.7653) (xy -4.74218 0.71882) (xy -4.74218 -0.55118) (xy -4.74218 -1.66116)
|
||||
(xy -4.74218 -2.62382) (xy -4.74472 -3.44678) (xy -4.7498 -4.14528) (xy -4.75742 -4.7244)
|
||||
(xy -4.77012 -5.19938) (xy -4.79044 -5.57784) (xy -4.81584 -5.87248) (xy -4.84886 -6.09346)
|
||||
(xy -4.8895 -6.2484) (xy -4.94284 -6.35254) (xy -5.0038 -6.4135) (xy -5.07746 -6.44144)
|
||||
(xy -5.16382 -6.44906) (xy -5.26542 -6.44398) (xy -5.37972 -6.4389) (xy -5.40512 -6.4389)
|
||||
(xy -5.6515 -6.4516) (xy -5.79374 -6.51002) (xy -5.90042 -6.65734) (xy -5.969 -6.79958)
|
||||
(xy -6.23062 -7.1755) (xy -6.57606 -7.4295) (xy -6.97738 -7.56158) (xy -7.40156 -7.57682)
|
||||
(xy -7.81558 -7.47014) (xy -8.1915 -7.24662) (xy -8.49376 -6.90626) (xy -8.58774 -6.73354)
|
||||
(xy -8.72998 -6.43636) (xy -14.05382 -6.43636) (xy -15.14602 -6.43636) (xy -16.08074 -6.43382)
|
||||
(xy -16.87068 -6.43128) (xy -17.52854 -6.42874) (xy -18.06702 -6.42112) (xy -18.49628 -6.4135)
|
||||
(xy -18.83156 -6.40334) (xy -19.08302 -6.39064) (xy -19.2659 -6.3754) (xy -19.38782 -6.35508)
|
||||
(xy -19.46402 -6.33222) (xy -19.50974 -6.30428) (xy -19.50974 -6.30174) (xy -19.53514 -6.26618)
|
||||
(xy -19.55546 -6.1976) (xy -19.57324 -6.08838) (xy -19.59102 -5.92582) (xy -19.60372 -5.69976)
|
||||
(xy -19.61388 -5.40004) (xy -19.6215 -5.0165) (xy -19.62912 -4.53644) (xy -19.6342 -3.95224)
|
||||
(xy -19.63928 -3.24866) (xy -19.64182 -2.41808) (xy -19.64182 -1.4478) (xy -19.64436 -0.32766)
|
||||
(xy -19.64436 0.71882) (xy -19.64436 1.9685) (xy -19.64182 3.06324) (xy -19.64182 4.00812)
|
||||
(xy -19.63928 4.81584) (xy -19.6342 5.49656) (xy -19.62912 6.06552) (xy -19.6215 6.52526)
|
||||
(xy -19.61134 6.8961) (xy -19.60118 7.18058) (xy -19.58848 7.39394) (xy -19.5707 7.54634)
|
||||
(xy -19.55292 7.64794) (xy -19.53006 7.71144) (xy -19.50974 7.73938) (xy -19.47418 7.76224)
|
||||
(xy -19.4056 7.7851) (xy -19.29892 7.80288) (xy -19.1389 7.81812) (xy -18.91538 7.83082)
|
||||
(xy -18.62074 7.84098) (xy -18.24228 7.85114) (xy -17.76984 7.85622) (xy -17.1958 7.86384)
|
||||
(xy -16.50238 7.86638) (xy -15.68704 7.86892) (xy -14.732 7.87146) (xy -13.63218 7.87146)
|
||||
(xy -12.37488 7.87146) (xy -12.192 7.874) (xy -10.91438 7.87146) (xy -9.79424 7.87146)
|
||||
(xy -8.82142 7.86892) (xy -7.98576 7.86638) (xy -7.2771 7.86384) (xy -6.68782 7.85876)
|
||||
(xy -6.20014 7.85114) (xy -5.81152 7.84352) (xy -5.50672 7.83336) (xy -5.27304 7.81812)
|
||||
(xy -5.1054 7.80542) (xy -4.9911 7.78764) (xy -4.91998 7.76732) (xy -4.87934 7.74192)
|
||||
(xy -4.8768 7.73938) (xy -4.8514 7.70128) (xy -4.83108 7.6327) (xy -4.8133 7.52348)
|
||||
(xy -4.79552 7.36092) (xy -4.78282 7.1374) (xy -4.77266 6.83768) (xy -4.76504 6.45414)
|
||||
(xy -4.75742 5.97408) (xy -4.75234 5.38734) (xy -4.74726 4.6863) (xy -4.74472 3.85318)
|
||||
(xy -4.74472 2.88544) (xy -4.74218 1.7653) (xy -4.74218 8.382) (xy -20.574 8.382)
|
||||
(xy -20.574 0) (xy -20.574 -8.382) (xy 0 -8.382) (xy 20.574 -8.382)
|
||||
(xy 20.574 0) (xy 20.574 8.382) (xy 20.574 8.382))
|
||||
(pts (xy -9.4742 6.26364) (xy -11.25728 6.26364) (xy -13.04036 6.26364) (xy -13.04036 6.0071)
|
||||
(xy -13.07846 5.76072) (xy -13.17752 5.48386) (xy -13.20038 5.4356) (xy -13.28674 5.29336)
|
||||
(xy -13.45692 5.0419) (xy -13.68806 4.70662) (xy -13.96746 4.31292) (xy -14.27226 3.88112)
|
||||
(xy -14.58976 3.4417) (xy -14.8971 3.02006) (xy -15.1765 2.63652) (xy -15.41526 2.31902)
|
||||
(xy -15.58798 2.09296) (xy -15.67942 1.98882) (xy -15.7099 2.03454) (xy -15.73022 2.24282)
|
||||
(xy -15.74038 2.61874) (xy -15.74292 3.15976) (xy -15.7353 3.76682) (xy -15.72514 4.37896)
|
||||
(xy -15.71244 4.84886) (xy -15.69974 5.19684) (xy -15.67688 5.45084) (xy -15.64894 5.63372)
|
||||
(xy -15.6083 5.76834) (xy -15.55496 5.88518) (xy -15.5194 5.94614) (xy -15.33144 6.26364)
|
||||
(xy -16.96974 6.26364) (xy -18.61058 6.26364) (xy -18.45056 5.94868) (xy -18.415 5.87502)
|
||||
(xy -18.38706 5.78612) (xy -18.36166 5.67182) (xy -18.34134 5.51688) (xy -18.3261 5.30606)
|
||||
(xy -18.3134 5.02666) (xy -18.30324 4.66598) (xy -18.29816 4.20624) (xy -18.29308 3.63728)
|
||||
(xy -18.29054 2.94386) (xy -18.29054 2.11328) (xy -18.29054 1.12776) (xy -18.288 0.889)
|
||||
(xy -18.29054 -0.13208) (xy -18.29054 -0.99568) (xy -18.29308 -1.71958) (xy -18.29562 -2.31394)
|
||||
(xy -18.30324 -2.79654) (xy -18.31086 -3.18008) (xy -18.32356 -3.47472) (xy -18.3388 -3.70078)
|
||||
(xy -18.35658 -3.86588) (xy -18.37944 -3.9878) (xy -18.40738 -4.08178) (xy -18.4404 -4.15798)
|
||||
(xy -18.45056 -4.17322) (xy -18.61058 -4.48818) (xy -17.01038 -4.48818) (xy -16.51 -4.48564)
|
||||
(xy -16.07566 -4.48056) (xy -15.73022 -4.4704) (xy -15.49908 -4.4577) (xy -15.41018 -4.44246)
|
||||
(xy -15.44574 -4.3434) (xy -15.53464 -4.16052) (xy -15.55496 -4.12496) (xy -15.61084 -3.9878)
|
||||
(xy -15.65402 -3.7973) (xy -15.6845 -3.52806) (xy -15.70736 -3.15468) (xy -15.72514 -2.64922)
|
||||
(xy -15.73276 -2.37236) (xy -15.75054 -1.70434) (xy -15.75816 -1.20396) (xy -15.748 -0.86106)
|
||||
(xy -15.70228 -0.6731) (xy -15.61084 -0.63754) (xy -15.46098 -0.74422) (xy -15.24 -0.99314)
|
||||
(xy -14.93266 -1.37668) (xy -14.5288 -1.8923) (xy -14.51102 -1.91516) (xy -14.04112 -2.51714)
|
||||
(xy -13.67028 -3.00482) (xy -13.39088 -3.39344) (xy -13.18768 -3.70078) (xy -13.0556 -3.94208)
|
||||
(xy -12.9794 -4.13004) (xy -12.95654 -4.28244) (xy -12.954 -4.29768) (xy -12.954 -4.48818)
|
||||
(xy -11.23696 -4.48818) (xy -9.51992 -4.48818) (xy -10.07364 -3.91668) (xy -10.25398 -3.7211)
|
||||
(xy -10.50544 -3.43154) (xy -10.81278 -3.06832) (xy -11.1633 -2.64922) (xy -11.54176 -2.19202)
|
||||
(xy -11.93038 -1.71704) (xy -12.319 -1.23952) (xy -12.68476 -0.78232) (xy -13.02004 -0.36068)
|
||||
(xy -13.30452 0.00254) (xy -13.5255 0.2921) (xy -13.66774 0.49022) (xy -13.716 0.57404)
|
||||
(xy -13.66774 0.66294) (xy -13.53058 0.86868) (xy -13.31976 1.17348) (xy -13.04798 1.55702)
|
||||
(xy -12.7254 2.00406) (xy -12.3698 2.49428) (xy -11.99388 3.00736) (xy -11.61034 3.5306)
|
||||
(xy -11.23442 4.0386) (xy -10.87628 4.51866) (xy -10.55116 4.95046) (xy -10.27176 5.31622)
|
||||
(xy -10.05332 5.59562) (xy -9.91108 5.76834) (xy -9.4742 6.26364) (xy -9.4742 6.26364))
|
||||
(pts (xy -5.75818 6.23316) (xy -5.83946 6.24332) (xy -6.06044 6.25094) (xy -6.39826 6.25856)
|
||||
(xy -6.82498 6.26364) (xy -7.239 6.26364) (xy -7.71906 6.2611) (xy -8.13562 6.25856)
|
||||
(xy -8.4582 6.25094) (xy -8.6614 6.24078) (xy -8.72236 6.23316) (xy -8.69188 6.14172)
|
||||
(xy -8.61822 5.95376) (xy -8.59536 5.89534) (xy -8.5598 5.72262) (xy -8.52932 5.40512)
|
||||
(xy -8.50392 4.9657) (xy -8.4836 4.42468) (xy -8.46836 3.81) (xy -8.4582 3.14198)
|
||||
(xy -8.45566 2.44602) (xy -8.45566 1.74498) (xy -8.46074 1.06172) (xy -8.47344 0.42164)
|
||||
(xy -8.49122 -0.15494) (xy -8.51408 -0.64262) (xy -8.54202 -1.01854) (xy -8.57504 -1.25984)
|
||||
(xy -8.59028 -1.31572) (xy -8.7122 -1.61036) (xy -7.36346 -1.61036) (xy -6.01218 -1.61036)
|
||||
(xy -6.01218 1.99136) (xy -6.01218 2.8956) (xy -6.00964 3.6449) (xy -6.00456 4.2545)
|
||||
(xy -5.9944 4.74472) (xy -5.98424 5.12572) (xy -5.96646 5.41274) (xy -5.94614 5.6261)
|
||||
(xy -5.92074 5.77596) (xy -5.89026 5.88264) (xy -5.88518 5.89534) (xy -5.8039 6.09854)
|
||||
(xy -5.76072 6.22046) (xy -5.75818 6.23316) (xy -5.75818 6.23316))
|
||||
(pts (xy 8.636 3.4544) (xy 8.62838 3.80238) (xy 8.60298 4.0259) (xy 8.54964 4.17322)
|
||||
(xy 8.45312 4.28752) (xy 8.4455 4.29514) (xy 8.08736 4.52628) (xy 7.66826 4.64058)
|
||||
(xy 7.24408 4.62788) (xy 7.05866 4.572) (xy 6.77672 4.37388) (xy 6.5913 4.07924)
|
||||
(xy 6.5405 3.74142) (xy 6.54558 3.70078) (xy 6.60146 3.45186) (xy 6.68782 3.25882)
|
||||
(xy 6.70052 3.24104) (xy 6.96468 3.03784) (xy 7.35076 2.88798) (xy 7.81812 2.8067)
|
||||
(xy 8.0645 2.794) (xy 8.636 2.794) (xy 8.636 3.4544) (xy 8.636 3.4544))
|
||||
(pts (xy 17.018 4.04876) (xy 16.7259 4.2291) (xy 16.34744 4.3942) (xy 15.94358 4.46024)
|
||||
(xy 15.56766 4.4196) (xy 15.35938 4.3307) (xy 15.13332 4.15544) (xy 14.9733 3.93192)
|
||||
(xy 14.86408 3.6322) (xy 14.80058 3.23342) (xy 14.77518 2.70764) (xy 14.77264 2.45364)
|
||||
(xy 14.79296 1.77546) (xy 14.859 1.23952) (xy 14.97076 0.82296) (xy 15.1384 0.508)
|
||||
(xy 15.33652 0.29718) (xy 15.66418 0.127) (xy 16.06042 0.08382) (xy 16.48714 0.17018)
|
||||
(xy 16.68018 0.254) (xy 17.018 0.42672) (xy 17.018 2.23774) (xy 17.018 4.04876)
|
||||
(xy 17.018 4.04876)) )
|
||||
)
|
|
@ -6,7 +6,6 @@ include_directories(
|
|||
./dialogs
|
||||
../common
|
||||
../common/dialogs
|
||||
${Boost_INCLUDE_DIR}
|
||||
${INC_AFTER}
|
||||
)
|
||||
|
||||
|
|
|
@ -162,7 +162,7 @@ void SCH_EDIT_FRAME::BeginSegment( wxDC* DC, int type )
|
|||
}
|
||||
|
||||
m_canvas->SetMouseCapture( DrawSegment, AbortCreateNewLine );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
}
|
||||
else // A segment is in progress: terminates the current segment and add a new segment.
|
||||
{
|
||||
|
@ -239,7 +239,8 @@ void SCH_EDIT_FRAME::EndSegment( wxDC* DC )
|
|||
return;
|
||||
|
||||
// Get the last non-null wire (this is the last created segment).
|
||||
m_itemToRepeat = segment = (SCH_LINE*) s_wires.GetLast();
|
||||
SetRepeatItem( segment = (SCH_LINE*) s_wires.GetLast() );
|
||||
|
||||
screen->SetCurItem( NULL );
|
||||
m_canvas->EndMouseCapture( -1, -1, wxEmptyString, false );
|
||||
|
||||
|
@ -341,7 +342,7 @@ void SCH_EDIT_FRAME::DeleteCurrentSegment( wxDC* DC )
|
|||
{
|
||||
SCH_SCREEN* screen = GetScreen();
|
||||
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
if( ( screen->GetCurItem() == NULL ) || !screen->GetCurItem()->IsNew() )
|
||||
return;
|
||||
|
@ -359,7 +360,7 @@ SCH_JUNCTION* SCH_EDIT_FRAME::AddJunction( wxDC* aDC, const wxPoint& aPosition,
|
|||
{
|
||||
SCH_JUNCTION* junction = new SCH_JUNCTION( aPosition );
|
||||
|
||||
m_itemToRepeat = junction;
|
||||
SetRepeatItem( junction );
|
||||
|
||||
m_canvas->CrossHairOff( aDC ); // Erase schematic cursor
|
||||
junction->Draw( m_canvas, aDC, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
|
@ -378,19 +379,19 @@ SCH_JUNCTION* SCH_EDIT_FRAME::AddJunction( wxDC* aDC, const wxPoint& aPosition,
|
|||
|
||||
SCH_NO_CONNECT* SCH_EDIT_FRAME::AddNoConnect( wxDC* aDC, const wxPoint& aPosition )
|
||||
{
|
||||
SCH_NO_CONNECT* NewNoConnect;
|
||||
SCH_NO_CONNECT* no_connect = new SCH_NO_CONNECT( aPosition );
|
||||
|
||||
NewNoConnect = new SCH_NO_CONNECT( aPosition );
|
||||
m_itemToRepeat = NewNoConnect;
|
||||
SetRepeatItem( no_connect );
|
||||
|
||||
m_canvas->CrossHairOff( aDC ); // Erase schematic cursor
|
||||
NewNoConnect->Draw( m_canvas, aDC, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
no_connect->Draw( m_canvas, aDC, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
|
||||
m_canvas->CrossHairOn( aDC ); // Display schematic cursor
|
||||
|
||||
GetScreen()->Append( NewNoConnect );
|
||||
GetScreen()->Append( no_connect );
|
||||
OnModify();
|
||||
SaveCopyInUndoList( NewNoConnect, UR_NEW );
|
||||
return NewNoConnect;
|
||||
SaveCopyInUndoList( no_connect, UR_NEW );
|
||||
return no_connect;
|
||||
}
|
||||
|
||||
|
||||
|
@ -420,35 +421,44 @@ static void AbortCreateNewLine( EDA_DRAW_PANEL* Panel, wxDC* DC )
|
|||
|
||||
void SCH_EDIT_FRAME::RepeatDrawItem( wxDC* DC )
|
||||
{
|
||||
if( m_itemToRepeat == NULL )
|
||||
SCH_ITEM* repeater = GetRepeatItem();
|
||||
|
||||
if( !repeater )
|
||||
return;
|
||||
|
||||
m_itemToRepeat = (SCH_ITEM*) m_itemToRepeat->Clone();
|
||||
//D( repeater>Show( 0, std::cout ); )
|
||||
|
||||
if( m_itemToRepeat->Type() == SCH_COMPONENT_T ) // If repeat component then put in move mode
|
||||
// clone the repeater, move it, insert into display list, then save a copy
|
||||
// via SetRepeatItem();
|
||||
|
||||
SCH_ITEM* my_clone = (SCH_ITEM*) repeater->Clone();
|
||||
|
||||
// If cloning a component then put into 'move' mode.
|
||||
if( my_clone->Type() == SCH_COMPONENT_T )
|
||||
{
|
||||
wxPoint pos = GetCrossHairPosition() -
|
||||
( (SCH_COMPONENT*) m_itemToRepeat )->GetPosition();
|
||||
( (SCH_COMPONENT*) my_clone )->GetPosition();
|
||||
|
||||
m_itemToRepeat->SetFlags( IS_NEW );
|
||||
( (SCH_COMPONENT*) m_itemToRepeat )->SetTimeStamp( GetNewTimeStamp() );
|
||||
m_itemToRepeat->Move( pos );
|
||||
m_itemToRepeat->Draw( m_canvas, DC, wxPoint( 0, 0 ), g_XorMode );
|
||||
MoveItem( m_itemToRepeat, DC );
|
||||
return;
|
||||
my_clone->SetFlags( IS_NEW );
|
||||
( (SCH_COMPONENT*) my_clone )->SetTimeStamp( GetNewTimeStamp() );
|
||||
my_clone->Move( pos );
|
||||
my_clone->Draw( m_canvas, DC, wxPoint( 0, 0 ), g_XorMode );
|
||||
MoveItem( my_clone, DC );
|
||||
}
|
||||
|
||||
m_itemToRepeat->Move( wxPoint( g_RepeatStep.GetWidth(), g_RepeatStep.GetHeight() ) );
|
||||
|
||||
if( m_itemToRepeat->CanIncrementLabel() )
|
||||
( (SCH_TEXT*) m_itemToRepeat )->IncrementLabel();
|
||||
|
||||
if( m_itemToRepeat )
|
||||
else
|
||||
{
|
||||
GetScreen()->Append( m_itemToRepeat );
|
||||
my_clone->Move( wxPoint( g_RepeatStep.GetWidth(), g_RepeatStep.GetHeight() ) );
|
||||
|
||||
if( my_clone->CanIncrementLabel() )
|
||||
( (SCH_TEXT*) my_clone )->IncrementLabel();
|
||||
|
||||
GetScreen()->Append( my_clone );
|
||||
GetScreen()->TestDanglingEnds();
|
||||
m_itemToRepeat->Draw( m_canvas, DC, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
SaveCopyInUndoList( m_itemToRepeat, UR_NEW );
|
||||
m_itemToRepeat->ClearFlags();
|
||||
my_clone->Draw( m_canvas, DC, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
SaveCopyInUndoList( my_clone, UR_NEW );
|
||||
my_clone->ClearFlags();
|
||||
}
|
||||
|
||||
// clone my_clone, now that it has been moved, thus saving new position.
|
||||
SetRepeatItem( my_clone );
|
||||
}
|
||||
|
|
|
@ -731,7 +731,7 @@ bool CMP_LIBRARY::SaveDocs( OUTPUTFORMATTER& aFormatter )
|
|||
|
||||
try
|
||||
{
|
||||
aFormatter.Print( 0, "%s Date: %s\n", DOCFILE_IDENT, TO_UTF8( DateAndTime() ) );
|
||||
aFormatter.Print( 0, "%s\n", DOCFILE_IDENT );
|
||||
|
||||
for( LIB_ALIAS_MAP::iterator it=aliases.begin(); it!=aliases.end(); it++ )
|
||||
{
|
||||
|
@ -752,8 +752,8 @@ bool CMP_LIBRARY::SaveDocs( OUTPUTFORMATTER& aFormatter )
|
|||
|
||||
bool CMP_LIBRARY::SaveHeader( OUTPUTFORMATTER& aFormatter )
|
||||
{
|
||||
aFormatter.Print( 0, "%s %d.%d Date: %s\n", LIBFILE_IDENT,
|
||||
LIB_VERSION_MAJOR, LIB_VERSION_MINOR, TO_UTF8( DateAndTime() ) );
|
||||
aFormatter.Print( 0, "%s %d.%d\n", LIBFILE_IDENT,
|
||||
LIB_VERSION_MAJOR, LIB_VERSION_MINOR );
|
||||
|
||||
aFormatter.Print( 0, "#encoding utf-8\n");
|
||||
|
||||
|
|
|
@ -35,6 +35,26 @@
|
|||
#include <general.h>
|
||||
#include <sch_component.h>
|
||||
|
||||
#include <wx/regex.h>
|
||||
|
||||
|
||||
/**
|
||||
* The regular expression string for label bus notation. Valid bus labels are defined as
|
||||
* one or more non-whitespace characters from the beginning of the string followed by the
|
||||
* bus notation [nn...mm] with no characters after the closing bracket.
|
||||
*/
|
||||
static wxRegEx busLabelRe( wxT( "^([^[:space:]]+)(\\[[\\d]+\\.+[\\d]+\\])$" ), wxRE_ADVANCED );
|
||||
|
||||
|
||||
bool IsBusLabel( const wxString& aLabel )
|
||||
{
|
||||
wxCHECK_MSG( busLabelRe.IsValid(), false,
|
||||
wxT( "Invalid regular expression in IsBusLabel()." ) );
|
||||
|
||||
return busLabelRe.Matches( aLabel );
|
||||
}
|
||||
|
||||
|
||||
#if defined(DEBUG)
|
||||
|
||||
#include <iostream>
|
||||
|
@ -220,31 +240,32 @@ void NETLIST_OBJECT::ConvertBusToNetListItems( NETLIST_OBJECT_LIST& aNetListItem
|
|||
wxCHECK_RET( false, wxT( "Net list object type is not valid." ) );
|
||||
|
||||
unsigned i;
|
||||
wxString tmp, busName;
|
||||
wxString tmp, busName, busNumber;
|
||||
long begin, end, member;
|
||||
|
||||
/* Search for '[' because a bus label is like "busname[nn..mm]" */
|
||||
i = m_Label.Find( '[' );
|
||||
busName = busLabelRe.GetMatch( m_Label, 1 );
|
||||
busNumber = busLabelRe.GetMatch( m_Label, 2 );
|
||||
|
||||
busName = m_Label.Left( i );
|
||||
/* Search for '[' because a bus label is like "busname[nn..mm]" */
|
||||
i = busNumber.Find( '[' );
|
||||
i++;
|
||||
|
||||
while( m_Label[i] != '.' && i < m_Label.Len() )
|
||||
while( busNumber[i] != '.' && i < busNumber.Len() )
|
||||
{
|
||||
tmp.Append( m_Label[i] );
|
||||
tmp.Append( busNumber[i] );
|
||||
i++;
|
||||
}
|
||||
|
||||
tmp.ToLong( &begin );
|
||||
|
||||
while( m_Label[i] == '.' && i < m_Label.Len() )
|
||||
while( busNumber[i] == '.' && i < busNumber.Len() )
|
||||
i++;
|
||||
|
||||
tmp.Empty();
|
||||
|
||||
while( m_Label[i] != ']' && i < m_Label.Len() )
|
||||
while( busNumber[i] != ']' && i < busNumber.Len() )
|
||||
{
|
||||
tmp.Append( m_Label[i] );
|
||||
tmp.Append( busNumber[i] );
|
||||
i++;
|
||||
}
|
||||
|
||||
|
|
|
@ -96,11 +96,7 @@ enum NET_CONNECTION_T {
|
|||
* @param aLabel A wxString object containing the label to test.
|
||||
* @return true if text is a bus notation format otherwise false is returned.
|
||||
*/
|
||||
inline bool IsBusLabel( const wxString& aLabel )
|
||||
{
|
||||
/* Search for '[' because a bus label is like "busname[nn..mm]" */
|
||||
return aLabel.Find( '[' ) != wxNOT_FOUND;
|
||||
}
|
||||
extern bool IsBusLabel( const wxString& aLabel );
|
||||
|
||||
|
||||
class NETLIST_OBJECT
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
*/
|
||||
|
||||
#include <wx/tooltip.h>
|
||||
#include <wx/hyperlink.h>
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <appl_wxstruct.h>
|
||||
|
@ -112,6 +113,7 @@ private:
|
|||
void addFieldButtonHandler( wxCommandEvent& event );
|
||||
void deleteFieldButtonHandler( wxCommandEvent& event );
|
||||
void moveUpButtonHandler( wxCommandEvent& event );
|
||||
void showButtonHandler( wxCommandEvent& event );
|
||||
|
||||
SCH_FIELD* findField( const wxString& aFieldName );
|
||||
|
||||
|
@ -252,8 +254,11 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::copyPanelToOptions()
|
|||
if( m_Cmp->GetUnit() )
|
||||
{
|
||||
int unit_selection = unitChoice->GetCurrentSelection() + 1;
|
||||
STATUS_FLAGS flags = m_Cmp->GetFlags();
|
||||
m_Cmp->SetUnitSelection( &m_Parent->GetCurrentSheet(), unit_selection );
|
||||
m_Cmp->SetUnit( unit_selection );
|
||||
m_Cmp->ClearFlags();
|
||||
m_Cmp->SetFlags( flags ); // Restore m_Flag modified by SetUnit()
|
||||
}
|
||||
|
||||
switch( orientationRadioBox->GetSelection() )
|
||||
|
@ -327,13 +332,13 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::OnOKButtonClick( wxCommandEvent& event
|
|||
&& !m_Parent->GetTemplates().HasFieldName( m_FieldsBuf[i].GetName( false ) )
|
||||
&& !removeRemainingFields )
|
||||
{
|
||||
wxString msg;
|
||||
|
||||
msg.Printf( _( "The field name <%s> does not have a value and is not defined in "
|
||||
"the field template list. Empty field values are invalid an will "
|
||||
"be removed from the component. Do you wish to remove this and "
|
||||
"all remaining undefined fields?" ),
|
||||
GetChars( m_FieldsBuf[i].GetName( false ) ) );
|
||||
wxString msg = wxString::Format(
|
||||
_( "The field name <%s> does not have a value and is not defined in "
|
||||
"the field template list. Empty field values are invalid an will "
|
||||
"be removed from the component. Do you wish to remove this and "
|
||||
"all remaining undefined fields?" ),
|
||||
GetChars( m_FieldsBuf[i].GetName( false ) )
|
||||
);
|
||||
|
||||
wxMessageDialog dlg( this, msg, _( "Remove Fields" ), wxYES_NO | wxNO_DEFAULT );
|
||||
|
||||
|
@ -428,6 +433,13 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::deleteFieldButtonHandler( wxCommandEven
|
|||
}
|
||||
|
||||
|
||||
void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::showButtonHandler( wxCommandEvent& event )
|
||||
{
|
||||
wxString datasheet_uri = fieldValueTextCtrl->GetValue();
|
||||
::wxLaunchDefaultBrowser( datasheet_uri );
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::moveUpButtonHandler( wxCommandEvent& event )
|
||||
{
|
||||
unsigned fieldNdx = getSelectedFieldNdx();
|
||||
|
@ -721,6 +733,8 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::copySelectedFieldToPanel()
|
|||
|
||||
fieldValueTextCtrl->SetValue( field.GetText() );
|
||||
|
||||
m_show_datasheet_button->Enable( fieldNdx == DATASHEET );
|
||||
|
||||
// For power symbols, the value is NOR editable, because value and pin
|
||||
// name must be same and can be edited only in library editor
|
||||
if( fieldNdx == VALUE && m_LibEntry && m_LibEntry->IsPower() )
|
||||
|
|
|
@ -178,26 +178,25 @@ DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP(
|
|||
fieldNameTextCtrl->SetMaxLength( 0 );
|
||||
fieldNameTextCtrl->SetToolTip( _("The name of the currently selected field\nSome fixed fields names are not editable") );
|
||||
|
||||
fieldNameBoxSizer->Add( fieldNameTextCtrl, 0, wxEXPAND, 5 );
|
||||
|
||||
|
||||
fieldEditBoxSizer->Add( fieldNameBoxSizer, 0, wxEXPAND, 5 );
|
||||
|
||||
wxBoxSizer* fieldTextBoxSizer;
|
||||
fieldTextBoxSizer = new wxBoxSizer( wxVERTICAL );
|
||||
fieldNameBoxSizer->Add( fieldNameTextCtrl, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
fieldValueLabel = new wxStaticText( this, wxID_ANY, _("Field Value"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fieldValueLabel->Wrap( -1 );
|
||||
fieldTextBoxSizer->Add( fieldValueLabel, 0, wxTOP, 5 );
|
||||
fieldNameBoxSizer->Add( fieldValueLabel, 0, wxALIGN_TOP|wxTOP, 5 );
|
||||
|
||||
fieldValueTextCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fieldValueTextCtrl->SetMaxLength( 0 );
|
||||
fieldValueTextCtrl->SetToolTip( _("The text (or value) of the currently selected field") );
|
||||
fieldValueTextCtrl->SetToolTip( _("The name of the currently selected field\nSome fixed fields names are not editable") );
|
||||
|
||||
fieldTextBoxSizer->Add( fieldValueTextCtrl, 0, wxEXPAND, 5 );
|
||||
fieldNameBoxSizer->Add( fieldValueTextCtrl, 0, wxEXPAND, 5 );
|
||||
|
||||
m_show_datasheet_button = new wxButton( this, wxID_ANY, _("Show in Browser"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_show_datasheet_button->SetToolTip( _("If your datasheet is an http:// link or a complete file path, then it may show in your browser by pressing this button.") );
|
||||
|
||||
fieldNameBoxSizer->Add( m_show_datasheet_button, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
|
||||
fieldEditBoxSizer->Add( fieldTextBoxSizer, 0, wxEXPAND, 5 );
|
||||
fieldEditBoxSizer->Add( fieldNameBoxSizer, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
wxFlexGridSizer* fgSizerPosSize;
|
||||
fgSizerPosSize = new wxFlexGridSizer( 3, 3, 0, 0 );
|
||||
|
@ -271,6 +270,7 @@ DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP(
|
|||
|
||||
this->SetSizer( mainSizer );
|
||||
this->Layout();
|
||||
mainSizer->Fit( this );
|
||||
|
||||
// Connect Events
|
||||
defaultsButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::SetInitCmp ), NULL, this );
|
||||
|
@ -279,6 +279,7 @@ DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP(
|
|||
addFieldButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::addFieldButtonHandler ), NULL, this );
|
||||
deleteFieldButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::deleteFieldButtonHandler ), NULL, this );
|
||||
moveUpButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::moveUpButtonHandler ), NULL, this );
|
||||
m_show_datasheet_button->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::showButtonHandler ), NULL, this );
|
||||
stdDialogButtonSizerCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::OnCancelButtonClick ), NULL, this );
|
||||
stdDialogButtonSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::OnOKButtonClick ), NULL, this );
|
||||
}
|
||||
|
@ -292,6 +293,7 @@ DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::~DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP(
|
|||
addFieldButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::addFieldButtonHandler ), NULL, this );
|
||||
deleteFieldButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::deleteFieldButtonHandler ), NULL, this );
|
||||
moveUpButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::moveUpButtonHandler ), NULL, this );
|
||||
m_show_datasheet_button->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::showButtonHandler ), NULL, this );
|
||||
stdDialogButtonSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::OnCancelButtonClick ), NULL, this );
|
||||
stdDialogButtonSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP::OnOKButtonClick ), NULL, this );
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
<property name="minimum_size"></property>
|
||||
<property name="name">DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size">700,496</property>
|
||||
<property name="size">-1,-1</property>
|
||||
<property name="style">wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU</property>
|
||||
<property name="subclass">DIALOG_SHIM; dialog_shim.h</property>
|
||||
<property name="title">Component Properties</property>
|
||||
|
@ -1808,7 +1808,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="minimum_size"></property>
|
||||
|
@ -1900,7 +1900,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1989,20 +1989,9 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">fieldTextBoxSizer</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxTOP</property>
|
||||
<property name="flag">wxALIGN_TOP|wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -2083,11 +2072,11 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="0">
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
|
@ -2136,7 +2125,7 @@
|
|||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">The text (or value) of the currently selected field</property>
|
||||
<property name="tooltip">The name of the currently selected field
Some fixed fields names are not editable</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
|
@ -2174,6 +2163,94 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxButton" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default">0</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Show in Browser</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_show_datasheet_button</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">If your datasheet is an http:// link or a complete file path, then it may show in your browser by pressing this button.</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnButtonClick">showButtonHandler</event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
|
|
@ -63,6 +63,7 @@ class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP : public DIALOG_SHIM
|
|||
wxTextCtrl* fieldNameTextCtrl;
|
||||
wxStaticText* fieldValueLabel;
|
||||
wxTextCtrl* fieldValueTextCtrl;
|
||||
wxButton* m_show_datasheet_button;
|
||||
wxStaticText* textSizeLabel;
|
||||
wxTextCtrl* textSizeTextCtrl;
|
||||
wxStaticText* m_staticTextUnitSize;
|
||||
|
@ -83,13 +84,14 @@ class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP : public DIALOG_SHIM
|
|||
virtual void addFieldButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void deleteFieldButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void moveUpButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void showButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnCancelButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnOKButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
|
||||
DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 700,496 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU );
|
||||
DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU );
|
||||
~DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP();
|
||||
|
||||
};
|
||||
|
|
|
@ -102,13 +102,19 @@ void DIALOG_LABEL_EDITOR::InitDialog()
|
|||
if( m_CurrentText->IsMultilineAllowed() )
|
||||
{
|
||||
m_textLabel = m_textLabelMultiLine;
|
||||
m_textLabelSingleLine->Show(false);
|
||||
m_textLabelSingleLine->Show( false );
|
||||
multiLine = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
m_textLabel = m_textLabelSingleLine;
|
||||
m_textLabelMultiLine->Show(false);
|
||||
m_textLabelMultiLine->Show( false );
|
||||
wxTextValidator* validator = (wxTextValidator*) m_textLabel->GetValidator();
|
||||
wxArrayString excludes;
|
||||
|
||||
// Add invalid label characters to this list.
|
||||
excludes.Add( wxT( " " ) );
|
||||
validator->SetExcludes( excludes );
|
||||
}
|
||||
|
||||
m_textLabel->SetValue( m_CurrentText->GetText() );
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Apr 10 2012)
|
||||
// C++ code generated with wxFormBuilder (version Apr 30 2013)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
|
@ -32,9 +32,13 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
bSizeText = new wxBoxSizer( wxVERTICAL );
|
||||
|
||||
m_textLabelSingleLine = new wxTextCtrl( this, wxID_VALUESINGLE, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER );
|
||||
m_textLabelSingleLine->SetMaxLength( 0 );
|
||||
m_textLabelSingleLine->SetValidator( wxTextValidator( wxFILTER_EXCLUDE_CHAR_LIST, &m_labelText ) );
|
||||
|
||||
bSizeText->Add( m_textLabelSingleLine, 0, wxEXPAND|wxLEFT, 3 );
|
||||
|
||||
m_textLabelMultiLine = new wxTextCtrl( this, wxID_VALUEMULTI, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE|wxTE_PROCESS_ENTER );
|
||||
m_textLabelMultiLine->SetMaxLength( 0 );
|
||||
m_textLabelMultiLine->SetMinSize( wxSize( -1,60 ) );
|
||||
|
||||
bSizeText->Add( m_textLabelMultiLine, 1, wxEXPAND|wxLEFT, 3 );
|
||||
|
@ -50,6 +54,7 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
bSizeCtrlSizer = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_TextSize = new wxTextCtrl( this, wxID_SIZE, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_TextSize->SetMaxLength( 0 );
|
||||
bSizeCtrlSizer->Add( m_TextSize, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT, 3 );
|
||||
|
||||
m_staticSizeUnits = new wxStaticText( this, wxID_ANY, _("units"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
|
|
|
@ -253,10 +253,10 @@
|
|||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="validator_data_type">wxString</property>
|
||||
<property name="validator_style">wxFILTER_EXCLUDE_CHAR_LIST</property>
|
||||
<property name="validator_type">wxTextValidator</property>
|
||||
<property name="validator_variable">m_labelText</property>
|
||||
<property name="value"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Apr 10 2012)
|
||||
// C++ code generated with wxFormBuilder (version Apr 30 2013)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
|
@ -11,6 +11,8 @@
|
|||
#include <wx/artprov.h>
|
||||
#include <wx/xrc/xmlres.h>
|
||||
#include <wx/intl.h>
|
||||
class DIALOG_SHIM;
|
||||
|
||||
#include "dialog_shim.h"
|
||||
#include <wx/string.h>
|
||||
#include <wx/stattext.h>
|
||||
|
@ -19,6 +21,7 @@
|
|||
#include <wx/colour.h>
|
||||
#include <wx/settings.h>
|
||||
#include <wx/textctrl.h>
|
||||
#include <wx/valtext.h>
|
||||
#include <wx/sizer.h>
|
||||
#include <wx/radiobox.h>
|
||||
#include <wx/button.h>
|
||||
|
@ -62,6 +65,7 @@ class DIALOG_LABEL_EDITOR_BASE : public DIALOG_SHIM
|
|||
|
||||
|
||||
public:
|
||||
wxString m_labelText;
|
||||
|
||||
DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Text Editor"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
||||
~DIALOG_LABEL_EDITOR_BASE();
|
||||
|
|
|
@ -77,6 +77,7 @@ private:
|
|||
void moveUpButtonHandler( wxCommandEvent& event );
|
||||
void OnCancelButtonClick( wxCommandEvent& event );
|
||||
void OnOKButtonClick( wxCommandEvent& event );
|
||||
void showButtonHandler( wxCommandEvent& event );
|
||||
|
||||
// internal functions:
|
||||
void setSelectedFieldNdx( int aFieldNdx );
|
||||
|
@ -379,6 +380,13 @@ void DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB:: moveUpButtonHandler( wxCommandEvent& e
|
|||
}
|
||||
|
||||
|
||||
void DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB::showButtonHandler( wxCommandEvent& event )
|
||||
{
|
||||
wxString datasheet_uri = fieldValueTextCtrl->GetValue();
|
||||
::wxLaunchDefaultBrowser( datasheet_uri );
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB::setSelectedFieldNdx( int aFieldNdx )
|
||||
{
|
||||
// deselect old selection, but I think this is done by single selection
|
||||
|
@ -645,6 +653,8 @@ void DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB::copySelectedFieldToPanel()
|
|||
|
||||
textSizeTextCtrl->SetValue( EDA_GRAPHIC_TEXT_CTRL::FormatSize( g_UserUnit, field.GetSize().x ) );
|
||||
|
||||
m_show_datasheet_button->Enable( fieldNdx == DATASHEET );
|
||||
|
||||
wxPoint coord = field.GetTextPosition();
|
||||
wxPoint zero;
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Oct 8 2012)
|
||||
// C++ code generated with wxFormBuilder (version Apr 30 2013)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
|
@ -109,26 +109,25 @@ DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE
|
|||
fieldNameTextCtrl->SetMaxLength( 0 );
|
||||
fieldNameTextCtrl->SetToolTip( _("The text (or value) of the currently selected field") );
|
||||
|
||||
fieldNameBoxSizer->Add( fieldNameTextCtrl, 0, wxEXPAND, 5 );
|
||||
|
||||
|
||||
fieldEditBoxSizer->Add( fieldNameBoxSizer, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
wxBoxSizer* fieldTextBoxSizer;
|
||||
fieldTextBoxSizer = new wxBoxSizer( wxVERTICAL );
|
||||
fieldNameBoxSizer->Add( fieldNameTextCtrl, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
fieldValueLabel = new wxStaticText( this, wxID_ANY, _("Field Value"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fieldValueLabel->Wrap( -1 );
|
||||
fieldTextBoxSizer->Add( fieldValueLabel, 0, 0, 5 );
|
||||
fieldNameBoxSizer->Add( fieldValueLabel, 0, wxTOP, 5 );
|
||||
|
||||
fieldValueTextCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fieldValueTextCtrl->SetMaxLength( 0 );
|
||||
fieldValueTextCtrl->SetToolTip( _("The text (or value) of the currently selected field") );
|
||||
|
||||
fieldTextBoxSizer->Add( fieldValueTextCtrl, 0, wxEXPAND, 5 );
|
||||
fieldNameBoxSizer->Add( fieldValueTextCtrl, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
m_show_datasheet_button = new wxButton( this, wxID_ANY, _("Show in Browser"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_show_datasheet_button->SetToolTip( _("If your datasheet is given as an http:// link, then pressing this button should bring it up in your webbrowser.") );
|
||||
|
||||
fieldNameBoxSizer->Add( m_show_datasheet_button, 0, wxBOTTOM|wxEXPAND, 5 );
|
||||
|
||||
|
||||
fieldEditBoxSizer->Add( fieldTextBoxSizer, 0, wxALL|wxEXPAND, 5 );
|
||||
fieldEditBoxSizer->Add( fieldNameBoxSizer, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
wxFlexGridSizer* fgSizerPosSize;
|
||||
fgSizerPosSize = new wxFlexGridSizer( 3, 3, 0, 0 );
|
||||
|
@ -200,6 +199,7 @@ DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE
|
|||
|
||||
this->SetSizer( mainSizer );
|
||||
this->Layout();
|
||||
mainSizer->Fit( this );
|
||||
|
||||
// Connect Events
|
||||
this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::OnInitDialog ) );
|
||||
|
@ -208,6 +208,7 @@ DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE
|
|||
addFieldButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::addFieldButtonHandler ), NULL, this );
|
||||
deleteFieldButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::deleteFieldButtonHandler ), NULL, this );
|
||||
moveUpButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::moveUpButtonHandler ), NULL, this );
|
||||
m_show_datasheet_button->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::showButtonHandler ), NULL, this );
|
||||
stdDialogButtonSizerCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::OnCancelButtonClick ), NULL, this );
|
||||
stdDialogButtonSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::OnOKButtonClick ), NULL, this );
|
||||
}
|
||||
|
@ -221,6 +222,7 @@ DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::~DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BAS
|
|||
addFieldButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::addFieldButtonHandler ), NULL, this );
|
||||
deleteFieldButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::deleteFieldButtonHandler ), NULL, this );
|
||||
moveUpButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::moveUpButtonHandler ), NULL, this );
|
||||
m_show_datasheet_button->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::showButtonHandler ), NULL, this );
|
||||
stdDialogButtonSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::OnCancelButtonClick ), NULL, this );
|
||||
stdDialogButtonSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE::OnOKButtonClick ), NULL, this );
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@
|
|||
<property name="minimum_size"></property>
|
||||
<property name="name">DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size">615,456</property>
|
||||
<property name="size">-1,-1</property>
|
||||
<property name="style">wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="title">Fields Properties</property>
|
||||
|
@ -975,7 +975,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxBoxSizer" expanded="0">
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">fieldNameBoxSizer</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
|
@ -1065,7 +1065,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1154,20 +1154,9 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxBoxSizer" expanded="0">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">fieldTextBoxSizer</property>
|
||||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag"></property>
|
||||
<property name="flag">wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1250,7 +1239,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1339,6 +1328,94 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxButton" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default">0</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Show in Browser</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_show_datasheet_button</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">If your datasheet is given as an http:// link, then pressing this button should bring it up in your webbrowser.</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnButtonClick">showButtonHandler</event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Oct 8 2012)
|
||||
// C++ code generated with wxFormBuilder (version Apr 30 2013)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
|
@ -51,6 +51,7 @@ class DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE : public wxDialog
|
|||
wxTextCtrl* fieldNameTextCtrl;
|
||||
wxStaticText* fieldValueLabel;
|
||||
wxTextCtrl* fieldValueTextCtrl;
|
||||
wxButton* m_show_datasheet_button;
|
||||
wxStaticText* textSizeLabel;
|
||||
wxTextCtrl* textSizeTextCtrl;
|
||||
wxStaticText* m_staticTextUnitSize;
|
||||
|
@ -72,13 +73,14 @@ class DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE : public wxDialog
|
|||
virtual void addFieldButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void deleteFieldButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void moveUpButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void showButtonHandler( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnCancelButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnOKButtonClick( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
|
||||
DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Fields Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 615,456 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU );
|
||||
DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Fields Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU );
|
||||
~DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB_BASE();
|
||||
|
||||
};
|
||||
|
|
|
@ -144,7 +144,7 @@ void SCH_EDIT_FRAME::MoveImage( SCH_BITMAP* aImageItem, wxDC* aDC )
|
|||
|
||||
m_canvas->SetMouseCapture( moveBitmap, abortMoveBitmap );
|
||||
GetScreen()->SetCurItem( aImageItem );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
SetUndoItem( aImageItem );
|
||||
|
||||
|
|
|
@ -72,7 +72,7 @@ SCH_TEXT* SCH_EDIT_FRAME::CreateNewText( wxDC* aDC, int aType )
|
|||
{
|
||||
SCH_TEXT* textItem = NULL;
|
||||
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
switch( aType )
|
||||
{
|
||||
|
@ -235,7 +235,7 @@ void SCH_EDIT_FRAME::OnConvertTextType( wxCommandEvent& aEvent )
|
|||
}
|
||||
}
|
||||
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
OnModify();
|
||||
newtext->Draw( m_canvas, &dc, wxPoint( 0, 0 ), GR_DEFAULT_DRAWMODE );
|
||||
m_canvas->CrossHairOn( &dc ); // redraw schematic cursor
|
||||
|
|
|
@ -199,7 +199,7 @@ SCH_COMPONENT* SCH_EDIT_FRAME::Load_Component( wxDC* aDC,
|
|||
{
|
||||
int unit = 1;
|
||||
int convert = 1;
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
m_canvas->SetIgnoreMouseEvents( true );
|
||||
|
||||
wxString Name = SelectComponentFromLibrary( aLibname, aHistoryList, aUseLibBrowser,
|
||||
|
|
|
@ -268,7 +268,7 @@ void HIERARCHY_NAVIG_DLG::OnSelect( wxTreeEvent& event )
|
|||
|
||||
void SCH_EDIT_FRAME::DisplayCurrentSheet()
|
||||
{
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
ClearMsgPanel();
|
||||
|
||||
SCH_SCREEN* screen = m_CurrentSheet->LastScreen();
|
||||
|
|
|
@ -385,7 +385,7 @@ void SCH_EDIT_FRAME::OnHotKey( wxDC* aDC, int aHotKey, const wxPoint& aPosition,
|
|||
break;
|
||||
|
||||
case HK_REPEAT_LAST:
|
||||
if( notBusy && m_itemToRepeat && ( m_itemToRepeat->GetFlags() == 0 ) )
|
||||
if( notBusy )
|
||||
RepeatDrawItem( aDC );
|
||||
break;
|
||||
|
||||
|
|
|
@ -52,13 +52,13 @@ static wxArrayString s_PowerNameList;
|
|||
|
||||
void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
||||
{
|
||||
SCH_ITEM* item = GetScreen()->GetCurItem();
|
||||
wxPoint gridPosition = GetGridPosition( aPosition );
|
||||
SCH_ITEM* item = GetScreen()->GetCurItem();
|
||||
wxPoint gridPosition = GetGridPosition( aPosition );
|
||||
|
||||
if( ( GetToolId() == ID_NO_TOOL_SELECTED ) || ( item && item->GetFlags() ) )
|
||||
{
|
||||
m_canvas->SetAutoPanRequest( false );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
if( item && item->GetFlags() )
|
||||
{
|
||||
|
@ -120,7 +120,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
m_CurrentSheet->Pop();
|
||||
DisplayCurrentSheet();
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_NOCONN_BUTT:
|
||||
|
@ -128,8 +127,9 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
if( false == GetScreen()->GetItem( gridPosition, 0, SCH_NO_CONNECT_T ) )
|
||||
{
|
||||
m_itemToRepeat = AddNoConnect( aDC, gridPosition );
|
||||
GetScreen()->SetCurItem( m_itemToRepeat );
|
||||
SCH_NO_CONNECT* no_connect = AddNoConnect( aDC, gridPosition );
|
||||
SetRepeatItem( no_connect );
|
||||
GetScreen()->SetCurItem( no_connect );
|
||||
m_canvas->SetAutoPanRequest( true );
|
||||
}
|
||||
}
|
||||
|
@ -137,7 +137,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_JUNCTION_BUTT:
|
||||
|
@ -145,8 +144,9 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
if( false == GetScreen()->GetItem( gridPosition, 0, SCH_JUNCTION_T ) )
|
||||
{
|
||||
m_itemToRepeat = AddJunction( aDC, gridPosition, true );
|
||||
GetScreen()->SetCurItem( m_itemToRepeat );
|
||||
SCH_JUNCTION* junction = AddJunction( aDC, gridPosition, true );
|
||||
SetRepeatItem( junction );
|
||||
GetScreen()->SetCurItem( junction );
|
||||
m_canvas->SetAutoPanRequest( true );
|
||||
}
|
||||
}
|
||||
|
@ -154,7 +154,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_WIRETOBUS_ENTRY_BUTT:
|
||||
|
@ -168,6 +167,7 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
addCurrentItemToList( aDC );
|
||||
}
|
||||
break;
|
||||
|
||||
case ID_BUSTOBUS_ENTRY_BUTT:
|
||||
if( ( item == NULL ) || ( item->GetFlags() == 0 ) )
|
||||
{
|
||||
|
@ -209,7 +209,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_ADD_IMAGE_BUTT:
|
||||
|
@ -222,7 +221,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_LABEL_BUTT:
|
||||
|
@ -235,7 +233,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_GLABEL_BUTT:
|
||||
|
@ -254,7 +251,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_SHEET_SYMBOL_BUTT:
|
||||
|
@ -272,7 +268,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_IMPORT_HLABEL_BUTT:
|
||||
|
@ -294,7 +289,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_SCH_PLACE_COMPONENT:
|
||||
|
@ -307,7 +301,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case ID_PLACE_POWER_BUTT:
|
||||
|
@ -321,7 +314,6 @@ void SCH_EDIT_FRAME::OnLeftClick( wxDC* aDC, const wxPoint& aPosition )
|
|||
{
|
||||
addCurrentItemToList( aDC );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
|
@ -119,7 +119,7 @@ void SCH_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
{
|
||||
case ID_HIERARCHY:
|
||||
InstallHierarchyFrame( &dc, pos );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
break;
|
||||
|
||||
case wxID_CUT:
|
||||
|
@ -127,7 +127,7 @@ void SCH_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
break;
|
||||
|
||||
HandleBlockEndByPopUp( BLOCK_DELETE, &dc );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
SetSheetNumberAndCount();
|
||||
break;
|
||||
|
||||
|
@ -182,7 +182,7 @@ void SCH_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
m_canvas->MoveCursorToCrossHair();
|
||||
DeleteConnection( id == ID_POPUP_SCH_DELETE_CONNECTION );
|
||||
screen->SetCurItem( NULL );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
screen->TestDanglingEnds( m_canvas, &dc );
|
||||
m_canvas->Refresh();
|
||||
break;
|
||||
|
@ -222,7 +222,7 @@ void SCH_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
|
||||
DeleteItem( item );
|
||||
screen->SetCurItem( NULL );
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
screen->TestDanglingEnds( m_canvas, &dc );
|
||||
SetSheetNumberAndCount();
|
||||
OnModify();
|
||||
|
@ -375,7 +375,7 @@ void SCH_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
// End switch ( id ) (Command execution)
|
||||
|
||||
if( GetToolId() == ID_NO_TOOL_SELECTED )
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
}
|
||||
|
||||
|
||||
|
@ -445,7 +445,7 @@ void SCH_EDIT_FRAME::OnMoveItem( wxCommandEvent& aEvent )
|
|||
}
|
||||
|
||||
if( GetToolId() == ID_NO_TOOL_SELECTED )
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
}
|
||||
|
||||
|
||||
|
@ -561,7 +561,7 @@ void SCH_EDIT_FRAME::OnSelectTool( wxCommandEvent& aEvent )
|
|||
break;
|
||||
|
||||
default:
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
}
|
||||
|
||||
// Simulate left click event if we got here from a hot key.
|
||||
|
@ -695,7 +695,7 @@ void SCH_EDIT_FRAME::MoveItem( SCH_ITEM* aItem, wxDC* aDC )
|
|||
{
|
||||
wxCHECK_RET( aItem != NULL, wxT( "Cannot move invalid schematic item" ) );
|
||||
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
if( !aItem->IsNew() )
|
||||
{
|
||||
|
|
|
@ -177,7 +177,8 @@ SCH_EDIT_FRAME::SCH_EDIT_FRAME( wxWindow* aParent, const wxString& aTitle,
|
|||
const wxPoint& aPosition, const wxSize& aSize,
|
||||
long aStyle ) :
|
||||
SCH_BASE_FRAME( aParent, SCHEMATIC_FRAME_TYPE, aTitle, aPosition, aSize,
|
||||
aStyle, SCH_EDIT_FRAME_NAME )
|
||||
aStyle, SCH_EDIT_FRAME_NAME ),
|
||||
m_item_to_repeat( 0 )
|
||||
{
|
||||
m_FrameName = SCH_EDIT_FRAME_NAME;
|
||||
m_showAxis = false; // true to show axis
|
||||
|
@ -207,8 +208,6 @@ SCH_EDIT_FRAME::SCH_EDIT_FRAME( wxWindow* aParent, const wxString& aTitle,
|
|||
icon.CopyFromBitmap( KiBitmap( icon_eeschema_xpm ) );
|
||||
SetIcon( icon );
|
||||
|
||||
m_itemToRepeat = NULL;
|
||||
|
||||
/* Get config */
|
||||
LoadSettings();
|
||||
|
||||
|
@ -268,8 +267,10 @@ SCH_EDIT_FRAME::SCH_EDIT_FRAME( wxWindow* aParent, const wxString& aTitle,
|
|||
|
||||
SCH_EDIT_FRAME::~SCH_EDIT_FRAME()
|
||||
{
|
||||
delete m_item_to_repeat; // we own the cloned object, see this->SetRepeatItem()
|
||||
|
||||
SetScreen( NULL );
|
||||
delete m_CurrentSheet; // a SCH_SHEET_PATH, on the heap.
|
||||
delete m_CurrentSheet; // a SCH_SHEET_PATH, on the heap.
|
||||
delete m_undoItem;
|
||||
delete g_RootSheet;
|
||||
delete m_findReplaceData;
|
||||
|
@ -281,6 +282,32 @@ SCH_EDIT_FRAME::~SCH_EDIT_FRAME()
|
|||
}
|
||||
|
||||
|
||||
void SCH_EDIT_FRAME::SetRepeatItem( SCH_ITEM* aItem )
|
||||
{
|
||||
// we cannot store a pointer to an item in the display list here since
|
||||
// that item may be deleted, such as part of a line concatonation or other.
|
||||
// So simply always keep a copy of the object which is to be repeated.
|
||||
|
||||
SCH_ITEM* old = m_item_to_repeat;
|
||||
SCH_ITEM* cur = aItem;
|
||||
|
||||
if( cur != old )
|
||||
{
|
||||
if( cur )
|
||||
{
|
||||
aItem = (SCH_ITEM*) cur->Clone();
|
||||
|
||||
// Clone() preserves the flags, we want 'em cleared.
|
||||
aItem->ClearFlags();
|
||||
}
|
||||
|
||||
m_item_to_repeat = aItem;
|
||||
|
||||
delete old;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void SCH_EDIT_FRAME::SetSheetNumberAndCount()
|
||||
{
|
||||
SCH_SCREEN* screen = GetScreen();
|
||||
|
@ -869,7 +896,7 @@ bool SCH_EDIT_FRAME::isAutoSaveRequired() const
|
|||
void SCH_EDIT_FRAME::addCurrentItemToList( wxDC* aDC )
|
||||
{
|
||||
SCH_SCREEN* screen = GetScreen();
|
||||
SCH_ITEM* item = screen->GetCurItem();
|
||||
SCH_ITEM* item = screen->GetCurItem();
|
||||
|
||||
wxCHECK_RET( item != NULL, wxT( "Cannot add current item to list." ) );
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ bool SCH_EDIT_FRAME::EditSheet( SCH_SHEET* aSheet, wxDC* aDC )
|
|||
if( aSheet == NULL )
|
||||
return false;
|
||||
|
||||
/* Get the new texts */
|
||||
// Get the new texts
|
||||
DIALOG_SCH_SHEET_PROPS dlg( this );
|
||||
|
||||
wxString units = GetUnitsLabel( g_UserUnit );
|
||||
|
@ -277,11 +277,12 @@ static void MoveOrResizeSheet( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint&
|
|||
}
|
||||
|
||||
|
||||
/* Complete sheet move. */
|
||||
// Complete sheet move.
|
||||
static void ExitSheet( EDA_DRAW_PANEL* aPanel, wxDC* aDC )
|
||||
{
|
||||
SCH_SCREEN* screen = (SCH_SCREEN*) aPanel->GetScreen();
|
||||
SCH_ITEM* item = screen->GetCurItem();
|
||||
SCH_ITEM* item = screen->GetCurItem();
|
||||
|
||||
SCH_EDIT_FRAME* parent = ( SCH_EDIT_FRAME* ) aPanel->GetParent();
|
||||
|
||||
if( (item == NULL) || (item->Type() != SCH_SHEET_T) || (parent == NULL) )
|
||||
|
@ -320,10 +321,10 @@ static void ExitSheet( EDA_DRAW_PANEL* aPanel, wxDC* aDC )
|
|||
}
|
||||
|
||||
|
||||
/* Create hierarchy sheet. */
|
||||
// Create hierarchy sheet.
|
||||
SCH_SHEET* SCH_EDIT_FRAME::CreateSheet( wxDC* aDC )
|
||||
{
|
||||
m_itemToRepeat = NULL;
|
||||
SetRepeatItem( NULL );
|
||||
|
||||
SCH_SHEET* sheet = new SCH_SHEET( GetCrossHairPosition() );
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ class BOARD_DESIGN_SETTINGS
|
|||
{
|
||||
public:
|
||||
bool m_MicroViasAllowed; ///< true to allow micro vias
|
||||
int m_CurrentViaType; ///< via type (VIA_BLIND_BURIED, VIA_TROUGHT VIA_MICROVIA)
|
||||
int m_CurrentViaType; ///< via type (VIA_BLIND_BURIED, VIA_THROUGH VIA_MICROVIA)
|
||||
|
||||
/// if true, when creating a new track starting on an existing track, use this track width
|
||||
bool m_UseConnectedTrackWidth;
|
||||
|
|
|
@ -123,7 +123,7 @@ public:
|
|||
|
||||
BASE_SCREEN* GetScreen();
|
||||
|
||||
virtual EDA_DRAW_FRAME* GetParent();
|
||||
EDA_DRAW_FRAME* GetParent();
|
||||
|
||||
void OnPaint( wxPaintEvent& event );
|
||||
|
||||
|
|
|
@ -19,15 +19,17 @@ class WS_DRAW_ITEM_TEXT; // Forward declaration
|
|||
#define USE_ITALIC (1<<1) // has meaning for texts
|
||||
#define USE_ALT_COLOR (1<<2)
|
||||
#define SELECTED_STATE (1<<3) // When set, use the hight light color to draw item
|
||||
#define LOCATE_STARTPOINT (1<<4) // Used in locate function:set by locate function
|
||||
#define NEW_ITEM (1<<4) // Set for new items which can be deleted
|
||||
// by an abort command
|
||||
#define LOCATE_STARTPOINT (1<<5) // Used in locate function:set by locate function
|
||||
// if the start point is located
|
||||
#define LOCATE_ENDPOINT (1<<5) // Used in locate function:set by locate function
|
||||
#define LOCATE_ENDPOINT (1<<6) // Used in locate function:set by locate function
|
||||
// if the end point is located
|
||||
#define PAGE1OPTION (3<<6) // flag to manage items drawn or not drawn only
|
||||
#define PAGE1OPTION (3<<7) // flag to manage items drawn or not drawn only
|
||||
// on page 1: NONE = item on all pages
|
||||
#define PAGE1OPTION_NONE (0<<6) // NONE = item on all pages
|
||||
#define PAGE1OPTION_PAGE1ONLY (1<<6) // = item only on page 1
|
||||
#define PAGE1OPTION_NOTONPAGE1 (2<<6) // = item on all pages but page 1
|
||||
#define PAGE1OPTION_NONE (0<<7) // NONE = item on all pages
|
||||
#define PAGE1OPTION_PAGE1ONLY (1<<7) // = item only on page 1
|
||||
#define PAGE1OPTION_NOTONPAGE1 (2<<7) // = item on all pages but page 1
|
||||
|
||||
// A coordinate is relative to a page corner.
|
||||
// Any of the 4 corners can be a reference.
|
||||
|
@ -418,6 +420,14 @@ public:
|
|||
*/
|
||||
void SetConstrainedTextSize();
|
||||
|
||||
|
||||
/** Replace the '\''n' sequence by EOL
|
||||
* and the sequence '\''\' by only one '\'
|
||||
* inside m_FullText
|
||||
* @return true if the EOL symbol is found or is inserted (multiline text)
|
||||
*/
|
||||
bool ReplaceAntiSlashSequence();
|
||||
|
||||
/**
|
||||
* @return true is a bold font should be selected
|
||||
*/
|
||||
|
|
|
@ -31,11 +31,10 @@
|
|||
#ifndef _CONVERT_FROM_IU_
|
||||
#define _CONVERT_FROM_IU_
|
||||
|
||||
#include <config.h> // USE_PCBNEW_NANOMETRES is defined here
|
||||
#include <config.h>
|
||||
|
||||
/// Convert from internal units to user units.
|
||||
#if defined(PCBNEW) || defined(CVPCB) || defined(GERBVIEW)
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
#if defined(GERBVIEW)
|
||||
#define MM_PER_IU 1.0 / 1e5 // Gerbview uses 10 micrometer.
|
||||
#else
|
||||
|
@ -43,32 +42,19 @@
|
|||
#endif
|
||||
#define MILS_PER_IU ( MM_PER_IU * 0.0254 )
|
||||
#define DECIMILS_PER_IU (MM_PER_IU * 0.00254 )
|
||||
#else // Pcbnew in deci-mils.
|
||||
#define DECIMILS_PER_IU 1
|
||||
#define MILS_PER_IU 0.1
|
||||
#define MM_PER_IU (25.4 / 1e4)
|
||||
#endif
|
||||
|
||||
/// Convert PCBNEW internal units (iu) to mils.
|
||||
inline int Iu2Mils( int iu )
|
||||
{
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
double x = iu * MILS_PER_IU;
|
||||
return int( x < 0 ? x - 0.5 : x + 0.5 );
|
||||
#else
|
||||
return iu * MILS_PER_IU;
|
||||
#endif
|
||||
}
|
||||
|
||||
/// Convert PCBNEW internal units (iu) to deci-mils.
|
||||
inline int Iu2DMils( int iu )
|
||||
{
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
double x = iu * DECIMILS_PER_IU;
|
||||
return int( x < 0 ? x - 0.5 : x + 0.5 );
|
||||
#else
|
||||
return iu;
|
||||
#endif
|
||||
}
|
||||
|
||||
#else // Eeschema and anything else.
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#ifndef CONVERT_TO_BIU_H_
|
||||
#define CONVERT_TO_BIU_H_
|
||||
|
||||
#include <config.h> // USE_PCBNEW_NANOMETRES is defined here
|
||||
#include <config.h>
|
||||
|
||||
/**
|
||||
* @file convert_to_biu.h
|
||||
|
@ -18,41 +18,26 @@
|
|||
|
||||
/// Scaling factor to convert mils to internal units.
|
||||
#if defined(PCBNEW) || defined(CVPCB) || defined(GERBVIEW)
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
#if defined(GERBVIEW)
|
||||
#define IU_PER_MM 1e5 // Gerbview IU is 10 nanometers.
|
||||
#else
|
||||
#define IU_PER_MM 1e6 // Pcbnew IU is 1 nanometer.
|
||||
#endif
|
||||
#define IU_PER_MILS (IU_PER_MM * 0.0254)
|
||||
#define IU_PER_DECIMILS (IU_PER_MM * 0.00254)
|
||||
|
||||
#else // Pcbnew compiled for deci-mils.
|
||||
#define IU_PER_DECIMILS 1
|
||||
#define IU_PER_MILS 10.0
|
||||
#define IU_PER_MM (1e4 / 25.4)
|
||||
#if defined(GERBVIEW)
|
||||
#define IU_PER_MM 1e5 // Gerbview IU is 10 nanometers.
|
||||
#else
|
||||
#define IU_PER_MM 1e6 // Pcbnew IU is 1 nanometer.
|
||||
#endif
|
||||
#define IU_PER_MILS (IU_PER_MM * 0.0254)
|
||||
#define IU_PER_DECIMILS (IU_PER_MM * 0.00254)
|
||||
|
||||
/// Convert mils to PCBNEW internal units (iu).
|
||||
inline int Mils2iu( int mils )
|
||||
{
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
double x = mils * IU_PER_MILS;
|
||||
return int( x < 0 ? x - 0.5 : x + 0.5 );
|
||||
#else
|
||||
return mils * IU_PER_MILS;
|
||||
#endif
|
||||
}
|
||||
|
||||
/// Convert deci-mils to PCBNEW internal units (iu).
|
||||
inline int DMils2iu( int dmils )
|
||||
{
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
double x = dmils * IU_PER_DECIMILS;
|
||||
return int( x < 0 ? x - 0.5 : x + 0.5 );
|
||||
#else
|
||||
return dmils;
|
||||
#endif
|
||||
}
|
||||
|
||||
#elif defined (PL_EDITOR)
|
||||
|
|
|
@ -47,9 +47,18 @@ class wxTextCtrl;
|
|||
* <li> know too much about the caller's UI, i.e. wx. </li>
|
||||
* <li> stop after the first error </li>
|
||||
* </ul>
|
||||
* the reporter has 3 levels (flags) for filtering:
|
||||
* no filter
|
||||
* report warning
|
||||
* report errors
|
||||
* They are indicators for the calling code, filtering is not made here
|
||||
*/
|
||||
class REPORTER
|
||||
{
|
||||
bool m_reportAll; // Filter flag: set to true to report all messages
|
||||
bool m_reportWarnings; // Filter flag: set to true to report warning
|
||||
bool m_reportErrors; // Filter flag: set to true to report errors
|
||||
|
||||
public:
|
||||
/**
|
||||
* Function Report
|
||||
|
@ -68,6 +77,41 @@ public:
|
|||
REPORTER& operator <<( wxChar aChar ) { return Report( wxString( aChar ) ); }
|
||||
|
||||
REPORTER& operator <<( const char* aText ) { return Report( aText ); }
|
||||
|
||||
/**
|
||||
* Returns true if all messages should be reported
|
||||
*/
|
||||
bool ReportAll() { return m_reportAll; }
|
||||
|
||||
/**
|
||||
* Returns true if all messages or warning messages should be reported
|
||||
*/
|
||||
bool ReportWarnings() { return m_reportAll | m_reportWarnings; }
|
||||
|
||||
/**
|
||||
* Returns true if all messages or error messages should be reported
|
||||
*/
|
||||
bool ReportErrors() { return m_reportAll | m_reportErrors; }
|
||||
|
||||
/**
|
||||
* Set the report filter state, for all messages
|
||||
* @param aEnable = filter state (true/false)
|
||||
*/
|
||||
void SetReportAll( bool aEnable) { m_reportAll = aEnable; }
|
||||
|
||||
/**
|
||||
* Set the report filter state, for warning messages
|
||||
* note: report can be disable only if m_reportAll = false
|
||||
* @param aEnable = filter state (true/false)
|
||||
*/
|
||||
void SetReportWarnings( bool aEnable) { m_reportWarnings = aEnable; }
|
||||
|
||||
/**
|
||||
* Set the report filter state, for error messages
|
||||
* note: report can be disable only if m_reportAll = false
|
||||
* @param aEnable = filter state (true/false)
|
||||
*/
|
||||
void SetReportErrors( bool aEnable) { m_reportErrors = aEnable; }
|
||||
};
|
||||
|
||||
|
||||
|
@ -84,6 +128,9 @@ public:
|
|||
REPORTER(),
|
||||
m_textCtrl( aTextCtrl )
|
||||
{
|
||||
SetReportAll( true );
|
||||
SetReportWarnings( true );
|
||||
SetReportErrors( true );
|
||||
}
|
||||
|
||||
REPORTER& Report( const wxString& aText );
|
||||
|
|
|
@ -267,7 +267,7 @@ protected:
|
|||
// for basic inscriptions, in schematic
|
||||
const TITLE_BLOCK* m_titleBlock; // for basic inscriptions
|
||||
const wxString* m_paperFormat; // for basic inscriptions
|
||||
const wxString* m_fileName; // for basic inscriptions
|
||||
wxString m_fileName; // for basic inscriptions
|
||||
const wxString* m_sheetFullName; // for basic inscriptions
|
||||
|
||||
|
||||
|
@ -281,7 +281,6 @@ public:
|
|||
m_sheetCount = 1;
|
||||
m_titleBlock = NULL;
|
||||
m_paperFormat = NULL;
|
||||
m_fileName = NULL;
|
||||
m_sheetFullName = NULL;
|
||||
}
|
||||
|
||||
|
@ -297,7 +296,7 @@ public:
|
|||
*/
|
||||
void SetFileName( const wxString & aFileName )
|
||||
{
|
||||
m_fileName = &aFileName;
|
||||
m_fileName = aFileName;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -134,7 +134,7 @@ private:
|
|||
wxArrayString m_findStringHistoryList;
|
||||
wxArrayString m_replaceStringHistoryList;
|
||||
BLOCK_SELECTOR m_blockItems; ///< List of selected items.
|
||||
SCH_ITEM* m_itemToRepeat; ///< Last item to insert by the repeat command.
|
||||
SCH_ITEM* m_item_to_repeat; ///< Last item to insert by the repeat command.
|
||||
int m_repeatLabelDelta; ///< Repeat label number increment step.
|
||||
SCH_COLLECTOR m_collectedItems; ///< List of collected items.
|
||||
SCH_FIND_COLLECTOR m_foundItems; ///< List of find/replace items.
|
||||
|
@ -899,11 +899,12 @@ private:
|
|||
void EditImage( SCH_BITMAP* aItem );
|
||||
|
||||
// Hierarchical Sheet & PinSheet
|
||||
void InstallHierarchyFrame( wxDC* DC, wxPoint& pos );
|
||||
SCH_SHEET* CreateSheet( wxDC* DC );
|
||||
void ReSizeSheet( SCH_SHEET* Sheet, wxDC* DC );
|
||||
// Loads the cache library associated to the aFileName
|
||||
bool LoadCacheLibrary( const wxString& aFileName );
|
||||
void InstallHierarchyFrame( wxDC* DC, wxPoint& pos );
|
||||
SCH_SHEET* CreateSheet( wxDC* DC );
|
||||
void ReSizeSheet( SCH_SHEET* Sheet, wxDC* DC );
|
||||
|
||||
/// Loads the cache library associated to the aFileName
|
||||
bool LoadCacheLibrary( const wxString& aFileName );
|
||||
|
||||
public:
|
||||
/**
|
||||
|
@ -1176,7 +1177,18 @@ public:
|
|||
*/
|
||||
void RepeatDrawItem( wxDC* DC );
|
||||
|
||||
void SetRepeatItem( SCH_ITEM* aItem ) { m_itemToRepeat = aItem; }
|
||||
/**
|
||||
* Function SetRepeatItem
|
||||
* clones aItem and owns that clone in this container.
|
||||
*/
|
||||
void SetRepeatItem( SCH_ITEM* aItem );
|
||||
|
||||
/**
|
||||
* Function GetRepeatItem
|
||||
* returns the item which is to be repeated with the insert key. Such object
|
||||
* is owned by this container, and must be cloned.
|
||||
*/
|
||||
SCH_ITEM* GetRepeatItem() const { return m_item_to_repeat; }
|
||||
|
||||
/**
|
||||
* Function SetUndoItem
|
||||
|
|
|
@ -1466,6 +1466,8 @@ public:
|
|||
* @param aSelectByTimestamp if true, use timestamp instead of reference to identify
|
||||
* footprints from components (use after reannotation of the
|
||||
* schematic)
|
||||
* @param aDeleteSinglePadNets if true, remove nets counting only one pad
|
||||
* and set net code to 0 for these pads
|
||||
* @param aIsDryRun performs a dry run without making any changes if true.
|
||||
*/
|
||||
void ReadPcbNetlist( const wxString& aNetlistFileName,
|
||||
|
@ -1475,6 +1477,7 @@ public:
|
|||
bool aDeleteBadTracks,
|
||||
bool aDeleteExtraFootprints,
|
||||
bool aSelectByTimestamp,
|
||||
bool aDeleteSinglePadNets,
|
||||
bool aIsDryRun );
|
||||
|
||||
/**
|
||||
|
|
|
@ -2,7 +2,6 @@ add_definitions(-DKICAD)
|
|||
|
||||
include_directories(BEFORE ${INC_BEFORE})
|
||||
include_directories(
|
||||
${Boost_INCLUDE_DIR}
|
||||
${INC_AFTER}
|
||||
)
|
||||
|
||||
|
|
|
@ -1,7 +1,30 @@
|
|||
/**
|
||||
* @file class_gbr_layout.cpp
|
||||
* @file class_pl_editor_layout.cpp
|
||||
* @brief PL_EDITOR_LAYOUT class functions.
|
||||
*/
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <limits.h>
|
||||
#include <algorithm>
|
||||
|
|
|
@ -1,6 +1,29 @@
|
|||
/**
|
||||
* @file class_pl_editor_layout.h
|
||||
*/
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef CLASS_PL_EDITOR_LAYOUT_H
|
||||
#define CLASS_PL_EDITOR_LAYOUT_H
|
||||
|
|
|
@ -1,6 +1,29 @@
|
|||
/**
|
||||
* @file class_pl_editor_screen.cpp
|
||||
*/
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <common.h>
|
||||
|
|
|
@ -1,5 +1,29 @@
|
|||
/**
|
||||
* @file class_pl_editor_layout.h
|
||||
* @file class_pl_editor_screen.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef CLASS_PL_EDITOR_SCREEN_H_
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
/**
|
||||
* @file pagelayout_editor/controle.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013-2013 Jean-Pierre Charras jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013-2013 KiCad Developers, see change_log.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file pagelayout_editor/controle.cpp
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <common.h>
|
||||
#include <class_drawpanel.h>
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
/**
|
||||
* @file design_tree_frame.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file design_tree_frame.cpp
|
||||
*/
|
||||
|
||||
#include <wx/imaglist.h>
|
||||
#include <wx/wupdlock.h>
|
||||
#include <fctsys.h>
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -1,8 +1,13 @@
|
|||
/**
|
||||
* @file dialog_new_dataitem.cpp
|
||||
* @brief a dialog called on creating a new plage layout data item.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,11 +27,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file dialog_new_dataitem.cpp
|
||||
* @brief a dialog called on creating a new plage layout data item.
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <common.h>
|
||||
#include <class_drawpanel.h>
|
||||
|
|
|
@ -2,8 +2,11 @@
|
|||
* @file dialogs_for_printing.cpp
|
||||
*/
|
||||
|
||||
/* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -2,6 +2,29 @@
|
|||
* @file pagelayout_editor/events_called_functions.cpp
|
||||
* @brief page layout editor command event functions.
|
||||
*/
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <wx/treectrl.h>
|
||||
|
@ -38,7 +61,7 @@ BEGIN_EVENT_TABLE( PL_EDITOR_FRAME, EDA_DRAW_FRAME )
|
|||
EVT_MENU( wxID_SAVEAS, PL_EDITOR_FRAME::Files_io )
|
||||
EVT_MENU( wxID_FILE, PL_EDITOR_FRAME::Files_io )
|
||||
EVT_MENU( ID_LOAD_DEFAULT_PAGE_LAYOUT, PL_EDITOR_FRAME::Files_io )
|
||||
EVT_MENU( ID_OPEN_POLYGON_DESCR_FILE, PL_EDITOR_FRAME::Files_io )
|
||||
EVT_MENU( ID_APPEND_DESCR_FILE, PL_EDITOR_FRAME::Files_io )
|
||||
|
||||
EVT_MENU( ID_GEN_PLOT, PL_EDITOR_FRAME::ToPlotter )
|
||||
|
||||
|
@ -67,7 +90,7 @@ BEGIN_EVENT_TABLE( PL_EDITOR_FRAME, EDA_DRAW_FRAME )
|
|||
EVT_TOOL( wxID_PREVIEW, PL_EDITOR_FRAME::ToPrinter )
|
||||
EVT_TOOL( ID_SHEET_SET, PL_EDITOR_FRAME::Process_Special_Functions )
|
||||
EVT_TOOL( ID_SHOW_REAL_MODE, PL_EDITOR_FRAME::OnSelectTitleBlockDisplayMode )
|
||||
EVT_TOOL( ID_SHOW_LPEDITOR_MODE, PL_EDITOR_FRAME::OnSelectTitleBlockDisplayMode )
|
||||
EVT_TOOL( ID_SHOW_PL_EDITOR_MODE, PL_EDITOR_FRAME::OnSelectTitleBlockDisplayMode )
|
||||
EVT_CHOICE( ID_SELECT_COORDINATE_ORIGIN, PL_EDITOR_FRAME::OnSelectCoordOriginCorner)
|
||||
EVT_CHOICE( ID_SELECT_PAGE_NUMBER, PL_EDITOR_FRAME::Process_Special_Functions)
|
||||
|
||||
|
@ -78,7 +101,7 @@ BEGIN_EVENT_TABLE( PL_EDITOR_FRAME, EDA_DRAW_FRAME )
|
|||
PL_EDITOR_FRAME::Process_Special_Functions )
|
||||
|
||||
EVT_UPDATE_UI( ID_SHOW_REAL_MODE, PL_EDITOR_FRAME::OnUpdateTitleBlockDisplayNormalMode )
|
||||
EVT_UPDATE_UI( ID_SHOW_LPEDITOR_MODE, PL_EDITOR_FRAME::OnUpdateTitleBlockDisplaySpecialMode )
|
||||
EVT_UPDATE_UI( ID_SHOW_PL_EDITOR_MODE, PL_EDITOR_FRAME::OnUpdateTitleBlockDisplaySpecialMode )
|
||||
|
||||
END_EVENT_TABLE()
|
||||
|
||||
|
@ -157,7 +180,22 @@ void PL_EDITOR_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
RebuildDesignTree();
|
||||
item = NULL;
|
||||
}
|
||||
m_canvas->Refresh();
|
||||
else
|
||||
{
|
||||
// Put the new item in move mode, after putting the cursor
|
||||
// on the start point:
|
||||
wxPoint position = item->GetStartPosUi();
|
||||
SetCrossHairPosition( position, false );
|
||||
position = GetCrossHairPosition();
|
||||
|
||||
if( m_canvas->IsPointOnDisplay( position ) )
|
||||
m_canvas->MoveCursorToCrossHair();
|
||||
else
|
||||
RedrawScreen( position, true );
|
||||
|
||||
item->SetFlags( NEW_ITEM );
|
||||
MoveItem( item );
|
||||
}
|
||||
break;
|
||||
|
||||
case ID_POPUP_ITEM_ADD_RECT:
|
||||
|
@ -171,7 +209,22 @@ void PL_EDITOR_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
RebuildDesignTree();
|
||||
item = NULL;
|
||||
}
|
||||
m_canvas->Refresh();
|
||||
else
|
||||
{
|
||||
// Put the new item in move mode, after putting the cursor
|
||||
// on the start point:
|
||||
wxPoint position = item->GetStartPosUi();
|
||||
SetCrossHairPosition( position, false );
|
||||
position = GetCrossHairPosition();
|
||||
|
||||
if( m_canvas->IsPointOnDisplay( position ) )
|
||||
m_canvas->MoveCursorToCrossHair();
|
||||
else
|
||||
RedrawScreen( position, true );
|
||||
|
||||
item->SetFlags( NEW_ITEM );
|
||||
MoveItem( item );
|
||||
}
|
||||
break;
|
||||
|
||||
case ID_POPUP_ITEM_ADD_TEXT:
|
||||
|
@ -185,11 +238,16 @@ void PL_EDITOR_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
RebuildDesignTree();
|
||||
item = NULL;
|
||||
}
|
||||
m_canvas->Refresh();
|
||||
else
|
||||
{
|
||||
// Put the new text in move mode:
|
||||
item->SetFlags( NEW_ITEM | LOCATE_STARTPOINT );
|
||||
MoveItem( item );
|
||||
}
|
||||
break;
|
||||
|
||||
case ID_POPUP_ITEM_ADD_POLY:
|
||||
cmd.SetId( ID_OPEN_POLYGON_DESCR_FILE );
|
||||
case ID_POPUP_ITEM_APPEND_PAGE_LAYOUT:
|
||||
cmd.SetId( ID_APPEND_DESCR_FILE );
|
||||
wxPostEvent( this, cmd );
|
||||
break;
|
||||
|
||||
|
@ -240,6 +298,11 @@ void PL_EDITOR_FRAME::Process_Special_Functions( wxCommandEvent& event )
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
* Function moveItem: called when the mouse cursor is moving
|
||||
* moves the item currently selected (or the start point or the end point)
|
||||
* to the cursor position
|
||||
*/
|
||||
DPOINT initialPosition; // The initial position of the item to move, in mm
|
||||
wxPoint initialPositionUi; // The initial position of the item to move, in Ui
|
||||
wxPoint initialCursorPosition; // The initial position of the cursor
|
||||
|
@ -265,27 +328,43 @@ static void moveItem( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aPositio
|
|||
aPanel->Refresh();
|
||||
}
|
||||
|
||||
/*
|
||||
* Function abortMoveItem: called when an item is currently moving,
|
||||
* and when the user aborts the move command.
|
||||
* Restores the initial position of the item
|
||||
*/
|
||||
static void abortMoveItem( EDA_DRAW_PANEL* aPanel, wxDC* aDC )
|
||||
{
|
||||
PL_EDITOR_SCREEN* screen = (PL_EDITOR_SCREEN*) aPanel->GetScreen();
|
||||
WORKSHEET_DATAITEM *item = screen->GetCurItem();
|
||||
if( (item->GetFlags() & LOCATE_STARTPOINT) )
|
||||
|
||||
if( (item->GetFlags() & NEW_ITEM ) )
|
||||
{
|
||||
item->MoveStartPointTo( initialPosition );
|
||||
}
|
||||
else if( (item->GetFlags() & LOCATE_ENDPOINT) )
|
||||
{
|
||||
item->MoveEndPointTo( initialPosition );
|
||||
PL_EDITOR_FRAME* plframe = (PL_EDITOR_FRAME*) aPanel->GetParent();
|
||||
plframe->RemoveLastCommandInUndoList();
|
||||
WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance();
|
||||
pglayout.Remove( item );
|
||||
plframe->RebuildDesignTree();
|
||||
}
|
||||
else
|
||||
item->MoveTo( initialPosition );
|
||||
{
|
||||
if( (item->GetFlags() & LOCATE_STARTPOINT) )
|
||||
{
|
||||
item->MoveStartPointTo( initialPosition );
|
||||
}
|
||||
else if( (item->GetFlags() & LOCATE_ENDPOINT) )
|
||||
{
|
||||
item->MoveEndPointTo( initialPosition );
|
||||
}
|
||||
else
|
||||
item->MoveTo( initialPosition );
|
||||
}
|
||||
|
||||
aPanel->SetMouseCapture( NULL, NULL );
|
||||
screen->SetCurItem( NULL );
|
||||
aPanel->Refresh();
|
||||
}
|
||||
|
||||
|
||||
void PL_EDITOR_FRAME::MoveItem( WORKSHEET_DATAITEM* aItem )
|
||||
{
|
||||
wxCHECK_RET( aItem != NULL, wxT( "Cannot move NULL item" ) );
|
||||
|
@ -328,6 +407,8 @@ void PL_EDITOR_FRAME::PlaceItem( WORKSHEET_DATAITEM* aItem )
|
|||
DPOINT currStartPos = aItem->GetStartPos();
|
||||
DPOINT currEndPos = aItem->GetEndPos();
|
||||
|
||||
aItem->ClearFlags( NEW_ITEM );
|
||||
|
||||
// Save the curren layout before changes
|
||||
if( (aItem->GetFlags() & LOCATE_STARTPOINT) )
|
||||
{
|
||||
|
@ -363,7 +444,7 @@ void PL_EDITOR_FRAME::OnSelectCoordOriginCorner( wxCommandEvent& event )
|
|||
|
||||
void PL_EDITOR_FRAME::OnSelectTitleBlockDisplayMode( wxCommandEvent& event )
|
||||
{
|
||||
WORKSHEET_DATAITEM::m_SpecialMode = (event.GetId() == ID_SHOW_LPEDITOR_MODE);
|
||||
WORKSHEET_DATAITEM::m_SpecialMode = (event.GetId() == ID_SHOW_PL_EDITOR_MODE);
|
||||
m_canvas->Refresh();
|
||||
}
|
||||
|
||||
|
@ -446,20 +527,13 @@ void PL_EDITOR_FRAME::OnTreeMiddleClick( wxTreeEvent& event )
|
|||
{
|
||||
}
|
||||
|
||||
extern void AddNewItemsCommand( wxMenu* aMainMenu );
|
||||
void PL_EDITOR_FRAME::OnTreeRightClick( wxTreeEvent& event )
|
||||
{
|
||||
m_treePagelayout->SelectCell( event.GetItem() );
|
||||
|
||||
wxMenu popMenu;
|
||||
|
||||
AddMenuItem( &popMenu, ID_POPUP_ITEM_ADD_LINE, _( "Add line" ),
|
||||
KiBitmap( add_dashed_line_xpm ) );
|
||||
AddMenuItem( &popMenu, ID_POPUP_ITEM_ADD_RECT, _( "Add rect" ),
|
||||
KiBitmap( add_rectangle_xpm ) );
|
||||
AddMenuItem( &popMenu, ID_POPUP_ITEM_ADD_TEXT, _( "Add text" ),
|
||||
KiBitmap( add_text_xpm ) );
|
||||
AddMenuItem( &popMenu, ID_POPUP_ITEM_ADD_POLY, _( "Import poly descr file" ),
|
||||
KiBitmap( add_polygon_xpm ) );
|
||||
AddNewItemsCommand( &popMenu );
|
||||
|
||||
popMenu.AppendSeparator();
|
||||
AddMenuItem( &popMenu, ID_POPUP_DESIGN_TREE_ITEM_DELETE, _( "Delete" ),
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
/**
|
||||
* @file gerbview/files.cpp
|
||||
* @file pl_editor/files.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2012 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
|
||||
* Copyright (C) 2004-2012 KiCad Developers, see change_log.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -112,9 +112,9 @@ void PL_EDITOR_FRAME::Files_io( wxCommandEvent& event )
|
|||
OnNewPageLayout();
|
||||
break;
|
||||
|
||||
case ID_OPEN_POLYGON_DESCR_FILE:
|
||||
case ID_APPEND_DESCR_FILE:
|
||||
{
|
||||
wxFileDialog openFileDialog(this, _("Open polygon descr file"),
|
||||
wxFileDialog openFileDialog(this, _("Append Page Layout Descr File"),
|
||||
wxEmptyString,
|
||||
wxEmptyString, PageLayoutDescrFileWildcard, wxFD_OPEN);
|
||||
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
/**
|
||||
* @file gerbview/hotkeys.cpp
|
||||
* @file pagelayout_editor/hotkeys.cpp
|
||||
*/
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -2,6 +2,30 @@
|
|||
* @file pagelayout_editor/hotkeys.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef PL_EDITOR_KOTKEYS_H_
|
||||
#define PL_EDITOR_KOTKEYS_H_
|
||||
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
/**
|
||||
* @file invoke_pl_editor.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
|
||||
* Copyright (C) 2013 KiCad Developers, see change_log.txt for contributors.
|
||||
*
|
||||
|
|
|
@ -1,8 +1,13 @@
|
|||
/**
|
||||
* @file pagelayout_editor/menubar.cpp
|
||||
* @brief (Re)Create the main menubar for Pl_Editor
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +27,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file pl_editor/menubar.cpp
|
||||
* @brief (Re)Create the main menubar for Pl_Editor
|
||||
*/
|
||||
#include <fctsys.h>
|
||||
|
||||
#include <appl_wxstruct.h>
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 CERN
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 CERN
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -40,6 +39,19 @@
|
|||
#include <class_worksheet_dataitem.h>
|
||||
#include <hotkeys.h>
|
||||
|
||||
// Helper function to add menuitems relative to items creation
|
||||
void AddNewItemsCommand( wxMenu* aMainMenu )
|
||||
{
|
||||
AddMenuItem( aMainMenu, ID_POPUP_ITEM_ADD_LINE, _( "Add Line" ),
|
||||
KiBitmap( add_dashed_line_xpm ) );
|
||||
AddMenuItem( aMainMenu, ID_POPUP_ITEM_ADD_RECT, _( "Add Rectangle" ),
|
||||
KiBitmap( add_rectangle_xpm ) );
|
||||
AddMenuItem( aMainMenu, ID_POPUP_ITEM_ADD_TEXT, _( "Add Text" ),
|
||||
KiBitmap( add_text_xpm ) );
|
||||
AddMenuItem( aMainMenu, ID_POPUP_ITEM_APPEND_PAGE_LAYOUT,
|
||||
_( "Append Page Layout Descr File" ),
|
||||
KiBitmap( import_xpm ) );
|
||||
}
|
||||
|
||||
/* Prepare the right-click pullup menu.
|
||||
* The menu already has a list of zoom commands.
|
||||
|
@ -102,15 +114,7 @@ bool PL_EDITOR_FRAME::OnRightClick( const wxPoint& aPosition, wxMenu* aPopMenu )
|
|||
|
||||
if( ! busy )
|
||||
{
|
||||
AddMenuItem( aPopMenu, ID_POPUP_ITEM_ADD_LINE, _( "Add line" ),
|
||||
KiBitmap( add_dashed_line_xpm ) );
|
||||
AddMenuItem( aPopMenu, ID_POPUP_ITEM_ADD_RECT, _( "Add rect" ),
|
||||
KiBitmap( add_rectangle_xpm ) );
|
||||
AddMenuItem( aPopMenu, ID_POPUP_ITEM_ADD_TEXT, _( "Add text" ),
|
||||
KiBitmap( add_text_xpm ) );
|
||||
AddMenuItem( aPopMenu, ID_POPUP_ITEM_ADD_POLY, _( "Import poly descr file" ),
|
||||
KiBitmap( add_polygon_xpm ) );
|
||||
|
||||
AddNewItemsCommand( aPopMenu );
|
||||
aPopMenu->AppendSeparator();
|
||||
}
|
||||
|
||||
|
|
|
@ -7,9 +7,8 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 1992-2013 Jean-Pierre Charras <jp.charras at wanadoo.fr>.
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see change_log.txt for contributors.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -99,7 +98,7 @@ public:
|
|||
}
|
||||
catch( IO_ERROR ioe )
|
||||
{
|
||||
wxMessageBox( ioe.errorText, _("Write Page Layout Error" ) );
|
||||
wxMessageBox( ioe.errorText, _("Error writing page layout descr file" ) );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -126,7 +125,7 @@ public:
|
|||
}
|
||||
catch( IO_ERROR ioe )
|
||||
{
|
||||
wxMessageBox( ioe.errorText, _("Write Page Layout Error" ) );
|
||||
wxMessageBox( ioe.errorText, _("Error writing page layout descr file" ) );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see change_log.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -103,7 +103,6 @@ bool EDA_APP::OnInit()
|
|||
|
||||
if( fn.IsOk() )
|
||||
{
|
||||
wxSetWorkingDirectory( fn.GetPath() );
|
||||
bool success = frame->LoadPageLayoutDescrFile( fn.GetFullPath() );
|
||||
if( !success )
|
||||
{
|
||||
|
@ -113,7 +112,10 @@ bool EDA_APP::OnInit()
|
|||
wxMessageBox( msg );
|
||||
}
|
||||
else
|
||||
{
|
||||
descrLoaded = true;
|
||||
frame->OnNewPageLayout();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Binary file not shown.
|
@ -1,8 +1,13 @@
|
|||
/**
|
||||
* @file pl_editor_config.cpp
|
||||
* @brief page layout editor configuration.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,11 +27,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file pl_editor_config.cpp
|
||||
* @brief page layout editor configuration.
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <common.h>
|
||||
#include <class_drawpanel.h>
|
||||
|
|
Binary file not shown.
|
@ -1,8 +1,12 @@
|
|||
/**
|
||||
* @file pl_editor_frame.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file pl_editor_frame.cpp
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <appl_wxstruct.h>
|
||||
#include <class_drawpanel.h>
|
||||
|
@ -66,8 +66,8 @@ PL_EDITOR_FRAME::PL_EDITOR_FRAME( wxWindow* aParent, const wxString& aTitle,
|
|||
m_HotkeysZoomAndGridList = s_PlEditor_Hokeys_Descr;
|
||||
m_originSelectChoice = 0;
|
||||
|
||||
m_designTreeWidth = 100;
|
||||
m_propertiesFrameWidth = 150;
|
||||
m_designTreeWidth = 150;
|
||||
m_propertiesFrameWidth = 200;
|
||||
|
||||
if( m_canvas )
|
||||
m_canvas->SetEnableBlockCommands( false );
|
||||
|
@ -178,7 +178,6 @@ PL_EDITOR_FRAME::PL_EDITOR_FRAME( wxWindow* aParent, const wxString& aTitle,
|
|||
|
||||
PL_EDITOR_FRAME::~PL_EDITOR_FRAME()
|
||||
{
|
||||
wxGetApp().SaveCurrentSetupValues( m_configSettings );
|
||||
}
|
||||
|
||||
|
||||
|
@ -230,8 +229,14 @@ void PL_EDITOR_FRAME::OnCloseWindow( wxCloseEvent& Event )
|
|||
}
|
||||
|
||||
SaveSettings();
|
||||
wxGetApp().SaveCurrentSetupValues( m_configSettings );
|
||||
|
||||
// do not show the window because we do not want any paint event
|
||||
Show( false );
|
||||
|
||||
// On Linux, m_propertiesPagelayout must be destroyed
|
||||
// before deleting the main frame to avoid a crash when closing
|
||||
m_propertiesPagelayout->Destroy();
|
||||
Destroy();
|
||||
}
|
||||
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
/**
|
||||
* @file pl_editor_frame.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2013 CERN
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -23,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file pl_editor_frame.h
|
||||
*/
|
||||
|
||||
#ifndef _PL_EDITOR_FRAME_H
|
||||
#define _PL_EDITOR_FRAME_H
|
||||
|
||||
|
|
|
@ -1,3 +1,31 @@
|
|||
/**
|
||||
* @file pl_editor_id.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* 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, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#ifndef _PL_EDITOR_ID_H_
|
||||
#define _PL_EDITOR_ID_H_
|
||||
|
||||
|
@ -22,12 +50,12 @@ enum pl_editor_ids
|
|||
ID_DESIGN_TREE_FRAME,
|
||||
|
||||
ID_SHOW_REAL_MODE,
|
||||
ID_SHOW_LPEDITOR_MODE,
|
||||
ID_SHOW_PL_EDITOR_MODE,
|
||||
ID_SELECT_COORDINATE_ORIGIN,
|
||||
ID_LOAD_DEFAULT_PAGE_LAYOUT,
|
||||
ID_SELECT_PAGE_NUMBER,
|
||||
|
||||
ID_OPEN_POLYGON_DESCR_FILE,
|
||||
ID_APPEND_DESCR_FILE,
|
||||
|
||||
ID_POPUP_START_RANGE,
|
||||
ID_POPUP_ITEM_DELETE,
|
||||
|
@ -35,7 +63,7 @@ enum pl_editor_ids
|
|||
ID_POPUP_ITEM_ADD_LINE,
|
||||
ID_POPUP_ITEM_ADD_RECT,
|
||||
ID_POPUP_ITEM_ADD_TEXT,
|
||||
ID_POPUP_ITEM_ADD_POLY,
|
||||
ID_POPUP_ITEM_APPEND_PAGE_LAYOUT,
|
||||
ID_POPUP_ITEM_MOVE,
|
||||
ID_POPUP_ITEM_PLACE,
|
||||
ID_POPUP_ITEM_MOVE_START_POINT,
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
/**
|
||||
* @file pl_editor_undo_redo.cpp
|
||||
* @brief page layout editor: undo and redo functions
|
||||
* @brief page layout editor: undo and redo functions
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
/**
|
||||
* @file properties_frame.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file properties_frame.cpp
|
||||
*/
|
||||
|
||||
#include <fctsys.h>
|
||||
#include <wxstruct.h>
|
||||
#include <class_drawpanel.h>
|
||||
|
@ -194,9 +194,10 @@ void PROPERTIES_FRAME::CopyPrmsFromItemToPanel( WORKSHEET_DATAITEM* aItem )
|
|||
m_SizerTextIncrementLabel->Show( true );
|
||||
|
||||
WORKSHEET_DATAITEM_TEXT* item = (WORKSHEET_DATAITEM_TEXT*) aItem;
|
||||
wxString text = item->m_TextBase;
|
||||
text.Replace(wxT("\\n"), wxT("\n") );
|
||||
m_textCtrlText->SetValue( text );
|
||||
item->m_FullText = item->m_TextBase;
|
||||
// Replace our '\' 'n' sequence by the EOL char
|
||||
item->ReplaceAntiSlashSequence();;
|
||||
m_textCtrlText->SetValue( item->m_FullText );
|
||||
|
||||
msg.Printf( wxT("%d"), item->m_IncrementLabel );
|
||||
m_textCtrlTextIncrement->SetValue( msg );
|
||||
|
@ -285,7 +286,12 @@ void PROPERTIES_FRAME::OnAcceptPrms( wxCommandEvent& event )
|
|||
|
||||
WORKSHEET_DATAITEM* item = m_parent->GetSelectedItem();
|
||||
if( item )
|
||||
{
|
||||
CopyPrmsFromPanelToItem( item );
|
||||
// Be sure what is displayed is waht is set for item
|
||||
// (mainly, texts can be modified if they contain "\n")
|
||||
CopyPrmsFromItemToPanel( item );
|
||||
}
|
||||
|
||||
CopyPrmsFromPanelToGeneral();
|
||||
|
||||
|
@ -392,7 +398,6 @@ bool PROPERTIES_FRAME::CopyPrmsFromPanelToItem( WORKSHEET_DATAITEM* aItem )
|
|||
WORKSHEET_DATAITEM_TEXT* item = (WORKSHEET_DATAITEM_TEXT*) aItem;
|
||||
|
||||
item->m_TextBase = m_textCtrlText->GetValue();
|
||||
item->m_TextBase.Replace( wxT("\n"), wxT("\\n") );
|
||||
|
||||
msg = m_textCtrlTextIncrement->GetValue();
|
||||
msg.ToLong( &itmp );
|
||||
|
|
|
@ -1,8 +1,12 @@
|
|||
/**
|
||||
* @file properties_frame.h
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -22,10 +26,6 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
/**
|
||||
* @file properties_frame.h
|
||||
*/
|
||||
|
||||
#ifndef _PROPERTIES_FRAME_H
|
||||
#define _PROPERTIES_FRAME_H
|
||||
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
|
||||
/**
|
||||
* @file toolbars_gerber.cpp
|
||||
* @file toolbars_pl_editor.cpp
|
||||
* @brief Build tool bars
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2013 CERN
|
||||
* @author Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -90,12 +90,14 @@ void PL_EDITOR_FRAME::ReCreateHToolbar( void )
|
|||
|
||||
// Display mode switch
|
||||
m_mainToolBar->AddSeparator();
|
||||
m_mainToolBar->AddTool( ID_SHOW_REAL_MODE, wxEmptyString, KiBitmap( pagelayout_normal_view_mode_xpm ),
|
||||
m_mainToolBar->AddTool( ID_SHOW_REAL_MODE, wxEmptyString,
|
||||
KiBitmap( pagelayout_normal_view_mode_xpm ),
|
||||
_( "Show title block like it will be displayed in applications\n"
|
||||
"texts with format are replaced by the full text"),
|
||||
wxITEM_CHECK );
|
||||
m_mainToolBar->AddTool( ID_SHOW_LPEDITOR_MODE, wxEmptyString, KiBitmap( pagelayout_special_view_mode_xpm ),
|
||||
_( "how title block in edit mode: texts are shown as is\n"
|
||||
m_mainToolBar->AddTool( ID_SHOW_PL_EDITOR_MODE,
|
||||
wxEmptyString, KiBitmap( pagelayout_special_view_mode_xpm ),
|
||||
_( "Show title block in edit mode: texts are shown as is:\n"
|
||||
"texts with format are displayed with no change"),
|
||||
wxITEM_CHECK );
|
||||
|
||||
|
|
|
@ -25,8 +25,6 @@
|
|||
#include <transline.h>
|
||||
#include <units.h>
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
||||
#ifndef INFINITY
|
||||
#define INFINITY std::numeric_limits<double>::infinity()
|
||||
|
@ -37,13 +35,6 @@ using namespace std;
|
|||
#define M_PI_2 (M_PI/2)
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_CMATH_ISINF
|
||||
inline bool isinf(double x)
|
||||
{
|
||||
return x == INFINITY; // return true if x is infinity
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
// Functions to Read/Write parameters in pcb_calculator main frame:
|
||||
// They are wrapper to actual functions, so all transline functions do not
|
||||
|
@ -148,7 +139,7 @@ void TRANSLINE::ellipke( double arg, double& k, double& e )
|
|||
k = INFINITY; // infinite
|
||||
e = 0;
|
||||
}
|
||||
else if( isinf( arg ) && arg < 0 )
|
||||
else if( std::isinf( arg ) && arg < 0 )
|
||||
{
|
||||
k = 0;
|
||||
e = INFINITY; // infinite
|
||||
|
|
|
@ -58,15 +58,6 @@ inline double atanh( double x )
|
|||
}
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.1415926535897932384626433832795029 /* pi */
|
||||
#endif
|
||||
|
||||
#ifndef M_E
|
||||
#define M_E 2.7182818284590452353602874713526625 /* e */
|
||||
#endif
|
||||
|
||||
#define MU0 12.566370614e-7 // magnetic constant
|
||||
#define C0 299792458.0 // speed of light in vacuum
|
||||
#define ZF0 376.73031346958504364963 // wave resistance in vacuum
|
||||
|
|
|
@ -1,33 +1,35 @@
|
|||
add_definitions(-DPCBNEW)
|
||||
add_definitions( -DPCBNEW )
|
||||
|
||||
if (KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/scripting)
|
||||
find_package(SWIG REQUIRED)
|
||||
include(${SWIG_USE_FILE})
|
||||
endif(KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
if( KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES )
|
||||
file( MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/scripting )
|
||||
find_package( SWIG REQUIRED )
|
||||
include( ${SWIG_USE_FILE} )
|
||||
|
||||
# Infrequently needed headers go at end of search paths, append to INC_AFTER
|
||||
set( INC_AFTER ${INC_AFTER} ${CMAKE_CURRENT_SOURCE_DIR}/scripting )
|
||||
|
||||
#message( STATUS "pcbnew INC_AFTER:${INC_AFTER}" )
|
||||
endif()
|
||||
|
||||
|
||||
###
|
||||
# Includes
|
||||
###
|
||||
include_directories(BEFORE ${INC_BEFORE})
|
||||
include_directories( BEFORE ${INC_BEFORE} )
|
||||
include_directories(
|
||||
./dialogs
|
||||
./autorouter
|
||||
../3d-viewer
|
||||
../common
|
||||
${Boost_INCLUDE_DIR}
|
||||
../polygon
|
||||
../common/dialogs
|
||||
./scripting
|
||||
${INC_AFTER}
|
||||
)
|
||||
|
||||
|
||||
###
|
||||
# Sources
|
||||
#
|
||||
set(PCBNEW_DIALOGS
|
||||
set( PCBNEW_DIALOGS
|
||||
dialogs/dialog_block_options_base.cpp
|
||||
dialogs/dialog_cleaning_options_base.cpp
|
||||
dialogs/dialog_cleaning_options.cpp
|
||||
|
@ -105,7 +107,7 @@ set(PCBNEW_DIALOGS
|
|||
dialogs/dialog_footprint_wizard_list.cpp
|
||||
)
|
||||
|
||||
set(PCBNEW_AUTOROUTER_SRCS
|
||||
set( PCBNEW_AUTOROUTER_SRCS
|
||||
autorouter/automove.cpp
|
||||
autorouter/autoplac.cpp
|
||||
autorouter/autorout.cpp
|
||||
|
@ -117,7 +119,7 @@ set(PCBNEW_AUTOROUTER_SRCS
|
|||
autorouter/work.cpp
|
||||
)
|
||||
|
||||
set(PCBNEW_CLASS_SRCS
|
||||
set( PCBNEW_CLASS_SRCS
|
||||
tool_modview.cpp
|
||||
modview.cpp
|
||||
modview_frame.cpp
|
||||
|
@ -218,12 +220,12 @@ set(PCBNEW_CLASS_SRCS
|
|||
class_footprint_wizard.cpp
|
||||
)
|
||||
|
||||
set(PCBNEW_SRCS ${PCBNEW_AUTOROUTER_SRCS} ${PCBNEW_CLASS_SRCS} ${PCBNEW_DIALOGS})
|
||||
set( PCBNEW_SRCS ${PCBNEW_AUTOROUTER_SRCS} ${PCBNEW_CLASS_SRCS} ${PCBNEW_DIALOGS} )
|
||||
|
||||
###
|
||||
# We need some extra sources from common
|
||||
###
|
||||
set(PCBNEW_COMMON_SRCS
|
||||
set( PCBNEW_COMMON_SRCS
|
||||
../common/dialogs/dialog_page_settings.cpp
|
||||
../common/base_units.cpp
|
||||
)
|
||||
|
@ -231,36 +233,42 @@ set(PCBNEW_COMMON_SRCS
|
|||
##
|
||||
# Scripting sources
|
||||
##
|
||||
set(PCBNEW_SCRIPTING_DIALOGS
|
||||
set( PCBNEW_SCRIPTING_DIALOGS
|
||||
dialogs/dialog_scripting_base.cpp
|
||||
dialogs/dialog_scripting.cpp
|
||||
)
|
||||
|
||||
|
||||
set(PCBNEW_SCRIPTING_PYTHON_HELPERS
|
||||
set( PCBNEW_SCRIPTING_PYTHON_HELPERS
|
||||
../scripting/wx_python_helpers.cpp
|
||||
../scripting/python_scripting.cpp
|
||||
scripting/pcbnew_scripting_helpers.cpp
|
||||
scripting/pcbnew_footprint_wizards.cpp
|
||||
)
|
||||
|
||||
if (KICAD_SCRIPTING)
|
||||
set(PCBNEW_SCRIPTING_SRCS
|
||||
if( KICAD_SCRIPTING )
|
||||
set( PCBNEW_SCRIPTING_SRCS
|
||||
${PCBNEW_SCRIPTING_DIALOGS}
|
||||
pcbnew_wrap.cxx
|
||||
${PCBNEW_SCRIPTING_PYTHON_HELPERS}
|
||||
)
|
||||
endif(KICAD_SCRIPTING)
|
||||
endif()
|
||||
|
||||
##
|
||||
# Scripting build
|
||||
##
|
||||
|
||||
if (KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
if( KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES )
|
||||
|
||||
set(SWIG_FLAGS -I${CMAKE_CURRENT_SOURCE_DIR}/../.. -I${CMAKE_CURRENT_SOURCE_DIR} -I${CMAKE_CURRENT_SOURCE_DIR}/../include -I${CMAKE_CURRENT_SOURCE_DIR}/../scripting )
|
||||
if (DEBUG)
|
||||
set(SWIG_FLAGS ${SWIG_FLAGS} -DDEBUG)
|
||||
set( SWIG_FLAGS
|
||||
-I${CMAKE_CURRENT_SOURCE_DIR}/../..
|
||||
-I${CMAKE_CURRENT_SOURCE_DIR}
|
||||
-I${CMAKE_CURRENT_SOURCE_DIR}/../include
|
||||
-I${CMAKE_CURRENT_SOURCE_DIR}/../scripting
|
||||
)
|
||||
|
||||
if( DEBUG )
|
||||
set( SWIG_FLAGS ${SWIG_FLAGS} -DDEBUG )
|
||||
endif()
|
||||
|
||||
# collect CFLAGS , and pass them to swig later
|
||||
|
@ -270,14 +278,10 @@ if (KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
|||
set( SWIG_FLAGS ${SWIG_FLAGS} -D${d} )
|
||||
endforeach()
|
||||
|
||||
if( USE_PCBNEW_NANOMETRES )
|
||||
set( SWIG_FLAGS ${SWIG_FLAGS} -DUSE_PCBNEW_NANOMETRES )
|
||||
endif( USE_PCBNEW_NANOMETRES )
|
||||
|
||||
endif(KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES)
|
||||
endif()
|
||||
|
||||
|
||||
if (KICAD_SCRIPTING)
|
||||
if( KICAD_SCRIPTING )
|
||||
|
||||
set( SWIG_OPTS -python -c++ -outdir ${CMAKE_CURRENT_BINARY_DIR} ${SWIG_FLAGS} )
|
||||
|
||||
|
@ -299,25 +303,25 @@ if (KICAD_SCRIPTING)
|
|||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
)
|
||||
|
||||
endif(KICAD_SCRIPTING)
|
||||
endif()
|
||||
|
||||
###
|
||||
# _pcbnew DLL/DSO file creation
|
||||
###
|
||||
|
||||
if ((KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES) AND NOT WIN32 AND NOT APPLE)
|
||||
if( ( KICAD_SCRIPTING OR KICAD_SCRIPTING_MODULES ) AND NOT WIN32 AND NOT APPLE )
|
||||
set ( PCBNEW_EXTRA_LIBS "rt" )
|
||||
endif()
|
||||
|
||||
|
||||
if (KICAD_SCRIPTING_MODULES)
|
||||
if( KICAD_SCRIPTING_MODULES )
|
||||
|
||||
#message( "building pcbnew scripting" )
|
||||
|
||||
set(CMAKE_SWIG_FLAGS ${SWIG_FLAGS})
|
||||
set_source_files_properties(scripting/pcbnew.i PROPERTIES CPLUSPLUS ON)
|
||||
swig_add_module(pcbnew python scripting/pcbnew.i ${PCBNEW_SCRIPTING_PYTHON_HELPERS} ${PCBNEW_SRCS} ${PCBNEW_COMMON_SRCS})
|
||||
swig_link_libraries(pcbnew
|
||||
set( CMAKE_SWIG_FLAGS ${SWIG_FLAGS} )
|
||||
set_source_files_properties( scripting/pcbnew.i PROPERTIES CPLUSPLUS ON )
|
||||
swig_add_module( pcbnew python scripting/pcbnew.i ${PCBNEW_SCRIPTING_PYTHON_HELPERS} ${PCBNEW_SRCS} ${PCBNEW_COMMON_SRCS} )
|
||||
swig_link_libraries( pcbnew
|
||||
3d-viewer
|
||||
pcbcommon
|
||||
common
|
||||
|
@ -334,33 +338,33 @@ if (KICAD_SCRIPTING_MODULES)
|
|||
${PCBNEW_EXTRA_LIBS}
|
||||
)
|
||||
|
||||
endif (KICAD_SCRIPTING_MODULES)
|
||||
endif()
|
||||
|
||||
###
|
||||
# Windows resource file
|
||||
###
|
||||
if(WIN32)
|
||||
if(MINGW)
|
||||
if( WIN32 )
|
||||
if( MINGW )
|
||||
# PCBNEW_RESOURCES variable is set by the macro.
|
||||
mingw_resource_compiler(pcbnew)
|
||||
else(MINGW)
|
||||
set(PCBNEW_RESOURCES pcbnew.rc)
|
||||
endif(MINGW)
|
||||
endif(WIN32)
|
||||
mingw_resource_compiler( pcbnew )
|
||||
else()
|
||||
set( PCBNEW_RESOURCES pcbnew.rc )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
###
|
||||
# Set properties for APPLE on pcbnew target
|
||||
###
|
||||
if(APPLE)
|
||||
set(PCBNEW_RESOURCES pcbnew.icns pcbnew_doc.icns)
|
||||
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/pcbnew.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
||||
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/pcbnew_doc.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources)
|
||||
set(MACOSX_BUNDLE_ICON_FILE pcbnew.icns)
|
||||
set(MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.pcbnew)
|
||||
set(MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
||||
endif(APPLE)
|
||||
if( APPLE )
|
||||
set( PCBNEW_RESOURCES pcbnew.icns pcbnew_doc.icns )
|
||||
set_source_files_properties( "${CMAKE_CURRENT_SOURCE_DIR}/pcbnew.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources )
|
||||
set_source_files_properties( "${CMAKE_CURRENT_SOURCE_DIR}/pcbnew_doc.icns"
|
||||
PROPERTIES MACOSX_PACKAGE_LOCATION Resources )
|
||||
set( MACOSX_BUNDLE_ICON_FILE pcbnew.icns )
|
||||
set( MACOSX_BUNDLE_GUI_IDENTIFIER org.kicad-eda.pcbnew )
|
||||
set( MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist )
|
||||
endif()
|
||||
|
||||
# Create a C++ compilable string initializer containing html text into a *.h file:
|
||||
add_custom_command(
|
||||
|
@ -392,10 +396,20 @@ make_lexer(
|
|||
)
|
||||
|
||||
|
||||
###
|
||||
# subcomponents of pcbnew
|
||||
###
|
||||
add_subdirectory( pcad2kicadpcb_plugin )
|
||||
if( BUILD_GITHUB_PLUGIN )
|
||||
add_subdirectory( github )
|
||||
endif()
|
||||
|
||||
|
||||
|
||||
###
|
||||
# Create the pcbnew executable
|
||||
###
|
||||
add_executable(pcbnew WIN32 MACOSX_BUNDLE
|
||||
add_executable( pcbnew WIN32 MACOSX_BUNDLE
|
||||
${PCBNEW_SRCS}
|
||||
${PCBNEW_COMMON_SRCS}
|
||||
${PCBNEW_SCRIPTING_SRCS}
|
||||
|
@ -405,15 +419,15 @@ add_executable(pcbnew WIN32 MACOSX_BUNDLE
|
|||
###
|
||||
# Set properties for APPLE on pcbnew target
|
||||
###
|
||||
if(APPLE)
|
||||
set_target_properties(pcbnew PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
|
||||
endif(APPLE)
|
||||
if( APPLE )
|
||||
set_target_properties( pcbnew PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist )
|
||||
endif()
|
||||
|
||||
###
|
||||
# Link executable target pcbnew with correct libraries
|
||||
###
|
||||
|
||||
target_link_libraries(pcbnew
|
||||
target_link_libraries( pcbnew
|
||||
3d-viewer
|
||||
pcbcommon
|
||||
common
|
||||
|
@ -445,48 +459,48 @@ endif(WIN32 AND MSYS)
|
|||
###
|
||||
# Add pcbnew as install target
|
||||
###
|
||||
install(TARGETS pcbnew
|
||||
install( TARGETS pcbnew
|
||||
DESTINATION ${KICAD_BIN}
|
||||
COMPONENT binary)
|
||||
COMPONENT binary )
|
||||
|
||||
|
||||
if(KICAD_SCRIPTING)
|
||||
add_custom_target(FixSwigImportsScripting ALL
|
||||
if( KICAD_SCRIPTING )
|
||||
add_custom_target( FixSwigImportsScripting ALL
|
||||
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/../scripting/fixswigimports.py ${CMAKE_CURRENT_BINARY_DIR}/pcbnew.py
|
||||
DEPENDS pcbnew
|
||||
COMMENT "Fixing swig_import_helper in Kicad scripting"
|
||||
)
|
||||
|
||||
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/pcbnew.py DESTINATION ${PYTHON_DEST})
|
||||
endif(KICAD_SCRIPTING)
|
||||
install( FILES ${CMAKE_BINARY_DIR}/pcbnew/pcbnew.py DESTINATION ${PYTHON_DEST} )
|
||||
endif()
|
||||
|
||||
if (KICAD_SCRIPTING_MODULES)
|
||||
add_custom_target(FixSwigImportsModuleScripting ALL
|
||||
if( KICAD_SCRIPTING_MODULES )
|
||||
add_custom_target( FixSwigImportsModuleScripting ALL
|
||||
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/../scripting/fixswigimports.py ${CMAKE_CURRENT_BINARY_DIR}/pcbnew.py
|
||||
DEPENDS _pcbnew
|
||||
COMMENT "Fixing swig_import_helper in Kicad scripting modules"
|
||||
)
|
||||
|
||||
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/pcbnew.py DESTINATION ${PYTHON_DEST})
|
||||
install( FILES ${CMAKE_BINARY_DIR}/pcbnew/pcbnew.py DESTINATION ${PYTHON_DEST} )
|
||||
|
||||
if (WIN32)
|
||||
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/_pcbnew.pyd DESTINATION ${PYTHON_DEST})
|
||||
else(WIN32)
|
||||
install(FILES ${CMAKE_BINARY_DIR}/pcbnew/_pcbnew.so DESTINATION ${PYTHON_DEST})
|
||||
endif(WIN32)
|
||||
|
||||
endif(KICAD_SCRIPTING_MODULES)
|
||||
if( WIN32 )
|
||||
install( FILES ${CMAKE_BINARY_DIR}/pcbnew/_pcbnew.pyd DESTINATION ${PYTHON_DEST} )
|
||||
else()
|
||||
install( FILES ${CMAKE_BINARY_DIR}/pcbnew/_pcbnew.so DESTINATION ${PYTHON_DEST} )
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
# The specctra test fails to build properly using MS Visual Studio.
|
||||
if(NOT MSVC)
|
||||
if( NOT MSVC )
|
||||
# This one gets made only when testing.
|
||||
add_executable(specctra_test EXCLUDE_FROM_ALL specctra_test.cpp specctra.cpp)
|
||||
target_link_libraries(specctra_test common ${wxWidgets_LIBRARIES})
|
||||
endif(NOT MSVC)
|
||||
add_executable( specctra_test EXCLUDE_FROM_ALL specctra_test.cpp specctra.cpp )
|
||||
target_link_libraries( specctra_test common ${wxWidgets_LIBRARIES} )
|
||||
endif()
|
||||
|
||||
# This one gets made only when testing.
|
||||
add_executable(layer_widget_test WIN32 EXCLUDE_FROM_ALL
|
||||
add_executable( layer_widget_test WIN32 EXCLUDE_FROM_ALL
|
||||
layer_widget.cpp
|
||||
)
|
||||
target_link_libraries(layer_widget_test common ${wxWidgets_LIBRARIES})
|
||||
target_link_libraries( layer_widget_test common ${wxWidgets_LIBRARIES} )
|
||||
|
||||
|
|
|
@ -699,7 +699,6 @@ void PCB_BASE_FRAME::UpdateStatusBar()
|
|||
|
||||
switch( g_UserUnit )
|
||||
{
|
||||
#if defined( USE_PCBNEW_NANOMETRES )
|
||||
case INCHES:
|
||||
absformatter = wxT( "X %.6f Y %.6f" );
|
||||
locformatter = wxT( "dx %.6f dy %.6f d %.6f" );
|
||||
|
@ -709,19 +708,6 @@ void PCB_BASE_FRAME::UpdateStatusBar()
|
|||
absformatter = wxT( "X %.6f Y %.6f" );
|
||||
locformatter = wxT( "dx %.6f dy %.6f d %.6f" );
|
||||
break;
|
||||
#else
|
||||
case INCHES:
|
||||
absformatter = wxT( "X %.4f Y %.4f" );
|
||||
locformatter = wxT( "dx %.4f dy %.4f d %.4f" );
|
||||
break;
|
||||
|
||||
case MILLIMETRES:
|
||||
dXpos = RoundTo0( dXpos, 1000.0 );
|
||||
dYpos = RoundTo0( dYpos, 1000.0 );
|
||||
absformatter = wxT( "X %.3f Y %.3f" );
|
||||
locformatter = wxT( "dx %.3f dy %.3f d %.3f" );
|
||||
break;
|
||||
#endif
|
||||
|
||||
case UNSCALED_UNITS:
|
||||
absformatter = wxT( "X %f Y %f" );
|
||||
|
@ -740,14 +726,6 @@ void PCB_BASE_FRAME::UpdateStatusBar()
|
|||
dXpos = To_User_Unit( g_UserUnit, dx );
|
||||
dYpos = To_User_Unit( g_UserUnit, dy );
|
||||
|
||||
#ifndef USE_PCBNEW_NANOMETRES
|
||||
if ( g_UserUnit == MILLIMETRES )
|
||||
{
|
||||
dXpos = RoundTo0( dXpos, 1000.0 );
|
||||
dYpos = RoundTo0( dYpos, 1000.0 );
|
||||
}
|
||||
#endif
|
||||
|
||||
// We already decided the formatter above
|
||||
line.Printf( locformatter, dXpos, dYpos, hypot( dXpos, dYpos ) );
|
||||
SetStatusText( line, 3 );
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue