Removed non-standard dialog UI control text colors missed in last commit.
This commit is contained in:
parent
0652ab4fd2
commit
1e6a46528d
|
@ -135,7 +135,7 @@ bool WinEDA_PinPropertiesFrame::Create( wxWindow* parent, wxWindowID id, const w
|
|||
void WinEDA_PinPropertiesFrame::CreateControls()
|
||||
{
|
||||
////@begin WinEDA_PinPropertiesFrame content construction
|
||||
// Generated by DialogBlocks, 24/04/2009 14:24:14 (unregistered)
|
||||
// Generated by DialogBlocks, 01/05/2009 16:19:57 (unregistered)
|
||||
|
||||
WinEDA_PinPropertiesFrame* itemDialog1 = this;
|
||||
|
||||
|
@ -161,7 +161,6 @@ void WinEDA_PinPropertiesFrame::CreateControls()
|
|||
|
||||
wxStaticBox* itemStaticBoxSizer9Static = new wxStaticBox(itemDialog1, wxID_ANY, _(" Pin Options :"));
|
||||
wxStaticBoxSizer* itemStaticBoxSizer9 = new wxStaticBoxSizer(itemStaticBoxSizer9Static, wxVERTICAL);
|
||||
itemStaticBoxSizer9Static->SetForegroundColour(wxColour(64, 0, 128));
|
||||
itemBoxSizer3->Add(itemStaticBoxSizer9, 0, wxGROW|wxALL, 5);
|
||||
|
||||
wxBoxSizer* itemBoxSizer10 = new wxBoxSizer(wxHORIZONTAL);
|
||||
|
@ -214,7 +213,6 @@ void WinEDA_PinPropertiesFrame::CreateControls()
|
|||
m_PinOrientStrings.Add(_("Down"));
|
||||
m_PinOrient = new wxRadioBox( itemDialog1, ID_RADIOBOX, _("Pin Orient:"), wxDefaultPosition, wxDefaultSize, m_PinOrientStrings, 1, wxRA_SPECIFY_COLS );
|
||||
m_PinOrient->SetSelection(0);
|
||||
m_PinOrient->SetForegroundColour(wxColour(41, 84, 84));
|
||||
itemBoxSizer17->Add(m_PinOrient, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
|
||||
|
||||
wxBoxSizer* itemBoxSizer24 = new wxBoxSizer(wxVERTICAL);
|
||||
|
@ -243,7 +241,6 @@ void WinEDA_PinPropertiesFrame::CreateControls()
|
|||
m_PinShapeStrings.Add(_("low out"));
|
||||
m_PinShape = new wxRadioBox( itemDialog1, ID_RADIOBOX1, _("Pin Shape:"), wxDefaultPosition, wxDefaultSize, m_PinShapeStrings, 1, wxRA_SPECIFY_COLS );
|
||||
m_PinShape->SetSelection(0);
|
||||
m_PinShape->SetForegroundColour(wxColour(0, 64, 0));
|
||||
itemBoxSizer28->Add(m_PinShape, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
|
||||
|
||||
wxArrayString m_PinElectricalTypeStrings;
|
||||
|
@ -259,7 +256,6 @@ void WinEDA_PinPropertiesFrame::CreateControls()
|
|||
m_PinElectricalTypeStrings.Add(_("Open emit"));
|
||||
m_PinElectricalType = new wxRadioBox( itemDialog1, ID_RADIOBOX2, _("Electrical Type:"), wxDefaultPosition, wxDefaultSize, m_PinElectricalTypeStrings, 1, wxRA_SPECIFY_COLS );
|
||||
m_PinElectricalType->SetSelection(0);
|
||||
m_PinElectricalType->SetForegroundColour(wxColour(68, 68, 34));
|
||||
itemBoxSizer28->Add(m_PinElectricalType, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
|
||||
|
||||
////@end WinEDA_PinPropertiesFrame content construction
|
||||
|
|
|
@ -673,7 +673,7 @@
|
|||
<string name="proxy-Label">" Pin Options :"</string>
|
||||
<string name="proxy-Member variable name">""</string>
|
||||
<string name="proxy-Sizer member variable name">""</string>
|
||||
<string name="proxy-Foreground colour">"400080"</string>
|
||||
<string name="proxy-Foreground colour">""</string>
|
||||
<string name="proxy-Font">""</string>
|
||||
<bool name="proxy-Hidden">0</bool>
|
||||
<bool name="proxy-Enabled">1</bool>
|
||||
|
@ -1519,7 +1519,7 @@
|
|||
<string name="proxy-Help text">""</string>
|
||||
<string name="proxy-Tooltip text">""</string>
|
||||
<string name="proxy-Background colour">""</string>
|
||||
<string name="proxy-Foreground colour">"295454"</string>
|
||||
<string name="proxy-Foreground colour">""</string>
|
||||
<string name="proxy-Font">""</string>
|
||||
<bool name="proxy-Hidden">0</bool>
|
||||
<bool name="proxy-Enabled">1</bool>
|
||||
|
@ -1794,7 +1794,7 @@
|
|||
<string name="proxy-Help text">""</string>
|
||||
<string name="proxy-Tooltip text">""</string>
|
||||
<string name="proxy-Background colour">""</string>
|
||||
<string name="proxy-Foreground colour">"004000"</string>
|
||||
<string name="proxy-Foreground colour">""</string>
|
||||
<string name="proxy-Font">""</string>
|
||||
<bool name="proxy-Hidden">0</bool>
|
||||
<bool name="proxy-Enabled">1</bool>
|
||||
|
@ -1858,7 +1858,7 @@
|
|||
<string name="proxy-Help text">""</string>
|
||||
<string name="proxy-Tooltip text">""</string>
|
||||
<string name="proxy-Background colour">""</string>
|
||||
<string name="proxy-Foreground colour">"444422"</string>
|
||||
<string name="proxy-Foreground colour">""</string>
|
||||
<string name="proxy-Font">""</string>
|
||||
<bool name="proxy-Hidden">0</bool>
|
||||
<bool name="proxy-Enabled">1</bool>
|
||||
|
|
|
@ -148,20 +148,15 @@ dialog_copper_zone_base::dialog_copper_zone_base( wxWindow* parent, wxWindowID i
|
|||
m_RightBoxSizer = new wxBoxSizer( wxVERTICAL );
|
||||
|
||||
m_ExportSetupButton = new wxButton( this, wxID_BUTTON_EXPORT, _("Export Setup to other zones"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_ExportSetupButton->SetForegroundColour( wxColour( 51, 111, 40 ) );
|
||||
m_ExportSetupButton->SetToolTip( _("Export this zone setup to all other copper zones") );
|
||||
|
||||
m_RightBoxSizer->Add( m_ExportSetupButton, 0, wxALL|wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 );
|
||||
|
||||
m_OkButton = new wxButton( this, wxID_OK, _("Ok"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_OkButton->SetDefault();
|
||||
m_OkButton->SetForegroundColour( wxColour( 140, 49, 47 ) );
|
||||
|
||||
m_RightBoxSizer->Add( m_OkButton, 0, wxALL|wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 );
|
||||
|
||||
m_ButtonCancel = new wxButton( this, wxID_CANCEL, _("Cancel"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_ButtonCancel->SetForegroundColour( wxColour( 45, 38, 155 ) );
|
||||
|
||||
m_RightBoxSizer->Add( m_ButtonCancel, 0, wxALL|wxALIGN_CENTER_HORIZONTAL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
|
|
|
@ -919,7 +919,7 @@
|
|||
<property name="context_help"></property>
|
||||
<property name="default">0</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg">51,111,40</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_BUTTON_EXPORT</property>
|
||||
|
@ -971,7 +971,7 @@
|
|||
<property name="context_help"></property>
|
||||
<property name="default">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg">140,49,47</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_OK</property>
|
||||
|
@ -1023,7 +1023,7 @@
|
|||
<property name="context_help"></property>
|
||||
<property name="default">0</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg">45,38,155</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_CANCEL</property>
|
||||
|
|
|
@ -43,24 +43,23 @@ public:
|
|||
|
||||
|
||||
private:
|
||||
void OnOkClick( wxCommandEvent& event );
|
||||
void OnCancelClick( wxCommandEvent& event );
|
||||
void OnOkClick( wxCommandEvent& event );
|
||||
void OnCancelClick( wxCommandEvent& event );
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
};
|
||||
|
||||
BEGIN_EVENT_TABLE( WinEDA_TextPCBPropertiesFrame, wxDialog )
|
||||
EVT_BUTTON( wxID_OK, WinEDA_TextPCBPropertiesFrame::OnOkClick )
|
||||
EVT_BUTTON( wxID_CANCEL, WinEDA_TextPCBPropertiesFrame::OnCancelClick )
|
||||
EVT_BUTTON( wxID_OK, WinEDA_TextPCBPropertiesFrame::OnOkClick )
|
||||
EVT_BUTTON( wxID_CANCEL, WinEDA_TextPCBPropertiesFrame::OnCancelClick )
|
||||
END_EVENT_TABLE()
|
||||
|
||||
|
||||
/******************************************************************************/
|
||||
void WinEDA_PcbFrame::InstallTextPCBOptionsFrame( TEXTE_PCB* TextPCB, wxDC* DC )
|
||||
/*******************************************************************************/
|
||||
{
|
||||
DrawPanel->m_IgnoreMouseEvents = TRUE;
|
||||
WinEDA_TextPCBPropertiesFrame* frame = new WinEDA_TextPCBPropertiesFrame( this, TextPCB, DC );
|
||||
WinEDA_TextPCBPropertiesFrame* frame =
|
||||
new WinEDA_TextPCBPropertiesFrame( this, TextPCB, DC );
|
||||
frame->ShowModal();
|
||||
frame->Destroy();
|
||||
DrawPanel->MouseToCursorSchema();
|
||||
|
@ -68,14 +67,14 @@ void WinEDA_PcbFrame::InstallTextPCBOptionsFrame( TEXTE_PCB* TextPCB, wxDC* DC )
|
|||
}
|
||||
|
||||
|
||||
/************************************************************************************/
|
||||
WinEDA_TextPCBPropertiesFrame::WinEDA_TextPCBPropertiesFrame( WinEDA_PcbFrame* parent,
|
||||
TEXTE_PCB* TextPCB, wxDC* DC ) :
|
||||
wxDialog( parent, -1, _( "TextPCB properties" ), wxDefaultPosition, wxSize( 390, 340 ) )
|
||||
/************************************************************************************/
|
||||
TEXTE_PCB* TextPCB,
|
||||
wxDC* DC ) :
|
||||
wxDialog( parent, -1, _( "TextPCB properties" ), wxDefaultPosition,
|
||||
wxSize( 390, 340 ) )
|
||||
{
|
||||
wxButton* Button;
|
||||
BOARD* board = parent->GetBoard();
|
||||
wxButton* Button;
|
||||
BOARD* board = parent->GetBoard();
|
||||
|
||||
m_Parent = parent;
|
||||
|
||||
|
@ -96,37 +95,38 @@ WinEDA_TextPCBPropertiesFrame::WinEDA_TextPCBPropertiesFrame( WinEDA_PcbFrame* p
|
|||
|
||||
/* Creation des boutons de commande */
|
||||
Button = new wxButton( this, wxID_OK, _( "OK" ) );
|
||||
Button->SetForegroundColour( *wxRED );
|
||||
RightBoxSizer->Add( Button, 0, wxGROW | wxALL, 5 );
|
||||
Button->SetDefault();
|
||||
|
||||
Button = new wxButton( this, wxID_CANCEL, _( "Cancel" ) );
|
||||
Button->SetForegroundColour( *wxBLUE );
|
||||
RightBoxSizer->Add( Button, 0, wxGROW | wxALL, 5 );
|
||||
|
||||
m_Name = new WinEDA_EnterText( this, _( "Text:" ),
|
||||
TextPCB->m_Text,
|
||||
LeftBoxSizer, wxSize( 200, 60 ),true );
|
||||
TextPCB->m_Text,
|
||||
LeftBoxSizer, wxSize( 200, 60 ), true );
|
||||
m_Name->SetFocus();
|
||||
m_Name->SetSelection( -1, -1 );
|
||||
|
||||
m_TxtSizeCtrl = new WinEDA_SizeCtrl( this, _( "Size" ),
|
||||
TextPCB->m_Size,
|
||||
g_UnitMetric, LeftBoxSizer, m_Parent->m_InternalUnits );
|
||||
g_UnitMetric, LeftBoxSizer,
|
||||
m_Parent->m_InternalUnits );
|
||||
|
||||
m_TxtWidthCtlr = new WinEDA_ValueCtrl( this, _( "Width" ),
|
||||
TextPCB->m_Width,
|
||||
g_UnitMetric, LeftBoxSizer, m_Parent->m_InternalUnits );
|
||||
g_UnitMetric, LeftBoxSizer,
|
||||
m_Parent->m_InternalUnits );
|
||||
|
||||
m_TxtPosCtrl = new WinEDA_PositionCtrl( this, _( "Position" ),
|
||||
TextPCB->m_Pos,
|
||||
g_UnitMetric, LeftBoxSizer, m_Parent->m_InternalUnits );
|
||||
g_UnitMetric, LeftBoxSizer,
|
||||
m_Parent->m_InternalUnits );
|
||||
|
||||
m_SelLayerBox = new WinEDAChoiceBox( this, ID_TEXTPCB_SELECT_LAYER,
|
||||
wxDefaultPosition, wxDefaultSize );
|
||||
MiddleBoxSizer->Add( m_SelLayerBox, 0, wxGROW | wxALL, 5 );
|
||||
|
||||
for( int layer=0; layer<NB_LAYERS; ++layer )
|
||||
for( int layer = 0; layer<NB_LAYERS; ++layer )
|
||||
{
|
||||
m_SelLayerBox->Append( board->GetLayerName( layer ) );
|
||||
}
|
||||
|
@ -134,11 +134,13 @@ WinEDA_TextPCBPropertiesFrame::WinEDA_TextPCBPropertiesFrame( WinEDA_PcbFrame* p
|
|||
m_SelLayerBox->SetSelection( TextPCB->GetLayer() );
|
||||
|
||||
|
||||
static const wxString orient_msg[4] = {
|
||||
wxT( "0" ), wxT( "90" ), wxT( "180" ), wxT( "-90" ) };
|
||||
static const wxString orient_msg[4] =
|
||||
{
|
||||
wxT( "0" ), wxT( "90" ), wxT( "180" ), wxT( "-90" )
|
||||
};
|
||||
|
||||
m_Orient = new wxRadioBox( this, -1, _( "Orientation" ),
|
||||
wxDefaultPosition, wxSize( -1, -1 ), 4, orient_msg,
|
||||
m_Orient = new wxRadioBox( this, -1, _( "Orientation" ), wxDefaultPosition,
|
||||
wxSize( -1, -1 ), 4, orient_msg,
|
||||
1, wxRA_SPECIFY_COLS );
|
||||
MiddleBoxSizer->Add( m_Orient, 0, wxGROW | wxALL, 5 );
|
||||
|
||||
|
@ -162,21 +164,21 @@ WinEDA_TextPCBPropertiesFrame::WinEDA_TextPCBPropertiesFrame( WinEDA_PcbFrame* p
|
|||
}
|
||||
|
||||
wxString display_msg[2] = { _( "Normal" ), _( "Mirror" ) };
|
||||
m_Mirror = new wxRadioBox( this, -1, _( "Display" ),
|
||||
wxDefaultPosition, wxSize( -1, -1 ), 2, display_msg,
|
||||
m_Mirror = new wxRadioBox( this, -1, _( "Display" ), wxDefaultPosition,
|
||||
wxSize( -1, -1 ), 2, display_msg,
|
||||
1, wxRA_SPECIFY_COLS );
|
||||
if( TextPCB->m_Mirror )
|
||||
m_Mirror->SetSelection( 1 );
|
||||
MiddleBoxSizer->Add( m_Mirror, 0, wxGROW | wxALL, 5 );
|
||||
|
||||
int style = 0;
|
||||
if (CurrentTextPCB->m_Italic )
|
||||
int style = 0;
|
||||
if( CurrentTextPCB->m_Italic )
|
||||
style = 1;
|
||||
wxString style_msg[] = { _( "Normal" ), _( "Italic" ) };
|
||||
m_Style = new wxRadioBox( this, -1, _( "Style" ),
|
||||
wxDefaultPosition, wxSize( -1, -1 ), 2, style_msg,
|
||||
1, wxRA_SPECIFY_COLS );
|
||||
m_Style->SetSelection(style);
|
||||
m_Style = new wxRadioBox( this, -1, _( "Style" ), wxDefaultPosition,
|
||||
wxSize( -1, -1 ), 2, style_msg,
|
||||
1, wxRA_SPECIFY_COLS );
|
||||
m_Style->SetSelection( style );
|
||||
MiddleBoxSizer->Add( m_Style, 0, wxGROW | wxALL, 5 );
|
||||
|
||||
GetSizer()->Fit( this );
|
||||
|
@ -184,27 +186,24 @@ WinEDA_TextPCBPropertiesFrame::WinEDA_TextPCBPropertiesFrame( WinEDA_PcbFrame* p
|
|||
}
|
||||
|
||||
|
||||
/**********************************************************************/
|
||||
void WinEDA_TextPCBPropertiesFrame::OnCancelClick( wxCommandEvent& WXUNUSED (event) )
|
||||
/**********************************************************************/
|
||||
void WinEDA_TextPCBPropertiesFrame::OnCancelClick( wxCommandEvent& WXUNUSED( event ) )
|
||||
{
|
||||
EndModal( -1 );
|
||||
EndModal( wxID_CANCEL );
|
||||
}
|
||||
|
||||
|
||||
/**************************************************************************************/
|
||||
void WinEDA_TextPCBPropertiesFrame::OnOkClick( wxCommandEvent& event )
|
||||
/**************************************************************************************/
|
||||
{
|
||||
// test for acceptable values for parameters:
|
||||
wxSize newsize = m_TxtSizeCtrl->GetValue();
|
||||
if ( newsize.x < TEXTS_MIN_SIZE )
|
||||
// test for acceptable values for parameters:
|
||||
wxSize newsize = m_TxtSizeCtrl->GetValue();
|
||||
|
||||
if( newsize.x < TEXTS_MIN_SIZE )
|
||||
newsize.x = TEXTS_MIN_SIZE;
|
||||
if ( newsize.y < TEXTS_MIN_SIZE )
|
||||
if( newsize.y < TEXTS_MIN_SIZE )
|
||||
newsize.y = TEXTS_MIN_SIZE;
|
||||
if ( newsize.x > TEXTS_MAX_WIDTH )
|
||||
if( newsize.x > TEXTS_MAX_WIDTH )
|
||||
newsize.x = TEXTS_MAX_WIDTH;
|
||||
if ( newsize.y > TEXTS_MAX_WIDTH )
|
||||
if( newsize.y > TEXTS_MAX_WIDTH )
|
||||
newsize.y = TEXTS_MAX_WIDTH;
|
||||
|
||||
if( m_DC ) // Erase old text on screen
|
||||
|
@ -216,14 +215,15 @@ void WinEDA_TextPCBPropertiesFrame::OnOkClick( wxCommandEvent& event )
|
|||
{
|
||||
CurrentTextPCB->m_Text = m_Name->GetValue();
|
||||
}
|
||||
CurrentTextPCB->m_Pos = m_TxtPosCtrl->GetValue();
|
||||
CurrentTextPCB->m_Size = newsize;
|
||||
CurrentTextPCB->m_Pos = m_TxtPosCtrl->GetValue();
|
||||
CurrentTextPCB->m_Size = newsize;
|
||||
|
||||
CurrentTextPCB->m_Width = m_TxtWidthCtlr->GetValue();
|
||||
|
||||
CurrentTextPCB->m_Width = m_TxtWidthCtlr->GetValue();
|
||||
// test for acceptable values for parameters:
|
||||
int max_tickness = min( CurrentTextPCB->m_Size.x, CurrentTextPCB->m_Size.y);
|
||||
int max_tickness = min( CurrentTextPCB->m_Size.x, CurrentTextPCB->m_Size.y );
|
||||
max_tickness /= 4;
|
||||
if ( CurrentTextPCB->m_Width > max_tickness)
|
||||
if( CurrentTextPCB->m_Width > max_tickness )
|
||||
CurrentTextPCB->m_Width = max_tickness;
|
||||
|
||||
CurrentTextPCB->m_Mirror = (m_Mirror->GetSelection() == 1) ? true : false;
|
||||
|
@ -233,9 +233,8 @@ void WinEDA_TextPCBPropertiesFrame::OnOkClick( wxCommandEvent& event )
|
|||
|
||||
if( m_DC ) // Display new text
|
||||
{
|
||||
CurrentTextPCB->Draw( m_Parent->DrawPanel, m_DC, GR_OR );
|
||||
CurrentTextPCB->Draw( m_Parent->DrawPanel, m_DC, GR_OR );
|
||||
}
|
||||
m_Parent->GetScreen()->SetModify();
|
||||
EndModal( 1 );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue