Skip to content

Commit

Permalink
[balti] add textbox code
Browse files Browse the repository at this point in the history
  • Loading branch information
fcharlie committed Oct 14, 2018
1 parent edeba88 commit 2ee6a9a
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion sources/baltic/window.cc
Expand Up @@ -234,6 +234,16 @@ Windows::UI::Xaml::UIElement CreateDefaultContent() {
/*container.Background(Windows::UI::Xaml::Media::SolidColorBrush{
* Windows::UI::Colors::LightSlateGray() });*/
container.Background(acrylicBrush);
Windows::UI::Xaml::Controls::TextBox text;
text.Width(600);
text.Height(60);
text.SetValue(Windows::UI::Xaml::FrameworkElement::VerticalAlignmentProperty(),
box_value(Windows::UI::Xaml::VerticalAlignment::Top));

text.SetValue(
Windows::UI::Xaml::FrameworkElement::HorizontalAlignmentProperty(),
box_value(Windows::UI::Xaml::HorizontalAlignment::Center));
container.Children().Append(text);

Windows::UI::Xaml::Controls::Button b;
/*
Expand All @@ -247,7 +257,7 @@ Windows::UI::Xaml::UIElement CreateDefaultContent() {
});
*/
b.Click([](Windows::Foundation::IInspectable const &sender,
Windows::UI::Xaml::RoutedEventArgs const &) {
Windows::UI::Xaml::RoutedEventArgs const &) {
MessageBoxW(nullptr, L"Hello world", L"Balti", MB_OK);
});
b.Width(600);
Expand Down

0 comments on commit 2ee6a9a

Please sign in to comment.