Eeschema: fix yet another symbol properties dialog layout issue.
Stop trying to make a read only wxTextCtrl with a custom font work for displaying the symbol library identifier and use an ellipsized wxStaticText control with the standard font instead. Fixes https://gitlab.com/kicad/code/kicad/-/issues/6240
This commit is contained in:
parent
6cefec64ea
commit
3dde4e5616
|
@ -343,13 +343,6 @@ DIALOG_SYMBOL_PROPERTIES::DIALOG_SYMBOL_PROPERTIES( SCH_EDIT_FRAME* aParent,
|
|||
|
||||
m_pinGrid->PushEventHandler( new GRID_TRICKS( m_pinGrid ) );
|
||||
|
||||
// Set font size for items showing long strings:
|
||||
wxFont infoFont = wxSystemSettings::GetFont( wxSYS_DEFAULT_GUI_FONT );
|
||||
infoFont.SetSymbolicSize( wxFONTSIZE_SMALL );
|
||||
|
||||
m_libraryIDLabel->SetFont( infoFont );
|
||||
m_tcLibraryID->SetFont( infoFont );
|
||||
|
||||
wxToolTip::Enable( true );
|
||||
m_stdDialogButtonSizerOK->SetDefault();
|
||||
|
||||
|
@ -494,7 +487,7 @@ bool DIALOG_SYMBOL_PROPERTIES::TransferDataToWindow()
|
|||
m_ShowPinNameButt->SetValue( m_part->ShowPinNames() );
|
||||
|
||||
// Set the component's library name.
|
||||
m_tcLibraryID->SetValue( m_comp->GetLibId().Format() );
|
||||
m_tcLibraryID->SetLabelText( m_comp->GetLibId().Format() );
|
||||
|
||||
Layout();
|
||||
|
||||
|
|
|
@ -302,11 +302,9 @@ DIALOG_SYMBOL_PROPERTIES_BASE::DIALOG_SYMBOL_PROPERTIES_BASE( wxWindow* parent,
|
|||
m_libraryIDLabel->Wrap( -1 );
|
||||
bLibLink->Add( m_libraryIDLabel, 0, wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_tcLibraryID = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_READONLY|wxBORDER_NONE );
|
||||
m_tcLibraryID->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_BTNFACE ) );
|
||||
m_tcLibraryID->SetToolTip( _("The library ID and footprint ID currently assigned. Use \"Change Footprint...\" to assign a different footprint.") );
|
||||
|
||||
bLibLink->Add( m_tcLibraryID, 1, wxEXPAND|wxLEFT|wxRIGHT, 5 );
|
||||
m_tcLibraryID = new wxStaticText( this, wxID_ANY, _("MyLabel"), wxDefaultPosition, wxDefaultSize, wxST_ELLIPSIZE_END );
|
||||
m_tcLibraryID->Wrap( -1 );
|
||||
bLibLink->Add( m_tcLibraryID, 1, wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT, 5 );
|
||||
|
||||
|
||||
bSizerBottom->Add( bLibLink, 1, wxEXPAND|wxLEFT, 10 );
|
||||
|
|
|
@ -1973,9 +1973,9 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxLEFT|wxRIGHT</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT|wxRIGHT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
|
@ -1985,7 +1985,7 @@
|
|||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg">wxSYS_COLOUR_BTNFACE</property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
|
@ -2003,10 +2003,11 @@
|
|||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">MyLabel</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="maxlength"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
|
@ -2021,18 +2022,14 @@
|
|||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxTE_READONLY</property>
|
||||
<property name="style">wxST_ELLIPSIZE_END</property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">The library ID and footprint ID currently assigned. Use "Change Footprint..." to assign a different footprint.</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="value"></property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style">wxBORDER_NONE</property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
|
|
|
@ -32,7 +32,6 @@ class WX_GRID;
|
|||
#include <wx/gbsizer.h>
|
||||
#include <wx/panel.h>
|
||||
#include <wx/notebook.h>
|
||||
#include <wx/textctrl.h>
|
||||
#include <wx/dialog.h>
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
@ -71,7 +70,7 @@ class DIALOG_SYMBOL_PROPERTIES_BASE : public DIALOG_SHIM
|
|||
wxPanel* m_pinTablePage;
|
||||
WX_GRID* m_pinGrid;
|
||||
wxStaticText* m_libraryIDLabel;
|
||||
wxTextCtrl* m_tcLibraryID;
|
||||
wxStaticText* m_tcLibraryID;
|
||||
wxButton* m_spiceFieldsButton;
|
||||
wxStdDialogButtonSizer* m_stdDialogButtonSizer;
|
||||
wxButton* m_stdDialogButtonSizerOK;
|
||||
|
|
Loading…
Reference in New Issue