← Back to team overview

kicad-developers team mailing list archive

Re: [PATCH] - DIALOG_PAGES_SETTINGS - fix custom page size setup.

 

On 03/30/2012 11:53 PM, Alexander Zakamaldin wrote:
> It's not possible to set up custom page size from the first attempt. Need to reenter page setup dialog and confirm selected sizes.
>
> Alexander.
> custom_page_setup.diff
>
>
> === modified file 'common/dialogs/dialog_page_settings.cpp'
> --- common/dialogs/dialog_page_settings.cpp	2012-03-27 16:41:13 +0000
> +++ common/dialogs/dialog_page_settings.cpp	2012-03-29 15:18:52 +0000
> @@ -438,6 +438,9 @@
>  
>              PAGE_INFO::SetCustomWidthMils( m_layout_size.x );
>              PAGE_INFO::SetCustomHeightMils( m_layout_size.y );
> +            m_pageInfo.SetWidthMils( m_layout_size.x );
> +            m_pageInfo.SetHeightMils( m_layout_size.y );

The following line is redundant, Set{Height,Width}Mils() track orientation just fine since
they call private updatePortrait()

> +            m_pageInfo.SetPortrait( m_layout_size.x < m_layout_size.y );
>          }
>      }
>      else
>




References