Loading common/copy_to_clipboard.cpp +102 −98 Original line number Diff line number Diff line ///////////////////////////////////////////////////////////////////////////// // Name: copy_to_clipboard.cpp // Author: jean-pierre Charras // Created: 18 aug 2006 Loading Loading @@ -33,6 +34,7 @@ static bool DrawPage(WinEDA_DrawPanel * panel); /************************************************************/ void WinEDA_DrawFrame::CopyToClipboard( wxCommandEvent& event ) /************************************************************/ /* calls the function to copy the current page or the current bock to the clipboard */ { Loading @@ -41,23 +43,27 @@ void WinEDA_DrawFrame::CopyToClipboard(wxCommandEvent& event) if( event.GetId() == ID_GEN_COPY_BLOCK_TO_CLIPBOARD ) { if( GetScreen()->BlockLocate.m_Command != BLOCK_IDLE ) DrawPanel->SetCursor(wxCursor(DrawPanel->m_PanelCursor = DrawPanel->m_PanelDefaultCursor) ); DrawPanel->SetCursor( wxCursor( DrawPanel->m_PanelCursor = DrawPanel->m_PanelDefaultCursor ) ); if( DrawPanel->ManageCurseur && DrawPanel->ForceCloseManageCurseur ) { wxClientDC dc( DrawPanel ); DrawPanel->PrepareGraphicContext( &dc ); DrawPanel->ForceCloseManageCurseur( DrawPanel, &dc ); } } } /*****************************************************************/ bool DrawPage( WinEDA_DrawPanel* panel ) /*****************************************************************/ /* copy the current page or block to the clipboard , to export drawings to other applications (word processing ...) Thi is not suitable for copy command within eeschema or pcbnew * to export drawings to other applications (word processing ...) * Thi is not suitable for copy command within eeschema or pcbnew */ { bool success = TRUE; Loading Loading @@ -99,7 +105,6 @@ wxMetafileDC dc/*(wxT(""), DrawArea.GetWidth(), DrawArea.GetHeight())*/; DisplayError( NULL, wxT( "CopyToClipboard: DrawPage error: wxMetafileDC not OK" ) ); success = FALSE; } else { EDA_Rect tmp = panel->m_ClipBox; Loading Loading @@ -138,4 +143,3 @@ wxMetafileDC dc/*(wxT(""), DrawArea.GetWidth(), DrawArea.GetHeight())*/; return success; } Loading
common/copy_to_clipboard.cpp +102 −98 Original line number Diff line number Diff line ///////////////////////////////////////////////////////////////////////////// // Name: copy_to_clipboard.cpp // Author: jean-pierre Charras // Created: 18 aug 2006 Loading Loading @@ -33,6 +34,7 @@ static bool DrawPage(WinEDA_DrawPanel * panel); /************************************************************/ void WinEDA_DrawFrame::CopyToClipboard( wxCommandEvent& event ) /************************************************************/ /* calls the function to copy the current page or the current bock to the clipboard */ { Loading @@ -41,23 +43,27 @@ void WinEDA_DrawFrame::CopyToClipboard(wxCommandEvent& event) if( event.GetId() == ID_GEN_COPY_BLOCK_TO_CLIPBOARD ) { if( GetScreen()->BlockLocate.m_Command != BLOCK_IDLE ) DrawPanel->SetCursor(wxCursor(DrawPanel->m_PanelCursor = DrawPanel->m_PanelDefaultCursor) ); DrawPanel->SetCursor( wxCursor( DrawPanel->m_PanelCursor = DrawPanel->m_PanelDefaultCursor ) ); if( DrawPanel->ManageCurseur && DrawPanel->ForceCloseManageCurseur ) { wxClientDC dc( DrawPanel ); DrawPanel->PrepareGraphicContext( &dc ); DrawPanel->ForceCloseManageCurseur( DrawPanel, &dc ); } } } /*****************************************************************/ bool DrawPage( WinEDA_DrawPanel* panel ) /*****************************************************************/ /* copy the current page or block to the clipboard , to export drawings to other applications (word processing ...) Thi is not suitable for copy command within eeschema or pcbnew * to export drawings to other applications (word processing ...) * Thi is not suitable for copy command within eeschema or pcbnew */ { bool success = TRUE; Loading Loading @@ -99,7 +105,6 @@ wxMetafileDC dc/*(wxT(""), DrawArea.GetWidth(), DrawArea.GetHeight())*/; DisplayError( NULL, wxT( "CopyToClipboard: DrawPage error: wxMetafileDC not OK" ) ); success = FALSE; } else { EDA_Rect tmp = panel->m_ClipBox; Loading Loading @@ -138,4 +143,3 @@ wxMetafileDC dc/*(wxT(""), DrawArea.GetWidth(), DrawArea.GetHeight())*/; return success; }