Commit f3b4aff7 authored by jean-pierre charras's avatar jean-pierre charras

Minor fixes: make a message translatable in CvPcb. Dialog choose component:...

Minor fixes: make a message translatable in CvPcb. Dialog choose component: fix a missing min size calculation and make min size bigger.
parent 7f1ea9e5
......@@ -192,7 +192,7 @@ bool CVPCB_MAINFRAME::ReadNetListAndLinkFiles()
// Check if footprint links were generated before the footprint library table was implemented.
if( hasMissingNicks )
{
msg = wxT(
msg = _(
"Some of the assigned footprints are legacy entries (are missing lib nicknames). "
"Would you like CvPcb to attempt to convert them to the new required FPID format? "
"(If you answer no, then these assignments will be cleared out and you will "
......
......@@ -58,9 +58,11 @@ DIALOG_CHOOSE_COMPONENT::DIALOG_CHOOSE_COMPONENT( SCH_BASE_FRAME* aParent, const
m_libraryComponentTree->SetFont( wxFont( font.GetPointSize(),
wxFONTFAMILY_MODERN, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL ) );
// this line fixes an issue on Linux Ubuntu using Unity (dialog not shown),
// and works fine on all systems
GetSizer()->Fit( this );
// We have to call SetSizeHints to fix the minimal size of the dialog
// and its widgets.
// this line also fixes an issue on Linux Ubuntu using Unity (dialog not shown).
GetSizer()->SetSizeHints( this );
Centre();
}
......
......@@ -11,7 +11,7 @@
DIALOG_CHOOSE_COMPONENT_BASE::DIALOG_CHOOSE_COMPONENT_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
{
this->SetSizeHints( wxSize( 450,100 ), wxDefaultSize );
this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
wxBoxSizer* bSizerMain;
bSizerMain = new wxBoxSizer( wxVERTICAL );
......@@ -30,7 +30,7 @@ DIALOG_CHOOSE_COMPONENT_BASE::DIALOG_CHOOSE_COMPONENT_BASE( wxWindow* parent, wx
bSizerMain->Add( bSearchSizer, 0, wxEXPAND, 5 );
m_libraryComponentTree = new wxTreeCtrl( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTR_DEFAULT_STYLE|wxTR_HIDE_ROOT );
m_libraryComponentTree->SetMinSize( wxSize( -1,50 ) );
m_libraryComponentTree->SetMinSize( wxSize( 400,200 ) );
bSizerMain->Add( m_libraryComponentTree, 1, wxALL|wxEXPAND, 5 );
......@@ -38,12 +38,12 @@ DIALOG_CHOOSE_COMPONENT_BASE::DIALOG_CHOOSE_COMPONENT_BASE( wxWindow* parent, wx
bSizerView = new wxBoxSizer( wxHORIZONTAL );
m_componentView = new wxPanel( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxFULL_REPAINT_ON_RESIZE|wxSUNKEN_BORDER );
m_componentView->SetMinSize( wxSize( 150,150 ) );
m_componentView->SetMinSize( wxSize( 200,200 ) );
bSizerView->Add( m_componentView, 4, wxEXPAND | wxALL, 5 );
m_componentDetails = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxSize( -1,-1 ), wxTE_MULTILINE );
m_componentDetails->SetMinSize( wxSize( -1,100 ) );
m_componentDetails->SetMinSize( wxSize( 200,200 ) );
bSizerView->Add( m_componentDetails, 3, wxALL|wxEXPAND, 5 );
......
......@@ -41,10 +41,10 @@
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="maximum_size"></property>
<property name="minimum_size">450,100</property>
<property name="minimum_size">-1,-1</property>
<property name="name">DIALOG_CHOOSE_COMPONENT_BASE</property>
<property name="pos"></property>
<property name="size">450,500</property>
<property name="size">503,500</property>
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER</property>
<property name="subclass">DIALOG_SHIM; dialog_shim.h</property>
<property name="title"></property>
......@@ -315,7 +315,7 @@
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size">-1,50</property>
<property name="minimum_size">400,200</property>
<property name="moveable">1</property>
<property name="name">m_libraryComponentTree</property>
<property name="pane_border">1</property>
......@@ -426,7 +426,7 @@
<property name="maximum_size"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size">150,150</property>
<property name="minimum_size">200,200</property>
<property name="moveable">1</property>
<property name="name">m_componentView</property>
<property name="pane_border">1</property>
......@@ -507,7 +507,7 @@
<property name="maxlength"></property>
<property name="min_size"></property>
<property name="minimize_button">0</property>
<property name="minimum_size">-1,100</property>
<property name="minimum_size">200,200</property>
<property name="moveable">1</property>
<property name="name">m_componentDetails</property>
<property name="pane_border">1</property>
......
......@@ -61,7 +61,7 @@ class DIALOG_CHOOSE_COMPONENT_BASE : public DIALOG_SHIM
public:
DIALOG_CHOOSE_COMPONENT_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = wxEmptyString, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 450,500 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
DIALOG_CHOOSE_COMPONENT_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = wxEmptyString, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 503,500 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
~DIALOG_CHOOSE_COMPONENT_BASE();
};
......
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