mirror of https://github.com/odrling/Aegisub
Some changes to subs edit area toolbuttons sizing
Originally committed to SVN as r2003.
This commit is contained in:
parent
c833156e8b
commit
1248cd264f
|
@ -161,19 +161,21 @@ SubsEditBox::SubsEditBox (wxWindow *parent,SubtitlesGrid *gridp) : wxPanel(paren
|
||||||
|
|
||||||
// Middle-bottom sizer
|
// Middle-bottom sizer
|
||||||
MiddleBotSizer = new wxBoxSizer(wxHORIZONTAL);
|
MiddleBotSizer = new wxBoxSizer(wxHORIZONTAL);
|
||||||
MiddleBotSizer->Add(Bold,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Bold,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Italics,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Italics,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Underline,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Underline,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Strikeout,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Strikeout,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(FontName,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(FontName,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->AddSpacer(5);
|
MiddleBotSizer->AddSpacer(5);
|
||||||
MiddleBotSizer->Add(Color1,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Color1,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Color2,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Color2,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Color3,0,wxALIGN_CENTER,0);
|
MiddleBotSizer->Add(Color3,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(Color4,0,wxRIGHT|wxALIGN_CENTER,5);
|
MiddleBotSizer->Add(Color4,0,wxALIGN_CENTER|wxEXPAND,0);
|
||||||
MiddleBotSizer->Add(CommitButton,0,wxRIGHT|wxALIGN_CENTER,10);
|
MiddleBotSizer->AddSpacer(5);
|
||||||
MiddleBotSizer->Add(ByTime,0,wxRIGHT | wxALIGN_CENTER,5);
|
MiddleBotSizer->Add(CommitButton,0,wxALIGN_CENTER,0);
|
||||||
MiddleBotSizer->Add(ByFrame,0,wxRIGHT | wxALIGN_CENTER,5);
|
MiddleBotSizer->AddSpacer(10);
|
||||||
|
MiddleBotSizer->Add(ByTime,0,wxRIGHT | wxALIGN_CENTER | wxEXPAND,5);
|
||||||
|
MiddleBotSizer->Add(ByFrame,0,wxRIGHT | wxALIGN_CENTER | wxEXPAND,5);
|
||||||
|
|
||||||
// Text editor
|
// Text editor
|
||||||
TextEdit = new SubsTextEditCtrl(this,EDIT_BOX,_T(""),wxDefaultPosition,wxSize(300,50));
|
TextEdit = new SubsTextEditCtrl(this,EDIT_BOX,_T(""),wxDefaultPosition,wxSize(300,50));
|
||||||
|
@ -184,7 +186,7 @@ SubsEditBox::SubsEditBox (wxWindow *parent,SubtitlesGrid *gridp) : wxPanel(paren
|
||||||
|
|
||||||
// Main sizer
|
// Main sizer
|
||||||
MainSizer = new wxBoxSizer(wxVERTICAL);
|
MainSizer = new wxBoxSizer(wxVERTICAL);
|
||||||
MainSizer->Add(TopSizer,0,wxEXPAND | wxLEFT | wxRIGHT | wxTOP,3);
|
MainSizer->Add(TopSizer,0,wxEXPAND | wxALL,3);
|
||||||
MainSizer->Add(MiddleSizer,0,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
MainSizer->Add(MiddleSizer,0,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
||||||
MainSizer->Add(MiddleBotSizer,0,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
MainSizer->Add(MiddleBotSizer,0,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
||||||
MainSizer->Add(BottomSizer,1,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
MainSizer->Add(BottomSizer,1,wxEXPAND | wxLEFT | wxRIGHT | wxBOTTOM,3);
|
||||||
|
@ -219,7 +221,7 @@ void SubsEditBox::SetSplitLineMode(wxSize newSize) {
|
||||||
|
|
||||||
if (topWidth >= midMin + botMin) {
|
if (topWidth >= midMin + botMin) {
|
||||||
MainSizer->Detach(MiddleBotSizer);
|
MainSizer->Detach(MiddleBotSizer);
|
||||||
MiddleSizer->Add(MiddleBotSizer);
|
MiddleSizer->Add(MiddleBotSizer,0,wxALIGN_CENTER_VERTICAL);
|
||||||
Layout();
|
Layout();
|
||||||
splitLineMode = false;
|
splitLineMode = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue