Commit 07cd3bcb authored by Maciej Suminski's avatar Maciej Suminski

Upstream merged

parents 80999ba0 0d41a7a5
......@@ -49,21 +49,21 @@
#include <3d_draw_basic_functions.h>
// Imported function:
extern void SetGLColor( int color );
extern void SetGLColor( EDA_COLOR_T color );
extern void Set_Object_Data( std::vector< S3D_VERTEX >& aVertices, double aBiuTo3DUnits );
extern void CheckGLError();
/* returns true if aLayer should be displayed, false otherwise
*/
static bool Is3DLayerEnabled( int aLayer );
static bool Is3DLayerEnabled( LAYER_NUM aLayer );
/* returns the Z orientation parameter 1.0 or -1.0 for aLayer
* Z orientation is 1.0 for all layers but "back" layers:
* LAYER_N_BACK , ADHESIVE_N_BACK, SOLDERPASTE_N_BACK ), SILKSCREEN_N_BACK
* used to calculate the Z orientation parameter for glNormal3f
*/
static GLfloat Get3DLayer_Z_Orientation( int aLayer );
static GLfloat Get3DLayer_Z_Orientation( LAYER_NUM aLayer );
void EDA_3D_CANVAS::Redraw( bool finish )
{
......@@ -163,7 +163,7 @@ GLuint EDA_3D_CANVAS::CreateDrawGL_List()
Draw3D_Via( (SEGVIA*) track );
else
{
int layer = track->GetLayer();
LAYER_NUM layer = track->GetLayer();
if( g_Parm_3D_Visu.m_BoardSettings->IsLayerVisible( layer ) )
Draw3D_Track( track );
......@@ -174,7 +174,7 @@ GLuint EDA_3D_CANVAS::CreateDrawGL_List()
{
for( int ii = 0; ii < pcb->GetAreaCount(); ii++ )
{
int layer = pcb->GetArea( ii )->GetLayer();
LAYER_NUM layer = pcb->GetArea( ii )->GetLayer();
if( g_Parm_3D_Visu.m_BoardSettings->IsLayerVisible( layer ) )
Draw3D_Zone( pcb->GetArea( ii ) );
......@@ -236,8 +236,8 @@ GLuint EDA_3D_CANVAS::CreateDrawGL_List()
*/
void EDA_3D_CANVAS::Draw3D_Zone( ZONE_CONTAINER* aZone )
{
int layer = aZone->GetLayer();
int color = g_ColorsSettings.GetLayerColor( layer );
LAYER_NUM layer = aZone->GetLayer();
EDA_COLOR_T color = g_ColorsSettings.GetLayerColor( layer );
int thickness = g_Parm_3D_Visu.GetLayerObjectThicknessBIU( layer );
if( layer == LAST_COPPER_LAYER )
......@@ -326,8 +326,8 @@ void EDA_3D_CANVAS::Draw3D_Zone( ZONE_CONTAINER* aZone )
void EDA_3D_CANVAS::DrawGrid( double aGriSizeMM )
{
double zpos = 0.0;
int gridcolor = DARKGRAY; // Color of grid lines
int gridcolor_marker = LIGHTGRAY; // Color of grid lines every 5 lines
EDA_COLOR_T gridcolor = DARKGRAY; // Color of grid lines
EDA_COLOR_T gridcolor_marker = LIGHTGRAY; // Color of grid lines every 5 lines
double scale = g_Parm_3D_Visu.m_BiuTo3Dunits;
glNormal3f( 0.0, 0.0, 1.0 );
......@@ -456,8 +456,8 @@ void EDA_3D_CANVAS::DrawGrid( double aGriSizeMM )
void EDA_3D_CANVAS::Draw3D_Track( TRACK* aTrack )
{
int layer = aTrack->GetLayer();
int color = g_ColorsSettings.GetLayerColor( layer );
LAYER_NUM layer = aTrack->GetLayer();
EDA_COLOR_T color = g_ColorsSettings.GetLayerColor( layer );
int thickness = g_Parm_3D_Visu.GetCopperThicknessBIU();
if( layer == LAST_COPPER_LAYER )
......@@ -475,8 +475,8 @@ void EDA_3D_CANVAS::Draw3D_Track( TRACK* aTrack )
void EDA_3D_CANVAS::Draw3D_Via( SEGVIA* via )
{
int layer, top_layer, bottom_layer;
int color;
LAYER_NUM layer, top_layer, bottom_layer;
EDA_COLOR_T color;
double biu_to_3Dunits = g_Parm_3D_Visu.m_BiuTo3Dunits ;
int outer_radius = via->GetWidth() / 2;
......@@ -486,7 +486,7 @@ void EDA_3D_CANVAS::Draw3D_Via( SEGVIA* via )
via->ReturnLayerPair( &top_layer, &bottom_layer );
// Drawing horizontal thick rings:
for( layer = bottom_layer; layer < g_Parm_3D_Visu.m_CopperLayersCount; layer++ )
for( layer = bottom_layer; layer < g_Parm_3D_Visu.m_CopperLayersCount; ++layer )
{
int zpos = g_Parm_3D_Visu.GetLayerZcoordBIU( layer );
......@@ -530,15 +530,15 @@ void EDA_3D_CANVAS::Draw3D_Via( SEGVIA* via )
void EDA_3D_CANVAS::Draw3D_DrawSegment( DRAWSEGMENT* segment )
{
int layer = segment->GetLayer();
int color = g_ColorsSettings.GetLayerColor( layer );
LAYER_NUM layer = segment->GetLayer();
EDA_COLOR_T color = g_ColorsSettings.GetLayerColor( layer );
int thickness = g_Parm_3D_Visu.GetLayerObjectThicknessBIU( layer );
SetGLColor( color );
if( layer == EDGE_N )
{
for( layer = 0; layer < g_Parm_3D_Visu.m_CopperLayersCount; layer++ )
for( layer = FIRST_LAYER; layer < g_Parm_3D_Visu.m_CopperLayersCount; ++layer )
{
glNormal3f( 0.0, 0.0, Get3DLayer_Z_Orientation( layer ) );
int zpos = g_Parm_3D_Visu.GetLayerZcoordBIU(layer);
......@@ -624,8 +624,8 @@ static void Draw3dTextSegm( int x0, int y0, int xf, int yf )
void EDA_3D_CANVAS::Draw3D_DrawText( TEXTE_PCB* text )
{
int layer = text->GetLayer();
int color = g_ColorsSettings.GetLayerColor( layer );
LAYER_NUM layer = text->GetLayer();
EDA_COLOR_T color = g_ColorsSettings.GetLayerColor( layer );
SetGLColor( color );
s_Text3DZPos = g_Parm_3D_Visu.GetLayerZcoordBIU( layer );
......@@ -754,7 +754,7 @@ void EDGE_MODULE::Draw3D( EDA_3D_CANVAS* glcanvas )
if( g_Parm_3D_Visu.m_BoardSettings->IsLayerVisible( m_Layer ) == false )
return;
int color = g_ColorsSettings.GetLayerColor( m_Layer );
EDA_COLOR_T color = g_ColorsSettings.GetLayerColor( m_Layer );
SetGLColor( color );
// for outline shape = S_POLYGON:
......@@ -790,7 +790,7 @@ void EDGE_MODULE::Draw3D( EDA_3D_CANVAS* glcanvas )
if( m_Layer == EDGE_N )
{
for( int layer = 0; layer < g_Parm_3D_Visu.m_CopperLayersCount; layer++ )
for( LAYER_NUM layer = FIRST_LAYER; layer < g_Parm_3D_Visu.m_CopperLayersCount; ++layer )
{
glNormal3f( 0.0, 0.0, Get3DLayer_Z_Orientation( layer ) );
int zpos = g_Parm_3D_Visu.GetLayerZcoordBIU( layer );
......@@ -948,7 +948,7 @@ void D_PAD::Draw3D( EDA_3D_CANVAS* glcanvas )
switch( GetShape() )
{
case PAD_CIRCLE:
for( int layer = FIRST_COPPER_LAYER; layer <= LAST_COPPER_LAYER; layer++ )
for( LAYER_NUM layer = FIRST_COPPER_LAYER; layer <= LAST_COPPER_LAYER; ++layer )
{
if( layer && (layer == nlmax) )
layer = LAYER_N_FRONT;
......@@ -998,7 +998,6 @@ void D_PAD::Draw3D( EDA_3D_CANVAS* glcanvas )
polyPadShape.insert( polyPadShape.end(), holecornersBuffer.begin(),
holecornersBuffer.end() );
}
break;
case PAD_RECT:
......@@ -1007,7 +1006,6 @@ void D_PAD::Draw3D( EDA_3D_CANVAS* glcanvas )
wxPoint coord[5];
BuildPadPolygon( coord, wxSize(0,0), m_Orient );
for( int ii = 0; ii < 4; ii ++ )
{
CPolyPt pt( coord[ii].x + shape_pos.x, coord[ii].y+ shape_pos.y );
polyPadShape.push_back( pt );
......@@ -1027,7 +1025,7 @@ void D_PAD::Draw3D( EDA_3D_CANVAS* glcanvas )
if( polyPadShape.size() )
{
for( int layer = FIRST_COPPER_LAYER; layer <= LAST_COPPER_LAYER; layer++ )
for( LAYER_NUM layer = FIRST_COPPER_LAYER; layer <= LAST_COPPER_LAYER; ++layer )
{
if( layer && (layer == nlmax) )
layer = LAYER_N_FRONT;
......@@ -1061,41 +1059,41 @@ void D_PAD::Draw3D( EDA_3D_CANVAS* glcanvas )
}
bool Is3DLayerEnabled( int aLayer )
bool Is3DLayerEnabled( LAYER_NUM aLayer )
{
int flg = -1;
int flg;
// see if layer needs to be shown
// check the flags
switch (aLayer)
{
case DRAW_N:
flg=g_Parm_3D_Visu.FL_DRAWINGS;
flg = g_Parm_3D_Visu.FL_DRAWINGS;
break;
case COMMENT_N:
flg=g_Parm_3D_Visu.FL_COMMENTS;
flg = g_Parm_3D_Visu.FL_COMMENTS;
break;
case ECO1_N:
flg=g_Parm_3D_Visu.FL_ECO1;
flg = g_Parm_3D_Visu.FL_ECO1;
break;
case ECO2_N:
flg=g_Parm_3D_Visu.FL_ECO2;
flg = g_Parm_3D_Visu.FL_ECO2;
break;
}
default:
// the layer was not a layer with a flag, so show it
if( flg < 0 )
return true;
}
// if the layer has a flag, return the flag
return g_Parm_3D_Visu.m_DrawFlags[flg];
}
GLfloat Get3DLayer_Z_Orientation( int aLayer )
GLfloat Get3DLayer_Z_Orientation( LAYER_NUM aLayer )
{
double nZ;
......
......@@ -122,10 +122,10 @@ static void Draw3D_VerticalPolygonalCylinder( const std::vector<CPolyPt>& aPolys
}
void SetGLColor( int color )
void SetGLColor( EDA_COLOR_T color )
{
double red, green, blue;
StructColors colordata = ColorRefs[color & MASKCOLOR];
const StructColors &colordata = g_ColorRefs[ColorGetBase( color )];
red = colordata.m_Red / 255.0;
blue = colordata.m_Blue / 255.0;
......
This diff is collapsed.
......@@ -115,26 +115,6 @@ public:
void Copy( S3D_MASTER* pattern );
int ReadData();
/**
* Function ReadMaterial
* read the description of a 3D material definition in the form:
* DEF yellow material Material (
* DiffuseColor 1.00000 1.00000 0.00000e 0
* EmissiveColor 0.00000e 0 0.00000e 0 0.00000e 0
* SpecularColor 1.00000 1.00000 1.00000
* AmbientIntensity 1.00000
* Transparency 0.00000e 0
* Shininess 1.00000
*)
* Or type:
* USE yellow material
*/
int ReadMaterial( FILE* file, int* LineNum );
int ReadChildren( FILE* file, int* LineNum );
int ReadShape( FILE* file, int* LineNum );
int ReadAppearance( FILE* file, int* LineNum );
int ReadGeometry( FILE* file, int* LineNum );
void Set_Object_Coords( std::vector< S3D_VERTEX >& aVertices );
#if defined(DEBUG)
......
......@@ -105,16 +105,16 @@ void EDA_3D_FRAME::ReCreateHToolbar()
m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_MOVE3D_LEFT, wxEmptyString, KiBitmap( left_xpm ),
_( "Move left <-" ) );
_( "Move left" ) );
m_HToolBar->AddTool( ID_MOVE3D_RIGHT, wxEmptyString, KiBitmap( right_xpm ),
_( "Move right ->" ) );
_( "Move right" ) );
m_HToolBar->AddTool( ID_MOVE3D_UP, wxEmptyString, KiBitmap( up_xpm ),
_( "Move up ^" ) );
_( "Move up" ) );
m_HToolBar->AddTool( ID_MOVE3D_DOWN, wxEmptyString, KiBitmap( down_xpm ),
_( "Move down v" ) );
_( "Move down" ) );
m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_ORTHO, wxEmptyString, KiBitmap( ortho_xpm ),
......
......@@ -19,6 +19,8 @@ set(3D-VIEWER_SRCS
3d_toolbar.cpp
info3d_visu.cpp
trackball.cpp
x3dmodelparser.cpp
vrmlmodelparser.cpp
)
add_library(3d-viewer STATIC ${3D-VIEWER_SRCS})
......@@ -135,7 +135,7 @@ void INFO3D_VISU::InitSettings( BOARD* aBoard )
}
// calculate z position for each non copper layer
for( int layer_id = FIRST_NO_COPPER_LAYER; layer_id < NB_LAYERS; layer_id++ )
for( int layer_id = FIRST_NON_COPPER_LAYER; layer_id < NB_PCB_LAYERS; layer_id++ )
{
double zpos;
#define NonCopperLayerThicknessMargin 1.1
......@@ -184,7 +184,7 @@ void INFO3D_VISU::InitSettings( BOARD* aBoard )
default:
zpos = zpos_copper_front +
(layer_id - FIRST_NO_COPPER_LAYER + 5) *
(layer_id - FIRST_NON_COPPER_LAYER + 5) *
m_NonCopperLayerThickness * NonCopperLayerThicknessMargin;
break;
}
......
......@@ -93,7 +93,7 @@ public:
double m_CurrentZpos; // temporary storage of current value of Z position,
// used in some calculation
private:
double m_LayerZcoord[LAYER_COUNT]; // Z position of each layer (normalized)
double m_LayerZcoord[NB_LAYERS]; // Z position of each layer (normalized)
double m_CopperThickness; // Copper thickness (normalized)
double m_EpoxyThickness; // Epoxy thickness (normalized)
double m_NonCopperLayerThickness; // Non copper layers thickness
......@@ -173,7 +173,7 @@ public: INFO3D_VISU();
*/
int GetLayerObjectThicknessBIU( int aLayerId) const
{
return aLayerId >= FIRST_NO_COPPER_LAYER ?
return aLayerId >= FIRST_NON_COPPER_LAYER ?
GetNonCopperLayerThicknessBIU() :
GetCopperThicknessBIU();
}
......
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2013 Tuomas Vaherkoski <tuomasvaherkoski@gmail.com>
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, you may find one here:
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
* or you may search the http://www.gnu.org website for the version 2 license,
* or you may write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
/**
* @file modelparsers.h
*/
#ifndef MODELPARSERS_H
#define MODELPARSERS_H
#include <map>
#include <vector>
#include <wx/string.h>
class S3D_MASTER;
class S3D_VERTEX;
extern void Set_Object_Data( std::vector< S3D_VERTEX >& aVertices, double aBiuTo3DUnits );
class S3D_MODEL_PARSER;
class X3D_MODEL_PARSER;
/**
* abstract class S3D_MODEL_PARSER
* Base class for 3D model parsers.
*/
class S3D_MODEL_PARSER
{
public:
S3D_MODEL_PARSER(S3D_MASTER* aMaster) :
master( aMaster )
{}
virtual ~S3D_MODEL_PARSER()
{}
S3D_MASTER* GetMaster()
{
return master;
}
/**
* Function Create
* Factory method for creating concrete 3D model parsers
* Notice that the caller is responsible to delete created parser.
*
* @param aMaster is master object that the parser will fill.
* @param aExtension is file extension of the file you are going to parse.
*/
static S3D_MODEL_PARSER* Create( S3D_MASTER* aMaster, const wxString aExtension );
/**
* Function Load
*
* Concrete parsers should implement this function
*/
virtual void Load( const wxString aFilename ) = 0;
private:
S3D_MASTER* master;
};
class wxXmlNode;
/**
* class X3D_MODEL_PARSER
* Implements parser for X3D file format (VRML2.0 successor)
* X3D files can be exported from eg. Blender */
class X3D_MODEL_PARSER: public S3D_MODEL_PARSER
{
public:
X3D_MODEL_PARSER( S3D_MASTER* aMaster );
~X3D_MODEL_PARSER();
void Load( const wxString aFilename );
typedef std::map< wxString, wxString > PROPERTY_MAP;
typedef std::vector< wxXmlNode* > NODE_LIST;
/**
* Function GetChildsByName
* Searches all child nodes with aName.
*
* @param aParent is node to search from
* @param aName is the name of node you try to find
* @param aResult contains found nodes
*/
static void GetChildsByName( wxXmlNode* aParent, const wxString aName, NODE_LIST& aResult );
/**
* Function GetNodeProperties
* Collects all node properties to map.
*
* @param aProps contains map of found properties
*/
static void GetNodeProperties( wxXmlNode* aNode, PROPERTY_MAP& aProps );
/**
* Return string representing x3d file in vrml format
* Function Load must be called before this function, otherwise empty
* data set is returned.
*/
wxString VRML_representation();
private:
std::vector< wxString > vrml_materials;
std::vector< wxString > vrml_points;
std::vector< wxString > vrml_coord_indexes;
void readTransform( wxXmlNode* aTransformNode );
void readMaterial( wxXmlNode* aMatNode );
void readIndexedFaceSet( wxXmlNode* aFaceNode, PROPERTY_MAP& aTransfromProps );
bool parseDoubleTriplet( const wxString& aData, S3D_VERTEX& aResult );
void rotate( S3D_VERTEX& aCoordinate, S3D_VERTEX& aRotAxis, double angle );
};
/**
* class WRL_MODEL_PARSER
* Parses
*/
class VRML_MODEL_PARSER: public S3D_MODEL_PARSER
{
public:
VRML_MODEL_PARSER( S3D_MASTER* aMaster );
~VRML_MODEL_PARSER();
void Load( const wxString aFilename );
private:
/**
* Function ReadMaterial
* read the description of a 3D material definition in the form:
* DEF yellow material Material (
* DiffuseColor 1.00000 1.00000 0.00000e 0
* EmissiveColor 0.00000e 0 0.00000e 0 0.00000e 0
* SpecularColor 1.00000 1.00000 1.00000
* AmbientIntensity 1.00000
* Transparency 0.00000e 0
* Shininess 1.00000
*)
* Or type:
* USE yellow material
*/
int readMaterial( FILE* file, int* LineNum );
int readChildren( FILE* file, int* LineNum );
int readShape( FILE* file, int* LineNum );
int readAppearance( FILE* file, int* LineNum );
int readGeometry( FILE* file, int* LineNum );
/**
* Function ReadCoordList
* reads 3D coordinate lists like:
* coord Coordinate { point [
* -5.24489 6.57640e-3 -9.42129e-2,
* -5.11821 6.57421e-3 0.542654,
* -3.45868 0.256565 1.32000 ] }
* or:
* normal Normal { vector [
* 0.995171 -6.08102e-6 9.81541e-2,
* 0.923880 -4.09802e-6 0.382683,
* 0.707107 -9.38186e-7 0.707107]
* }
*
* text_buffer contains the first line of this node :
* "coord Coordinate { point ["
*/
void readCoordsList( FILE* file, char* text_buffer, std::vector< double >& aList,
int* LineNum );
};
#endif // MODELPARSERS_H
This diff is collapsed.
This diff is collapsed.
......@@ -42,7 +42,7 @@ option(KICAD_STABLE_VERSION
)
option(KICAD_TESTING_VERSION
"set this option to ON to build the stable version of KICAD. mainly used to set version ID (default OFF)"
"set this option to ON to build the testing version of KICAD. mainly used to set version ID (default OFF)"
)
option(KICAD_SCRIPTING
......
......@@ -24,18 +24,20 @@ Contribute to KiCad (under Linux)
cd kicad_john
mkdir build; cd build
cmake ../ -DKICAD_TESTING_VERSION=ON -DCMAKE_BUILD_TYPE=Debug
to build a debug version
or
cmake ../ -DKICAD_TESTING_VERSION=ON -DCMAKE_BUILD_TYPE=Release
to build a release version
make -j 4 # this is for a 4 core machine
7) Repeat step 5 and 6 until satisfied.
8) Delete the "build" folder and create a patch:
cd kicad_john
rm -R ./build
bzr add .
bzr status
bzr diff > gui_better_zoom.patch
8) Create a patch:
in kicad_john:
if some files are added: bzr add [FILE...]
bzr diff > my_changes.patch
9) Send the patch file "gui_better_zoom.patch" to the KiCad developers mailing list.
9) Send the patch file "my_changes.patch" to the KiCad developers mailing list.
in the subject of the e-mail include the keyword "[PATCH]".
in the body of the e-mail clearly explain what you have done.
......
......@@ -9,12 +9,11 @@ AUTHORS.txt - The authors, contributors, document writers and translators li
CHANGELOG.txt - This years changelog (see for previous years Documentation/changelogs)
CMakeList.txt - CMAKE build tool script
COPYRIGHT.txt - A copy of the GNU General Public License Version 2
CTestConfig.txt - Support for CTest and CDash testing tools
Doxyfile - Doxygen preferences
CTestConfig.cmake - Support for CTest and CDash testing tools
Doxyfile - Doxygen config file for Kicad
INSTALL.txt - The release (binairy) installation instructions
TODO.txt - Todo list
uncrustify.cfg - Uncrustify code formatting tool preferences
version.txt - The current stable released version
uncrustify.cfg - Uncrustify config file for uncrustify sorces formatting tool
Subdirectories
--------------
......@@ -37,6 +36,6 @@ packaging - Files for packaging on Windows and Mac OSX
pcbnew - Sourcecode of the printed circuit board editor
polygon - Sourcecode of the polygon library
resources - Resources for installation, freedesktop mime-types for linux
scripts - Helper scripts. For building, sourcecode packaging, font setting, pcb adjusting.
scripts - Helper scripts. For building, sourcecode packaging.
template - Project template(s)
......@@ -26,13 +26,14 @@
// For some unknown reasons, polygon.hpp shoul be included first
#include <boost/polygon/polygon.hpp>
#include <wx/wx.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <stdlib.h>
#include <cmath>
#include <vector>
#include <layers_id_colors_and_visibility.h>
#include <potracelib.h>
#include <auxiliary.h>
......@@ -310,8 +311,7 @@ void BITMAPCONV_INFO::OuputOnePolygon( KPolygon & aPolygon )
case PCBNEW_FMT:
{
#define SILKSCREEN_N_FRONT 21
int layer = SILKSCREEN_N_FRONT;
LAYER_NUM layer = SILKSCREEN_N_FRONT;
int width = 1;
fprintf( m_Outfile, "DP %d %d %d %d %d %d %d\n",
0, 0, 0, 0,
......
......@@ -92,6 +92,7 @@ set(COMMON_SRCS
netlist_keywords.cpp
newstroke_font.cpp
projet_config.cpp
ptree.cpp
richio.cpp
selcolor.cpp
string.cpp
......@@ -135,7 +136,6 @@ set(PCB_COMMON_SRCS
../pcbnew/class_marker_pcb.cpp
../pcbnew/class_mire.cpp
../pcbnew/class_module.cpp
../pcbnew/class_module_transform_functions.cpp
../pcbnew/class_pad.cpp
../pcbnew/class_pad_draw_functions.cpp
../pcbnew/class_pcb_text.cpp
......
......@@ -90,7 +90,7 @@ void EDA_ITEM::InitVars()
void EDA_ITEM::SetModified()
{
m_Flags |= IS_CHANGED;
SetFlags( IS_CHANGED );
// If this a child object, then the parent modification state also needs to be set.
if( m_Parent )
......
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2009 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
* Copyright (C) 2011 Wayne Stambaugh <stambaughw@verizon.net>
* Copyright (C) 1992-2011 KiCad Developers, see AUTHORS.txt for contributors.
* Copyright (C) 2013 Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 2013 Wayne Stambaugh <stambaughw@verizon.net>
* Copyright (C) 1992-2013 KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
......@@ -289,7 +289,7 @@ wxString EDA_BASE_FRAME::GetFileFromHistory( int cmdId, const wxString& type,
if( !wxFileName::FileExists( fn ) )
{
msg = type + _( " file <" ) + fn + _( "> was not found." );
msg.Printf( wxT( "file <%s> was not found." ), GetChars( fn ) );
wxMessageBox( msg );
fileHistory->RemoveFileFromHistory( i );
fn = wxEmptyString;
......@@ -388,7 +388,8 @@ void EDA_BASE_FRAME::OnSelectPreferredEditor( wxCommandEvent& event )
wildcard += wxT( ".exe" );
#endif
wildcard = _( "Executable file (" ) + wildcard + wxT( ")|" ) + wildcard;
wildcard.Printf( _( "Executable file (%s)|%s" ),
GetChars( wildcard ), GetChars( wildcard ) );
wxFileDialog dlg( this, _( "Select Preferred Editor" ), fn.GetPath(),
fn.GetFullName(), wildcard,
......@@ -644,7 +645,8 @@ edits you made?" ),
// Rename the old file to the backup file name.
if( !wxRenameFile( aFileName.GetFullPath(), backupFileName.GetFullPath() ) )
{
msg = _( "Could not create backup file " ) + backupFileName.GetFullPath();
msg.Printf( _( "Could not create backup file <%s>" ),
GetChars( backupFileName.GetFullPath() ) );
wxMessageBox( msg );
}
}
......
......@@ -108,7 +108,7 @@ void BLOCK_SELECTOR::SetMessageBlock( EDA_DRAW_FRAME* frame )
break;
default:
msg = wxT( "????" );
msg = wxT( "???" );
break;
}
......
......@@ -40,6 +40,7 @@ static const EDA_COLOR_T default_items_color[LAYERSCOLORSBUFFERSIZE] =
CYAN, // VIA_MICROVIA_VISIBLE
BROWN, // VIA_BBLIND_VISIBLE
LIGHTGRAY, // VIA_THROUGH_VISIBLE
YELLOW, // NON_PLATED_VISIBLE
LIGHTGRAY, // MOD_TEXT_FR_VISIBLE
BLUE, // MOD_TEXT_BK_VISIBLE
DARKGRAY, // MOD_TEXT_INVISIBLE
......@@ -47,23 +48,15 @@ static const EDA_COLOR_T default_items_color[LAYERSCOLORSBUFFERSIZE] =
RED, // PAD_FR_VISIBLE
GREEN, // PAD_BK_VISIBLE
LIGHTGRAY, // RATSNEST_VISIBLE
DARKGRAY, //GRID_VISIBLE
DARKGRAY, // GRID_VISIBLE
LIGHTRED, LIGHTGRAY, LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY,
LIGHTGRAY
LIGHTGRAY, LIGHTGRAY, LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY, LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY, LIGHTGRAY, LIGHTGRAY,
LIGHTGRAY, LIGHTGRAY, LIGHTGRAY
};
COLORS_DESIGN_SETTINGS:: COLORS_DESIGN_SETTINGS()
COLORS_DESIGN_SETTINGS::COLORS_DESIGN_SETTINGS()
{
for( unsigned ii = 0; ii < DIM(m_LayersColors); ii++ )
m_LayersColors[ii] = default_layer_color[ii];
......@@ -78,7 +71,7 @@ COLORS_DESIGN_SETTINGS:: COLORS_DESIGN_SETTINGS()
* @return the color for aLayer which is one of the layer indices given
* in pcbstruct.h or in schematic
*/
EDA_COLOR_T COLORS_DESIGN_SETTINGS::GetLayerColor( int aLayer ) const
EDA_COLOR_T COLORS_DESIGN_SETTINGS::GetLayerColor( LAYER_NUM aLayer ) const
{
if( (unsigned) aLayer < DIM(m_LayersColors) )
{
......@@ -93,7 +86,7 @@ EDA_COLOR_T COLORS_DESIGN_SETTINGS::GetLayerColor( int aLayer ) const
* sets the color for aLayer which is one of the layer indices given
* in pcbstruct.h or in schematic
*/
void COLORS_DESIGN_SETTINGS::SetLayerColor( int aLayer, EDA_COLOR_T aColor )
void COLORS_DESIGN_SETTINGS::SetLayerColor( LAYER_NUM aLayer, EDA_COLOR_T aColor )
{
if( (unsigned) aLayer < DIM(m_LayersColors) )
{
......
......@@ -65,14 +65,14 @@ int LAYER_BOX_SELECTOR::GetChoice()
// Get Current Layer
int LAYER_BOX_SELECTOR::GetLayerSelection()
LAYER_NUM LAYER_BOX_SELECTOR::GetLayerSelection() const
{
return (long) GetClientData( GetSelection() );
return (LAYER_NUM)((unsigned long) GetClientData( GetSelection() ) );
}
// Set Layer #
int LAYER_BOX_SELECTOR::SetLayerSelection( int layer )
int LAYER_BOX_SELECTOR::SetLayerSelection( LAYER_NUM layer )
{
int elements = GetCount();
......@@ -97,8 +97,8 @@ int LAYER_BOX_SELECTOR::SetLayerSelection( int layer )
void LAYER_BOX_SELECTOR::ResyncBitmapOnly()
{
int elements = GetCount();
for( int i = 0; i < elements; i++ )
LAYER_NUM elements = GetCount();
for( LAYER_NUM i = FIRST_LAYER; i < elements; ++i )
{
wxBitmap layerbmp( 14, 14 );
SetBitmapLayer( layerbmp, i );
......@@ -106,14 +106,14 @@ void LAYER_BOX_SELECTOR::ResyncBitmapOnly()
}
void LAYER_BOX_SELECTOR::SetBitmapLayer( wxBitmap& aLayerbmp, int aLayerIndex )
void LAYER_BOX_SELECTOR::SetBitmapLayer( wxBitmap& aLayerbmp, LAYER_NUM aLayer )
{
wxMemoryDC bmpDC;
wxBrush brush;
// Prepare Bitmap
bmpDC.SelectObject( aLayerbmp );
brush.SetColour( MakeColour( GetLayerColor( aLayerIndex ) ) );
brush.SetColour( MakeColour( GetLayerColor( aLayer ) ) );
brush.SetStyle( wxSOLID );
bmpDC.SetBrush( brush );
......
......@@ -330,7 +330,7 @@ void PAGE_INFO::Format( OUTPUTFORMATTER* aFormatter, int aNestLevel, int aContro
GetCustomWidthMils() * 25.4 / 1000.0,
GetCustomHeightMils() * 25.4 / 1000.0 );
if( IsCustom() && IsPortrait() )
if( !IsCustom() && IsPortrait() )
aFormatter->Print( 0, " portrait" );
aFormatter->Print( 0, ")\n" );
......
......@@ -195,7 +195,7 @@ UNDO_REDO_T PICKED_ITEMS_LIST::GetPickedItemStatus( unsigned int aIdx )
}
int PICKED_ITEMS_LIST::GetPickerFlags( unsigned aIdx )
STATUS_FLAGS PICKED_ITEMS_LIST::GetPickerFlags( unsigned aIdx )
{
if( aIdx < m_ItemsList.size() )
return m_ItemsList[aIdx].GetFlags();
......@@ -253,7 +253,7 @@ bool PICKED_ITEMS_LIST::SetPickedItemStatus( UNDO_REDO_T aStatus, unsigned aIdx
}
bool PICKED_ITEMS_LIST::SetPickerFlags( int aFlags, unsigned aIdx )
bool PICKED_ITEMS_LIST::SetPickerFlags( STATUS_FLAGS aFlags, unsigned aIdx )
{
if( aIdx < m_ItemsList.size() )
{
......
......@@ -52,14 +52,9 @@ wxString g_ProductName = wxT( "KiCad E.D.A. " );
bool g_ShowPageLimits = true;
wxString g_UserLibDirBuffer;
wxString g_Prj_Default_Config_FullFilename;
wxString g_Prj_Config_LocalFilename;
EDA_UNITS_T g_UserUnit;
EDA_COLOR_T g_GhostColor;
#if defined(KICAD_GOST)
static const bool s_gost = true;
#else
......@@ -77,34 +72,40 @@ bool IsGOST()
* Please: if you change a value, remember these values are carefully chosen
* to have good results in Pcbnew, that uses the ORed value of basic colors
* when displaying superimposed objects
* This list must have exactly NBCOLOR items
* This list must have exactly NBCOLORS items
*/
StructColors ColorRefs[NBCOLOR] =
const StructColors g_ColorRefs[NBCOLORS] =
{
{ 0, 0, 0, BLACK, wxT( "BLACK" ), DARKDARKGRAY },
{ 192, 0, 0, BLUE, wxT( "BLUE" ), LIGHTBLUE },
{ 0, 160, 0, GREEN, wxT( "GREEN" ), LIGHTGREEN },
{ 160, 160, 0, CYAN, wxT( "CYAN" ), LIGHTCYAN },
{ 0, 0, 160, RED, wxT( "RED" ), LIGHTRED },
{ 160, 0, 160, MAGENTA, wxT( "MAGENTA" ), LIGHTMAGENTA },
{ 0, 128, 128, BROWN, wxT( "BROWN" ), YELLOW },
{ 192, 192, 192, LIGHTGRAY, wxT( "GRAY" ), WHITE },
{ 128, 128, 128, DARKGRAY, wxT( "DARKGRAY" ), LIGHTGRAY },
{ 255, 0, 0, LIGHTBLUE, wxT( "LIGHTBLUE" ), LIGHTBLUE },
{ 0, 255, 0, LIGHTGREEN, wxT( "LIGHTGREEN" ), LIGHTGREEN },
{ 255, 255, 0, LIGHTCYAN, wxT( "LIGHTCYAN" ), LIGHTCYAN },
{ 0, 0, 255, LIGHTRED, wxT( "LIGHTRED" ), LIGHTRED },
{ 255, 0, 255, LIGHTMAGENTA, wxT( "LIGHTMAGENTA" ), LIGHTMAGENTA },
{ 0, 255, 255, YELLOW, wxT( "YELLOW" ), YELLOW },
{ 255, 255, 255, WHITE, wxT( "WHITE" ), WHITE },
{ 64, 64, 64, DARKDARKGRAY, wxT( "DARKDARKGRAY" ), DARKGRAY },
{ 64, 0, 0, DARKBLUE, wxT( "DARKBLUE" ), BLUE },
{ 0, 64, 0, DARKGREEN, wxT( "DARKGREEN" ), GREEN },
{ 64, 64, 0, DARKCYAN, wxT( "DARKCYAN" ), CYAN },
{ 0, 0, 80, DARKRED, wxT( "DARKRED" ), RED },
{ 64, 0, 64, DARKMAGENTA, wxT( "DARKMAGENTA" ), MAGENTA },
{ 0, 64, 64, DARKBROWN, wxT( "DARKBROWN" ), BROWN },
{ 128, 255, 255, LIGHTYELLOW, wxT( "LIGHTYELLOW" ), LIGHTYELLOW }
{ 0, 0, 0, BLACK, wxT( "Black" ), DARKDARKGRAY },
{ 72, 72, 72, DARKDARKGRAY, wxT( "Gray 1" ), DARKGRAY },
{ 132, 132, 132, DARKGRAY, wxT( "Gray 2" ), LIGHTGRAY },
{ 194, 194, 194, LIGHTGRAY, wxT( "Gray 3" ), WHITE },
{ 255, 255, 255, WHITE, wxT( "White" ), WHITE },
{ 194, 255, 255, LIGHTYELLOW, wxT( "L.Yellow" ), WHITE },
{ 72, 0, 0, DARKBLUE, wxT( "Blue 1" ), BLUE },
{ 0, 72, 0, DARKGREEN, wxT( "Green 1" ), GREEN },
{ 72, 72, 0, DARKCYAN, wxT( "Cyan 1" ), CYAN },
{ 0, 0, 72, DARKRED, wxT( "Red 1" ), RED },
{ 72, 0, 72, DARKMAGENTA, wxT( "Magenta 1" ), MAGENTA },
{ 0, 72, 72, DARKBROWN, wxT( "Brown 1" ), BROWN },
{ 132, 0, 0, BLUE, wxT( "Blue 2" ), LIGHTBLUE },
{ 0, 132, 0, GREEN, wxT( "Green 2" ), LIGHTGREEN },
{ 132, 132, 0, CYAN, wxT( "Cyan 2" ), LIGHTCYAN },
{ 0, 0, 132, RED, wxT( "Red 2" ), LIGHTRED },
{ 132, 0, 132, MAGENTA, wxT( "Magenta 2" ), LIGHTMAGENTA },
{ 0, 132, 132, BROWN, wxT( "Brown 2" ), YELLOW },
{ 194, 0, 0, LIGHTBLUE, wxT( "Blue 3" ), PUREBLUE, },
{ 0, 194, 0, LIGHTGREEN, wxT( "Green 3" ), PUREGREEN },
{ 194, 194, 0, LIGHTCYAN, wxT( "Cyan 3" ), PURECYAN },
{ 0, 0, 194, LIGHTRED, wxT( "Red 3" ), PURERED },
{ 194, 0, 194, LIGHTMAGENTA, wxT( "Magenta 3" ), PUREMAGENTA },
{ 0, 194, 194, YELLOW, wxT( "Yellow 3" ), PUREYELLOW },
{ 255, 0, 0, PUREBLUE, wxT( "Blue 4" ), WHITE },
{ 0, 255, 0, PUREGREEN, wxT( "Green 4" ), WHITE },
{ 255, 255, 0, PURECYAN, wxT( "Cyan 4" ), WHITE },
{ 0, 0, 255, PURERED, wxT( "Red 4" ), WHITE },
{ 255, 0, 255, PUREMAGENTA, wxT( "Magenta 4" ), WHITE },
{ 0, 255, 255, PUREYELLOW, wxT( "Yellow 4" ), WHITE },
};
......
......@@ -45,7 +45,7 @@ void DXF_PLOTTER::SetViewport( const wxPoint& aOffset, double aIusPerDecimil,
SetDefaultLineWidth( 0 ); // No line width on DXF
plotMirror = false; // No mirroring on DXF
currentColor = BLACK;
m_currentColor = BLACK;
}
/**
......@@ -151,7 +151,7 @@ bool DXF_PLOTTER::StartPlot()
" 2\n"
"LAYER\n"
" 70\n"
"%d\n", NBCOLOR );
"%d\n", NBCOLORS );
/* The layer/colors palette. The acad/DXF palette is divided in 3 zones:
......@@ -159,7 +159,7 @@ bool DXF_PLOTTER::StartPlot()
- An HSV zone (10-250, 5 values x 2 saturations x 10 hues
- Greys (251 - 255)
The is *no* black... the white does it on paper, usually, and
There is *no* black... the white does it on paper, usually, and
anyway it depends on the plotter configuration, since DXF colors
are meant to be logical only (they represent *both* line color and
width); later version with plot styles only complicate the matter!
......@@ -170,36 +170,41 @@ bool DXF_PLOTTER::StartPlot()
static const struct {
const char *name;
int color;
} dxf_layer[NBCOLOR] = {
{ "BLACK", 250 },
{ "BLUE", 5 },
{ "GREEN", 3 },
{ "CYAN", 4 },
{ "RED", 1 },
{ "MAGENTA", 6 },
{ "BROWN", 54 },
{ "LIGHTGRAY", 9 },
{ "DARKGRAY", 8 },
{ "LIGHTBLUE", 171 },
{ "LIGHTGREEN", 91 },
{ "LIGHTCYAN", 131 },
{ "LIGHTRED", 11 },
{ "LIGHTMAGENTA", 221 },
{ "YELLOW", 2 },
} dxf_layer[NBCOLORS] = {
{ "BLACK", 7 }, // In DXF, color 7 is *both* white and black!
{ "GRAY1", 251 },
{ "GRAY2", 8 },
{ "GRAY3", 9 },
{ "WHITE", 7 },
{ "DARKDARKGRAY", 251 },
{ "DARKBLUE", 178 },
{ "DARKGREEN", 98 },
{ "DARKCYAN", 138 },
{ "DARKRED", 18 },
{ "DARKMAGENTA", 228 },
{ "DARKBROWN", 58 },
{ "LIGHTYELLOW", 51 },
{ "LYELLOW", 51 },
{ "BLUE1", 178 },
{ "GREEN1", 98 },
{ "CYAN1", 138 },
{ "RED1", 18 },
{ "MAGENTA1", 228 },
{ "BROWN1", 58 },
{ "BLUE2", 5 },
{ "GREEN2", 3 },
{ "CYAN2", 4 },
{ "RED2", 1 },
{ "MAGENTA2", 6 },
{ "BROWN2", 54 },
{ "BLUE3", 171 },
{ "GREEN3", 91 },
{ "CYAN3", 131 },
{ "RED3", 11 },
{ "MAGENTA3", 221 },
{ "YELLOW3", 2 },
{ "BLUE4", 5 },
{ "GREEN4", 3 },
{ "CYAN4", 4 },
{ "RED4", 1 },
{ "MAGENTA4", 6 },
{ "YELLOW4", 2 }
};
for( int i = 0; i < NBCOLOR; i++ )
for( EDA_COLOR_T i = BLACK; i < NBCOLORS; i = NextColor(i) )
{
wxString cname = ColorRefs[i].m_Name;
fprintf( outputFile,
" 0\n"
"LAYER\n"
......@@ -254,10 +259,10 @@ void DXF_PLOTTER::SetColor( EDA_COLOR_T color )
|| ( color == BLACK )
|| ( color == WHITE ) )
{
currentColor = color;
m_currentColor = color;
}
else
currentColor = BLACK;
m_currentColor = BLACK;
}
/**
......@@ -287,7 +292,7 @@ void DXF_PLOTTER::Circle( const wxPoint& centre, int diameter, FILL_T fill, int
DPOINT centre_dev = userToDeviceCoordinates( centre );
if( radius > 0 )
{
wxString cname = ColorRefs[currentColor].m_Name;
wxString cname( ColorGetName( m_currentColor ) );
if (!fill)
{
fprintf( outputFile, "0\nCIRCLE\n8\n%s\n10\n%g\n20\n%g\n40\n%g\n",
......@@ -349,7 +354,7 @@ void DXF_PLOTTER::PenTo( const wxPoint& pos, char plume )
if( penLastpos != pos && plume == 'D' )
{
// DXF LINE
wxString cname = ColorRefs[currentColor].m_Name;
wxString cname( ColorGetName( m_currentColor ) );
fprintf( outputFile, "0\nLINE\n8\n%s\n10\n%g\n20\n%g\n11\n%g\n21\n%g\n",
TO_UTF8( cname ),
pen_lastpos_dev.x, pen_lastpos_dev.y, pos_dev.x, pos_dev.y );
......@@ -396,7 +401,7 @@ void DXF_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int rad
double radius_dev = userToDeviceSize( radius );
// Emit a DXF ARC entity
wxString cname = ColorRefs[currentColor].m_Name;
wxString cname( ColorGetName( m_currentColor ) );
fprintf( outputFile,
"0\nARC\n8\n%s\n10\n%g\n20\n%g\n40\n%g\n50\n%g\n51\n%g\n",
TO_UTF8( cname ),
......@@ -570,7 +575,7 @@ void DXF_PLOTTER::Text( const wxPoint& aPos,
more useful as a CAD object */
DPOINT origin_dev = userToDeviceCoordinates( aPos );
SetColor( aColor );
wxString cname = ColorRefs[currentColor].m_Name;
wxString cname( ColorGetName( m_currentColor ) );
DPOINT size_dev = userToDeviceSize( aSize );
int h_code = 0, v_code = 0;
switch( aH_justify )
......
......@@ -39,9 +39,9 @@ void PSLIKE_PLOTTER::SetColor( EDA_COLOR_T color )
if( colorMode )
{
double r = ColorRefs[color].m_Red / 255.0;
double g = ColorRefs[color].m_Green / 255.0;
double b = ColorRefs[color].m_Blue / 255.0;
double r = g_ColorRefs[color].m_Red / 255.0;
double g = g_ColorRefs[color].m_Green / 255.0;
double b = g_ColorRefs[color].m_Blue / 255.0;
if( negativeMode )
emitSetRGBColor( 1 - r, 1 - g, 1 - b );
else
......
This diff is collapsed.
/*
/**
* @file confirm.cpp
* utilities to display some error, warning and info short messges
* @brief utilities to display some error, warning and info short messges
*/
#include <fctsys.h>
......
......@@ -109,8 +109,7 @@ bool DrawPageOnClipboard( EDA_DRAW_FRAME* aFrame )
dc.SetClippingRegion( DrawArea );
}
const int maskLayer = 0xFFFFFFFF;
aFrame->PrintPage( &dc, maskLayer, false );
aFrame->PrintPage( &dc, FULL_LAYERS, false );
screen->m_IsPrinting = false;
aFrame->GetCanvas()->SetClipBox( tmp );
wxMetafile* mf = dc.Close();
......
......@@ -63,9 +63,9 @@ const wxString pageFmts[] =
_("C 17x22in"),
_("D 22x34in"),
_("E 34x44in"),
_("USLetter 8.5x11in"),
_("USLegal 8.5x14in"),
_("USLedger 11x17in"),
_("US Letter 8.5x11in"),
_("US Legal 8.5x14in"),
_("US Ledger 11x17in"),
_("User (Custom)"),
wxT("") // end of list
};
......@@ -609,12 +609,20 @@ void DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample()
wxPoint pointLeftTop( pageDUMMY.GetLeftMarginMils(), pageDUMMY.GetTopMarginMils() );
wxPoint pointRightBottom( pageDUMMY.GetRightMarginMils(), pageDUMMY.GetBottomMarginMils() );
// Get page type
int idx = m_paperSizeComboBox->GetSelection();
if( idx < 0 )
idx = 0;
wxString paperType = m_pageFmt[idx].Left( m_pageFmt[idx].Index( wxT( " " ) ) );
// Draw layout preview.
wxString emptyString;
GRResetPenAndBrush( ( wxDC* ) &memDC );
m_Parent->TraceWorkSheet( (wxDC*) &memDC, dummySize, pointLeftTop, pointRightBottom,
emptyString, emptyString, m_tb, m_Screen->m_NumberOfScreens,
paperType, emptyString, m_tb, m_Screen->m_NumberOfScreens,
m_Screen->m_ScreenNumber, 1, appScale, LIGHTGRAY, RED );
memDC.SelectObject( wxNullBitmap );
......
......@@ -166,9 +166,7 @@ EDA_DRAW_FRAME::EDA_DRAW_FRAME( wxWindow* aParent,
m_messagePanel = new EDA_MSG_PANEL( this, -1, wxPoint( 0, m_FrameSize.y ),
wxSize( m_FrameSize.x, m_MsgFrameHeight ) );
m_messagePanel->SetBackgroundColour( wxColour( ColorRefs[LIGHTGRAY].m_Red,
ColorRefs[LIGHTGRAY].m_Green,
ColorRefs[LIGHTGRAY].m_Blue ) );
m_messagePanel->SetBackgroundColour( MakeColour( LIGHTGRAY ) );
}
......@@ -324,7 +322,7 @@ void EDA_DRAW_FRAME::ToolOnRightClick( wxCommandEvent& event )
}
void EDA_DRAW_FRAME::PrintPage( wxDC* aDC,int aPrintMask, bool aPrintMirrorMode, void* aData )
void EDA_DRAW_FRAME::PrintPage( wxDC* aDC,LAYER_MSK aPrintMask, bool aPrintMirrorMode, void* aData )
{
wxMessageBox( wxT("EDA_DRAW_FRAME::PrintPage() error") );
}
......
This diff is collapsed.
......@@ -29,7 +29,7 @@
#include <cstdlib> // bsearch()
#include <cctype>
#include <macros.h>
#include <dsnlexer.h>
//#include "fctsys.h"
......@@ -280,24 +280,25 @@ bool DSNLEXER::IsSymbol( int aTok )
void DSNLEXER::Expecting( int aTok ) throw( IO_ERROR )
{
wxString errText( _("Expecting") );
errText << wxT(" ") << GetTokenString( aTok );
wxString errText;
errText.Printf( _("Expecting '%s'"), GetChars( GetTokenString( aTok ) ) );
THROW_PARSE_ERROR( errText, CurSource(), CurLine(), CurLineNumber(), CurOffset() );
}
void DSNLEXER::Expecting( const char* text ) throw( IO_ERROR )
{
wxString errText( _("Expecting") );
errText << wxT(" '") << wxString::FromUTF8( text ) << wxT("'");
wxString errText;
errText.Printf( _("Expecting '%s'"),
GetChars( wxString::FromUTF8( text ) ) );
THROW_PARSE_ERROR( errText, CurSource(), CurLine(), CurLineNumber(), CurOffset() );
}
void DSNLEXER::Unexpected( int aTok ) throw( IO_ERROR )
{
wxString errText( _("Unexpected") );
errText << wxT(" ") << GetTokenString( aTok );
wxString errText;
errText.Printf( _("Unexpected '%s'"), GetChars( GetTokenString( aTok ) ) );
THROW_PARSE_ERROR( errText, CurSource(), CurLine(), CurLineNumber(), CurOffset() );
}
......@@ -312,8 +313,9 @@ void DSNLEXER::Duplicate( int aTok ) throw( IO_ERROR )
void DSNLEXER::Unexpected( const char* text ) throw( IO_ERROR )
{
wxString errText( _("Unexpected") );
errText << wxT(" '") << wxString::FromUTF8( text ) << wxT("'");
wxString errText;
errText.Printf( _("Unexpected '%s'"),
GetChars( wxString::FromUTF8( text ) ) );
THROW_PARSE_ERROR( errText, CurSource(), CurLine(), CurLineNumber(), CurOffset() );
}
......
......@@ -122,8 +122,7 @@ bool GetAssociatedDocument( wxFrame* aFrame,
if( !wxFileExists( fullfilename ) )
{
msg = _( "Doc File " );
msg << wxT("\"") << aDocName << wxT("\"") << _( " not found" );
msg.Printf( _( "Doc File <%s> not found" ), GetChars( aDocName ) );
DisplayError( aFrame, msg );
return false;
}
......
......@@ -269,22 +269,12 @@ void EDA_TEXT::DrawOneLineOfText( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
if( aDrawMode != -1 )
GRSetDrawMode( aDC, aDrawMode );
/* Draw text anchor, if allowed */
// Draw text anchor, if requested
if( aAnchor_color != UNSPECIFIED_COLOR )
{
int anchor_size = aDC->DeviceToLogicalXRel( 2 );
aAnchor_color = (EDA_COLOR_T) ( aAnchor_color & MASKCOLOR );
int cX = aPos.x + aOffset.x;
int cY = aPos.y + aOffset.y;
GRLine( aPanel->GetClipBox(), aDC, cX - anchor_size, cY,
cX + anchor_size, cY, 0, aAnchor_color );
GRLine( aPanel->GetClipBox(), aDC, cX, cY - anchor_size,
cX, cY + anchor_size, 0, aAnchor_color );
GRDrawAnchor( aPanel->GetClipBox(), aDC,
aPos.x + aOffset.x, aPos.y + aOffset.y,
DIM_ANCRE_TEXTE, aAnchor_color );
}
if( aFillMode == SKETCH )
......
......@@ -652,15 +652,16 @@ bool OpenPDF( const wxString& file )
if( !success )
{
wxString msg = _( "Problem while running the PDF viewer" );
msg << _( "\n command is " ) << command;
wxString msg;
msg.Printf( _( "Problem while running the PDF viewer\nCommand is '%s'" ),
GetChars( command ) );
DisplayError( NULL, msg );
}
}
else
{
wxString msg = _( "Unable to find a PDF viewer for" );
msg << wxT( " " ) << filename;
wxString msg;
msg.Printf( _( "Unable to find a PDF viewer for <%s>" ), GetChars( filename ) );
DisplayError( NULL, msg );
success = false;
}
......
......@@ -1451,3 +1451,124 @@ void GRBezier( EDA_RECT* ClipBox,
std::vector<wxPoint> Points = Bezier2Poly( x1, y1, x2, y2, x3, y3, x4, y4 );
GRPoly( ClipBox, DC, Points.size(), &Points[0], false, width, Color, Color );
}
EDA_COLOR_T ColorMix( EDA_COLOR_T aColor1, EDA_COLOR_T aColor2 )
{
/* Memoization storage. This could be potentially called for each
* color merge so a cache is useful (there are few colours anyway) */
static EDA_COLOR_T mix_cache[NBCOLORS][NBCOLORS];
// TODO how is alpha used? it's a mac only thing, I have no idea
aColor1 = ColorGetBase( aColor1 );
aColor2 = ColorGetBase( aColor2 );
// First easy thing: a black gives always the other colour
if( aColor1 == BLACK )
return aColor2;
if( aColor2 == BLACK)
return aColor1;
/* Now we are sure that black can't occur, so the rule is:
* BLACK means not computed yet. If we're lucky we already have
* an answer */
EDA_COLOR_T candidate = mix_cache[aColor1][aColor2];
if( candidate != BLACK )
return candidate;
// Blend the two colors (i.e. OR the RGB values)
const StructColors &c1 = g_ColorRefs[aColor1];
const StructColors &c2 = g_ColorRefs[aColor2];
// Ask the palette for the nearest color to the mix
wxColour mixed( c1.m_Red | c2.m_Red,
c1.m_Green | c2.m_Green,
c1.m_Blue | c2.m_Blue );
candidate = ColorFindNearest( mixed );
/* Here, BLACK is *not* a good answer, since it would recompute the next time.
* Even theorically its not possible (with the current rules), but
* maybe the metric will change in the future */
if( candidate == BLACK)
candidate = DARKDARKGRAY;
// Store the result in the cache. The operation is commutative, too
mix_cache[aColor1][aColor2] = candidate;
mix_cache[aColor2][aColor1] = candidate;
return candidate;
}
EDA_COLOR_T ColorByName( const wxChar *aName )
{
// look for a match in the palette itself
for( EDA_COLOR_T trying = BLACK; trying < NBCOLORS; trying = NextColor(trying) )
{
if( 0 == wxStricmp( aName, g_ColorRefs[trying].m_Name ) )
return trying;
}
// Not found, no idea...
return UNSPECIFIED_COLOR;
}
bool ColorIsLight( EDA_COLOR_T aColor )
{
const StructColors &c = g_ColorRefs[ColorGetBase( aColor )];
int r = c.m_Red;
int g = c.m_Green;
int b = c.m_Blue;
return ((r * r) + (g * g) + (b * b)) > (128 * 128 * 3);
}
EDA_COLOR_T ColorFindNearest( const wxColour &aColor )
{
EDA_COLOR_T candidate = BLACK;
// These are ints because we will subtract them later
int r = aColor.Red();
int g = aColor.Green();
int b = aColor.Blue();
/* Find the 'nearest' color in the palette. This is fun. There is
a gazilion of metrics for the color space and no one of the
useful one is in the RGB color space. Who cares, this is a CAD,
not a photosomething...
I hereby declare that the distance is the sum of the square of the
component difference. Think about the RGB color cube. Now get the
euclidean distance, but without the square root... for ordering
purposes it's the same, obviously. Also each component can't be
less of the target one, since I found this currently work better...
*/
int nearest_distance = 255 * 255 * 3 + 1; // Can't beat this
for( EDA_COLOR_T trying = BLACK; trying < NBCOLORS; trying = NextColor(trying) )
{
const StructColors &c = g_ColorRefs[trying];
int distance = (r - c.m_Red) * (r - c.m_Red) +
(g - c.m_Green) * (g - c.m_Green) +
(b - c.m_Blue) * (b - c.m_Blue);
if( distance < nearest_distance && c.m_Red >= r &&
c.m_Green >= g && c.m_Blue >= b )
{
nearest_distance = distance;
candidate = trying;
}
}
return candidate;
}
void GRDrawAnchor( EDA_RECT *aClipBox, wxDC *aDC, int x, int y,
int aSize, EDA_COLOR_T aColor )
{
int anchor_size = aDC->DeviceToLogicalXRel( aSize );
GRLine( aClipBox, aDC,
x - anchor_size, y,
x + anchor_size, y, 0, aColor );
GRLine( aClipBox, aDC,
x, y - anchor_size,
x, y + anchor_size, 0, aColor );
}
......@@ -205,9 +205,7 @@ void EDA_MSG_PANEL::showItem( wxDC& aDC, const MSG_PANEL_ITEM& aItem )
if( color >= 0 )
{
color = ColorGetBase( color );
aDC.SetTextForeground( wxColour( ColorRefs[color].m_Red,
ColorRefs[color].m_Green,
ColorRefs[color].m_Blue ) );
aDC.SetTextForeground( MakeColour( color ) );
}
if( !aItem.m_UpperText.IsEmpty() )
......
......@@ -123,7 +123,7 @@ const char* const newstroke_font[] =
"KYVcUcSbR`RVQTOSQRRPRFSDUCVC",
"H\\RbRD",
"KYNcOcQbR`RVSTUSSRRPRFQDOCNC",
"KZMHNGPFTHVGWF",
"KZMSNRPQTSVRWQ",
"F^K[KFYFY[K[",
/* // LATIN-1 SUPPLEMENT (0080-00FF) */
"F^K[KFYFY[K[", /* U+80 */
......
......@@ -46,11 +46,11 @@ RENDER_SETTINGS::RENDER_SETTINGS()
m_outlineWidth = 60000;
// Store the predefined colors used in KiCad in format used by GAL
for( int i = 0; i < NBCOLOR; i++ )
for( int i = 0; i < NBCOLORS; i++ )
{
m_legacyColorMap[ColorRefs[i].m_Numcolor] = COLOR4D( (double) ColorRefs[i].m_Red / 255.0,
(double) ColorRefs[i].m_Green / 255.0,
(double) ColorRefs[i].m_Blue / 255.0,
m_legacyColorMap[g_ColorRefs[i].m_Numcolor] = COLOR4D( (double) g_ColorRefs[i].m_Red / 255.0,
(double) g_ColorRefs[i].m_Green / 255.0,
(double) g_ColorRefs[i].m_Blue / 255.0,
m_layerOpacity );
}
}
......
......@@ -34,6 +34,7 @@
#include <pcbcommon.h>
#include <plot_common.h>
#include <class_board.h>
#include <class_pad.h>
#include <class_zone_settings.h>
#include <class_board_design_settings.h>
......@@ -42,36 +43,9 @@
class MODULE;
/* return a one bit layer mask from a layer number
* aLayerNumber = the layer number to convert (0 .. LAYER_COUNT-1)
*/
int GetLayerMask( int aLayerNumber )
{
wxASSERT( aLayerNumber < LAYER_COUNT && aLayerNumber >= 0 );
#if 0
// Look up Table for conversion one layer number -> one bit layer mask:
static int tabOneLayerMask[LAYER_COUNT] =
{
0x00000001, 0x00000002, 0x00000004, 0x00000008,
0x00000010, 0x00000020, 0x00000040, 0x00000080,
0x00000100, 0x00000200, 0x00000400, 0x00000800,
0x00001000, 0x00002000, 0x00004000, 0x00008000,
0x00010000, 0x00020000, 0x00040000, 0x00080000,
0x00100000, 0x00200000, 0x00400000, 0x00800000,
0x01000000, 0x02000000, 0x04000000, 0x08000000,
0x10000000, 0x20000000, 0x40000000, 0x80000000
};
return( tabOneLayerMask[aLayerNumber] );
#else
return 1 << aLayerNumber;
#endif
}
/* Look up Table for conversion copper layer count -> general copper layer
* mask: */
int g_TabAllCopperLayerMask[NB_COPPER_LAYERS] = {
LAYER_MSK g_TabAllCopperLayerMask[NB_COPPER_LAYERS] = {
0x0001, 0x8001, 0x8003, 0x8007,
0x800F, 0x801F, 0x803F, 0x807F,
0x80FF, 0x81FF, 0x83FF, 0x87FF,
......@@ -79,7 +53,7 @@ int g_TabAllCopperLayerMask[NB_COPPER_LAYERS] = {
};
DISPLAY_OPTIONS DisplayOpt; /* Display options for board items */
DISPLAY_OPTIONS DisplayOpt; // Display options for board items
int g_RotationAngle;
......@@ -99,3 +73,156 @@ int g_PadCMPColor = RED;
*/
DLIST<TRACK> g_CurrentTrackList;
LAYER_NUM FlipLayer( LAYER_NUM oldlayer )
{
switch( oldlayer )
{
case LAYER_N_BACK:
return LAYER_N_FRONT;
case LAYER_N_FRONT:
return LAYER_N_BACK;
case SILKSCREEN_N_BACK:
return SILKSCREEN_N_FRONT;
case SILKSCREEN_N_FRONT:
return SILKSCREEN_N_BACK;
case ADHESIVE_N_BACK:
return ADHESIVE_N_FRONT;
case ADHESIVE_N_FRONT:
return ADHESIVE_N_BACK;
case SOLDERMASK_N_BACK:
return SOLDERMASK_N_FRONT;
case SOLDERMASK_N_FRONT:
return SOLDERMASK_N_BACK;
case SOLDERPASTE_N_BACK:
return SOLDERPASTE_N_FRONT;
case SOLDERPASTE_N_FRONT:
return SOLDERPASTE_N_BACK;
// No change for the other layers
default:
return oldlayer;
}
}
LAYER_MSK FlipLayerMask( LAYER_MSK aMask )
{
LAYER_MSK newMask;
newMask = aMask & ~(LAYER_BACK | LAYER_FRONT |
SILKSCREEN_LAYER_BACK | SILKSCREEN_LAYER_FRONT |
ADHESIVE_LAYER_BACK | ADHESIVE_LAYER_FRONT |
SOLDERMASK_LAYER_BACK | SOLDERMASK_LAYER_FRONT |
SOLDERPASTE_LAYER_BACK | SOLDERPASTE_LAYER_FRONT |
ADHESIVE_LAYER_BACK | ADHESIVE_LAYER_FRONT);
if( aMask & LAYER_BACK )
newMask |= LAYER_FRONT;
if( aMask & LAYER_FRONT )
newMask |= LAYER_BACK;
if( aMask & SILKSCREEN_LAYER_BACK )
newMask |= SILKSCREEN_LAYER_FRONT;
if( aMask & SILKSCREEN_LAYER_FRONT )
newMask |= SILKSCREEN_LAYER_BACK;
if( aMask & ADHESIVE_LAYER_BACK )
newMask |= ADHESIVE_LAYER_FRONT;
if( aMask & ADHESIVE_LAYER_FRONT )
newMask |= ADHESIVE_LAYER_BACK;
if( aMask & SOLDERMASK_LAYER_BACK )
newMask |= SOLDERMASK_LAYER_FRONT;
if( aMask & SOLDERMASK_LAYER_FRONT )
newMask |= SOLDERMASK_LAYER_BACK;
if( aMask & SOLDERPASTE_LAYER_BACK )
newMask |= SOLDERPASTE_LAYER_FRONT;
if( aMask & SOLDERPASTE_LAYER_FRONT )
newMask |= SOLDERPASTE_LAYER_BACK;
if( aMask & ADHESIVE_LAYER_BACK )
newMask |= ADHESIVE_LAYER_FRONT;
if( aMask & ADHESIVE_LAYER_FRONT )
newMask |= ADHESIVE_LAYER_BACK;
return newMask;
}
LAYER_NUM ExtractLayer( LAYER_MSK aMask )
{
if( aMask == NO_LAYERS )
return UNSELECTED_LAYER;
LAYER_NUM candidate = UNDEFINED_LAYER;
// Scan all the layers and take note of the first set; if other are
// then found return UNDEFINED_LAYER
for( LAYER_NUM i = FIRST_LAYER; i < NB_LAYERS; ++i )
{
if( aMask & GetLayerMask( i ) )
{
if( candidate == UNDEFINED_LAYER )
candidate = i;
else
return UNDEFINED_LAYER;
}
}
return candidate;
}
wxString LayerMaskDescribe( const BOARD *aBoard, LAYER_MSK aMask )
{
// Try the single or no- layer case (easy)
LAYER_NUM layer = ExtractLayer( aMask );
switch( layer )
{
case UNSELECTED_LAYER:
return _( "No layers" );
case UNDEFINED_LAYER:
break;
default:
return aBoard->GetLayerName( layer );
}
// Try to be smart and useful, starting with outer copper
// (which are more important than internal ones)
wxString layerInfo;
if( aMask & LAYER_FRONT )
AccumulateDescription( layerInfo, aBoard->GetLayerName( LAYER_N_FRONT ) );
if( aMask & LAYER_BACK )
AccumulateDescription( layerInfo, aBoard->GetLayerName( LAYER_N_BACK ) );
if( aMask & INTERNAL_CU_LAYERS )
AccumulateDescription( layerInfo, _("Internal" ) );
if( aMask & ALL_NO_CU_LAYERS )
AccumulateDescription( layerInfo, _("Non-copper" ) );
return layerInfo;
}
void AccumulateDescription( wxString &aDesc, const wxString &aItem )
{
if( !aDesc.IsEmpty() )
aDesc << wxT(", ");
aDesc << aItem;
}
This diff is collapsed.
/*
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2013 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
* Copyright (C) 2013 KiCad Developers, see CHANGELOG.TXT for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, you may find one here:
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
* or you may search the http://www.gnu.org website for the version 2 license,
* or you may write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
// Something in either <boost/property_tree/ptree.hpp> causes a bunch of compiler
// errors in <wx/msw/winundef.h> version 2.9 on MinGW.
#include <macros.h>
#include <boost/property_tree/ptree.hpp>
#include <assert.h>
#include <ptree.h>
typedef PTREE::const_iterator CITER;
typedef PTREE::iterator ITER;
#if defined(DEBUG)
#define D(x) x
#else
#define D(x)
#endif
#define CTL_OMIT_NL (1<<0)
#define CTL_IN_ATTRS (1<<1)
//-----<Scan>------------------------------------------------------------------
/**
* Function scanList
* reads a sexpr list from the input stream into a new node with key
* aLexer->CurText().
*/
inline void scanList( PTREE* aTree, DSNLEXER* aLexer )
{
assert( aLexer->CurTok() == DSN_LEFT );
int tok = aLexer->NextTok();
const char* key = aLexer->CurText();
//D(printf( "%s: '%s'\n", __func__, key );)
PTREE* list = &aTree->push_back( PTREE::value_type( key, PTREE() ) )->second;
if( tok != DSN_RIGHT )
{
while( ( tok = aLexer->NextTok() ) != DSN_RIGHT )
{
if( tok == DSN_EOF )
aLexer->Unexpected( DSN_EOF );
Scan( list, aLexer );
}
}
}
inline void scanAtom( PTREE* aTree, DSNLEXER* aLexer )
{
const char* key = aLexer->CurText();
//D(printf( "%s: '%s'\n", __func__, key );)
aTree->push_back( PTREE::value_type( key, PTREE() ) );
}
void Scan( PTREE* aTree, DSNLEXER* aLexer ) throw( IO_ERROR )
{
int tok = aLexer->CurTok();
// conditionally read first token.
if( tok == DSN_NONE )
tok = aLexer->NextTok();
if( tok == DSN_EOF )
{
aLexer->Unexpected( DSN_EOF );
}
if( tok == DSN_LEFT )
{
scanList( aTree, aLexer );
}
else
{
scanAtom( aTree, aLexer );
}
}
//-----<Format>------------------------------------------------------------------
inline bool isAtom( CPTREE& aTree )
{
return aTree.size()==0 && aTree.data().size()==0;
}
inline bool isLast( CPTREE& aTree, CITER it )
{
CITER next = it;
++next;
return next == aTree.end();
}
inline CITER next( CITER it )
{
CITER n = it;
return ++n;
}
static void formatNode( OUTPUTFORMATTER* out, int aNestLevel, int aCtl,
const std::string& aKey, CPTREE& aTree ) throw( IO_ERROR );
static void formatList( OUTPUTFORMATTER* out, int aNestLevel, int aCtl, CPTREE& aTree )
throw( IO_ERROR )
{
for( CITER it = aTree.begin(); it != aTree.end(); ++it )
{
// Processing a tree which was read in with xml_parser?
if( it->first == "<xmlattr>" )
{
formatList( out, aNestLevel, aCtl | CTL_IN_ATTRS, it->second );
continue;
}
int ctl = 0;
#if defined(DEBUG)
if( it->first == "field" )
{
int breakhere = 1;
(void) breakhere;
}
#endif
if( isLast( aTree, it ) ) // is "it" the last one?
{
//if( !( aCtl & CTL_IN_ATTRS ) )
ctl = CTL_OMIT_NL;
}
else if( isAtom( next( it )->second ) )
{
/* if( !( aCtl & CTL_IN_ATTRS ) ) */
ctl = CTL_OMIT_NL;
}
formatNode( out, aNestLevel+1, ctl, it->first, it->second );
}
}
static void formatNode( OUTPUTFORMATTER* out, int aNestLevel, int aCtl,
const std::string& aKey, CPTREE& aTree )
throw( IO_ERROR )
{
if( !isAtom( aTree ) ) // is a list, not an atom
{
int ctl = CTL_OMIT_NL;
// aTree is list and its first child is a list
if( aTree.size() && !isAtom( aTree.begin()->second ) && !aTree.data().size() )
ctl = 0;
out->Print( aNestLevel, "(%s%s", out->Quotes( aKey ).c_str(), ctl & CTL_OMIT_NL ? "" : "\n" );
if( aTree.data().size() ) // only xml typically uses "data()", not sexpr.
{
out->Print( 0, " %s%s",
out->Quotes( aTree.data() ).c_str(),
aTree.size() ? "\n" : ""
);
}
formatList( out, aNestLevel, aCtl, aTree );
out->Print( 0, ")%s", aCtl & CTL_OMIT_NL ? "" : "\n" );
}
else // is an atom, not a list
{
const char* atom = out->Quotes( aKey ).c_str();
out->Print( 0, " %s", atom );
}
}
void Format( OUTPUTFORMATTER* out, int aNestLevel, int aCtl, CPTREE& aTree ) throw( IO_ERROR )
{
if( aTree.size() == 1 && !aTree.data().size() )
{
// The topmost node is basically only a container for the document root.
// It anchors the paths which traverse the tree deeper.
CITER it = aTree.begin();
formatNode( out, aNestLevel, aCtl, it->first, it->second );
}
else
{
// This is not expected, neither for sexpr nor xml.
formatNode( out, aNestLevel, aCtl, "", aTree );
}
}
......@@ -58,7 +58,7 @@ bool sort_schematic_items( const SCH_ITEM* aItem1, const SCH_ITEM* aItem2 )
SCH_ITEM::SCH_ITEM( EDA_ITEM* aParent, KICAD_T aType ) :
EDA_ITEM( aParent, aType )
{
m_Layer = 0;
m_Layer = LAYER_WIRE; // It's only a default, in fact
}
......
This diff is collapsed.
......@@ -95,4 +95,4 @@ const wxString PdfFileWildcard( _( "Portable document format files (*.pdf)|*.pdf
const wxString PSFileWildcard( _( "PostScript files (.ps)|*.ps" ) );
const wxString ReportFileWildcard = _( "Report files (*.rpt)|*.rpt" );
const wxString FootprintPlaceFileWildcard = _( "Footprint place files (*.pos)|*.pos" );
const wxString VrmlFileWildcard( _( "Vrml files (*.wrl)|*.wrl" ) );
const wxString Shapes3DFileWildcard( _( "Vrml and x3d files (*.wrl *.x3d)|*.wrl;*.x3d" ) );
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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