Add syntax help for text markup.
Fixes https://gitlab.com/kicad/code/kicad/issues/4233
This commit is contained in:
parent
1f68323439
commit
8ef66732e4
|
@ -38,6 +38,7 @@
|
|||
#include <dialog_edit_label_base.h>
|
||||
#include <kicad_string.h>
|
||||
#include <tool/actions.h>
|
||||
#include <html_messagebox.h>
|
||||
|
||||
class SCH_EDIT_FRAME;
|
||||
class SCH_TEXT;
|
||||
|
@ -71,8 +72,9 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
virtual void OnEnterKey( wxCommandEvent& aEvent ) override;
|
||||
void OnCharHook( wxKeyEvent& aEvt );
|
||||
void OnEnterKey( wxCommandEvent& aEvent ) override;
|
||||
void OnCharHook( wxKeyEvent& aEvent );
|
||||
void OnFormattingHelp( wxHyperlinkEvent& aEvent ) override;
|
||||
|
||||
bool TransferDataToWindow() override;
|
||||
bool TransferDataFromWindow() override;
|
||||
|
@ -174,7 +176,10 @@ DIALOG_LABEL_EDITOR::DIALOG_LABEL_EDITOR( SCH_EDIT_FRAME* aParent, SCH_TEXT* aTe
|
|||
m_note2->SetFont( infoFont );
|
||||
}
|
||||
else
|
||||
m_textOffsetNote->Show( false );
|
||||
{
|
||||
m_note1->Show( false );
|
||||
m_note2->Show( false );
|
||||
}
|
||||
|
||||
m_sdbSizer1OK->SetDefault();
|
||||
Layout();
|
||||
|
@ -491,3 +496,77 @@ bool DIALOG_LABEL_EDITOR::TransferDataFromWindow()
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_LABEL_EDITOR::OnFormattingHelp( wxHyperlinkEvent& aEvent )
|
||||
{
|
||||
wxString msg = _(
|
||||
"<table>"
|
||||
" <tr>"
|
||||
" <th>Markup</th>"
|
||||
" <th> </th>"
|
||||
" <th>Result</th>"
|
||||
" </tr>"
|
||||
" <tr>"
|
||||
" <td> <br>^{superscript}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br><sup>superscript</sup></td>"
|
||||
" </tr>"
|
||||
" <tr>"
|
||||
" <td> <br>Driver Board^{Rev A}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br>Driver Board<sup>Rev A</sup></td>"
|
||||
" </tr>"
|
||||
" <tr><td><br></td></tr>"
|
||||
" <tr>"
|
||||
" <td> <br>_{subscript}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br><sub>subscript</sub></td>"
|
||||
" </tr>"
|
||||
" <tr>"
|
||||
" <td> <br>D_{0} - D_{15}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br>D<sub>0</sub> - D<sub>31</sub></td>"
|
||||
" </tr>"
|
||||
" <tr><td></td></tr>"
|
||||
" <tr>"
|
||||
" <td>"
|
||||
" <br>~overbar<br>"
|
||||
" <br>~CLK"
|
||||
" </td>"
|
||||
" <td></td>"
|
||||
" <td>"
|
||||
" <u> </u><br>overbar<br>"
|
||||
" <u> </u><br>CLK"
|
||||
" </td>"
|
||||
" </tr>"
|
||||
" <tr><td><br></td></tr>"
|
||||
" <tr>"
|
||||
" <td> <br>${variable}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br><i>variable_value</i></td>"
|
||||
" </tr>"
|
||||
" <tr>"
|
||||
" <td> <br>${REVISION}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br>2020.1</td>"
|
||||
" </tr>"
|
||||
" <tr><td><br></td></tr>"
|
||||
" <tr>"
|
||||
" <td> <br>${refdes:field}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br><i>field_value</i></td>"
|
||||
" </tr>"
|
||||
" <tr>"
|
||||
" <td> <br>${R3:VALUE}</td>"
|
||||
" <td></td>"
|
||||
" <td> <br>150K</td>"
|
||||
" </tr>"
|
||||
"</table>" );
|
||||
|
||||
HTML_MESSAGE_BOX dlg( GetParent(), _( "Syntax Help" ) );
|
||||
dlg.SetDialogSizeInDU( 180, 280 );
|
||||
|
||||
dlg.AddHTML_Text( msg );
|
||||
dlg.ShowModal();
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
wxBoxSizer* bMainSizer;
|
||||
bMainSizer = new wxBoxSizer( wxVERTICAL );
|
||||
|
||||
m_textEntrySizer = new wxFlexGridSizer( 4, 2, 3, 3 );
|
||||
m_textEntrySizer = new wxFlexGridSizer( 5, 2, 3, 3 );
|
||||
m_textEntrySizer->AddGrowableCol( 1 );
|
||||
m_textEntrySizer->AddGrowableRow( 1 );
|
||||
m_textEntrySizer->SetFlexibleDirection( wxBOTH );
|
||||
|
@ -27,16 +27,16 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
m_labelSingleLine->Wrap( -1 );
|
||||
m_labelSingleLine->SetToolTip( _("Enter the text to be used within the schematic") );
|
||||
|
||||
m_textEntrySizer->Add( m_labelSingleLine, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT, 3 );
|
||||
m_textEntrySizer->Add( m_labelSingleLine, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 3 );
|
||||
|
||||
m_valueSingleLine = new wxTextCtrl( this, wxID_VALUESINGLE, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER|wxTE_RICH );
|
||||
m_valueSingleLine->SetMinSize( wxSize( 360,-1 ) );
|
||||
|
||||
m_textEntrySizer->Add( m_valueSingleLine, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT, 5 );
|
||||
m_textEntrySizer->Add( m_valueSingleLine, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
m_labelMultiLine = new wxStaticText( this, wxID_ANY, _("Text:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_labelMultiLine->Wrap( -1 );
|
||||
m_textEntrySizer->Add( m_labelMultiLine, 0, wxTOP|wxRIGHT, 6 );
|
||||
m_textEntrySizer->Add( m_labelMultiLine, 0, wxTOP|wxRIGHT, 2 );
|
||||
|
||||
m_valueMultiLine = new wxStyledTextCtrl( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxBORDER_SUNKEN, wxEmptyString );
|
||||
m_valueMultiLine->SetUseTabs( true );
|
||||
|
@ -67,7 +67,7 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
m_valueMultiLine->MarkerDefine( wxSTC_MARKNUM_FOLDERTAIL, wxSTC_MARK_EMPTY );
|
||||
m_valueMultiLine->SetSelBackground( true, wxSystemSettings::GetColour( wxSYS_COLOUR_HIGHLIGHT ) );
|
||||
m_valueMultiLine->SetSelForeground( true, wxSystemSettings::GetColour( wxSYS_COLOUR_HIGHLIGHTTEXT ) );
|
||||
m_textEntrySizer->Add( m_valueMultiLine, 1, wxEXPAND|wxTOP|wxBOTTOM|wxLEFT, 5 );
|
||||
m_textEntrySizer->Add( m_valueMultiLine, 1, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
m_labelCombo = new wxStaticText( this, wxID_ANY, _("Label:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_labelCombo->Wrap( -1 );
|
||||
|
@ -76,40 +76,38 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
m_valueCombo = new wxComboBox( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, wxTE_PROCESS_ENTER );
|
||||
m_valueCombo->SetMinSize( wxSize( 360,-1 ) );
|
||||
|
||||
m_textEntrySizer->Add( m_valueCombo, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
||||
m_textEntrySizer->Add( m_valueCombo, 0, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
m_textSizeLabel = new wxStaticText( this, wxID_ANY, _("Text Size:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_textSizeLabel->Wrap( -1 );
|
||||
m_textEntrySizer->Add( m_textSizeLabel, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 3 );
|
||||
m_textEntrySizer->Add( m_textSizeLabel, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT, 6 );
|
||||
|
||||
wxBoxSizer* bSizeCtrlSizer;
|
||||
bSizeCtrlSizer = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_textSizeCtrl = new wxTextCtrl( this, wxID_SIZE, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
bSizeCtrlSizer->Add( m_textSizeCtrl, 0, wxLEFT|wxRIGHT|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
bSizeCtrlSizer->Add( m_textSizeCtrl, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT|wxLEFT, 6 );
|
||||
|
||||
m_textSizeUnits = new wxStaticText( this, wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_textSizeUnits->Wrap( -1 );
|
||||
bSizeCtrlSizer->Add( m_textSizeUnits, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 20 );
|
||||
bSizeCtrlSizer->Add( m_textSizeUnits, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT, 6 );
|
||||
|
||||
|
||||
bSizeCtrlSizer->Add( 0, 0, 0, wxEXPAND, 15 );
|
||||
bSizeCtrlSizer->Add( 0, 0, 1, wxEXPAND, 15 );
|
||||
|
||||
m_textOffsetNote = new wxBoxSizer( wxHORIZONTAL );
|
||||
m_formattingHelp = new wxHyperlinkCtrl( this, wxID_ANY, _("Syntax help"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
bSizeCtrlSizer->Add( m_formattingHelp, 0, wxBOTTOM|wxRIGHT|wxLEFT, 8 );
|
||||
|
||||
|
||||
m_textEntrySizer->Add( bSizeCtrlSizer, 1, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT, 3 );
|
||||
|
||||
m_note1 = new wxStaticText( this, wxID_ANY, _("Note:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_note1->Wrap( -1 );
|
||||
m_textOffsetNote->Add( m_note1, 0, wxBOTTOM|wxRIGHT, 5 );
|
||||
m_textEntrySizer->Add( m_note1, 0, wxTOP|wxRIGHT, 5 );
|
||||
|
||||
m_note2 = new wxStaticText( this, wxID_ANY, _("the margins around the text are controlled by the text\noffset ratio in Schematic Setup > General > Formatting."), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_note2 = new wxStaticText( this, wxID_ANY, _("The margins around the text are controlled by the text offset ratio\nin Schematic Setup > General > Formatting."), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_note2->Wrap( -1 );
|
||||
m_textOffsetNote->Add( m_note2, 0, wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizeCtrlSizer->Add( m_textOffsetNote, 1, wxEXPAND|wxLEFT, 10 );
|
||||
|
||||
|
||||
m_textEntrySizer->Add( bSizeCtrlSizer, 1, wxEXPAND|wxALIGN_CENTER_VERTICAL|wxTOP, 3 );
|
||||
m_textEntrySizer->Add( m_note2, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
|
||||
bMainSizer->Add( m_textEntrySizer, 1, wxEXPAND|wxLEFT|wxRIGHT|wxTOP, 12 );
|
||||
|
@ -161,6 +159,7 @@ DIALOG_LABEL_EDITOR_BASE::DIALOG_LABEL_EDITOR_BASE( wxWindow* parent, wxWindowID
|
|||
// Connect Events
|
||||
m_valueSingleLine->Connect( wxEVT_COMMAND_TEXT_ENTER, wxCommandEventHandler( DIALOG_LABEL_EDITOR_BASE::OnEnterKey ), NULL, this );
|
||||
m_valueCombo->Connect( wxEVT_COMMAND_TEXT_ENTER, wxCommandEventHandler( DIALOG_LABEL_EDITOR_BASE::OnEnterKey ), NULL, this );
|
||||
m_formattingHelp->Connect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( DIALOG_LABEL_EDITOR_BASE::OnFormattingHelp ), NULL, this );
|
||||
}
|
||||
|
||||
DIALOG_LABEL_EDITOR_BASE::~DIALOG_LABEL_EDITOR_BASE()
|
||||
|
@ -168,5 +167,6 @@ DIALOG_LABEL_EDITOR_BASE::~DIALOG_LABEL_EDITOR_BASE()
|
|||
// Disconnect Events
|
||||
m_valueSingleLine->Disconnect( wxEVT_COMMAND_TEXT_ENTER, wxCommandEventHandler( DIALOG_LABEL_EDITOR_BASE::OnEnterKey ), NULL, this );
|
||||
m_valueCombo->Disconnect( wxEVT_COMMAND_TEXT_ENTER, wxCommandEventHandler( DIALOG_LABEL_EDITOR_BASE::OnEnterKey ), NULL, this );
|
||||
m_formattingHelp->Disconnect( wxEVT_COMMAND_HYPERLINK, wxHyperlinkEventHandler( DIALOG_LABEL_EDITOR_BASE::OnFormattingHelp ), NULL, this );
|
||||
|
||||
}
|
||||
|
|
|
@ -72,11 +72,11 @@
|
|||
<property name="name">m_textEntrySizer</property>
|
||||
<property name="non_flexible_grow_mode">wxFLEX_GROWMODE_SPECIFIED</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="rows">4</property>
|
||||
<property name="rows">5</property>
|
||||
<property name="vgap">3</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">3</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -137,7 +137,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM|wxLEFT</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -201,7 +201,7 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">6</property>
|
||||
<property name="border">2</property>
|
||||
<property name="flag">wxTOP|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
|
@ -263,7 +263,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxTOP|wxBOTTOM|wxLEFT</property>
|
||||
<property name="flag">wxEXPAND|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxStyledTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -390,7 +390,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxComboBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -455,8 +455,8 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">3</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT</property>
|
||||
<property name="border">6</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -517,7 +517,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">3</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxTOP</property>
|
||||
<property name="flag">wxEXPAND|wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="minimum_size"></property>
|
||||
|
@ -525,8 +525,8 @@
|
|||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxLEFT|wxRIGHT|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="border">6</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -589,8 +589,8 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">20</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT</property>
|
||||
<property name="border">6</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxTOP|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -652,7 +652,7 @@
|
|||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">15</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="spacer" expanded="1">
|
||||
<property name="height">0</property>
|
||||
<property name="permission">protected</property>
|
||||
|
@ -660,140 +660,193 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">10</property>
|
||||
<property name="flag">wxEXPAND|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="border">8</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxHyperlinkCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="hover_color"></property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Syntax help</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">m_textOffsetNote</property>
|
||||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_formattingHelp</property>
|
||||
<property name="normal_color"></property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Note:</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_note1</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">the margins around the text are controlled by the text
offset ratio in Schematic Setup > General > Formatting.</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_note2</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxHL_DEFAULT_STYLE</property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="url"></property>
|
||||
<property name="visited_color"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnHyperlink">OnFormattingHelp</event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxTOP|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Note:</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_note1</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxTOP|wxRIGHT|wxLEFT|wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">The margins around the text are controlled by the text offset ratio
in Schematic Setup > General > Formatting.</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_note2</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include <wx/textctrl.h>
|
||||
#include <wx/stc/stc.h>
|
||||
#include <wx/combobox.h>
|
||||
#include <wx/hyperlink.h>
|
||||
#include <wx/sizer.h>
|
||||
#include <wx/radiobox.h>
|
||||
#include <wx/button.h>
|
||||
|
@ -51,7 +52,7 @@ class DIALOG_LABEL_EDITOR_BASE : public DIALOG_SHIM
|
|||
wxStaticText* m_textSizeLabel;
|
||||
wxTextCtrl* m_textSizeCtrl;
|
||||
wxStaticText* m_textSizeUnits;
|
||||
wxBoxSizer* m_textOffsetNote;
|
||||
wxHyperlinkCtrl* m_formattingHelp;
|
||||
wxStaticText* m_note1;
|
||||
wxStaticText* m_note2;
|
||||
wxRadioBox* m_TextOrient;
|
||||
|
@ -63,6 +64,7 @@ class DIALOG_LABEL_EDITOR_BASE : public DIALOG_SHIM
|
|||
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
virtual void OnEnterKey( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnFormattingHelp( wxHyperlinkEvent& event ) { event.Skip(); }
|
||||
|
||||
|
||||
public:
|
||||
|
|
Loading…
Reference in New Issue