Commit 7f23d262 authored by charras's avatar charras
Browse files

Eeschema

* Some bugs fixed
* Starting enhancements in Libedit: menubar and commands to "plot" current component in PNG or SVF file (SVG file not fully working, must be refined)
parent 2c15036e
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -4,6 +4,13 @@ KiCad ChangeLog 2010
Please add newer entries at the top, list the date and your name with
email address.

2010-mar-18 UPDATE Jean-Pierre Charras <jean-pierre.charras@gipsa-lab.inpg.fr>
================================================================================
++Eeschema
    Some bugs fixed
    Starting enhancements in Libedit: menubar and commands to "plot"
    current component in PNG or SVF file (SVG file not fully working, must be refined)

2010-mar-13 UPDATE Jean-Pierre Charras <jean-pierre.charras@gipsa-lab.inpg.fr>
================================================================================
++ All:
+2 −2
Original line number Diff line number Diff line
@@ -6,10 +6,10 @@
#endif

#ifndef KICAD_BUILD_VERSION
#define KICAD_BUILD_VERSION "(2010-03-13)"
#define KICAD_BUILD_VERSION "(2010-03-17)"
#endif

#define VERSION_STABILITY "final"
#define VERSION_STABILITY "unstable"

/** Function GetBuildVersion()
 * Return the build date and version
+12 −11
Original line number Diff line number Diff line
@@ -18,7 +18,7 @@
static const bool   s_PlotBlackAndWhite = FALSE;
static const bool   Print_Sheet_Ref = TRUE;

static bool DrawPage( WinEDA_DrawPanel* panel );
static bool DrawPage( WinEDA_DrawFrame* aFrame );


/* calls the function to copy the current page or the current bock to
@@ -26,7 +26,7 @@ static bool DrawPage( WinEDA_DrawPanel* panel );
 */
void WinEDA_DrawFrame::CopyToClipboard( wxCommandEvent& event )
{
    DrawPage( DrawPanel );
    DrawPage( this );

    if(  event.GetId() == ID_GEN_COPY_BLOCK_TO_CLIPBOARD )
    {
@@ -43,7 +43,7 @@ void WinEDA_DrawFrame::CopyToClipboard( wxCommandEvent& event )
 * to export drawings to other applications (word processing ...)
 * This is not suitable for copy command within eeschema or pcbnew
 */
bool DrawPage( WinEDA_DrawPanel* panel )
bool DrawPage( WinEDA_DrawFrame* aFrame )
{
    bool    success = TRUE;

@@ -55,10 +55,10 @@ bool DrawPage( WinEDA_DrawPanel* panel )
    int     ClipboardSizeX, ClipboardSizeY;
    bool    DrawBlock = FALSE;
    wxRect  DrawArea;
    BASE_SCREEN* screen = panel->GetScreen();
    BASE_SCREEN* screen = aFrame->DrawPanel->GetScreen();

    /* scale is the ratio resolution/internal units */
    float   scale = 82.0 / panel->GetParent()->m_InternalUnits;
    float   scale = 82.0 / aFrame->m_InternalUnits;

    if( screen->m_BlockLocate.m_Command != BLOCK_IDLE )
    {
@@ -80,25 +80,26 @@ bool DrawPage( WinEDA_DrawPanel* panel )

    wxMetafileDC dc /*(wxT(""), DrawArea.GetWidth(), DrawArea.GetHeight())*/;

    EDA_Rect tmp = panel->m_ClipBox;
    EDA_Rect tmp = aFrame->DrawPanel->m_ClipBox;
    GRResetPenAndBrush( &dc );
    GRForceBlackPen( s_PlotBlackAndWhite );
    screen->m_IsPrinting = true;
    dc.SetUserScale( scale, scale );
    ClipboardSizeX = dc.MaxX() + 10;
    ClipboardSizeY = dc.MaxY() + 10;
    panel->m_ClipBox.SetX( 0 ); panel->m_ClipBox.SetY( 0 );
    panel->m_ClipBox.SetWidth( 0x7FFFFF0 );
    panel->m_ClipBox.SetHeight( 0x7FFFFF0 );
    aFrame->DrawPanel->m_ClipBox.SetX( 0 );
    aFrame->DrawPanel->m_ClipBox.SetY( 0 );
    aFrame->DrawPanel->m_ClipBox.SetWidth( 0x7FFFFF0 );
    aFrame->DrawPanel->m_ClipBox.SetHeight( 0x7FFFFF0 );

    if( DrawBlock )
    {
        dc.SetClippingRegion( DrawArea );
    }

    panel->PrintPage( &dc, Print_Sheet_Ref, -1, false, NULL );
    aFrame->PrintPage( &dc, Print_Sheet_Ref, -1, false );
    screen->m_IsPrinting = false;
    panel->m_ClipBox = tmp;
    aFrame->DrawPanel->m_ClipBox = tmp;
    wxMetafile* mf = dc.Close();

    if( mf )
+1 −1
Original line number Diff line number Diff line
@@ -30,7 +30,7 @@ DIALOG_PAGES_SETTINGS_BASE::DIALOG_PAGES_SETTINGS_BASE( wxWindow* parent, wxWind
	
	wxString m_PageSizeBoxChoices[] = { _("Size A4"), _("Size A3"), _("Size A2"), _("Size A1"), _("Size A0"), _("Size A"), _("Size B"), _("Size C"), _("Size D"), _("Size E"), _("User size") };
	int m_PageSizeBoxNChoices = sizeof( m_PageSizeBoxChoices ) / sizeof( wxString );
	m_PageSizeBox = new wxRadioBox( this, wxID_ANY, _("wxRadioBox"), wxDefaultPosition, wxDefaultSize, m_PageSizeBoxNChoices, m_PageSizeBoxChoices, 1, wxRA_SPECIFY_COLS );
	m_PageSizeBox = new wxRadioBox( this, wxID_ANY, _("Page Size:"), wxDefaultPosition, wxDefaultSize, m_PageSizeBoxNChoices, m_PageSizeBoxChoices, 1, wxRA_SPECIFY_COLS );
	m_PageSizeBox->SetSelection( 1 );
	LeftColumnSizer->Add( m_PageSizeBox, 0, wxALL|wxEXPAND, 5 );
	
+1 −1
Original line number Diff line number Diff line
@@ -113,7 +113,7 @@
                                        <property name="font"></property>
                                        <property name="hidden">0</property>
                                        <property name="id">wxID_ANY</property>
                                        <property name="label">wxRadioBox</property>
                                        <property name="label">Page Size:</property>
                                        <property name="majorDimension">1</property>
                                        <property name="maximum_size"></property>
                                        <property name="minimum_size"></property>
Loading