Commit ac26035f authored by Garth Corral's avatar Garth Corral

Merged trunk @ 5348

parents bb2bc9d1 846b2ae2
...@@ -116,7 +116,7 @@ LINK_DIRECTORIES( ${LINK_DIRECTORIES_PATH} ) ...@@ -116,7 +116,7 @@ LINK_DIRECTORIES( ${LINK_DIRECTORIES_PATH} )
if( UNIX ) if( UNIX )
set( KICAD_USER_CONFIG_DIR $ENV{HOME} CACHE PATH "Location of user specific KiCad config files" ) set( KICAD_USER_CONFIG_DIR $ENV{HOME} CACHE PATH "Location of user specific KiCad config files" )
elseif( MINGW ) elseif( MINGW )
set( KICAD_USER_CONFIG_DIR $ENV{%APPDATA%} CACHE PATH "Location of user specific KiCad config files" ) set( KICAD_USER_CONFIG_DIR $ENV{APPDATA} CACHE PATH "Location of user specific KiCad config files" )
endif() endif()
mark_as_advanced( KICAD_USER_CONFIG_DIR ) mark_as_advanced( KICAD_USER_CONFIG_DIR )
......
...@@ -165,7 +165,7 @@ if(WIN32 AND NOT CYGWIN) ...@@ -165,7 +165,7 @@ if(WIN32 AND NOT CYGWIN)
find_library(LIB_EAY find_library(LIB_EAY
NAMES NAMES
${LIB_EAY_NAMES} ${LIB_EAY_NAMES}
${_OPENSLL_ROOT_HINTS_AND_PATHS} ${_OPENSSL_ROOT_HINTS_AND_PATHS}
PATH_SUFFIXES PATH_SUFFIXES
"lib" "lib"
"lib/MinGW" "lib/MinGW"
...@@ -177,7 +177,7 @@ if(WIN32 AND NOT CYGWIN) ...@@ -177,7 +177,7 @@ if(WIN32 AND NOT CYGWIN)
find_library(SSL_EAY find_library(SSL_EAY
NAMES NAMES
${SSL_EAY_NAMES} ${SSL_EAY_NAMES}
${_OPENSLL_ROOT_HINTS_AND_PATHS} ${_OPENSSL_ROOT_HINTS_AND_PATHS}
PATH_SUFFIXES PATH_SUFFIXES
"lib" "lib"
"lib/MinGW" "lib/MinGW"
......
Compiling KiCad from Source Compiling KiCad from Source
=========================== ===========================
KiCad Documentation Team KiCad Documentation Team
Last revised on 12-mars-2012 by jp Charras Last revised on 2014-december-24 by JP Charras
Introduction Introduction
------------ ------------
...@@ -32,7 +32,7 @@ KiCad from source. ...@@ -32,7 +32,7 @@ KiCad from source.
* CMake - Cross-platform make * CMake - Cross-platform make
* GLUT - The OpenGL Utility Library * GLUT - The OpenGL Utility Library
* GLEW * GLEW
* wxGTK or wxWidgets - The wxWidgets GUI toolkit with GTK+ bindings * wxWidgets - The wxWidgets GUI toolkit with GTK+ bindings version 3.0 or more
* libbz2 (dev) * libbz2 (dev)
* libcairo (dev) * libcairo (dev)
...@@ -57,7 +57,7 @@ Compiler and basic development tools ...@@ -57,7 +57,7 @@ Compiler and basic development tools
Make sure g++, make and other tools are in your path. Make sure g++, make and other tools are in your path.
If windows, then try running g++ and make from within your msys bash shell. If windows, then try running g++ and make from within your msys bash shell.
PLEASE NOTE: g++ 4.7.1 at least (possibly the 4.7.x series) is known to PLEASE NOTE: g++ 4.7.1 and 4.7.2 are known to
miscompile pcbnew (it get zones wrong) with -O2; using -O1 is a suitable miscompile pcbnew (it get zones wrong) with -O2; using -O1 is a suitable
workaround until they fix the compiler. workaround until they fix the compiler.
...@@ -68,7 +68,7 @@ WARNING: ...@@ -68,7 +68,7 @@ WARNING:
see wxWidgets_patch_notes.txt for patches and issues in wxWidgets. see wxWidgets_patch_notes.txt for patches and issues in wxWidgets.
On Windows, download On Windows, download
http://sourceforge.net/projects/wxwindows/files/3.0.0/wxWidgets-3.0.0.zip/download http://sourceforge.net/projects/wxwindows/files/3.0.2/wxWidgets-3.0.2.zip/download
or a newer version. or a newer version.
Do NOT use previous versions which all have annoying issues for KiCad. Do NOT use previous versions which all have annoying issues for KiCad.
Start msys so you have a bash shell. Start msys so you have a bash shell.
...@@ -95,6 +95,10 @@ or more recent (Older versions have a print function which does not work). ...@@ -95,6 +95,10 @@ or more recent (Older versions have a print function which does not work).
Verify that wx-config is in your path by running it from a command prompt. Verify that wx-config is in your path by running it from a command prompt.
Linux users then go to next step. Linux users then go to next step.
Note also wxWidgets must be compiled with the wxWebView support.
This is the default when building wxWidgets, but only if the libwebkitgtk-dev is installed
before building wxWidgets (sudo apt-get install libwebkitgtk-dev)
Install CMake Install CMake
------------- -------------
On windows, download the installation binary for windows from cmake.org. On windows, download the installation binary for windows from cmake.org.
...@@ -167,9 +171,12 @@ Linux and windows users both then make two "out of source" build directories: ...@@ -167,9 +171,12 @@ Linux and windows users both then make two "out of source" build directories:
On either cmake command line shown below, you can optionally include On either cmake command line shown below, you can optionally include
-DCMAKE_INSTALL_PREFIX=<finallInstallDir> -DCMAKE_INSTALL_PREFIX=<finallInstallDir>
For instance on Linux: <finallInstallDir>=/usr/local/kicad or ~/kicad
On windows, run the following command: On windows, run the following command:
cmake -G "MSYS Makefiles" -DCMAKE_BUILD_TYPE=Release -DwxWidgets_ROOT_DIR=<wxInstallDir> ../../ cmake -G "MSYS Makefiles" -DCMAKE_BUILD_TYPE=Release -DwxWidgets_ROOT_DIR=<wxInstallDir> ../../
Avoid installing Kicad on C: disk, which is protected by Windows.
Use D: or E: ...
On linux, run instead the following command: On linux, run instead the following command:
cmake -DCMAKE_BUILD_TYPE=Release ../../ cmake -DCMAKE_BUILD_TYPE=Release ../../
......
...@@ -100,9 +100,12 @@ USE_IMAGES_IN_MENUS (ON/OFF) ...@@ -100,9 +100,12 @@ USE_IMAGES_IN_MENUS (ON/OFF)
---------------------------- ----------------------------
Default: OFF for OSX, ON for other platforms. Default: OFF for OSX, ON for other platforms.
This option is used to enable or disable building KiCad with images in menu This option is used to enable or disable building KiCad with images (icons) in menu
items. If this is not defined when CMake is used to create the build files, 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. images will be included in menu items on all platforms except OSX.
Note also, on Linux, some window managers do not show icons in menu, or
show them only if the current option is activated.
Therefore, even if you have icons in menus, they will be not always displayed
DOWNLOAD_DIR (PATH) DOWNLOAD_DIR (PATH)
...@@ -138,6 +141,7 @@ Default: OFF ...@@ -138,6 +141,7 @@ Default: OFF
This option enables or disables building Python scripting support within KiCad. This option enables or disables building Python scripting support within KiCad.
Currently only Pcbnew is supported. This option requires SWIG and Python to be Currently only Pcbnew is supported. This option requires SWIG and Python to be
installed on the system. installed on the system.
It allows using footprint wizards in footprint editor to create new footprints
KICAD_SCRIPTING_MODULES (ON/OFF) KICAD_SCRIPTING_MODULES (ON/OFF)
...@@ -147,6 +151,8 @@ Default: OFF ...@@ -147,6 +151,8 @@ Default: OFF
This option enables or disables building KiCad Python modules that can be used This option enables or disables building KiCad Python modules that can be used
externally by Python. Currently only Pcbnew is supported. This option externally by Python. Currently only Pcbnew is supported. This option
requires SWIG and Python to be installed on the system. requires SWIG and Python to be installed on the system.
This python module is used to edit board files (.kicad_pcb files) from a
python script, outside kicad.
KICAD_SCRIPTING_WXPYTHON (ON/OFF) KICAD_SCRIPTING_WXPYTHON (ON/OFF)
...@@ -156,6 +162,7 @@ Default: OFF ...@@ -156,6 +162,7 @@ Default: OFF
This option enables or disables building wxPython support into the KiCad This option enables or disables building wxPython support into the KiCad
scripting support. Currently only Pcbnew has scripting support. This option requires scripting support. Currently only Pcbnew has scripting support. This option requires
SWIG, Python, and wxPython to be installed on the system. SWIG, Python, and wxPython to be installed on the system.
It allows execution of python scripts insided Pcbnew, during a session.
PYTHON_SITE_PACKAGE_PATH (PATH) PYTHON_SITE_PACKAGE_PATH (PATH)
...@@ -169,11 +176,21 @@ different path, set this variable to the desired path. ...@@ -169,11 +176,21 @@ different path, set this variable to the desired path.
BUILD_GITHUB_PLUGIN (ON/OFF) BUILD_GITHUB_PLUGIN (ON/OFF)
---------------------------- ----------------------------
Default: OFF Default: ON
This option enables or disables building KiCad with a pcbnew plugin for loading This option enables or disables building KiCad with a pcbnew plugin for loading
footprints from a GitHub repository. footprints from a GitHub repository.
KICAD_USE_WEBKIT (ON/OFF)
----------------------------
Default: ON (and OFF when BUILD_GITHUB_PLUGIN is OFF)
This option enables or disables building a web viewer used if the
footprint library table wizard to easily add footprints library entries
to this tables when libraries are on a GitHub repository.
This option need the full support of wxWebview/WebKit in wxWidgets, which is not
always the case on Linux.
KICAD_REPO_NAME (STRING) KICAD_REPO_NAME (STRING)
------------------------ ------------------------
......
...@@ -85,16 +85,18 @@ void EDA_DRAW_FRAME::Process_PageSettings( wxCommandEvent& event ) ...@@ -85,16 +85,18 @@ void EDA_DRAW_FRAME::Process_PageSettings( wxCommandEvent& event )
} }
DIALOG_PAGES_SETTINGS::DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent ) : DIALOG_PAGES_SETTINGS::DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent ) :
DIALOG_PAGES_SETTINGS_BASE( parent ), DIALOG_PAGES_SETTINGS_BASE( parent ),
m_initialized( false ) m_initialized( false )
{ {
m_parent = parent; m_parent = parent;
m_screen = m_parent->GetScreen(); m_screen = m_parent->GetScreen();
m_projectPath = Prj().GetProjectPath();
m_page_bitmap = NULL; m_page_bitmap = NULL;
m_tb = m_parent->GetTitleBlock(); m_tb = m_parent->GetTitleBlock();
m_customFmt = false; m_customFmt = false;
m_localPrjConfigChanged = false; m_localPrjConfigChanged = false;
m_pagelayout = NULL;
initDialog(); initDialog();
...@@ -105,8 +107,8 @@ DIALOG_PAGES_SETTINGS::DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent ) : ...@@ -105,8 +107,8 @@ DIALOG_PAGES_SETTINGS::DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent ) :
DIALOG_PAGES_SETTINGS::~DIALOG_PAGES_SETTINGS() DIALOG_PAGES_SETTINGS::~DIALOG_PAGES_SETTINGS()
{ {
if( m_page_bitmap ) delete m_page_bitmap;
delete m_page_bitmap; delete m_pagelayout;
} }
...@@ -225,7 +227,7 @@ void DIALOG_PAGES_SETTINGS::OnOkClick( wxCommandEvent& event ) ...@@ -225,7 +227,7 @@ void DIALOG_PAGES_SETTINGS::OnOkClick( wxCommandEvent& event )
m_screen->SetModify(); m_screen->SetModify();
m_parent->GetCanvas()->Refresh(); m_parent->GetCanvas()->Refresh();
if( m_localPrjConfigChanged ) if( LocalPrjConfigChanged() )
m_parent->SaveProjectSettings( true ); m_parent->SaveProjectSettings( true );
EndModal( true ); EndModal( true );
...@@ -409,9 +411,12 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings() ...@@ -409,9 +411,12 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings()
if( fileName != BASE_SCREEN::m_PageLayoutDescrFileName ) if( fileName != BASE_SCREEN::m_PageLayoutDescrFileName )
{ {
if( !fileName.IsEmpty() ) wxString fullFileName =
WORKSHEET_LAYOUT::MakeFullFileName( fileName, m_projectPath );
if( !fullFileName.IsEmpty() )
{ {
wxString fullFileName = WORKSHEET_LAYOUT::MakeFullFileName( fileName );
if( !wxFileExists( fullFileName ) ) if( !wxFileExists( fullFileName ) )
{ {
wxString msg; wxString msg;
...@@ -424,7 +429,7 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings() ...@@ -424,7 +429,7 @@ bool DIALOG_PAGES_SETTINGS::SavePageSettings()
BASE_SCREEN::m_PageLayoutDescrFileName = fileName; BASE_SCREEN::m_PageLayoutDescrFileName = fileName;
WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance(); WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance();
pglayout.SetPageLayout( fileName ); pglayout.SetPageLayout( fullFileName );
m_localPrjConfigChanged = true; m_localPrjConfigChanged = true;
} }
...@@ -663,6 +668,7 @@ void DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample() ...@@ -663,6 +668,7 @@ void DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample()
wxString emptyString; wxString emptyString;
GRResetPenAndBrush( &memDC ); GRResetPenAndBrush( &memDC );
WORKSHEET_LAYOUT::SetAltInstance( m_pagelayout );
DrawPageLayout( &memDC, NULL, pageDUMMY, DrawPageLayout( &memDC, NULL, pageDUMMY,
emptyString, emptyString, emptyString, emptyString,
m_tb, m_screen->m_NumberOfScreens, m_tb, m_screen->m_NumberOfScreens,
...@@ -670,6 +676,7 @@ void DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample() ...@@ -670,6 +676,7 @@ void DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample()
memDC.SelectObject( wxNullBitmap ); memDC.SelectObject( wxNullBitmap );
m_PageLayoutExampleBitmap->SetBitmap( *m_page_bitmap ); m_PageLayoutExampleBitmap->SetBitmap( *m_page_bitmap );
WORKSHEET_LAYOUT::SetAltInstance( NULL );
// Refresh the dialog. // Refresh the dialog.
Layout(); Layout();
...@@ -782,11 +789,9 @@ void DIALOG_PAGES_SETTINGS::GetCustomSizeMilsFromDialog() ...@@ -782,11 +789,9 @@ void DIALOG_PAGES_SETTINGS::GetCustomSizeMilsFromDialog()
// Called on .kicad_wks file description selection change // Called on .kicad_wks file description selection change
void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxCommandEvent& event ) void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxCommandEvent& event )
{ {
wxString pro_dir = wxPathOnly( Prj().GetProjectFullName() );
// Display a file picker dialog // Display a file picker dialog
wxFileDialog fileDialog( this, _( "Select Page Layout Descr File" ), wxFileDialog fileDialog( this, _( "Select Page Layout Descr File" ),
pro_dir, GetWksFileName(), m_projectPath, GetWksFileName(),
PageLayoutDescrFileWildcard, PageLayoutDescrFileWildcard,
wxFD_DEFAULT_STYLE | wxFD_FILE_MUST_EXIST ); wxFD_DEFAULT_STYLE | wxFD_FILE_MUST_EXIST );
...@@ -796,24 +801,30 @@ void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxCommandEvent& event ) ...@@ -796,24 +801,30 @@ void DIALOG_PAGES_SETTINGS::OnWksFileSelection( wxCommandEvent& event )
wxString fileName = fileDialog.GetPath(); wxString fileName = fileDialog.GetPath();
// Try to remove the path, if the path is the current working dir, // Try to remove the path, if the path is the current working dir,
// or the dir of kicad.pro (template) // or the dir of kicad.pro (template), and use a relative path
wxString shortFileName = WORKSHEET_LAYOUT::MakeShortFileName( fileName ); wxString shortFileName = WORKSHEET_LAYOUT::MakeShortFileName( fileName, m_projectPath );
wxFileName fn = shortFileName;
// For Win/Linux/macOS compatibility, a relative path is a good idea // For Win/Linux/macOS compatibility, a relative path is a good idea
if( fn.IsAbsolute() && fileName != GetWksFileName() ) if( shortFileName != GetWksFileName() && shortFileName != fileName )
{ {
fn.MakeRelativeTo( pro_dir );
wxString msg = wxString::Format( _( wxString msg = wxString::Format( _(
"The page layout descr filename has changed.\n" "The page layout descr filename has changed.\n"
"Do you want to use the relative path:\n" "Do you want to use the relative path:\n"
"'%s'" ), "'%s'\n"
GetChars( fn.GetFullPath() ) "instead of\n"
); "'%s'" ), GetChars( shortFileName ), GetChars( fileName ) );
if( IsOK( this, msg ) )
shortFileName = fn.GetFullPath(); if( !IsOK( this, msg ) )
shortFileName = fileName;
} }
SetWksFileName( shortFileName ); SetWksFileName( shortFileName );
if( m_pagelayout == NULL )
m_pagelayout = new WORKSHEET_LAYOUT;
m_pagelayout->SetPageLayout( fileName );
GetPageLayoutInfoFromDialog();
UpdatePageLayoutExample();
} }
...@@ -37,6 +37,7 @@ class DIALOG_PAGES_SETTINGS: public DIALOG_PAGES_SETTINGS_BASE ...@@ -37,6 +37,7 @@ class DIALOG_PAGES_SETTINGS: public DIALOG_PAGES_SETTINGS_BASE
private: private:
EDA_DRAW_FRAME* m_parent; EDA_DRAW_FRAME* m_parent;
BASE_SCREEN* m_screen; BASE_SCREEN* m_screen;
wxString m_projectPath; // the curr project path
wxArrayString m_pageFmt; /// list of page sizes (not translated) wxArrayString m_pageFmt; /// list of page sizes (not translated)
bool m_initialized; bool m_initialized;
bool m_localPrjConfigChanged; /// the page layuout filename was changed bool m_localPrjConfigChanged; /// the page layuout filename was changed
...@@ -45,6 +46,8 @@ private: ...@@ -45,6 +46,8 @@ private:
PAGE_INFO m_pageInfo; /// Temporary page info. PAGE_INFO m_pageInfo; /// Temporary page info.
bool m_customFmt; /// true if the page selection is custom bool m_customFmt; /// true if the page selection is custom
TITLE_BLOCK m_tb; /// Temporary title block (basic inscriptions). TITLE_BLOCK m_tb; /// Temporary title block (basic inscriptions).
WORKSHEET_LAYOUT *m_pagelayout; // the alternate and temporary page layout shown by the dialog
// when the initial one is replaced by a new one
public: public:
DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent ); DIALOG_PAGES_SETTINGS( EDA_DRAW_FRAME* parent );
......
...@@ -36,3 +36,5 @@ tstamps ...@@ -36,3 +36,5 @@ tstamps
uri uri
value value
version version
aliases
alias
...@@ -60,7 +60,8 @@ ...@@ -60,7 +60,8 @@
// The layout shape used in the application // The layout shape used in the application
// It is accessible by WORKSHEET_LAYOUT::GetTheInstance() // It is accessible by WORKSHEET_LAYOUT::GetTheInstance()
WORKSHEET_LAYOUT wksTheInstance; static WORKSHEET_LAYOUT wksTheInstance;
static WORKSHEET_LAYOUT* wksAltInstance;
WORKSHEET_LAYOUT::WORKSHEET_LAYOUT() WORKSHEET_LAYOUT::WORKSHEET_LAYOUT()
{ {
...@@ -71,6 +72,28 @@ WORKSHEET_LAYOUT::WORKSHEET_LAYOUT() ...@@ -71,6 +72,28 @@ WORKSHEET_LAYOUT::WORKSHEET_LAYOUT()
m_bottomMargin = 10.0; // the bottom page margin in mm m_bottomMargin = 10.0; // the bottom page margin in mm
} }
/* static function: returns the instance of WORKSHEET_LAYOUT
* used in the application
*/
WORKSHEET_LAYOUT& WORKSHEET_LAYOUT::GetTheInstance()
{
if( wksAltInstance )
return *wksAltInstance;
else
return wksTheInstance;
}
/**
* static function: Set an alternate instance of WORKSHEET_LAYOUT
* mainly used in page setting dialog
* @param aLayout = the alternate page layout.
* if null, restore the basic page layout
*/
void WORKSHEET_LAYOUT::SetAltInstance( WORKSHEET_LAYOUT* aLayout )
{
wksAltInstance = aLayout;
}
void WORKSHEET_LAYOUT::SetLeftMargin( double aMargin ) void WORKSHEET_LAYOUT::SetLeftMargin( double aMargin )
{ {
...@@ -163,10 +186,22 @@ WORKSHEET_DATAITEM* WORKSHEET_LAYOUT::GetItem( unsigned aIdx ) const ...@@ -163,10 +186,22 @@ WORKSHEET_DATAITEM* WORKSHEET_LAYOUT::GetItem( unsigned aIdx ) const
} }
const wxString WORKSHEET_LAYOUT::MakeShortFileName( const wxString& aFullFileName ) const wxString WORKSHEET_LAYOUT::MakeShortFileName( const wxString& aFullFileName,
const wxString& aProjectPath )
{ {
wxFileName fn = aFullFileName;
wxString shortFileName = aFullFileName; wxString shortFileName = aFullFileName;
wxFileName fn = aFullFileName;
if( fn.IsRelative() )
return shortFileName;
if( ! aProjectPath.IsEmpty() && aFullFileName.StartsWith( aProjectPath ) )
{
fn.MakeRelativeTo( aProjectPath );
shortFileName = fn.GetFullPath();
return shortFileName;
}
wxString fileName = Kiface().KifaceSearch().FindValidPath( fn.GetFullName() ); wxString fileName = Kiface().KifaceSearch().FindValidPath( fn.GetFullName() );
if( !fileName.IsEmpty() ) if( !fileName.IsEmpty() )
...@@ -180,17 +215,34 @@ const wxString WORKSHEET_LAYOUT::MakeShortFileName( const wxString& aFullFileNam ...@@ -180,17 +215,34 @@ const wxString WORKSHEET_LAYOUT::MakeShortFileName( const wxString& aFullFileNam
} }
const wxString WORKSHEET_LAYOUT::MakeFullFileName( const wxString& aShortFileName ) const wxString WORKSHEET_LAYOUT::MakeFullFileName( const wxString& aShortFileName,
const wxString& aProjectPath )
{ {
wxFileName fn = aShortFileName; wxString fullFileName = ExpandEnvVarSubstitutions( aShortFileName );
wxString fullFileName = aShortFileName;
if( fn.GetPath().IsEmpty() && !fn.GetFullName().IsEmpty() ) if( fullFileName.IsEmpty() )
return fullFileName;
wxFileName fn = fullFileName;
if( fn.IsAbsolute() )
return fullFileName;
// the path is not absolute: search it in project path, and then in
// kicad valid paths
if( !aProjectPath.IsEmpty() )
{ {
wxString name = Kiface().KifaceSearch().FindValidPath( fn.GetFullName() ); fn.MakeAbsolute( aProjectPath );
if( !name.IsEmpty() )
fullFileName = name; if( wxFileExists( fn.GetFullPath() ) )
return fn.GetFullPath();
} }
fn = fullFileName;
wxString name = Kiface().KifaceSearch().FindValidPath( fn.GetFullName() );
if( !name.IsEmpty() )
fullFileName = name;
return fullFileName; return fullFileName;
} }
...@@ -773,9 +773,9 @@ void WORKSHEET_LAYOUT::SetPageLayout( const char* aPageLayout, bool Append ) ...@@ -773,9 +773,9 @@ void WORKSHEET_LAYOUT::SetPageLayout( const char* aPageLayout, bool Append )
#include <wx/file.h> #include <wx/file.h>
// SetLayout() try to load a custom layout file, // SetLayout() try to load the aFullFileName custom layout file,
// currently defined by the environment variable KICAD_WKSFILE // if aFullFileName is empty, try the filename defined by the
// (a *.kicad_wks file). // environment variable KICAD_WKSFILE (a *.kicad_wks filename).
// if does not exists, loads the default page layout. // if does not exists, loads the default page layout.
void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append ) void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append )
{ {
...@@ -783,8 +783,6 @@ void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append ...@@ -783,8 +783,6 @@ void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append
if( !Append ) if( !Append )
{ {
fullFileName = MakeFullFileName( aFullFileName );
if( fullFileName.IsEmpty() ) if( fullFileName.IsEmpty() )
wxGetEnv( wxT( "KICAD_WKSFILE" ), &fullFileName ); wxGetEnv( wxT( "KICAD_WKSFILE" ), &fullFileName );
...@@ -816,17 +814,19 @@ void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append ...@@ -816,17 +814,19 @@ void WORKSHEET_LAYOUT::SetPageLayout( const wxString& aFullFileName, bool Append
if( wksFile.Read( buffer, filelen ) != filelen ) if( wksFile.Read( buffer, filelen ) != filelen )
wxLogMessage( _("The file <%s> was not fully read"), wxLogMessage( _("The file <%s> was not fully read"),
fullFileName.GetData() ); fullFileName.GetData() );
else else
{ {
buffer[filelen]=0; buffer[filelen]=0;
if( ! Append ) if( ! Append )
ClearList(); ClearList();
PAGE_LAYOUT_READER_PARSER lp_parser( buffer, fullFileName );
PAGE_LAYOUT_READER_PARSER pl_parser( buffer, fullFileName );
try try
{ {
lp_parser.Parse( this ); pl_parser.Parse( this );
} }
catch( const IO_ERROR& ioe ) catch( const IO_ERROR& ioe )
{ {
......
...@@ -77,6 +77,7 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce ...@@ -77,6 +77,7 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce
// Attempt to determine where the 3D shape libraries were installed using the // Attempt to determine where the 3D shape libraries were installed using the
// legacy path: // legacy path:
// on Unix: /usr/local/kicad/share/modules/packages3d // on Unix: /usr/local/kicad/share/modules/packages3d
// oor /usr/local/kicad/share/kicad/modules/packages3d
// or /usr/share/kicad/modules/packages3d // or /usr/share/kicad/modules/packages3d
// On Windows: bin../share/modules/packages3d // On Windows: bin../share/modules/packages3d
wxString relpath( wxT( "modules/" ) ); wxString relpath( wxT( "modules/" ) );
...@@ -112,6 +113,16 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce ...@@ -112,6 +113,16 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce
return true; return true;
} }
path.Empty();
wxGetEnv( wxT("HOME"), &path );
path += wxT("/kicad/share/kicad/") + relpath;
if( wxFileName::DirExists( path ) )
{
wxSetEnv( aKiSys3Dmod, path );
return true;
}
// Try the standard install path: // Try the standard install path:
path = wxT("/usr/local/kicad/share/") + relpath; path = wxT("/usr/local/kicad/share/") + relpath;
...@@ -121,6 +132,14 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce ...@@ -121,6 +132,14 @@ bool Set3DShapesDefaultPath( const wxString& aKiSys3Dmod, const PGM_BASE* aProce
return true; return true;
} }
// Try the new standard install path:
path = wxT("/usr/local/kicad/share/kicad/") + relpath;
if( wxFileName::DirExists( path ) )
{
wxSetEnv( aKiSys3Dmod, path );
return true;
}
// Try the official distrib standard install path: // Try the official distrib standard install path:
path = wxT("/usr/share/kicad/") + relpath; path = wxT("/usr/share/kicad/") + relpath;
......
...@@ -37,6 +37,7 @@ set( CVPCB_DIALOGS ...@@ -37,6 +37,7 @@ set( CVPCB_DIALOGS
../pcbnew/dialogs/dialog_fp_plugin_options_base.cpp ../pcbnew/dialogs/dialog_fp_plugin_options_base.cpp
../pcbnew/dialogs/wizard_add_fplib_base.cpp ../pcbnew/dialogs/wizard_add_fplib_base.cpp
../pcbnew/dialogs/wizard_add_fplib.cpp ../pcbnew/dialogs/wizard_add_fplib.cpp
../pcbnew/dialogs/dialog_select_dirlist_base.cpp
) )
set( CVPCB_SRCS set( CVPCB_SRCS
......
...@@ -438,25 +438,39 @@ void CVPCB_MAINFRAME::LoadNetList( wxCommandEvent& event ) ...@@ -438,25 +438,39 @@ void CVPCB_MAINFRAME::LoadNetList( wxCommandEvent& event )
bool CVPCB_MAINFRAME::OpenProjectFiles( const std::vector<wxString>& aFileSet, int aCtl ) bool CVPCB_MAINFRAME::OpenProjectFiles( const std::vector<wxString>& aFileSet, int aCtl )
{ {
if( aFileSet.size() == 1 ) if( aFileSet.size() != 1 ) // Unexpected comand
{ return false;
m_NetlistFileName = aFileSet[0];
ReadNetListAndLinkFiles();
UpdateTitle(); m_NetlistFileName = aFileSet[0];
ReadNetListAndLinkFiles();
// Resize the components list box. This is needed in case the UpdateTitle();
// contents have shrunk compared to the previous netlist.
m_compListBox->UpdateWidth();
// OSX need it since some objects are "rebuild" just make aware AUI // Resize the components list box. This is needed in case the
// Fixes #1258081 // contents have shrunk compared to the previous netlist.
m_auimgr.Update(); m_compListBox->UpdateWidth();
// OSX need it since some objects are "rebuild" just make aware AUI
// Fixes #1258081
m_auimgr.Update();
return true; if( Kiface().IsSingle() )
{
// PROJECT::SetProjectFullName() is an impactful function. It should only be
// called under carefully considered circumstances.
// The calling code should know not to ask me here to change projects unless
// it knows what consequences that will have on other KIFACEs running and using
// this same PROJECT. It can be very harmful if that calling code is stupid.
//
// In Cvpcb, we call SetProjectFullName only in Single mode, i.e. it is not
// called from a project
wxFileName pro = m_NetlistFileName;
pro.SetExt( ProjectFileExtension );
Prj().SetProjectFullName( pro.GetFullPath() );
} }
return false; return true;
} }
......
...@@ -64,50 +64,49 @@ void CVPCB_MAINFRAME::ReCreateMenuBar() ...@@ -64,50 +64,49 @@ void CVPCB_MAINFRAME::ReCreateMenuBar()
// Menu File: // Menu File:
wxMenu* filesMenu = new wxMenu; wxMenu* filesMenu = new wxMenu;
// Open // Open files can be used only outside a project, because opening a netlist
AddMenuItem( filesMenu, // which is not the project netlist is a non sense.
ID_LOAD_PROJECT, if( Kiface().IsSingle() )
_( "&Open Netlist" ), LOAD_FILE_HELP, KiBitmap( open_document_xpm ) ); {
AddMenuItem( filesMenu, ID_LOAD_PROJECT,
_( "&Open Netlist" ), LOAD_FILE_HELP, KiBitmap( open_document_xpm ) );
// Open Recent submenu // Open Recent submenu
static wxMenu* openRecentMenu; static wxMenu* openRecentMenu;
// Add this menu to list menu managed by m_fileHistory // Add this menu to list menu managed by m_fileHistory
// (the file history will be updated when adding/removing files in history // (the file history will be updated when adding/removing files in history
if( openRecentMenu ) if( openRecentMenu )
Kiface().GetFileHistory().RemoveMenu( openRecentMenu ); Kiface().GetFileHistory().RemoveMenu( openRecentMenu );
openRecentMenu = new wxMenu(); openRecentMenu = new wxMenu();
Kiface().GetFileHistory().UseMenu( openRecentMenu ); Kiface().GetFileHistory().UseMenu( openRecentMenu );
Kiface().GetFileHistory().AddFilesToMenu(); Kiface().GetFileHistory().AddFilesToMenu();
AddMenuItem( filesMenu, openRecentMenu, -1, AddMenuItem( filesMenu, openRecentMenu, -1,
_( "Open &Recent" ), _( "Open &Recent" ),
_( "Open recent netlist" ), _( "Open recent netlist" ),
KiBitmap( open_project_xpm ) ); KiBitmap( open_project_xpm ) );
// Separator // Separator
filesMenu->AppendSeparator(); filesMenu->AppendSeparator();
}
// Save the .cmp file // Save the .cmp file
AddMenuItem( filesMenu, AddMenuItem( filesMenu, wxID_SAVE,
wxID_SAVE,
_( "&Save\tCtrl+S" ), SAVE_HLP_MSG, KiBitmap( save_xpm ) ); _( "&Save\tCtrl+S" ), SAVE_HLP_MSG, KiBitmap( save_xpm ) );
// Save as the .cmp file // Save as the .cmp file
AddMenuItem( filesMenu, AddMenuItem( filesMenu, wxID_SAVEAS,
wxID_SAVEAS,
_( "Save &As...\tCtrl+Shift+S" ), SAVE_AS_HLP_MSG, KiBitmap( save_xpm ) ); _( "Save &As...\tCtrl+Shift+S" ), SAVE_AS_HLP_MSG, KiBitmap( save_xpm ) );
// Separator // Separator
filesMenu->AppendSeparator(); filesMenu->AppendSeparator();
// Quit // Quit
AddMenuItem( filesMenu, AddMenuItem( filesMenu, wxID_EXIT,
wxID_EXIT, _( "&Quit" ), _( "Quit CvPcb" ),
_( "&Quit" ),
_( "Quit CvPcb" ),
KiBitmap( exit_xpm ) ); KiBitmap( exit_xpm ) );
// Menu Preferences: // Menu Preferences:
......
...@@ -49,8 +49,13 @@ void CVPCB_MAINFRAME::ReCreateHToolbar() ...@@ -49,8 +49,13 @@ void CVPCB_MAINFRAME::ReCreateHToolbar()
m_mainToolBar = new wxAuiToolBar( this, ID_H_TOOLBAR, wxDefaultPosition, wxDefaultSize, m_mainToolBar = new wxAuiToolBar( this, ID_H_TOOLBAR, wxDefaultPosition, wxDefaultSize,
wxAUI_TB_DEFAULT_STYLE | wxAUI_TB_HORZ_LAYOUT ); wxAUI_TB_DEFAULT_STYLE | wxAUI_TB_HORZ_LAYOUT );
m_mainToolBar->AddTool( ID_CVPCB_READ_INPUT_NETLIST, wxEmptyString, // Open files can be used only outside a project, because opening a netlist
KiBitmap( open_document_xpm ), LOAD_FILE_HELP ); // which is not the project netlist is a non sense.
if( Kiface().IsSingle() )
{
m_mainToolBar->AddTool( ID_CVPCB_READ_INPUT_NETLIST, wxEmptyString,
KiBitmap( open_document_xpm ), LOAD_FILE_HELP );
}
m_mainToolBar->AddTool( wxID_SAVE, wxEmptyString, KiBitmap( save_xpm ), SAVE_HLP_MSG ); m_mainToolBar->AddTool( wxID_SAVE, wxEmptyString, KiBitmap( save_xpm ), SAVE_HLP_MSG );
......
...@@ -21,6 +21,20 @@ X ~ 2 0 -200 170 U 40 40 1 1 P ...@@ -21,6 +21,20 @@ X ~ 2 0 -200 170 U 40 40 1 1 P
ENDDRAW ENDDRAW
ENDDEF ENDDEF
# #
# CONN_1
#
DEF ~CONN_1 P 0 30 N N 1 F N
F0 "P" 80 0 40 H V L CNN
F1 "CONN_1" 0 55 30 H I C CNN
F2 "" 0 0 60 H V C CNN
F3 "" 0 0 60 H V C CNN
DRAW
C 0 0 31 0 1 0 N
P 2 0 1 0 -30 0 -50 0 N
X 1 1 -150 0 100 R 60 60 1 1 P
ENDDRAW
ENDDEF
#
# CONN_2 # CONN_2
# #
DEF CONN_2 P 0 40 Y N 1 F N DEF CONN_2 P 0 40 Y N 1 F N
......
Cmp-Mod V01 Genere par PcbNew le 11/12/2006-20:19:14 Cmp-Mod V01 Created by Cvpcb (2014-12-31 BZR 5344)-product date = 01/01/2015 18:02:29
BeginCmp BeginCmp
TimeStamp = 4549F4BE; TimeStamp = /4549F4BE;
Reference = C1; Reference = C1;
ValeurCmp = 10uF; ValeurCmp = 10uF;
IdModule = C2V10; IdModule = discret:C2V10;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F3BE; TimeStamp = /4549F3BE;
Reference = C2; Reference = C2;
ValeurCmp = 680nF; ValeurCmp = 680nF;
IdModule = CP8; IdModule = discret:C2;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F464; TimeStamp = /4549F464;
Reference = P1; Reference = P1;
ValeurCmp = IN; ValeurCmp = IN;
IdModule = BORNIER2; IdModule = connect:bornier2;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F46C; TimeStamp = /4549F46C;
Reference = P2; Reference = P2;
ValeurCmp = OUT; ValeurCmp = OUT;
IdModule = BORNIER2; IdModule = connect:bornier2;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F4A5; TimeStamp = /4549F4A5;
Reference = P3; Reference = P3;
ValeurCmp = POWER; ValeurCmp = POWER;
IdModule = BORNIER2; IdModule = connect:bornier2;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 456A8ACC; TimeStamp = /456A8ACC;
Reference = P4; Reference = P4;
ValeurCmp = CONN_2; ValeurCmp = CONN_2;
IdModule = BORNIER2; IdModule = connect:bornier2;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F38A; TimeStamp = /54A5890A;
Reference = P5;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A58C65;
Reference = P6;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A58C8A;
Reference = P7;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A58CA3;
Reference = P8;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /4549F38A;
Reference = R1; Reference = R1;
ValeurCmp = 1.5K; ValeurCmp = 1.5K;
IdModule = R3; IdModule = discret:R3;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F39D; TimeStamp = /4549F39D;
Reference = R2; Reference = R2;
ValeurCmp = 1.5K; ValeurCmp = 1.5K;
IdModule = R3; IdModule = discret:R3;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F3AD; TimeStamp = /4549F3AD;
Reference = R3; Reference = R3;
ValeurCmp = 100K; ValeurCmp = 100K;
IdModule = R3; IdModule = discret:R3;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 4549F3A2; TimeStamp = /4549F3A2;
Reference = R4; Reference = R4;
ValeurCmp = 47K; ValeurCmp = 47K;
IdModule = R3; IdModule = discret:R3;
EndCmp EndCmp
BeginCmp BeginCmp
TimeStamp = 454A08DD; TimeStamp = /48B4F266;
Reference = U1; Reference = U1;
ValeurCmp = ECC83; ValeurCmp = ECC83;
IdModule = ECC-83-1; IdModule = Valves:VALVE-ECC-83-1;
EndCmp EndCmp
EndListe EndListe
This diff is collapsed.
(export (version D) (export (version D)
(design (design
(source F:/kicad-launchpad/testing/demos/ecc83/ecc83-pp.sch) (source F:/kicad-launchpad/testing/demos/ecc83/ecc83-pp.sch)
(date "04/07/2014 20:15:10") (date "01/01/2015 18:01:45")
(tool "Eeschema (2014-07-02 BZR 4969)-product")) (tool "Eeschema (2014-12-31 BZR 5344)-product"))
(components (components
(comp (ref U1) (comp (ref U1)
(value ECC83) (value ECC83)
(footprint VALVE-NOVAL_P) (footprint Valves:VALVE-ECC-83-1)
(libsource (lib valves) (part ECC83)) (libsource (lib valves) (part ECC83))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 48B4F266)) (tstamp 48B4F266))
(comp (ref P4) (comp (ref P4)
(value CONN_2) (value CONN_2)
(footprint connect:bornier2)
(libsource (lib conn) (part CONN_2)) (libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 456A8ACC)) (tstamp 456A8ACC))
(comp (ref C1) (comp (ref C1)
(value 10uF) (value 10uF)
(footprint discret:C2V10)
(libsource (lib device) (part C)) (libsource (lib device) (part C))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F4BE)) (tstamp 4549F4BE))
(comp (ref P3) (comp (ref P3)
(value POWER) (value POWER)
(footprint connect:bornier2)
(libsource (lib conn) (part CONN_2)) (libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F4A5)) (tstamp 4549F4A5))
(comp (ref P2) (comp (ref P2)
(value OUT) (value OUT)
(footprint connect:bornier2)
(libsource (lib conn) (part CONN_2)) (libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F46C)) (tstamp 4549F46C))
(comp (ref P1) (comp (ref P1)
(value IN) (value IN)
(footprint connect:bornier2)
(libsource (lib conn) (part CONN_2)) (libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F464)) (tstamp 4549F464))
(comp (ref C2) (comp (ref C2)
(value 680nF) (value 680nF)
(footprint discret:C2)
(libsource (lib device) (part C)) (libsource (lib device) (part C))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F3BE)) (tstamp 4549F3BE))
(comp (ref R3) (comp (ref R3)
(value 100K) (value 100K)
(footprint discret:R3)
(libsource (lib device) (part R)) (libsource (lib device) (part R))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F3AD)) (tstamp 4549F3AD))
(comp (ref R4) (comp (ref R4)
(value 47K) (value 47K)
(footprint discret:R3)
(libsource (lib device) (part R)) (libsource (lib device) (part R))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F3A2)) (tstamp 4549F3A2))
(comp (ref R2) (comp (ref R2)
(value 1.5K) (value 1.5K)
(footprint discret:R3)
(libsource (lib device) (part R)) (libsource (lib device) (part R))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F39D)) (tstamp 4549F39D))
(comp (ref R1) (comp (ref R1)
(value 1.5K) (value 1.5K)
(footprint discret:R3)
(libsource (lib device) (part R)) (libsource (lib device) (part R))
(sheetpath (names /) (tstamps /)) (sheetpath (names /) (tstamps /))
(tstamp 4549F38A))) (tstamp 4549F38A))
(comp (ref P5)
(value CONN_1)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A5890A))
(comp (ref P6)
(value CONN_1)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A58C65))
(comp (ref P7)
(value CONN_1)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A58C8A))
(comp (ref P8)
(value CONN_1)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A58CA3)))
(libparts (libparts
(libpart (lib device) (part C) (libpart (lib device) (part C)
(description "Condensateur non polarise") (description "Condensateur non polarise")
...@@ -87,6 +117,13 @@ ...@@ -87,6 +117,13 @@
(pins (pins
(pin (num 1) (name ~) (type passive)) (pin (num 1) (name ~) (type passive))
(pin (num 2) (name ~) (type passive)))) (pin (num 2) (name ~) (type passive))))
(libpart (lib conn) (part CONN_1)
(description "1 pin")
(fields
(field (name Reference) P)
(field (name Value) CONN_1))
(pins
(pin (num 1) (name 1) (type passive))))
(libpart (lib conn) (part CONN_2) (libpart (lib conn) (part CONN_2)
(description "Symbole general de connecteur") (description "Symbole general de connecteur")
(fields (fields
...@@ -114,47 +151,55 @@ ...@@ -114,47 +151,55 @@
(pin (num 9) (name F2) (type power_in))))) (pin (num 9) (name F2) (type power_in)))))
(libraries (libraries
(library (logical device) (library (logical device)
(uri f:\kicad\share\library\device.lib)) (uri f:\kicad\share\kicad\library\device.lib))
(library (logical conn) (library (logical conn)
(uri f:\kicad\share\library\conn.lib)) (uri f:\kicad\share\kicad\library\conn.lib))
(library (logical valves) (library (logical valves)
(uri f:\kicad\share\library\valves.lib))) (uri f:\kicad\share\kicad\library\valves.lib)))
(nets (nets
(net (code 1) (name "Net-(C1-Pad1)") (net (code 1) (name GND)
(node (ref R4) (pin 2))
(node (ref R2) (pin 2))
(node (ref R3) (pin 2))
(node (ref P1) (pin 1))
(node (ref P2) (pin 2))
(node (ref P3) (pin 2))
(node (ref C1) (pin 2)))
(net (code 2) (name "Net-(C1-Pad1)")
(node (ref U1) (pin 6)) (node (ref U1) (pin 6))
(node (ref C1) (pin 1)) (node (ref P3) (pin 1))
(node (ref P3) (pin 1))) (node (ref C1) (pin 1)))
(net (code 2) (name "Net-(R2-Pad1)") (net (code 3) (name "Net-(R2-Pad1)")
(node (ref R2) (pin 1)) (node (ref U1) (pin 3))
(node (ref U1) (pin 3))) (node (ref R2) (pin 1)))
(net (code 3) (name "Net-(C2-Pad2)") (net (code 4) (name "Net-(P8-Pad1)")
(node (ref P8) (pin 1)))
(net (code 5) (name "Net-(P7-Pad1)")
(node (ref P7) (pin 1)))
(net (code 6) (name "Net-(P6-Pad1)")
(node (ref P6) (pin 1)))
(net (code 7) (name "Net-(P5-Pad1)")
(node (ref P5) (pin 1)))
(net (code 8) (name "Net-(C2-Pad2)")
(node (ref U1) (pin 8)) (node (ref U1) (pin 8))
(node (ref R1) (pin 2)) (node (ref C2) (pin 2))
(node (ref C2) (pin 2))) (node (ref R1) (pin 2)))
(net (code 4) (name "Net-(C2-Pad1)") (net (code 9) (name "Net-(C2-Pad1)")
(node (ref C2) (pin 1)) (node (ref C2) (pin 1))
(node (ref R3) (pin 1)) (node (ref P2) (pin 1))
(node (ref P2) (pin 1))) (node (ref R3) (pin 1)))
(net (code 5) (name "Net-(P4-Pad2)") (net (code 10) (name "Net-(P4-Pad2)")
(node (ref U1) (pin 9)) (node (ref U1) (pin 9))
(node (ref P4) (pin 2))) (node (ref P4) (pin 2)))
(net (code 6) (name "Net-(P1-Pad2)") (net (code 11) (name "Net-(P1-Pad2)")
(node (ref U1) (pin 2)) (node (ref U1) (pin 2))
(node (ref P1) (pin 2)) (node (ref R4) (pin 1))
(node (ref R4) (pin 1))) (node (ref P1) (pin 2)))
(net (code 7) (name "Net-(R1-Pad1)") (net (code 12) (name "Net-(R1-Pad1)")
(node (ref R1) (pin 1)) (node (ref R1) (pin 1))
(node (ref U1) (pin 1)) (node (ref U1) (pin 1))
(node (ref U1) (pin 7))) (node (ref U1) (pin 7)))
(net (code 8) (name GND) (net (code 13) (name "Net-(P4-Pad1)")
(node (ref R3) (pin 2))
(node (ref C1) (pin 2))
(node (ref P1) (pin 1))
(node (ref P2) (pin 2))
(node (ref P3) (pin 2))
(node (ref R4) (pin 2))
(node (ref R2) (pin 2)))
(net (code 9) (name "Net-(P4-Pad1)")
(node (ref U1) (pin 4)) (node (ref U1) (pin 4))
(node (ref U1) (pin 5)) (node (ref P4) (pin 1))
(node (ref P4) (pin 1))))) (node (ref U1) (pin 5)))))
\ No newline at end of file \ No newline at end of file
update=07/03/2011 07:10:15 update=01/01/2015 18:35:22
last_client=cvpcb last_client=kicad
[general] [general]
version=1 version=1
RootSch=ecc83-pp.sch RootSch=ecc83-pp.sch
BoardNm=ecc83-pp.brd BoardNm=ecc83-pp.brd
[common] [common]
NetDir= NetDir=
[cvpcb]
version=1
NetIExt=.net
[cvpcb/libraries]
EquName1=devcms
[eeschema] [eeschema]
version=1 version=1
LibDir= 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
RptD_X=0
RptD_Y=100
RptLab=1
PenMin=20
SimCmd=
UseNetN=0
[eeschema/libraries] [eeschema/libraries]
LibName1=power LibName1=power
LibName2=device LibName2=device
...@@ -46,55 +21,24 @@ LibName3=conn ...@@ -46,55 +21,24 @@ LibName3=conn
LibName4=valves LibName4=valves
LibName5=linear LibName5=linear
LibName6=regul LibName6=regul
LibName7=74xx LibName7=special
LibName8=cmos4000
LibName9=adc-dac
LibName10=memory
LibName11=xilinx
LibName12=special
LibName13=microcontrollers
LibName14=microchip
LibName15=analog_switches
LibName16=motorola
LibName17=intel
LibName18=audio
LibName19=interface
LibName20=digital-audio
LibName21=philips
LibName22=display
LibName23=cypress
LibName24=siliconi
LibName25=contrib
[pcbnew] [pcbnew]
version=1 version=1
PadDrlX=760 PageLayoutDescrFile=
PadDimH=1100
PadDimV=550
BoardThickness=630
SgPcb45=1
TxtPcbV=800
TxtPcbH=600
TxtModV=600
TxtModH=600
TxtModW=120
VEgarde=100
DrawLar=150
EdgeLar=150
TxtLar=120
MSegLar=150
LastNetListRead= LastNetListRead=
[pcbnew/libraries] UseCmpFile=1
LibName1=dip_sockets PadDrill=1.9304
LibName2=valves PadDrillOvalY=1.9304
LibName3=connect PadSizeH=2.794
LibName4=discret PadSizeV=1.397
LibName5=pin_array PcbTextSizeV=2.032
LibName6=divers PcbTextSizeH=1.524
LibName7=libcms PcbTextThickness=0.3048
LibName8=display ModuleTextSizeV=1.524
LibDir= ModuleTextSizeH=1.524
[cvpcb] ModuleTextSizeThickness=0.3048
version=1 SolderMaskClearance=0.09999999999999999
NetIExt=.net SolderMaskMinWidth=0
[cvpcb/libraries] DrawSegmentWidth=0.381
EquName1=devcms BoardOutlineThickness=0.381
ModuleOutlineThickness=0.381
This diff is collapsed.
...@@ -21,6 +21,20 @@ X ~ 2 0 -200 170 U 40 40 1 1 P ...@@ -21,6 +21,20 @@ X ~ 2 0 -200 170 U 40 40 1 1 P
ENDDRAW ENDDRAW
ENDDEF ENDDEF
# #
# CONN_1
#
DEF ~CONN_1 P 0 30 N N 1 F N
F0 "P" 80 0 40 H V L CNN
F1 "CONN_1" 0 55 30 H I C CNN
F2 "" 0 0 60 H V C CNN
F3 "" 0 0 60 H V C CNN
DRAW
C 0 0 31 0 1 0 N
P 2 0 1 0 -30 0 -50 0 N
X 1 1 -150 0 100 R 60 60 1 1 P
ENDDRAW
ENDDEF
#
# CONN_2 # CONN_2
# #
DEF CONN_2 P 0 40 Y N 1 F N DEF CONN_2 P 0 40 Y N 1 F N
......
Cmp-Mod V01 Created by Cvpcb (2014-12-31 BZR 5344)-product date = 01/01/2015 18:25:40
BeginCmp
TimeStamp = /4549F4BE;
Reference = C1;
ValeurCmp = 10uF;
IdModule = discret:C2V10;
EndCmp
BeginCmp
TimeStamp = /4549F3BE;
Reference = C2;
ValeurCmp = 680nF;
IdModule = discret:CP8;
EndCmp
BeginCmp
TimeStamp = /4549F464;
Reference = P1;
ValeurCmp = IN;
IdModule = pin_array:pin_array_1x02;
EndCmp
BeginCmp
TimeStamp = /4549F46C;
Reference = P2;
ValeurCmp = OUT;
IdModule = pin_array:pin_array_1x02;
EndCmp
BeginCmp
TimeStamp = /4549F4A5;
Reference = P3;
ValeurCmp = POWER;
IdModule = pin_array:pin_array_1x02;
EndCmp
BeginCmp
TimeStamp = /456A8ACC;
Reference = P4;
ValeurCmp = CONN_2;
IdModule = pin_array:pin_array_1x02;
EndCmp
BeginCmp
TimeStamp = /54A5830A;
Reference = P5;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A58363;
Reference = P6;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A5837A;
Reference = P7;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /54A58391;
Reference = P8;
ValeurCmp = CONN_1;
IdModule = connect:1pin;
EndCmp
BeginCmp
TimeStamp = /4549F38A;
Reference = R1;
ValeurCmp = 1.5K;
IdModule = discret:R3;
EndCmp
BeginCmp
TimeStamp = /4549F39D;
Reference = R2;
ValeurCmp = 1.5K;
IdModule = discret:R3;
EndCmp
BeginCmp
TimeStamp = /4549F3AD;
Reference = R3;
ValeurCmp = 100K;
IdModule = discret:R3;
EndCmp
BeginCmp
TimeStamp = /4549F3A2;
Reference = R4;
ValeurCmp = 47K;
IdModule = discret:R3;
EndCmp
BeginCmp
TimeStamp = /48B4F266;
Reference = U1;
ValeurCmp = ECC83;
IdModule = Valves:VALVE-ECC-83-1;
EndCmp
EndListe
This diff is collapsed.
(export (version D)
(design
(source F:/kicad-launchpad/testing/demos/ecc83/ecc83-pp_v2.sch)
(date "01/01/2015 18:25:50")
(tool "Eeschema (2014-12-31 BZR 5344)-product"))
(components
(comp (ref U1)
(value ECC83)
(footprint Valves:VALVE-ECC-83-1)
(libsource (lib valves) (part ECC83))
(sheetpath (names /) (tstamps /))
(tstamp 48B4F266))
(comp (ref P4)
(value CONN_2)
(footprint pin_array:pin_array_1x02)
(libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /))
(tstamp 456A8ACC))
(comp (ref C1)
(value 10uF)
(footprint discret:C2V10)
(libsource (lib device) (part C))
(sheetpath (names /) (tstamps /))
(tstamp 4549F4BE))
(comp (ref P3)
(value POWER)
(footprint pin_array:pin_array_1x02)
(libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /))
(tstamp 4549F4A5))
(comp (ref P2)
(value OUT)
(footprint pin_array:pin_array_1x02)
(libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /))
(tstamp 4549F46C))
(comp (ref P1)
(value IN)
(footprint pin_array:pin_array_1x02)
(libsource (lib conn) (part CONN_2))
(sheetpath (names /) (tstamps /))
(tstamp 4549F464))
(comp (ref C2)
(value 680nF)
(footprint discret:CP8)
(libsource (lib device) (part C))
(sheetpath (names /) (tstamps /))
(tstamp 4549F3BE))
(comp (ref R3)
(value 100K)
(footprint discret:R3)
(libsource (lib device) (part R))
(sheetpath (names /) (tstamps /))
(tstamp 4549F3AD))
(comp (ref R4)
(value 47K)
(footprint discret:R3)
(libsource (lib device) (part R))
(sheetpath (names /) (tstamps /))
(tstamp 4549F3A2))
(comp (ref R2)
(value 1.5K)
(footprint discret:R3)
(libsource (lib device) (part R))
(sheetpath (names /) (tstamps /))
(tstamp 4549F39D))
(comp (ref R1)
(value 1.5K)
(footprint discret:R3)
(libsource (lib device) (part R))
(sheetpath (names /) (tstamps /))
(tstamp 4549F38A))
(comp (ref P5)
(value CONN_1)
(footprint connect:1pin)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A5830A))
(comp (ref P6)
(value CONN_1)
(footprint connect:1pin)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A58363))
(comp (ref P7)
(value CONN_1)
(footprint connect:1pin)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A5837A))
(comp (ref P8)
(value CONN_1)
(footprint connect:1pin)
(libsource (lib conn) (part CONN_1))
(sheetpath (names /) (tstamps /))
(tstamp 54A58391)))
(libparts
(libpart (lib device) (part C)
(description "Condensateur non polarise")
(footprints
(fp SM*)
(fp C?)
(fp C1-1))
(fields
(field (name Reference) C)
(field (name Value) C))
(pins
(pin (num 1) (name ~) (type passive))
(pin (num 2) (name ~) (type passive))))
(libpart (lib device) (part R)
(description Resistance)
(footprints
(fp R?)
(fp SM0603)
(fp SM0805)
(fp R?-*)
(fp SM1206))
(fields
(field (name Reference) R)
(field (name Value) R))
(pins
(pin (num 1) (name ~) (type passive))
(pin (num 2) (name ~) (type passive))))
(libpart (lib valves) (part ECC81)
(aliases
(alias ECC83))
(fields
(field (name Reference) U)
(field (name Value) ECC81)
(field (name Footprint) VALVE-NOVAL_P))
(pins
(pin (num 1) (name A) (type output))
(pin (num 2) (name G) (type input))
(pin (num 3) (name K) (type BiDi))
(pin (num 4) (name F1) (type power_in))
(pin (num 5) (name F1) (type power_in))
(pin (num 6) (name A) (type output))
(pin (num 7) (name G) (type input))
(pin (num 8) (name K) (type BiDi))
(pin (num 9) (name F2) (type power_in))))
(libpart (lib conn) (part CONN_1)
(description "1 pin")
(fields
(field (name Reference) P)
(field (name Value) CONN_1))
(pins
(pin (num 1) (name 1) (type passive))))
(libpart (lib conn) (part CONN_2)
(description "Symbole general de connecteur")
(fields
(field (name Reference) P)
(field (name Value) CONN_2))
(pins
(pin (num 1) (name P1) (type passive))
(pin (num 2) (name PM) (type passive)))))
(libraries
(library (logical device)
(uri f:\kicad\share\kicad\library\device.lib))
(library (logical valves)
(uri f:\kicad\share\kicad\library\valves.lib))
(library (logical conn)
(uri f:\kicad\share\kicad\library\conn.lib)))
(nets
(net (code 1) (name GND)
(node (ref R4) (pin 2))
(node (ref R3) (pin 2))
(node (ref P1) (pin 1))
(node (ref R2) (pin 2))
(node (ref P2) (pin 2))
(node (ref P3) (pin 2))
(node (ref C1) (pin 2)))
(net (code 2) (name "Net-(C1-Pad1)")
(node (ref P3) (pin 1))
(node (ref C1) (pin 1))
(node (ref U1) (pin 6)))
(net (code 3) (name "Net-(P8-Pad1)")
(node (ref P8) (pin 1)))
(net (code 4) (name "Net-(P7-Pad1)")
(node (ref P7) (pin 1)))
(net (code 5) (name "Net-(P6-Pad1)")
(node (ref P6) (pin 1)))
(net (code 6) (name "Net-(P5-Pad1)")
(node (ref P5) (pin 1)))
(net (code 7) (name "Net-(R2-Pad1)")
(node (ref R2) (pin 1))
(node (ref U1) (pin 3)))
(net (code 8) (name "Net-(C2-Pad2)")
(node (ref C2) (pin 2))
(node (ref R1) (pin 2))
(node (ref U1) (pin 8)))
(net (code 9) (name "Net-(C2-Pad1)")
(node (ref C2) (pin 1))
(node (ref R3) (pin 1))
(node (ref P2) (pin 1)))
(net (code 10) (name "Net-(P4-Pad2)")
(node (ref U1) (pin 9))
(node (ref P4) (pin 2)))
(net (code 11) (name "Net-(P1-Pad2)")
(node (ref U1) (pin 2))
(node (ref R4) (pin 1))
(node (ref P1) (pin 2)))
(net (code 12) (name "Net-(R1-Pad1)")
(node (ref R1) (pin 1))
(node (ref U1) (pin 1))
(node (ref U1) (pin 7)))
(net (code 13) (name "Net-(P4-Pad1)")
(node (ref U1) (pin 4))
(node (ref U1) (pin 5))
(node (ref P4) (pin 1)))))
\ No newline at end of file
update=04/07/2014 20:10:13 update=01/01/2015 18:33:52
last_client=kicad last_client=kicad
[general] [general]
version=1 version=1
RootSch=ecc83-pp.sch RootSch=ecc83-pp.sch
BoardNm=ecc83-pp.brd BoardNm=ecc83-pp.brd
[eeschema]
version=1
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
RptD_X=0
RptD_Y=100
RptLab=1
PenMin=20
SimCmd=
UseNetN=0
[eeschema/libraries]
LibName1=power
LibName2=device
LibName3=valves
LibName4=conn
LibName5=linear
LibName6=regul
LibName7=74xx
LibName8=cmos4000
LibName9=adc-dac
LibName10=memory
LibName11=xilinx
LibName12=special
LibName13=microcontrollers
LibName14=microchip
LibName15=analog_switches
LibName16=motorola
LibName17=intel
LibName18=audio
LibName19=interface
LibName20=digital-audio
LibName21=philips
LibName22=display
LibName23=cypress
LibName24=siliconi
LibName25=contrib
[pcbnew] [pcbnew]
version=1 version=1
PageLayoutDescrFile= PageLayoutDescrFile=
...@@ -83,3 +24,13 @@ SolderMaskMinWidth=0 ...@@ -83,3 +24,13 @@ SolderMaskMinWidth=0
DrawSegmentWidth=0.381 DrawSegmentWidth=0.381
BoardOutlineThickness=0.381 BoardOutlineThickness=0.381
ModuleOutlineThickness=0.381 ModuleOutlineThickness=0.381
[eeschema]
version=1
LibDir=
[eeschema/libraries]
LibName1=power
LibName2=device
LibName3=valves
LibName4=conn
LibName5=linear
LibName6=regul
...@@ -25,7 +25,7 @@ LIBS:cypress ...@@ -25,7 +25,7 @@ LIBS:cypress
LIBS:siliconi LIBS:siliconi
LIBS:contrib LIBS:contrib
LIBS:ecc83-pp_v2-cache LIBS:ecc83-pp_v2-cache
EELAYER 24 0 EELAYER 25 0
EELAYER END EELAYER END
$Descr A4 11693 8268 $Descr A4 11693 8268
encoding utf-8 encoding utf-8
...@@ -105,7 +105,7 @@ U 3 1 48B4F266 ...@@ -105,7 +105,7 @@ U 3 1 48B4F266
P 2000 6100 P 2000 6100
F 0 "U1" H 2130 6410 50 0000 C CNN F 0 "U1" H 2130 6410 50 0000 C CNN
F 1 "ECC83" H 2350 5800 50 0000 C CNN F 1 "ECC83" H 2350 5800 50 0000 C CNN
F 2 "ECC-83-1" H 2450 5650 50 0000 C CNN F 2 "Valves:VALVE-ECC-83-1" H 2450 5650 50 0000 C CNN
F 3 "" H 2000 6100 60 0001 C CNN F 3 "" H 2000 6100 60 0001 C CNN
3 2000 6100 3 2000 6100
1 0 0 -1 1 0 0 -1
...@@ -116,7 +116,7 @@ U 2 1 48B4F263 ...@@ -116,7 +116,7 @@ U 2 1 48B4F263
P 4950 4450 P 4950 4450
F 0 "U1" H 5080 4760 50 0000 C CNN F 0 "U1" H 5080 4760 50 0000 C CNN
F 1 "ECC83" H 5150 4100 50 0000 C CNN F 1 "ECC83" H 5150 4100 50 0000 C CNN
F 2 "ECC-83-1" H 5150 4000 50 0000 C CNN F 2 "Valves:VALVE-ECC-83-1" H 5150 4000 50 0000 C CNN
F 3 "" H 4950 4450 60 0001 C CNN F 3 "" H 4950 4450 60 0001 C CNN
2 4950 4450 2 4950 4450
1 0 0 -1 1 0 0 -1
...@@ -127,7 +127,7 @@ U 1 1 48B4F256 ...@@ -127,7 +127,7 @@ U 1 1 48B4F256
P 5750 4450 P 5750 4450
F 0 "U1" H 5880 4760 50 0000 C CNN F 0 "U1" H 5880 4760 50 0000 C CNN
F 1 "ECC83" H 5500 4150 50 0000 C CNN F 1 "ECC83" H 5500 4150 50 0000 C CNN
F 2 "ECC-83-1" H 5750 3950 50 0000 C CNN F 2 "Valves:VALVE-ECC-83-1" H 5750 3950 50 0000 C CNN
F 3 "" H 5750 4450 60 0001 C CNN F 3 "" H 5750 4450 60 0001 C CNN
1 5750 4450 1 5750 4450
-1 0 0 -1 -1 0 0 -1
...@@ -193,7 +193,7 @@ U 1 1 456A8ACC ...@@ -193,7 +193,7 @@ U 1 1 456A8ACC
P 2000 7100 P 2000 7100
F 0 "P4" V 1950 7100 40 0000 C CNN F 0 "P4" V 1950 7100 40 0000 C CNN
F 1 "CONN_2" V 2050 7100 40 0000 C CNN F 1 "CONN_2" V 2050 7100 40 0000 C CNN
F 2 "BORNIER2" V 2150 7100 60 0000 C CNN F 2 "pin_array:pin_array_1x02" V 2150 7100 60 0000 C CNN
F 3 "" H 2000 7100 60 0001 C CNN F 3 "" H 2000 7100 60 0001 C CNN
1 2000 7100 1 2000 7100
0 1 1 0 0 1 1 0
...@@ -204,7 +204,7 @@ U 1 1 4549F4BE ...@@ -204,7 +204,7 @@ U 1 1 4549F4BE
P 6700 4050 P 6700 4050
F 0 "C1" H 6750 4150 50 0000 L CNN F 0 "C1" H 6750 4150 50 0000 L CNN
F 1 "10uF" H 6450 4150 50 0000 L CNN F 1 "10uF" H 6450 4150 50 0000 L CNN
F 2 "C2V10" H 6700 4050 60 0000 C CNN F 2 "discret:C2V10" H 6700 4050 60 0000 C CNN
F 3 "" H 6700 4050 60 0001 C CNN F 3 "" H 6700 4050 60 0001 C CNN
1 6700 4050 1 6700 4050
1 0 0 -1 1 0 0 -1
...@@ -237,7 +237,7 @@ U 1 1 4549F4A5 ...@@ -237,7 +237,7 @@ U 1 1 4549F4A5
P 7300 3950 P 7300 3950
F 0 "P3" V 7250 3950 40 0000 C CNN F 0 "P3" V 7250 3950 40 0000 C CNN
F 1 "POWER" V 7350 3950 40 0000 C CNN F 1 "POWER" V 7350 3950 40 0000 C CNN
F 2 "BORNIER2" H 7300 4150 60 0000 C CNN F 2 "pin_array:pin_array_1x02" H 7300 4150 60 0000 C CNN
F 3 "" H 7300 3950 60 0001 C CNN F 3 "" H 7300 3950 60 0001 C CNN
1 7300 3950 1 7300 3950
1 0 0 -1 1 0 0 -1
...@@ -248,7 +248,7 @@ U 1 1 4549F46C ...@@ -248,7 +248,7 @@ U 1 1 4549F46C
P 7300 4900 P 7300 4900
F 0 "P2" V 7250 4900 40 0000 C CNN F 0 "P2" V 7250 4900 40 0000 C CNN
F 1 "OUT" V 7350 4900 40 0000 C CNN F 1 "OUT" V 7350 4900 40 0000 C CNN
F 2 "BORNIER2" H 7300 5100 60 0000 C CNN F 2 "pin_array:pin_array_1x02" H 7300 5100 60 0000 C CNN
F 3 "" H 7300 4900 60 0001 C CNN F 3 "" H 7300 4900 60 0001 C CNN
1 7300 4900 1 7300 4900
1 0 0 -1 1 0 0 -1
...@@ -259,7 +259,7 @@ U 1 1 4549F464 ...@@ -259,7 +259,7 @@ U 1 1 4549F464
P 3800 4900 P 3800 4900
F 0 "P1" V 3750 4900 40 0000 C CNN F 0 "P1" V 3750 4900 40 0000 C CNN
F 1 "IN" V 3850 4900 40 0000 C CNN F 1 "IN" V 3850 4900 40 0000 C CNN
F 2 "BORNIER2" H 3750 4700 60 0000 C CNN F 2 "pin_array:pin_array_1x02" H 3750 4700 60 0000 C CNN
F 3 "" H 3800 4900 60 0001 C CNN F 3 "" H 3800 4900 60 0001 C CNN
1 3800 4900 1 3800 4900
-1 0 0 1 -1 0 0 1
...@@ -270,7 +270,7 @@ U 1 1 4549F3BE ...@@ -270,7 +270,7 @@ U 1 1 4549F3BE
P 6500 4800 P 6500 4800
F 0 "C2" H 6550 4900 50 0000 L CNN F 0 "C2" H 6550 4900 50 0000 L CNN
F 1 "680nF" H 6550 4700 50 0000 L CNN F 1 "680nF" H 6550 4700 50 0000 L CNN
F 2 "CP8" H 6400 4900 60 0000 C CNN F 2 "discret:CP8" H 6400 4900 60 0000 C CNN
F 3 "" H 6500 4800 60 0001 C CNN F 3 "" H 6500 4800 60 0001 C CNN
1 6500 4800 1 6500 4800
0 1 1 0 0 1 1 0
...@@ -281,7 +281,7 @@ U 1 1 4549F3AD ...@@ -281,7 +281,7 @@ U 1 1 4549F3AD
P 6700 5650 P 6700 5650
F 0 "R3" V 6780 5650 50 0000 C CNN F 0 "R3" V 6780 5650 50 0000 C CNN
F 1 "100K" V 6700 5650 50 0000 C CNN F 1 "100K" V 6700 5650 50 0000 C CNN
F 2 "R3" H 6700 5650 60 0000 C CNN F 2 "discret:R3" H 6700 5650 60 0000 C CNN
F 3 "" H 6700 5650 60 0001 C CNN F 3 "" H 6700 5650 60 0001 C CNN
1 6700 5650 1 6700 5650
1 0 0 -1 1 0 0 -1
...@@ -292,7 +292,7 @@ U 1 1 4549F3A2 ...@@ -292,7 +292,7 @@ U 1 1 4549F3A2
P 4450 5650 P 4450 5650
F 0 "R4" V 4530 5650 50 0000 C CNN F 0 "R4" V 4530 5650 50 0000 C CNN
F 1 "47K" V 4450 5650 50 0000 C CNN F 1 "47K" V 4450 5650 50 0000 C CNN
F 2 "R3" V 4350 5650 60 0000 C CNN F 2 "discret:R3" V 4350 5650 60 0000 C CNN
F 3 "" H 4450 5650 60 0001 C CNN F 3 "" H 4450 5650 60 0001 C CNN
1 4450 5650 1 4450 5650
1 0 0 -1 1 0 0 -1
...@@ -303,7 +303,7 @@ U 1 1 4549F39D ...@@ -303,7 +303,7 @@ U 1 1 4549F39D
P 4850 5650 P 4850 5650
F 0 "R2" V 4930 5650 50 0000 C CNN F 0 "R2" V 4930 5650 50 0000 C CNN
F 1 "1.5K" V 4850 5650 50 0000 C CNN F 1 "1.5K" V 4850 5650 50 0000 C CNN
F 2 "R3" V 4756 5656 60 0000 C CNN F 2 "discret:R3" V 4756 5656 60 0000 C CNN
F 3 "" H 4850 5650 60 0001 C CNN F 3 "" H 4850 5650 60 0001 C CNN
1 4850 5650 1 4850 5650
1 0 0 -1 1 0 0 -1
...@@ -314,9 +314,57 @@ U 1 1 4549F38A ...@@ -314,9 +314,57 @@ U 1 1 4549F38A
P 6300 4250 P 6300 4250
F 0 "R1" V 6380 4250 50 0000 C CNN F 0 "R1" V 6380 4250 50 0000 C CNN
F 1 "1.5K" V 6300 4250 50 0000 C CNN F 1 "1.5K" V 6300 4250 50 0000 C CNN
F 2 "R3" H 6400 4150 60 0000 C CNN F 2 "discret:R3" H 6400 4150 60 0000 C CNN
F 3 "" H 6300 4250 60 0001 C CNN F 3 "" H 6300 4250 60 0001 C CNN
1 6300 4250 1 6300 4250
1 0 0 -1 1 0 0 -1
$EndComp $EndComp
$Comp
L CONN_1 P5
U 1 1 54A5830A
P 6300 6600
F 0 "P5" H 6380 6600 40 0000 L CNN
F 1 "CONN_1" H 6300 6655 30 0001 C CNN
F 2 "connect:1pin" H 6300 6600 60 0001 C CNN
F 3 "" H 6300 6600 60 0000 C CNN
1 6300 6600
1 0 0 -1
$EndComp
$Comp
L CONN_1 P6
U 1 1 54A58363
P 6300 6700
F 0 "P6" H 6380 6700 40 0000 L CNN
F 1 "CONN_1" H 6300 6755 30 0001 C CNN
F 2 "connect:1pin" H 6300 6700 60 0001 C CNN
F 3 "" H 6300 6700 60 0000 C CNN
1 6300 6700
1 0 0 -1
$EndComp
$Comp
L CONN_1 P7
U 1 1 54A5837A
P 6300 6800
F 0 "P7" H 6380 6800 40 0000 L CNN
F 1 "CONN_1" H 6300 6855 30 0001 C CNN
F 2 "connect:1pin" H 6300 6800 60 0001 C CNN
F 3 "" H 6300 6800 60 0000 C CNN
1 6300 6800
1 0 0 -1
$EndComp
$Comp
L CONN_1 P8
U 1 1 54A58391
P 6300 6900
F 0 "P8" H 6380 6900 40 0000 L CNN
F 1 "CONN_1" H 6300 6955 30 0001 C CNN
F 2 "connect:1pin" H 6300 6900 60 0001 C CNN
F 3 "" H 6300 6900 60 0000 C CNN
1 6300 6900
1 0 0 -1
$EndComp
NoConn ~ 6150 6600
NoConn ~ 6150 6700
NoConn ~ 6150 6800
NoConn ~ 6150 6900
$EndSCHEMATC $EndSCHEMATC
(fp_lib_table
(lib (name Valves)(type KiCad)(uri ${KISYSMOD}/Valves.pretty)(options "")(descr ""))
)
...@@ -479,16 +479,11 @@ bool SCH_EDIT_FRAME::LoadProjectFile() ...@@ -479,16 +479,11 @@ bool SCH_EDIT_FRAME::LoadProjectFile()
// Load the page layout decr file, from the filename stored in // Load the page layout decr file, from the filename stored in
// BASE_SCREEN::m_PageLayoutDescrFileName, read in config project file // BASE_SCREEN::m_PageLayoutDescrFileName, read in config project file
// If empty, the default descr is loaded // If empty, or not existing, the default descr is loaded
WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance(); WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance();
wxString pg_fullfilename = ExpandEnvVarSubstitutions( BASE_SCREEN::m_PageLayoutDescrFileName ); wxString pg_fullfilename = WORKSHEET_LAYOUT::MakeFullFileName(
BASE_SCREEN::m_PageLayoutDescrFileName,
if( !pg_fullfilename.IsEmpty() ) Prj().GetProjectPath() );
{
// When the page layout filename is not absolute, therefore
// relative to the current project, make it absolute
pg_fullfilename = Prj().AbsolutePath( pg_fullfilename );
}
pglayout.SetPageLayout( pg_fullfilename ); pglayout.SetPageLayout( pg_fullfilename );
......
...@@ -550,11 +550,15 @@ public: ...@@ -550,11 +550,15 @@ public:
* static function: returns the instance of WORKSHEET_LAYOUT * static function: returns the instance of WORKSHEET_LAYOUT
* used in the application * used in the application
*/ */
static WORKSHEET_LAYOUT& GetTheInstance() static WORKSHEET_LAYOUT& GetTheInstance();
{
extern WORKSHEET_LAYOUT wksTheInstance; /**
return wksTheInstance; * static function: Set an alternate instance of WORKSHEET_LAYOUT
} * mainly used in page setting dialog
* @param aLayout = the alternate page layout.
* if null, restore the basic page layout
*/
static void SetAltInstance( WORKSHEET_LAYOUT* aLayout = NULL );
// Accessors: // Accessors:
double GetLeftMargin() { return m_leftMargin; } double GetLeftMargin() { return m_leftMargin; }
...@@ -664,19 +668,28 @@ public: ...@@ -664,19 +668,28 @@ public:
/** /**
* @return a short filename from a full filename: * @return a short filename from a full filename:
* if the path is the current path, or if the path * if the path is the current project path, or if the path
* is the same as kicad.pro (in template), returns the shortname * is the same as kicad.pro (in template), returns the shortname
* else do nothing and returns a full filename * else do nothing and returns a full filename
* @param aFullFileName = the full filename, which can be a relative
* @param aProjectPath = the curr project absolute path (can be empty)
*/ */
static const wxString MakeShortFileName( const wxString& aFullFileName ); static const wxString MakeShortFileName( const wxString& aFullFileName,
const wxString& aProjectPath );
/** /**
* @return a full filename from a short filename, * Static function
* if the short filename path is void * @return a full filename from a short filename.
* In this case the path is the same as kicad.pro (in template) * @param aShortFileName = the short filename, which can be a relative
* else return the short filename (which have an absolute os relative path * @param aProjectPath = the curr project absolute path (can be empty)
*/ * or absolute path, and can include env variable reference ( ${envvar} expression )
static const wxString MakeFullFileName( const wxString& aShortFileName ); * if the short filename path is relative, it is expected relative to the project path
* or (if aProjectPath is empty or if the file does not exist)
* relative to kicad.pro (in template)
* If aShortFileName is absolute return aShortFileName
*/
static const wxString MakeFullFileName( const wxString& aShortFileName,
const wxString& aProjectPath );
}; };
#endif // WORKSHEET_SHAPE_BUILDER_H #endif // WORKSHEET_SHAPE_BUILDER_H
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Nov 5 2013) // C++ code generated with wxFormBuilder (version Jun 5 2014)
// http://www.wxformbuilder.org/ // http://www.wxformbuilder.org/
// //
// PLEASE DO "NOT" EDIT THIS FILE! // PLEASE DO "NOT" EDIT THIS FILE!
...@@ -166,7 +166,7 @@ PCB_CALCULATOR_FRAME_BASE::PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindow ...@@ -166,7 +166,7 @@ PCB_CALCULATOR_FRAME_BASE::PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindow
m_staticTextRegType = new wxStaticText( m_panelRegulators, wxID_ANY, _("Type"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextRegType = new wxStaticText( m_panelRegulators, wxID_ANY, _("Type"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticTextRegType->Wrap( -1 ); m_staticTextRegType->Wrap( -1 );
m_staticTextRegType->SetToolTip( _("Type of the regulator.\nThere are 2 types:\n- regulators which have a dedicted sense pin for the voltage regulation.\n- 3 terminal pins.") ); m_staticTextRegType->SetToolTip( _("Type of the regulator.\nThere are 2 types:\n- regulators which have a dedicated sense pin for the voltage regulation.\n- 3 terminal pins.") );
fgSizerRegParams->Add( m_staticTextRegType, 0, wxALL, 5 ); fgSizerRegParams->Add( m_staticTextRegType, 0, wxALL, 5 );
...@@ -1232,7 +1232,7 @@ PCB_CALCULATOR_FRAME_BASE::PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindow ...@@ -1232,7 +1232,7 @@ PCB_CALCULATOR_FRAME_BASE::PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindow
wxArrayString m_BoardClassesUnitsSelectorChoices; wxArrayString m_BoardClassesUnitsSelectorChoices;
m_BoardClassesUnitsSelector = new UNIT_SELECTOR_LEN( m_panelBoardClass, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_BoardClassesUnitsSelectorChoices, 0 ); m_BoardClassesUnitsSelector = new UNIT_SELECTOR_LEN( m_panelBoardClass, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_BoardClassesUnitsSelectorChoices, 0 );
m_BoardClassesUnitsSelector->SetSelection( -1 ); m_BoardClassesUnitsSelector->SetSelection( 0 );
bSizerBoardClass->Add( m_BoardClassesUnitsSelector, 0, wxALL, 5 ); bSizerBoardClass->Add( m_BoardClassesUnitsSelector, 0, wxALL, 5 );
wxBoxSizer* brdclsSizerRight; wxBoxSizer* brdclsSizerRight;
......
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<wxFormBuilder_Project> <wxFormBuilder_Project>
<FileVersion major="1" minor="11" /> <FileVersion major="1" minor="13" />
<object class="Project" expanded="1"> <object class="Project" expanded="1">
<property name="class_decoration"></property> <property name="class_decoration"></property>
<property name="code_generation">C++</property> <property name="code_generation">C++</property>
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="name">PCB_CALCULATOR_FRAME_BASE</property> <property name="name">PCB_CALCULATOR_FRAME_BASE</property>
<property name="pos"></property> <property name="pos"></property>
<property name="size">670,489</property> <property name="size">702,489</property>
<property name="style">wxDEFAULT_FRAME_STYLE|wxRESIZE_BORDER</property> <property name="style">wxDEFAULT_FRAME_STYLE|wxRESIZE_BORDER</property>
<property name="subclass">KIWAY_PLAYER; kiway_player.h</property> <property name="subclass">KIWAY_PLAYER; kiway_player.h</property>
<property name="title">PCB Calculator</property> <property name="title">PCB Calculator</property>
...@@ -2308,7 +2308,7 @@ ...@@ -2308,7 +2308,7 @@
<property name="style"></property> <property name="style"></property>
<property name="subclass"></property> <property name="subclass"></property>
<property name="toolbar_pane">0</property> <property name="toolbar_pane">0</property>
<property name="tooltip">Type of the regulator.&#x0A;There are 2 types:&#x0A;- regulators which have a dedicted sense pin for the voltage regulation.&#x0A;- 3 terminal pins.</property> <property name="tooltip">Type of the regulator.&#x0A;There are 2 types:&#x0A;- regulators which have a dedicated sense pin for the voltage regulation.&#x0A;- 3 terminal pins.</property>
<property name="window_extra_style"></property> <property name="window_extra_style"></property>
<property name="window_name"></property> <property name="window_name"></property>
<property name="window_style"></property> <property name="window_style"></property>
...@@ -18263,7 +18263,7 @@ ...@@ -18263,7 +18263,7 @@
<property name="pin_button">1</property> <property name="pin_button">1</property>
<property name="pos"></property> <property name="pos"></property>
<property name="resize">Resizable</property> <property name="resize">Resizable</property>
<property name="selection">-1</property> <property name="selection">0</property>
<property name="show">1</property> <property name="show">1</property>
<property name="size"></property> <property name="size"></property>
<property name="style"></property> <property name="style"></property>
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Nov 5 2013) // C++ code generated with wxFormBuilder (version Jun 5 2014)
// http://www.wxformbuilder.org/ // http://www.wxformbuilder.org/
// //
// PLEASE DO "NOT" EDIT THIS FILE! // PLEASE DO "NOT" EDIT THIS FILE!
...@@ -293,7 +293,7 @@ class PCB_CALCULATOR_FRAME_BASE : public KIWAY_PLAYER ...@@ -293,7 +293,7 @@ class PCB_CALCULATOR_FRAME_BASE : public KIWAY_PLAYER
public: public:
PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("PCB Calculator"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 670,489 ), long style = wxDEFAULT_FRAME_STYLE|wxRESIZE_BORDER|wxFULL_REPAINT_ON_RESIZE|wxTAB_TRAVERSAL ); PCB_CALCULATOR_FRAME_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("PCB Calculator"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 702,489 ), long style = wxDEFAULT_FRAME_STYLE|wxRESIZE_BORDER|wxFULL_REPAINT_ON_RESIZE|wxTAB_TRAVERSAL );
~PCB_CALCULATOR_FRAME_BASE(); ~PCB_CALCULATOR_FRAME_BASE();
......
...@@ -157,7 +157,7 @@ void PCB_CALCULATOR_FRAME::OnClosePcbCalc( wxCloseEvent& event ) ...@@ -157,7 +157,7 @@ void PCB_CALCULATOR_FRAME::OnClosePcbCalc( wxCloseEvent& event )
msg.Printf( _("Unable to write file<%s>\n"\ msg.Printf( _("Unable to write file<%s>\n"\
"Do you want to exit and abandon your change?"), GetDataFilename().c_str() ); "Do you want to exit and abandon your change?"), GetDataFilename().c_str() );
int opt = wxMessageBox( msg, _("Write Data File Errror"), int opt = wxMessageBox( msg, _("Write Data File Error"),
wxYES_NO | wxICON_QUESTION ); wxYES_NO | wxICON_QUESTION );
if( opt == wxNO ) if( opt == wxNO )
return; return;
......
...@@ -120,6 +120,7 @@ set( PCBNEW_DIALOGS ...@@ -120,6 +120,7 @@ set( PCBNEW_DIALOGS
dialogs/dialog_SVG_print_base.cpp dialogs/dialog_SVG_print_base.cpp
dialogs/dialog_select_pretty_lib.cpp dialogs/dialog_select_pretty_lib.cpp
dialogs/dialog_select_pretty_lib_base.cpp dialogs/dialog_select_pretty_lib_base.cpp
dialogs/dialog_select_dirlist_base.cpp
dialogs/dialog_set_grid.cpp dialogs/dialog_set_grid.cpp
dialogs/dialog_set_grid_base.cpp dialogs/dialog_set_grid_base.cpp
dialogs/dialog_target_properties_base.cpp dialogs/dialog_target_properties_base.cpp
......
...@@ -33,5 +33,9 @@ ...@@ -33,5 +33,9 @@
<key>LSRequiresCarbon</key> <true/> <key>LSRequiresCarbon</key> <true/>
<key>NSHumanReadableCopyright</key> <string></string> <key>NSHumanReadableCopyright</key> <string></string>
<key>NSHighResolutionCapable</key> <string>True</string> <key>NSHighResolutionCapable</key> <string>True</string>
<key>LSEnvironment</key>
<dict>
<key>KIGITHUB</key> <string>https://github.com/kicad</string>
</dict>
</dict> </dict>
</plist> </plist>
...@@ -295,6 +295,10 @@ public: ...@@ -295,6 +295,10 @@ public:
m_global( aGlobal ), m_global( aGlobal ),
m_project( aProject ) m_project( aProject )
{ {
// For user info, shows the table filenames:
m_PrjTableFilename->SetLabel( Prj().FootprintLibTblName() );
m_GblTableFilename->SetLabel( FP_LIB_TABLE::GetGlobalTableFileName() );
// wxGrid only supports user owned tables if they exist past end of ~wxGrid(), // wxGrid only supports user owned tables if they exist past end of ~wxGrid(),
// so make it a grid owned table. // so make it a grid owned table.
m_global_grid->SetTable( new FP_TBL_MODEL( *aGlobal ), true ); m_global_grid->SetTable( new FP_TBL_MODEL( *aGlobal ), true );
......
...@@ -24,6 +24,22 @@ DIALOG_FP_LIB_TABLE_BASE::DIALOG_FP_LIB_TABLE_BASE( wxWindow* parent, wxWindowID ...@@ -24,6 +24,22 @@ DIALOG_FP_LIB_TABLE_BASE::DIALOG_FP_LIB_TABLE_BASE( wxWindow* parent, wxWindowID
wxBoxSizer* m_global_sizer; wxBoxSizer* m_global_sizer;
m_global_sizer = new wxBoxSizer( wxVERTICAL ); m_global_sizer = new wxBoxSizer( wxVERTICAL );
wxFlexGridSizer* fgSizer1;
fgSizer1 = new wxFlexGridSizer( 1, 2, 0, 0 );
fgSizer1->SetFlexibleDirection( wxBOTH );
fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_staticText3 = new wxStaticText( m_global_panel, wxID_ANY, _("Table:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText3->Wrap( -1 );
fgSizer1->Add( m_staticText3, 0, wxRIGHT|wxLEFT, 5 );
m_GblTableFilename = new wxStaticText( m_global_panel, wxID_ANY, _("Table Name"), wxDefaultPosition, wxDefaultSize, 0 );
m_GblTableFilename->Wrap( -1 );
fgSizer1->Add( m_GblTableFilename, 0, wxRIGHT|wxLEFT, 5 );
m_global_sizer->Add( fgSizer1, 0, wxEXPAND, 5 );
m_global_grid = new wxGrid( m_global_panel, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 ); m_global_grid = new wxGrid( m_global_panel, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
// Grid // Grid
...@@ -60,6 +76,22 @@ DIALOG_FP_LIB_TABLE_BASE::DIALOG_FP_LIB_TABLE_BASE( wxWindow* parent, wxWindowID ...@@ -60,6 +76,22 @@ DIALOG_FP_LIB_TABLE_BASE::DIALOG_FP_LIB_TABLE_BASE( wxWindow* parent, wxWindowID
wxBoxSizer* m_project_sizer; wxBoxSizer* m_project_sizer;
m_project_sizer = new wxBoxSizer( wxVERTICAL ); m_project_sizer = new wxBoxSizer( wxVERTICAL );
wxFlexGridSizer* fgSizer2;
fgSizer2 = new wxFlexGridSizer( 1, 2, 0, 0 );
fgSizer2->SetFlexibleDirection( wxBOTH );
fgSizer2->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_staticText4 = new wxStaticText( m_project_panel, wxID_ANY, _("Table:"), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText4->Wrap( -1 );
fgSizer2->Add( m_staticText4, 0, wxRIGHT|wxLEFT, 5 );
m_PrjTableFilename = new wxStaticText( m_project_panel, wxID_ANY, _("Table Name"), wxDefaultPosition, wxDefaultSize, 0 );
m_PrjTableFilename->Wrap( -1 );
fgSizer2->Add( m_PrjTableFilename, 0, wxRIGHT|wxLEFT, 5 );
m_project_sizer->Add( fgSizer2, 0, wxEXPAND, 5 );
m_project_grid = new wxGrid( m_project_panel, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 ); m_project_grid = new wxGrid( m_project_panel, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
// Grid // Grid
......
This diff is collapsed.
...@@ -14,13 +14,14 @@ ...@@ -14,13 +14,14 @@
class DIALOG_SHIM; class DIALOG_SHIM;
#include "dialog_shim.h" #include "dialog_shim.h"
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/string.h> #include <wx/string.h>
#include <wx/font.h> #include <wx/stattext.h>
#include <wx/grid.h>
#include <wx/gdicmn.h> #include <wx/gdicmn.h>
#include <wx/font.h>
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/sizer.h> #include <wx/sizer.h>
#include <wx/grid.h>
#include <wx/panel.h> #include <wx/panel.h>
#include <wx/bitmap.h> #include <wx/bitmap.h>
#include <wx/image.h> #include <wx/image.h>
...@@ -43,8 +44,12 @@ class DIALOG_FP_LIB_TABLE_BASE : public DIALOG_SHIM ...@@ -43,8 +44,12 @@ class DIALOG_FP_LIB_TABLE_BASE : public DIALOG_SHIM
protected: protected:
wxAuiNotebook* m_auinotebook; wxAuiNotebook* m_auinotebook;
wxPanel* m_global_panel; wxPanel* m_global_panel;
wxStaticText* m_staticText3;
wxStaticText* m_GblTableFilename;
wxGrid* m_global_grid; wxGrid* m_global_grid;
wxPanel* m_project_panel; wxPanel* m_project_panel;
wxStaticText* m_staticText4;
wxStaticText* m_PrjTableFilename;
wxGrid* m_project_grid; wxGrid* m_project_grid;
wxButton* m_append_button; wxButton* m_append_button;
wxButton* m_buttonWizard; wxButton* m_buttonWizard;
......
...@@ -42,8 +42,8 @@ DIALOG_FREEROUTE_BASE::DIALOG_FREEROUTE_BASE( wxWindow* parent, wxWindowID id, c ...@@ -42,8 +42,8 @@ DIALOG_FREEROUTE_BASE::DIALOG_FREEROUTE_BASE( wxWindow* parent, wxWindowID id, c
bLeftButtonsSizer->Add( m_ExportDSN, 0, wxALL|wxEXPAND, 5 ); bLeftButtonsSizer->Add( m_ExportDSN, 0, wxALL|wxEXPAND, 5 );
m_buttonLaunchFreeroute = new wxButton( this, wxID_BUTTON_LAUNCH, _("Launch FreeRouter and Launch FreeRouter"), wxDefaultPosition, wxDefaultSize, 0 ); m_buttonLaunchFreeroute = new wxButton( this, wxID_BUTTON_LAUNCH, _("Export a Specctra Design and Launch FreeRoute"), wxDefaultPosition, wxDefaultSize, 0 );
m_buttonLaunchFreeroute->SetToolTip( _("Use Java Web Start function to run FreeRouter via Internet (or your Browser if not found)") ); m_buttonLaunchFreeroute->SetToolTip( _("FreeRouter can be run only if freeroute.jar is found in Kicad binaries folder") );
bLeftButtonsSizer->Add( m_buttonLaunchFreeroute, 0, wxALL|wxEXPAND, 5 ); bLeftButtonsSizer->Add( m_buttonLaunchFreeroute, 0, wxALL|wxEXPAND, 5 );
......
...@@ -343,7 +343,7 @@ ...@@ -343,7 +343,7 @@
<property name="gripper">0</property> <property name="gripper">0</property>
<property name="hidden">0</property> <property name="hidden">0</property>
<property name="id">wxID_BUTTON_LAUNCH</property> <property name="id">wxID_BUTTON_LAUNCH</property>
<property name="label">Launch FreeRouter and Launch FreeRouter</property> <property name="label">Export a Specctra Design and Launch FreeRoute</property>
<property name="max_size"></property> <property name="max_size"></property>
<property name="maximize_button">0</property> <property name="maximize_button">0</property>
<property name="maximum_size"></property> <property name="maximum_size"></property>
...@@ -364,7 +364,7 @@ ...@@ -364,7 +364,7 @@
<property name="style"></property> <property name="style"></property>
<property name="subclass"></property> <property name="subclass"></property>
<property name="toolbar_pane">0</property> <property name="toolbar_pane">0</property>
<property name="tooltip">Use Java Web Start function to run FreeRouter via Internet (or your Browser if not found)</property> <property name="tooltip">FreeRouter can be run only if freeroute.jar is found in Kicad binaries folder</property>
<property name="validator_data_type"></property> <property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property> <property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property> <property name="validator_type">wxDefaultValidator</property>
......
...@@ -16,7 +16,7 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind ...@@ -16,7 +16,7 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind
wxBoxSizer* bSizerMain; wxBoxSizer* bSizerMain;
bSizerMain = new wxBoxSizer( wxVERTICAL ); bSizerMain = new wxBoxSizer( wxVERTICAL );
m_staticText = new wxStaticText( this, wxID_ANY, _("The footprint library is a folde.\nFootprints are files inside this folder."), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText = new wxStaticText( this, wxID_ANY, _("The footprint library is a folder.\nFootprints are files inside this folder."), wxDefaultPosition, wxDefaultSize, 0 );
m_staticText->Wrap( -1 ); m_staticText->Wrap( -1 );
m_staticText->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 92, false, wxEmptyString ) ); m_staticText->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 92, false, wxEmptyString ) );
...@@ -25,10 +25,12 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind ...@@ -25,10 +25,12 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind
m_dirCtrl = new wxGenericDirCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxDIRCTRL_3D_INTERNAL|wxDIRCTRL_DIR_ONLY|wxDIRCTRL_MULTIPLE|wxDIRCTRL_SHOW_FILTERS|wxSUNKEN_BORDER, _("*.pretty|*"), 0 ); m_dirCtrl = new wxGenericDirCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxDIRCTRL_3D_INTERNAL|wxDIRCTRL_DIR_ONLY|wxDIRCTRL_MULTIPLE|wxDIRCTRL_SHOW_FILTERS|wxSUNKEN_BORDER, _("*.pretty|*"), 0 );
m_dirCtrl->ShowHidden( false ); m_dirCtrl->ShowHidden( false );
m_dirCtrl->SetMinSize( wxSize( 400,350 ) );
bSizerMain->Add( m_dirCtrl, 1, wxEXPAND | wxALL, 5 ); bSizerMain->Add( m_dirCtrl, 1, wxEXPAND | wxALL, 5 );
m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); m_staticline = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
bSizerMain->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 ); bSizerMain->Add( m_staticline, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
m_sdbSizer = new wxStdDialogButtonSizer(); m_sdbSizer = new wxStdDialogButtonSizer();
m_sdbSizerOK = new wxButton( this, wxID_OK ); m_sdbSizerOK = new wxButton( this, wxID_OK );
...@@ -37,7 +39,7 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind ...@@ -37,7 +39,7 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind
m_sdbSizer->AddButton( m_sdbSizerCancel ); m_sdbSizer->AddButton( m_sdbSizerCancel );
m_sdbSizer->Realize(); m_sdbSizer->Realize();
bSizerMain->Add( m_sdbSizer, 0, wxALIGN_RIGHT, 5 ); bSizerMain->Add( m_sdbSizer, 0, wxALIGN_RIGHT|wxALL, 5 );
this->SetSizer( bSizerMain ); this->SetSizer( bSizerMain );
...@@ -48,6 +50,8 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind ...@@ -48,6 +50,8 @@ DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWind
// Connect Events // Connect Events
m_dirCtrl->Connect( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this ); m_dirCtrl->Connect( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this );
m_dirCtrl->Connect( wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this ); m_dirCtrl->Connect( wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this );
m_sdbSizerCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnCancelClick ), NULL, this );
m_sdbSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnOKClick ), NULL, this );
} }
DIALOG_SELECT_DIRLIST_BASE::~DIALOG_SELECT_DIRLIST_BASE() DIALOG_SELECT_DIRLIST_BASE::~DIALOG_SELECT_DIRLIST_BASE()
...@@ -55,5 +59,7 @@ DIALOG_SELECT_DIRLIST_BASE::~DIALOG_SELECT_DIRLIST_BASE() ...@@ -55,5 +59,7 @@ DIALOG_SELECT_DIRLIST_BASE::~DIALOG_SELECT_DIRLIST_BASE()
// Disconnect Events // Disconnect Events
m_dirCtrl->Disconnect( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this ); m_dirCtrl->Disconnect( wxEVT_COMMAND_TREE_ITEM_ACTIVATED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this );
m_dirCtrl->Disconnect( wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this ); m_dirCtrl->Disconnect( wxEVT_COMMAND_TREE_SEL_CHANGED, wxTreeEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnSelectFolder ), NULL, this );
m_sdbSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnCancelClick ), NULL, this );
m_sdbSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnOKClick ), NULL, this );
} }
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<property name="minimum_size">400,300</property> <property name="minimum_size">400,300</property>
<property name="name">DIALOG_SELECT_DIRLIST_BASE</property> <property name="name">DIALOG_SELECT_DIRLIST_BASE</property>
<property name="pos"></property> <property name="pos"></property>
<property name="size">400,300</property> <property name="size">400,321</property>
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER</property> <property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER</property>
<property name="subclass">DIALOG_SHIM; dialog_shim.h</property> <property name="subclass">DIALOG_SHIM; dialog_shim.h</property>
<property name="title">Select Footprint Library Folder</property> <property name="title">Select Footprint Library Folder</property>
...@@ -125,7 +125,7 @@ ...@@ -125,7 +125,7 @@
<property name="gripper">0</property> <property name="gripper">0</property>
<property name="hidden">0</property> <property name="hidden">0</property>
<property name="id">wxID_ANY</property> <property name="id">wxID_ANY</property>
<property name="label">The footprint library is a folde.&#x0A;Footprints are files inside this folder.</property> <property name="label">The footprint library is a folder.&#x0A;Footprints are files inside this folder.</property>
<property name="max_size"></property> <property name="max_size"></property>
<property name="maximize_button">0</property> <property name="maximize_button">0</property>
<property name="maximum_size"></property> <property name="maximum_size"></property>
...@@ -216,7 +216,7 @@ ...@@ -216,7 +216,7 @@
<property name="maximum_size"></property> <property name="maximum_size"></property>
<property name="min_size"></property> <property name="min_size"></property>
<property name="minimize_button">0</property> <property name="minimize_button">0</property>
<property name="minimum_size"></property> <property name="minimum_size">400,350</property>
<property name="moveable">1</property> <property name="moveable">1</property>
<property name="name">m_dirCtrl</property> <property name="name">m_dirCtrl</property>
<property name="pane_border">1</property> <property name="pane_border">1</property>
...@@ -280,7 +280,7 @@ ...@@ -280,7 +280,7 @@
</object> </object>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="1">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxEXPAND | wxALL</property> <property name="flag">wxEXPAND|wxTOP|wxRIGHT|wxLEFT</property>
<property name="proportion">0</property> <property name="proportion">0</property>
<object class="wxStaticLine" expanded="1"> <object class="wxStaticLine" expanded="1">
<property name="BottomDockable">1</property> <property name="BottomDockable">1</property>
...@@ -317,7 +317,7 @@ ...@@ -317,7 +317,7 @@
<property name="minimize_button">0</property> <property name="minimize_button">0</property>
<property name="minimum_size"></property> <property name="minimum_size"></property>
<property name="moveable">1</property> <property name="moveable">1</property>
<property name="name">m_staticline1</property> <property name="name">m_staticline</property>
<property name="pane_border">1</property> <property name="pane_border">1</property>
<property name="pane_position"></property> <property name="pane_position"></property>
<property name="pane_size"></property> <property name="pane_size"></property>
...@@ -361,7 +361,7 @@ ...@@ -361,7 +361,7 @@
</object> </object>
<object class="sizeritem" expanded="1"> <object class="sizeritem" expanded="1">
<property name="border">5</property> <property name="border">5</property>
<property name="flag">wxALIGN_RIGHT</property> <property name="flag">wxALIGN_RIGHT|wxALL</property>
<property name="proportion">0</property> <property name="proportion">0</property>
<object class="wxStdDialogButtonSizer" expanded="1"> <object class="wxStdDialogButtonSizer" expanded="1">
<property name="Apply">0</property> <property name="Apply">0</property>
...@@ -376,11 +376,11 @@ ...@@ -376,11 +376,11 @@
<property name="name">m_sdbSizer</property> <property name="name">m_sdbSizer</property>
<property name="permission">protected</property> <property name="permission">protected</property>
<event name="OnApplyButtonClick"></event> <event name="OnApplyButtonClick"></event>
<event name="OnCancelButtonClick"></event> <event name="OnCancelButtonClick">OnCancelClick</event>
<event name="OnContextHelpButtonClick"></event> <event name="OnContextHelpButtonClick"></event>
<event name="OnHelpButtonClick"></event> <event name="OnHelpButtonClick"></event>
<event name="OnNoButtonClick"></event> <event name="OnNoButtonClick"></event>
<event name="OnOKButtonClick"></event> <event name="OnOKButtonClick">OnOKClick</event>
<event name="OnSaveButtonClick"></event> <event name="OnSaveButtonClick"></event>
<event name="OnYesButtonClick"></event> <event name="OnYesButtonClick"></event>
</object> </object>
......
...@@ -39,18 +39,20 @@ class DIALOG_SELECT_DIRLIST_BASE : public DIALOG_SHIM ...@@ -39,18 +39,20 @@ class DIALOG_SELECT_DIRLIST_BASE : public DIALOG_SHIM
protected: protected:
wxStaticText* m_staticText; wxStaticText* m_staticText;
wxGenericDirCtrl* m_dirCtrl; wxGenericDirCtrl* m_dirCtrl;
wxStaticLine* m_staticline1; wxStaticLine* m_staticline;
wxStdDialogButtonSizer* m_sdbSizer; wxStdDialogButtonSizer* m_sdbSizer;
wxButton* m_sdbSizerOK; wxButton* m_sdbSizerOK;
wxButton* m_sdbSizerCancel; wxButton* m_sdbSizerCancel;
// Virtual event handlers, overide them in your derived class // Virtual event handlers, overide them in your derived class
virtual void OnSelectFolder( wxTreeEvent& event ) { event.Skip(); } virtual void OnSelectFolder( wxTreeEvent& event ) { event.Skip(); }
virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); }
virtual void OnOKClick( wxCommandEvent& event ) { event.Skip(); }
public: public:
DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Select Footprint Library Folder"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 400,300 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Select Footprint Library Folder"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 400,321 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_SELECT_DIRLIST_BASE(); ~DIALOG_SELECT_DIRLIST_BASE();
}; };
......
...@@ -55,6 +55,7 @@ ...@@ -55,6 +55,7 @@
#include <project.h> // For PROJECT_VAR_NAME definition #include <project.h> // For PROJECT_VAR_NAME definition
#include <io_mgr.h> #include <io_mgr.h>
#include <wizard_add_fplib.h> #include <wizard_add_fplib.h>
#include <dialog_select_dirlist_base.h>
// a key to store the default Kicad Github libs URL // a key to store the default Kicad Github libs URL
#define KICAD_FPLIBS_URL_KEY wxT( "kicad_fplib_url" ) #define KICAD_FPLIBS_URL_KEY wxT( "kicad_fplib_url" )
...@@ -640,6 +641,11 @@ public: ...@@ -640,6 +641,11 @@ public:
{ {
if( !aDefaultPath.IsEmpty() ) if( !aDefaultPath.IsEmpty() )
m_dirCtrl->SetPath( aDefaultPath ); m_dirCtrl->SetPath( aDefaultPath );
Layout();
GetSizer()->Fit( this );
GetSizer()->SetSizeHints(this);
Centre();
} }
~DIALOG_SELECT_DIRLIST() {}; ~DIALOG_SELECT_DIRLIST() {};
......
...@@ -251,52 +251,3 @@ WIZARD_FPLIB_TABLE_BASE::~WIZARD_FPLIB_TABLE_BASE() ...@@ -251,52 +251,3 @@ WIZARD_FPLIB_TABLE_BASE::~WIZARD_FPLIB_TABLE_BASE()
m_pages.Clear(); m_pages.Clear();
} }
DIALOG_SELECT_DIRLIST_BASE::DIALOG_SELECT_DIRLIST_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
wxBoxSizer* bSizerMain;
bSizerMain = new wxBoxSizer( wxVERTICAL );
m_staticTextInfo = new wxStaticText( this, wxID_ANY, _("The footprint library is a folder.\nFootprints are files inside this folder."), wxDefaultPosition, wxDefaultSize, wxALIGN_CENTRE );
m_staticTextInfo->Wrap( -1 );
m_staticTextInfo->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 92, false, wxEmptyString ) );
bSizerMain->Add( m_staticTextInfo, 0, wxALL|wxALIGN_CENTER_HORIZONTAL, 5 );
m_dirCtrl = new wxGenericDirCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxDIRCTRL_3D_INTERNAL|wxDIRCTRL_DIR_ONLY|wxDIRCTRL_MULTIPLE|wxSUNKEN_BORDER, wxEmptyString, 0 );
m_dirCtrl->ShowHidden( false );
bSizerMain->Add( m_dirCtrl, 1, wxEXPAND | wxALL, 5 );
m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
bSizerMain->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
m_sdbSizer = new wxStdDialogButtonSizer();
m_sdbSizerOK = new wxButton( this, wxID_OK );
m_sdbSizer->AddButton( m_sdbSizerOK );
m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
m_sdbSizer->AddButton( m_sdbSizerCancel );
m_sdbSizer->Realize();
bSizerMain->Add( m_sdbSizer, 0, wxEXPAND, 5 );
this->SetSizer( bSizerMain );
this->Layout();
this->Centre( wxBOTH );
// Connect Events
m_sdbSizerCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnCancelClick ), NULL, this );
m_sdbSizerOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnOKClick ), NULL, this );
}
DIALOG_SELECT_DIRLIST_BASE::~DIALOG_SELECT_DIRLIST_BASE()
{
// Disconnect Events
m_sdbSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnCancelClick ), NULL, this );
m_sdbSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_DIRLIST_BASE::OnOKClick ), NULL, this );
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -267,17 +267,11 @@ bool PCB_EDIT_FRAME::LoadProjectSettings() ...@@ -267,17 +267,11 @@ bool PCB_EDIT_FRAME::LoadProjectSettings()
// Load the page layout decr file, from the filename stored in // Load the page layout decr file, from the filename stored in
// BASE_SCREEN::m_PageLayoutDescrFileName, read in config project file // BASE_SCREEN::m_PageLayoutDescrFileName, read in config project file
// If empty, the default descr is loaded // If empty, or not existing, the default descr is loaded
WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance(); WORKSHEET_LAYOUT& pglayout = WORKSHEET_LAYOUT::GetTheInstance();
wxString pg_fullfilename = ExpandEnvVarSubstitutions( wxString pg_fullfilename = WORKSHEET_LAYOUT::MakeFullFileName(
BASE_SCREEN::m_PageLayoutDescrFileName ); BASE_SCREEN::m_PageLayoutDescrFileName,
Prj().GetProjectPath() );
if( !pg_fullfilename.IsEmpty() )
{
// When the page layout filename is not absolute, therefore
// relative to the current project, make it absolute
pg_fullfilename = Prj().AbsolutePath( pg_fullfilename );
}
pglayout.SetPageLayout( pg_fullfilename ); pglayout.SetPageLayout( pg_fullfilename );
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment