Oos, sorry, mistype in patch. Correct patch attached.

On 11.03.2013 16:17, Sergey A. Borshch wrote:
This patch makes scale option "fit to page" do the same as in all other programs
worldwide - produce biggest image that still fits to page.
  Pcbnew generates 1:1-scaled centered image instead.

--
Regards,
  Sergey A. Borshch            mailto: sb...@sourceforge.net
    SB ELDI ltd. Riga, Latvia
=== modified file 'pcbnew/printout_controler.cpp'
--- pcbnew/printout_controler.cpp       2013-02-12 17:41:13 +0000
+++ pcbnew/printout_controler.cpp       2013-03-10 21:38:01 +0000
@@ -194,7 +194,9 @@
 
     if( m_PrintParams.m_PrintScale == 0 )                //  fit in page
     {
-        userscale = 1.0;
+        double scaleX = m_Parent->GetPageSizeIU().x / 
boardBoundingBox.GetWidth();
+        double scaleY = m_Parent->GetPageSizeIU().y / 
boardBoundingBox.GetWidth();
+        userscale = scaleX < scaleY ? scaleX : scaleY;
     }

_______________________________________________
Mailing list: https://launchpad.net/~kicad-developers
Post to     : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp

Reply via email to