Terminal: Layout the find window better
This commit is contained in:
@@ -21,6 +21,7 @@
|
|||||||
#include <GroupLayoutBuilder.h>
|
#include <GroupLayoutBuilder.h>
|
||||||
#include <Locale.h>
|
#include <Locale.h>
|
||||||
#include <RadioButton.h>
|
#include <RadioButton.h>
|
||||||
|
#include <SpaceLayoutItem.h>
|
||||||
#include <String.h>
|
#include <String.h>
|
||||||
#include <TextControl.h>
|
#include <TextControl.h>
|
||||||
|
|
||||||
@@ -50,20 +51,25 @@ FindWindow::FindWindow(BMessenger messenger, const BString& str,
|
|||||||
|
|
||||||
BRadioButton* useSelection = NULL;
|
BRadioButton* useSelection = NULL;
|
||||||
const float spacing = be_control_look->DefaultItemSpacing();
|
const float spacing = be_control_look->DefaultItemSpacing();
|
||||||
AddChild(BGroupLayoutBuilder(B_VERTICAL, 5.0)
|
AddChild(BGroupLayoutBuilder(B_VERTICAL, B_USE_SMALL_SPACING)
|
||||||
.SetInsets(spacing, spacing, spacing, spacing)
|
.SetInsets(spacing, spacing, spacing, spacing)
|
||||||
.Add(BGridLayoutBuilder()
|
.Add(BGridLayoutBuilder(B_USE_SMALL_SPACING, B_USE_SMALL_SPACING)
|
||||||
.Add(fTextRadio = new BRadioButton(B_TRANSLATE("Use text:"),
|
.Add(fTextRadio = new BRadioButton(B_TRANSLATE("Use text:"),
|
||||||
new BMessage(TOGGLE_FIND_CONTROL)), 0, 0)
|
new BMessage(TOGGLE_FIND_CONTROL)), 0, 0)
|
||||||
.Add(fFindLabel = new BTextControl(NULL, NULL, NULL), 1, 0)
|
.Add(fFindLabel = new BTextControl(NULL, NULL, NULL), 1, 0)
|
||||||
.Add(useSelection = new BRadioButton(B_TRANSLATE("Use selection"),
|
.Add(useSelection = new BRadioButton(B_TRANSLATE("Use selection"),
|
||||||
new BMessage(TOGGLE_FIND_CONTROL)), 0, 1))
|
new BMessage(TOGGLE_FIND_CONTROL)), 0, 1))
|
||||||
|
.Add(BSpaceLayoutItem::CreateVerticalStrut(spacing / 4))
|
||||||
.Add(separator)
|
.Add(separator)
|
||||||
|
.Add(BSpaceLayoutItem::CreateVerticalStrut(spacing / 4))
|
||||||
.Add(fForwardSearchBox = new BCheckBox(B_TRANSLATE("Search forward")))
|
.Add(fForwardSearchBox = new BCheckBox(B_TRANSLATE("Search forward")))
|
||||||
.Add(fMatchCaseBox = new BCheckBox(B_TRANSLATE("Match case")))
|
.Add(fMatchCaseBox = new BCheckBox(B_TRANSLATE("Match case")))
|
||||||
.Add(fMatchWordBox = new BCheckBox(B_TRANSLATE("Match word")))
|
.Add(fMatchWordBox = new BCheckBox(B_TRANSLATE("Match word")))
|
||||||
.Add(fFindButton = new BButton(B_TRANSLATE("Find"),
|
.AddGroup(B_HORIZONTAL)
|
||||||
|
.AddGlue()
|
||||||
|
.Add(fFindButton = new BButton(B_TRANSLATE("Find"),
|
||||||
new BMessage(MSG_FIND)))
|
new BMessage(MSG_FIND)))
|
||||||
|
.End()
|
||||||
.TopView());
|
.TopView());
|
||||||
|
|
||||||
fFindLabel->SetDivider(0.0);
|
fFindLabel->SetDivider(0.0);
|
||||||
|
|||||||
Reference in New Issue
Block a user